All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/1] staging: wilc1000: remove redundant reset of station statistics
@ 2019-01-28 22:38 Adham.Abozaeid
  2019-01-29  8:39 ` Dan Carpenter
  0 siblings, 1 reply; 3+ messages in thread
From: Adham.Abozaeid @ 2019-01-28 22:38 UTC (permalink / raw)
  To: linux-wireless; +Cc: devel, gregkh, johannes, Ajay.Kathat

From: Adham Abozaeid <adham.abozaeid@microchip.com>

Driver sends configuration wids to reset connection statistics in the
device, but the device already resets it when starting a new connection

Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
---
 drivers/staging/wilc1000/host_interface.c | 20 +-------------------
 1 file changed, 1 insertion(+), 19 deletions(-)

diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c
index fbb61de20304..286685e426c1 100644
--- a/drivers/staging/wilc1000/host_interface.c
+++ b/drivers/staging/wilc1000/host_interface.c
@@ -342,29 +342,11 @@ static int wilc_send_connect_wid(struct wilc_vif *vif)
 {
 	int result = 0;
 	struct wid wid_list[8];
-	u32 wid_cnt = 0, dummyval = 0;
+	u32 wid_cnt = 0;
 	struct host_if_drv *hif_drv = vif->hif_drv;
 	struct wilc_conn_info *conn_attr = &hif_drv->conn_info;
 	struct wilc_join_bss_param *bss_param = conn_attr->param;
 
-	wid_list[wid_cnt].id = WID_SUCCESS_FRAME_COUNT;
-	wid_list[wid_cnt].type = WID_INT;
-	wid_list[wid_cnt].size = sizeof(u32);
-	wid_list[wid_cnt].val = (s8 *)(&(dummyval));
-	wid_cnt++;
-
-	wid_list[wid_cnt].id = WID_RECEIVED_FRAGMENT_COUNT;
-	wid_list[wid_cnt].type = WID_INT;
-	wid_list[wid_cnt].size = sizeof(u32);
-	wid_list[wid_cnt].val = (s8 *)(&(dummyval));
-	wid_cnt++;
-
-	wid_list[wid_cnt].id = WID_FAILED_COUNT;
-	wid_list[wid_cnt].type = WID_INT;
-	wid_list[wid_cnt].size = sizeof(u32);
-	wid_list[wid_cnt].val = (s8 *)(&(dummyval));
-	wid_cnt++;
-
 	wid_list[wid_cnt].id = WID_INFO_ELEMENT_ASSOCIATE;
 	wid_list[wid_cnt].type = WID_BIN_DATA;
 	wid_list[wid_cnt].val = conn_attr->req_ies;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] staging: wilc1000: remove redundant reset of station statistics
  2019-01-28 22:38 [PATCH 1/1] staging: wilc1000: remove redundant reset of station statistics Adham.Abozaeid
@ 2019-01-29  8:39 ` Dan Carpenter
  2019-01-29 18:40   ` Adham.Abozaeid
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Carpenter @ 2019-01-29  8:39 UTC (permalink / raw)
  To: Adham.Abozaeid; +Cc: linux-wireless, devel, gregkh, johannes, Ajay.Kathat

On Mon, Jan 28, 2019 at 10:38:20PM +0000, Adham.Abozaeid@microchip.com wrote:
> From: Adham Abozaeid <adham.abozaeid@microchip.com>
> 
> Driver sends configuration wids to reset connection statistics in the
> device, but the device already resets it when starting a new connection
> 
> Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
> ---
>  drivers/staging/wilc1000/host_interface.c | 20 +-------------------
>  1 file changed, 1 insertion(+), 19 deletions(-)
> 
> diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c
> index fbb61de20304..286685e426c1 100644
> --- a/drivers/staging/wilc1000/host_interface.c
> +++ b/drivers/staging/wilc1000/host_interface.c
> @@ -342,29 +342,11 @@ static int wilc_send_connect_wid(struct wilc_vif *vif)
>  {
>  	int result = 0;
>  	struct wid wid_list[8];
                   ^^^^^^^^^^^
We could make this array smaller as well.

> -	u32 wid_cnt = 0, dummyval = 0;
> +	u32 wid_cnt = 0;

regards,
dan carpenter

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] staging: wilc1000: remove redundant reset of station statistics
  2019-01-29  8:39 ` Dan Carpenter
@ 2019-01-29 18:40   ` Adham.Abozaeid
  0 siblings, 0 replies; 3+ messages in thread
From: Adham.Abozaeid @ 2019-01-29 18:40 UTC (permalink / raw)
  To: dan.carpenter; +Cc: linux-wireless, devel, gregkh, johannes, Ajay.Kathat


On 1/29/19 1:39 AM, Dan Carpenter wrote:
> On Mon, Jan 28, 2019 at 10:38:20PM +0000, Adham.Abozaeid@microchip.com wrote:
>> From: Adham Abozaeid <adham.abozaeid@microchip.com>
>>
>> Driver sends configuration wids to reset connection statistics in the
>> device, but the device already resets it when starting a new connection
>>
>> Signed-off-by: Adham Abozaeid <adham.abozaeid@microchip.com>
>> ---
>>  drivers/staging/wilc1000/host_interface.c | 20 +-------------------
>>  1 file changed, 1 insertion(+), 19 deletions(-)
>>
>> diff --git a/drivers/staging/wilc1000/host_interface.c b/drivers/staging/wilc1000/host_interface.c
>> index fbb61de20304..286685e426c1 100644
>> --- a/drivers/staging/wilc1000/host_interface.c
>> +++ b/drivers/staging/wilc1000/host_interface.c
>> @@ -342,29 +342,11 @@ static int wilc_send_connect_wid(struct wilc_vif *vif)
>>  {
>>  	int result = 0;
>>  	struct wid wid_list[8];
>                    ^^^^^^^^^^^
> We could make this array smaller as well.
Agree. Will send v2 with smaller array.
>
>> -	u32 wid_cnt = 0, dummyval = 0;
>> +	u32 wid_cnt = 0;
> regards,
> dan carpenter

Thanks,

Adham


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-01-29 18:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-28 22:38 [PATCH 1/1] staging: wilc1000: remove redundant reset of station statistics Adham.Abozaeid
2019-01-29  8:39 ` Dan Carpenter
2019-01-29 18:40   ` Adham.Abozaeid

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.