staging: wilc1000: fix multiple checkpatch errors
PATCH 1/1 staging: wilc1000: fix multiple checkpatch errors
Address the following checkpatch errors:
* ERROR: "(foo*)" should be "(foo *)"
* ERROR: space required after that ',' (ctx:VxV)
* ERROR: spaces prohibited around that '->' (ctx:WxV)
* ERROR: do not initialise statics to false
* ERROR: do not initialise statics to 0x00
--- drivers/staging/wilc1000/host_interface.c | 2 +- drivers/staging/wilc1000/wilc_spi.c | 9 ++++++--- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 4 ++-- drivers/staging/wilc1000/wilc_wlan.c | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-)
drivers/staging/wilc1000/host_interface.c +1 -1
@@ -2679,7 +2679,7 @@ static int hostIFthread(void *pvArg) {u32 u32Ret;struct host_if_msg msg; -struct wilc *wilc = (struct wilc *)pvArg; +struct wilc *wilc = (struct wilc *)pvArg;struct wilc_vif *vif;memset (&msg,0 ,sizeof (struct host_if_msg ));
drivers/staging/wilc1000/wilc_spi.c +6 -3
@@ -514,7 +514,8 @@ static int spi_cmd_complete(struct wilc *wilc, u8 cmd, u32 adr, u8 *b, u32 sz, crc[0 ] = rb[rix++]; crc[1 ] = rb[rix++]; }else { -dev_err (&spi->dev,"buffer overrun when reading crc.\n" ); +dev_err (&spi->dev, +"buffer overrun when reading crc.\n" ); result =N_FAIL ;return result; }
@@ -680,7 +681,8 @@ static int spi_data_write(struct wilc *wilc, u8 *b, u32 sz)**/ if (!g_spi.crc_off) {if (wilc_spi_tx (wilc, crc,2 )) { -dev_err (&spi->dev,"Failed data block crc write, bus error...\n" ); +dev_err (&spi->dev, +"Failed data block crc write, bus error...\n" ); result =N_FAIL ;break ; }
@@ -1074,7 +1076,8 @@ static int wilc_spi_clear_int_ext(struct wilc *wilc, u32 val) ret =wilc_spi_write_reg (wilc,WILC_VMM_CORE_CTL ,1 );if (!ret) { -dev_err (&spi->dev,"fail write reg vmm_core_ctl...\n" ); +dev_err (&spi->dev, +"fail write reg vmm_core_ctl...\n" ); goto _fail_; } }
drivers/staging/wilc1000/wilc_wfi_cfgoperations.c +2 -2
@@ -157,7 +157,7 @@ static u8 wlan_channel = INVALID_CHANNEL;static u8 curr_channel;static u8 p2p_oui[] = {0x50 ,0x6f ,0x9A ,0x09 };static u8 p2p_local_random =0x01 ; -static u8 p2p_recv_random =0x00 ; +static u8 p2p_recv_random;static u8 p2p_vendor_spec[] = {0xdd ,0x05 ,0x00 ,0x08 ,0x40 ,0x03 };static bool wilc_ie;
@@ -2126,7 +2126,7 @@ static int start_ap(struct wiphy *wiphy, struct net_device *dev, priv =wiphy_priv (wiphy); vif =netdev_priv (dev); - wl = vif ->wilc; + wl = vif->wilc;PRINT_D (HOSTAPD_DBG ,"Starting ap\n" ); PRINT_D(HOSTAPD_DBG, "Interval = %d\n DTIM period = %d\n Head length = %zu Tail length = %zu\n",
drivers/staging/wilc1000/wilc_wlan.c +1 -1
@@ -325,7 +325,7 @@ static int wilc_wlan_txq_filter_dup_tcp_ack(struct net_device *dev)return 1 ; } -static bool enabled = false; +static bool enabled;void wilc_enable_tcp_ack_filter (bool value) {
Signature · 1 line
1.9.1
Quoted 6 lines · Eva Rachel Retuya
Address the following checkpatch errors:
* ERROR: "(foo*)" should be "(foo *)"
* ERROR: space required after that ',' (ctx:VxV)
* ERROR: spaces prohibited around that '->' (ctx:WxV)
* ERROR: do not initialise statics to false
* ERROR: do not initialise statics to0x00
This should be a patch series. Each patch should only do one thing. Perhaps you could put all the whitespace ones together, and all the initialization ones together. But they should not all be in one patch.
julia
Quoted 100 lines
Signed-off-by Eva Rachel Retuya <[email protected]>--- drivers/staging/wilc1000/host_interface.c | 2 +- drivers/staging/wilc1000/wilc_spi.c | 9 ++++++--- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 4 ++-- drivers/staging/wilc1000/wilc_wlan.c | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-)drivers/staging/wilc1000/host_interface.c +1
-1@@ -2679,7 +2679,7 @@ static int hostIFthread(void *pvArg) {u32 u32Ret;struct host_if_msg msg; -struct wilc *wilc = (struct wilc *)pvArg; +struct wilc *wilc = (struct wilc *)pvArg;struct wilc_vif *vif;memset (&msg,0 ,sizeof (struct host_if_msg ));drivers/staging/wilc1000/wilc_spi.c +6
-3@@ -514,7 +514,8 @@ static int spi_cmd_complete(struct wilc *wilc, u8 cmd, u32 adr, u8 *b, u32 sz, crc[0 ] = rb[rix++]; crc[1 ] = rb[rix++]; }else { -dev_err (&spi->dev,"buffer overrun when reading crc.\n" ); +dev_err (&spi->dev, +"buffer overrun when reading crc.\n" ); result =N_FAIL ;return result; }@@ -680,7 +681,8 @@ static int spi_data_write(struct wilc *wilc, u8 *b, u32 sz)**/ if (!g_spi.crc_off) {if (wilc_spi_tx (wilc, crc,2 )) { -dev_err (&spi->dev,"Failed data block crc write, bus error...\n" ); +dev_err (&spi->dev, +"Failed data block crc write, bus error...\n" ); result =N_FAIL ;break ; }@@ -1074,7 +1076,8 @@ static int wilc_spi_clear_int_ext(struct wilc *wilc, u32 val) ret =wilc_spi_write_reg (wilc,WILC_VMM_CORE_CTL ,1 );if (!ret) { -dev_err (&spi->dev,"fail write reg vmm_core_ctl...\n" ); +dev_err (&spi->dev, +"fail write reg vmm_core_ctl...\n" ); goto _fail_; } }drivers/staging/wilc1000/wilc_wfi_cfgoperations.c +2
-2@@ -157,7 +157,7 @@ static u8 wlan_channel = INVALID_CHANNEL;static u8 curr_channel;static u8 p2p_oui[] = {0x50 ,0x6f ,0x9A ,0x09 };static u8 p2p_local_random =0x01 ; -static u8 p2p_recv_random =0x00 ; +static u8 p2p_recv_random;static u8 p2p_vendor_spec[] = {0xdd ,0x05 ,0x00 ,0x08 ,0x40 ,0x03 };static bool wilc_ie;@@ -2126,7 +2126,7 @@ static int start_ap(struct wiphy *wiphy, struct net_device *dev, priv =wiphy_priv (wiphy); vif =netdev_priv (dev); - wl = vif ->wilc; + wl = vif->wilc;PRINT_D (HOSTAPD_DBG ,"Starting ap\n" ); PRINT_D(HOSTAPD_DBG, "Interval = %d\n DTIM period = %d\n Head length = %zu Tail length = %zu\n",drivers/staging/wilc1000/wilc_wlan.c +1
-1@@ -325,7 +325,7 @@ static int wilc_wlan_txq_filter_dup_tcp_ack(struct net_device *dev)return 1 ; } -static bool enabled = false; +static bool enabled;void wilc_enable_tcp_ack_filter (bool value) {Signature · 8 lines
1.9.1 -- You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1455419372-6149-1-git-send-email-eraretuya%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Quoted 11 lines · Julia Lawall
Quoted 6 lines · Eva Rachel Retuya
Address the following checkpatch errors:
* ERROR: "(foo*)" should be "(foo *)"
* ERROR: space required after that ',' (ctx:VxV)
* ERROR: spaces prohibited around that '->' (ctx:WxV)
* ERROR: do not initialise statics to false
* ERROR: do not initialise statics to0x00
Quoted 6 lines
This should be a patch series. Each patch should only do one thing. Perhaps you could put all the whitespace ones together, and all the initialization ones together. But they should not all be in one patch.
julia
Will be sending a v2 shortly.
Thank you for the input,
Eva
Quoted 100 lines
Quoted 100 lines
Signed-off-by Eva Rachel Retuya <[email protected]>--- drivers/staging/wilc1000/host_interface.c | 2 +- drivers/staging/wilc1000/wilc_spi.c | 9 ++++++--- drivers/staging/wilc1000/wilc_wfi_cfgoperations.c | 4 ++-- drivers/staging/wilc1000/wilc_wlan.c | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-)drivers/staging/wilc1000/host_interface.c +1
-1@@ -2679,7 +2679,7 @@ static int hostIFthread(void *pvArg) {u32 u32Ret;struct host_if_msg msg; -struct wilc *wilc = (struct wilc *)pvArg; +struct wilc *wilc = (struct wilc *)pvArg;struct wilc_vif *vif;memset (&msg,0 ,sizeof (struct host_if_msg ));drivers/staging/wilc1000/wilc_spi.c +6
-3@@ -514,7 +514,8 @@ static int spi_cmd_complete(struct wilc *wilc, u8 cmd, u32 adr, u8 *b, u32 sz, crc[0 ] = rb[rix++]; crc[1 ] = rb[rix++]; }else { -dev_err (&spi->dev,"buffer overrun when reading crc.\n" ); +dev_err (&spi->dev, +"buffer overrun when reading crc.\n" ); result =N_FAIL ;return result; }@@ -680,7 +681,8 @@ static int spi_data_write(struct wilc *wilc, u8 *b, u32 sz)**/ if (!g_spi.crc_off) {if (wilc_spi_tx (wilc, crc,2 )) { -dev_err (&spi->dev,"Failed data block crc write, bus error...\n" ); +dev_err (&spi->dev, +"Failed data block crc write, bus error...\n" ); result =N_FAIL ;break ; }@@ -1074,7 +1076,8 @@ static int wilc_spi_clear_int_ext(struct wilc *wilc, u32 val) ret =wilc_spi_write_reg (wilc,WILC_VMM_CORE_CTL ,1 );if (!ret) { -dev_err (&spi->dev,"fail write reg vmm_core_ctl...\n" ); +dev_err (&spi->dev, +"fail write reg vmm_core_ctl...\n" ); goto _fail_; } }drivers/staging/wilc1000/wilc_wfi_cfgoperations.c +2
-2@@ -157,7 +157,7 @@ static u8 wlan_channel = INVALID_CHANNEL;static u8 curr_channel;static u8 p2p_oui[] = {0x50 ,0x6f ,0x9A ,0x09 };static u8 p2p_local_random =0x01 ; -static u8 p2p_recv_random =0x00 ; +static u8 p2p_recv_random;static u8 p2p_vendor_spec[] = {0xdd ,0x05 ,0x00 ,0x08 ,0x40 ,0x03 };static bool wilc_ie;@@ -2126,7 +2126,7 @@ static int start_ap(struct wiphy *wiphy, struct net_device *dev, priv =wiphy_priv (wiphy); vif =netdev_priv (dev); - wl = vif ->wilc; + wl = vif->wilc;PRINT_D (HOSTAPD_DBG ,"Starting ap\n" ); PRINT_D(HOSTAPD_DBG, "Interval = %d\n DTIM period = %d\n Head length = %zu Tail length = %zu\n",drivers/staging/wilc1000/wilc_wlan.c +1
-1@@ -325,7 +325,7 @@ static int wilc_wlan_txq_filter_dup_tcp_ack(struct net_device *dev)return 1 ; } -static bool enabled = false; +static bool enabled;void wilc_enable_tcp_ack_filter (bool value) {Signature · 8 lines
1.9.1 -- You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1455419372-6149-1-git-send-email-eraretuya%40gmail.com. For more options, visit https://groups.google.com/d/optout.