Skip to content

Commit

Permalink
Fix functions with empty params (qmk#19647)
Browse files Browse the repository at this point in the history
* Fix functions with empty params

* Found a bunch more
  • Loading branch information
fauxpark authored and omikronik committed Jan 22, 2023
1 parent 609c26b commit b5b3d42
Show file tree
Hide file tree
Showing 170 changed files with 276 additions and 276 deletions.
2 changes: 1 addition & 1 deletion docs/gpio_control.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ The above functions are not always guaranteed to work atomically. Therefore, if

eg.
```c
void some_function() {
void some_function(void) {
// some process
ATOMIC_BLOCK_FORCEON {
// Atomic Processing
Expand Down
2 changes: 1 addition & 1 deletion docs/quantum_painter_lvgl.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ To init. the display please read the [Display Initialisation](quantum_painter.md
### Quantum Painter LVGL Detach :id=lvgl-api-init

```c
void qp_lvgl_detach()
void qp_lvgl_detach(void)
```
The `qp_lvgl_detach` function stops the internal LVGL ticks and releases resources related to it.
Expand Down
2 changes: 1 addition & 1 deletion drivers/lcd/hd44780.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ void hd44780_on(bool cursor, bool blink) {
}
}

void hd44780_off() {
void hd44780_off(void) {
hd44780_command(HD44780_CMD_DISPLAY);
}

Expand Down
2 changes: 1 addition & 1 deletion drivers/sensors/adns9800.c
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ uint8_t adns9800_read(uint8_t reg_addr) {
return data;
}

void adns9800_init() {
void adns9800_init(void) {
setPinOutput(ADNS9800_CS_PIN);

spi_init();
Expand Down
2 changes: 1 addition & 1 deletion drivers/sensors/cirque_pinnacle.c
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ void cirque_pinnacle_scale_data(pinnacle_data_t* coordinates, uint16_t xResoluti
}

// Clears Status1 register flags (SW_CC and SW_DR)
void cirque_pinnacle_clear_flags() {
void cirque_pinnacle_clear_flags(void) {
RAP_Write(HOSTREG__STATUS1, HOSTREG__STATUS1_DEFVAL & ~(HOSTREG__STATUS1__COMMAND_COMPLETE | HOSTREG__STATUS1__DATA_READY));
wait_us(50);
}
Expand Down
8 changes: 4 additions & 4 deletions drivers/usb2422.c
Original file line number Diff line number Diff line change
Expand Up @@ -344,7 +344,7 @@ static void USB2422_write_block(void) {

// ***************************************************************

void USB2422_init() {
void USB2422_init(void) {
#ifdef USB2422_RESET_PIN
setPinOutput(USB2422_RESET_PIN);
#endif
Expand All @@ -355,7 +355,7 @@ void USB2422_init() {
i2c_init(); // IC2 clk must be high at USB2422 reset release time to signal SMB configuration
}

void USB2422_configure() {
void USB2422_configure(void) {
static const char SERNAME[] = "Unavailable";

memset(&config, 0, sizeof(Usb2422_t));
Expand Down Expand Up @@ -385,15 +385,15 @@ void USB2422_configure() {
USB2422_write_block();
}

void USB2422_reset() {
void USB2422_reset(void) {
#ifdef USB2422_RESET_PIN
writePinLow(USB2422_RESET_PIN);
wait_us(2);
writePinHigh(USB2422_RESET_PIN);
#endif
}

bool USB2422_active() {
bool USB2422_active(void) {
#ifdef USB2422_ACTIVE_PIN
return readPin(USB2422_ACTIVE_PIN);
#else
Expand Down
4 changes: 2 additions & 2 deletions keyboards/40percentclub/gherkin/keymaps/mjt/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -174,13 +174,13 @@ void matrix_init_user(void) {

#ifdef AUDIO_ENABLE

void startup_user()
void startup_user(void)
{
_delay_ms(20); // gets rid of tick
PLAY_SONG(tone_startup);
}

void shutdown_user()
void shutdown_user(void)
{
PLAY_SONG(tone_goodbye);
_delay_ms(150);
Expand Down
2 changes: 1 addition & 1 deletion keyboards/40percentclub/gherkin/keymaps/steno/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
STN_NUM, STN_NUM, STN_A, STN_O, STN_NUM, STN_E, STN_U, STN_NUM, STN_NUM, STN_NUM),
};

void matrix_init_user() {
void matrix_init_user(void) {
steno_set_mode(STENO_MODE_GEMINI); // or STENO_MODE_BOLT
}
2 changes: 1 addition & 1 deletion keyboards/40percentclub/mf68/keymaps/delivrance/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ void led_set_user(uint8_t usb_led) {
static uint32_t timer;
static bool is_idle;

void matrix_scan_user() {
void matrix_scan_user(void) {
// Check the timer only if the keyboard is not idle
if (!is_idle) {
if (timer_elapsed32(timer) >= (uint32_t) BACKLIGHT_IDLE_TIMEOUT * 1000) {
Expand Down
2 changes: 1 addition & 1 deletion keyboards/40percentclub/ut47/ut47.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#ifdef LED_ENABLE
#include "uart.h"

void matrix_init_kb() {
void matrix_init_kb(void) {
uart_init(9600);
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion keyboards/annepro2/annepro2.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ void keyboard_post_init_kb(void) {
keyboard_post_init_user();
}

void matrix_scan_kb() {
void matrix_scan_kb(void) {
// if there's stuff on the ble serial buffer
// read it into the capslock struct
while (!sdGetWouldBlock(&SD1)) {
Expand Down
12 changes: 6 additions & 6 deletions keyboards/annepro2/ap2_led.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,15 +60,15 @@ void ap2_led_enable(void) { proto_tx(CMD_LED_ON, NULL, 0, 3); }

void ap2_led_set_profile(uint8_t prof) { proto_tx(CMD_LED_SET_PROFILE, &prof, sizeof(prof), 3); }

void ap2_led_get_status() { proto_tx(CMD_LED_GET_STATUS, NULL, 0, 3); }
void ap2_led_get_status(void) { proto_tx(CMD_LED_GET_STATUS, NULL, 0, 3); }

void ap2_led_next_profile() { proto_tx(CMD_LED_NEXT_PROFILE, NULL, 0, 3); }
void ap2_led_next_profile(void) { proto_tx(CMD_LED_NEXT_PROFILE, NULL, 0, 3); }

void ap2_led_next_intensity() { proto_tx(CMD_LED_NEXT_INTENSITY, NULL, 0, 3); }
void ap2_led_next_intensity(void) { proto_tx(CMD_LED_NEXT_INTENSITY, NULL, 0, 3); }

void ap2_led_next_animation_speed() { proto_tx(CMD_LED_NEXT_ANIMATION_SPEED, NULL, 0, 3); }
void ap2_led_next_animation_speed(void) { proto_tx(CMD_LED_NEXT_ANIMATION_SPEED, NULL, 0, 3); }

void ap2_led_prev_profile() { proto_tx(CMD_LED_PREV_PROFILE, NULL, 0, 3); }
void ap2_led_prev_profile(void) { proto_tx(CMD_LED_PREV_PROFILE, NULL, 0, 3); }

void ap2_led_mask_set_key(uint8_t row, uint8_t col, ap2_led_t color) {
uint8_t payload[] = {row, col, color.p.blue, color.p.green, color.p.red, color.p.alpha};
Expand Down Expand Up @@ -127,7 +127,7 @@ void ap2_led_set_foreground_color(uint8_t red, uint8_t green, uint8_t blue) {
ap2_led_mask_set_mono(color);
}

void ap2_led_reset_foreground_color() {
void ap2_led_reset_foreground_color(void) {
ap2_led_t color = {
.p.red = 0,
.p.green = 0,
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bemeier/bmek/bmek.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include "bmek.h"

__attribute__((weak))
void shutdown_user() {
void shutdown_user(void) {
#ifdef RGBLIGHT_ENABLE
rgblight_setrgb(255, 0, 0);
#endif
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bpiphany/frosty_flake/20130602/20130602.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "frosty_flake.h"

void keyboard_pre_init_kb() {
void keyboard_pre_init_kb(void) {
setPinOutput(B7); // caps lock
writePinHigh(B7);
setPinOutput(C5); // num lock
Expand Down
2 changes: 1 addition & 1 deletion keyboards/bpiphany/frosty_flake/20140521/20140521.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "frosty_flake.h"

void keyboard_pre_init_kb() {
void keyboard_pre_init_kb(void) {
setPinOutput(B7); // num lock
writePinHigh(B7);
setPinOutput(C5); // caps lock
Expand Down
4 changes: 2 additions & 2 deletions keyboards/cannonkeys/satisfaction75/satisfaction75.c
Original file line number Diff line number Diff line change
Expand Up @@ -361,11 +361,11 @@ void custom_config_reset(void){
eeprom_update_byte((uint8_t*)EEPROM_ENABLED_ENCODER_MODES, 0x1F);
}

void backlight_config_save(){
void backlight_config_save(void){
eeprom_update_byte((uint8_t*)EEPROM_CUSTOM_BACKLIGHT, kb_backlight_config.raw);
}

void custom_config_load(){
void custom_config_load(void){
kb_backlight_config.raw = eeprom_read_byte((uint8_t*)EEPROM_CUSTOM_BACKLIGHT);
#ifdef DYNAMIC_KEYMAP_ENABLE
oled_mode = eeprom_read_byte((uint8_t*)EEPROM_DEFAULT_OLED);
Expand Down
10 changes: 5 additions & 5 deletions keyboards/cannonkeys/satisfaction75/satisfaction_encoder.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "satisfaction75.h"
#include "eeprom.h"

void pre_encoder_mode_change(){
void pre_encoder_mode_change(void){
if(encoder_mode == ENC_MODE_CLOCK_SET){
RTCDateTime timespec;
timespec.year = year_config;
Expand All @@ -16,7 +16,7 @@ void pre_encoder_mode_change(){
}
}

void post_encoder_mode_change(){
void post_encoder_mode_change(void){
if(encoder_mode == ENC_MODE_CLOCK_SET){
hour_config = (last_minute / 60);
minute_config = last_minute % 60;
Expand Down Expand Up @@ -86,7 +86,7 @@ void update_time_config(int8_t increment){
}
}

uint16_t handle_encoder_clockwise(){
uint16_t handle_encoder_clockwise(void){
uint16_t mapped_code = 0;
switch(encoder_mode){
default:
Expand Down Expand Up @@ -130,7 +130,7 @@ uint16_t handle_encoder_clockwise(){
return mapped_code;
}

uint16_t handle_encoder_ccw(){
uint16_t handle_encoder_ccw(void){
uint16_t mapped_code = 0;
switch(encoder_mode){
default:
Expand Down Expand Up @@ -175,7 +175,7 @@ uint16_t handle_encoder_ccw(){
return mapped_code;
}

uint16_t handle_encoder_press(){
uint16_t handle_encoder_press(void){
uint16_t mapped_code = 0;
switch(encoder_mode){
case ENC_MODE_VOLUME:
Expand Down
4 changes: 2 additions & 2 deletions keyboards/cannonkeys/satisfaction75/satisfaction_oled.c
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ static char* get_date(void) {
return date_str;
}

void draw_default() {
void draw_default(void) {
oled_write_P(PSTR("LAYER "), false);
oled_write_char(get_highest_layer(layer_state) + 0x30, true);

Expand Down Expand Up @@ -220,7 +220,7 @@ void draw_default() {
draw_line_v(71, 0, 8);
}

void draw_clock() {
void draw_clock(void) {
oled_set_cursor(0, 0);
oled_write(get_date(), false);
oled_set_cursor(0, 2);
Expand Down
2 changes: 1 addition & 1 deletion keyboards/capsunlocked/cu75/cu75.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ bool process_record_kb(uint16_t keycode, keyrecord_t* record)
return process_record_user(keycode, record);
}

void reset_keyboard_kb(){
void reset_keyboard_kb(void){
#ifdef WATCHDOG_ENABLE
MCUSR = 0;
wdt_disable();
Expand Down
6 changes: 3 additions & 3 deletions keyboards/converter/adb_usb/adb.c
Original file line number Diff line number Diff line change
Expand Up @@ -238,15 +238,15 @@ void adb_host_kbd_led(uint8_t led) {
}

#ifdef ADB_PSW_BIT
static inline void psw_lo() {
static inline void psw_lo(void) {
ADB_DDR |= (1 << ADB_PSW_BIT);
ADB_PORT &= ~(1 << ADB_PSW_BIT);
}
static inline void psw_hi() {
static inline void psw_hi(void) {
ADB_PORT |= (1 << ADB_PSW_BIT);
ADB_DDR &= ~(1 << ADB_PSW_BIT);
}
static inline bool psw_in() {
static inline bool psw_in(void) {
ADB_PORT |= (1 << ADB_PSW_BIT);
ADB_DDR &= ~(1 << ADB_PSW_BIT);
return ADB_PIN & (1 << ADB_PSW_BIT);
Expand Down
2 changes: 1 addition & 1 deletion keyboards/converter/hp_46010a/matrix.c
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ void Matrix_ThrowByte(void) {
return ;
}

void matrix_init () {
void matrix_init (void) {
// debug_matrix = 1;
// PB0 (SS) and PB1 (SCLK) set to outputs
DDRB |= RESET | SCLK ;
Expand Down
2 changes: 1 addition & 1 deletion keyboards/converter/ibm_terminal/keymaps/priyadi/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,6 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
return true;
}

void matrix_init_user() {
void matrix_init_user(void) {
set_unicode_input_mode(UNICODE_MODE_LINUX);
}
12 changes: 6 additions & 6 deletions keyboards/converter/m0110_usb/m0110.c
Original file line number Diff line number Diff line change
Expand Up @@ -318,31 +318,31 @@ static inline uint8_t instant(void) {
return data;
}

static inline void clock_lo() {
static inline void clock_lo(void) {
M0110_CLOCK_PORT &= ~(1 << M0110_CLOCK_BIT);
M0110_CLOCK_DDR |= (1 << M0110_CLOCK_BIT);
}
static inline void clock_hi() {
static inline void clock_hi(void) {
/* input with pull up */
M0110_CLOCK_DDR &= ~(1 << M0110_CLOCK_BIT);
M0110_CLOCK_PORT |= (1 << M0110_CLOCK_BIT);
}
static inline bool clock_in() {
static inline bool clock_in(void) {
M0110_CLOCK_DDR &= ~(1 << M0110_CLOCK_BIT);
M0110_CLOCK_PORT |= (1 << M0110_CLOCK_BIT);
_delay_us(1);
return M0110_CLOCK_PIN & (1 << M0110_CLOCK_BIT);
}
static inline void data_lo() {
static inline void data_lo(void) {
M0110_DATA_PORT &= ~(1 << M0110_DATA_BIT);
M0110_DATA_DDR |= (1 << M0110_DATA_BIT);
}
static inline void data_hi() {
static inline void data_hi(void) {
/* input with pull up */
M0110_DATA_DDR &= ~(1 << M0110_DATA_BIT);
M0110_DATA_PORT |= (1 << M0110_DATA_BIT);
}
static inline bool data_in() {
static inline bool data_in(void) {
M0110_DATA_DDR &= ~(1 << M0110_DATA_BIT);
M0110_DATA_PORT |= (1 << M0110_DATA_BIT);
_delay_us(1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ void oled_render_keylog(void) {
oled_write((const char *)&logged_char, false);
}

void render_master_oled() {
void render_master_oled(void) {
if (timer_elapsed32(oled_timer) > CUSTOM_OLED_TIMEOUT) {
oled_off();
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#include "jpe230.h"

void render_slave_oled() {
void render_slave_oled(void) {
static const char PROGMEM crkbd_logo[] = {
0x80, 0x81, 0x82, 0x83, 0x84, 0x85, 0x86, 0x87, 0x88, 0x89, 0x8a, 0x8b, 0x8c, 0x8d, 0x8e, 0x8f, 0x90, 0x91, 0x92, 0x93, 0x94,
0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa6, 0xa7, 0xa8, 0xa9, 0xaa, 0xab, 0xac, 0xad, 0xae, 0xaf, 0xb0, 0xb1, 0xb2, 0xb3, 0xb4,
Expand Down
2 changes: 1 addition & 1 deletion keyboards/crkbd/keymaps/jpe230/oled/oled_handler.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ __attribute__ ((weak)) void handle_oled_keypress(uint16_t keycode, keyrecord_t *
__attribute__ ((weak)) oled_rotation_t rotate_master(oled_rotation_t rotation) {return rotation;}
__attribute__ ((weak)) oled_rotation_t rotate_slave(oled_rotation_t rotation) {return rotation;}

void oled_timer_reset() { oled_timer = timer_read32(); }
void oled_timer_reset(void) { oled_timer = timer_read32(); }

oled_rotation_t oled_init_user(oled_rotation_t rotation) {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ void oled_render_layer_state(void) {

}

void render_master_oled() {
void render_master_oled(void) {
if (timer_elapsed32(oled_timer) > CUSTOM_OLED_TIMEOUT) {
oled_off();
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include "jpe230.h"
#include "ocean_dream.h"

void render_slave_oled() {
void render_slave_oled(void) {
render_stars();
}

Expand Down
Loading

0 comments on commit b5b3d42

Please sign in to comment.