lkml.org 
[lkml]   [2022]   [Jan]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 6/7] staging: r8188eu: IntArray and C2hArray are set but never used
From
On 12/30/21 21:11, Pavel Skripkin wrote:
> On 12/30/21 23:00, Michael Straube wrote:
>> The fields IntArray and C2hArray of struct hal_data_8188e are set but
>> never used. Remove them.
>>
>> While at it, remove the unsed defines USB_INTR_CONTENT_CPWM1_OFFSET
>> and USB_INTR_CONTENT_CPWM2_OFFSET as well.
>>
>> Signed-off-by: Michael Straube <straube.linux@gmail.com>
>> ---
>
> Hi Michael,
>
> thanks for your clean ups!
>
>>   drivers/staging/r8188eu/hal/usb_ops_linux.c     | 10 ----------
>>   drivers/staging/r8188eu/include/rtl8188e_hal.h  |  3 ---
>>   drivers/staging/r8188eu/include/rtl8188e_spec.h |  7 -------
>>   3 files changed, 20 deletions(-)
>>
>> diff --git a/drivers/staging/r8188eu/hal/usb_ops_linux.c
>> b/drivers/staging/r8188eu/hal/usb_ops_linux.c
>> index 9ec55a77dccd..85bcde5ee79a 100644
>> --- a/drivers/staging/r8188eu/hal/usb_ops_linux.c
>> +++ b/drivers/staging/r8188eu/hal/usb_ops_linux.c
>> @@ -185,20 +185,10 @@ int rtw_writeN(struct adapter *adapter, u32
>> addr, u32 length, u8 *data)
>>   static void interrupt_handler_8188eu(struct adapter *adapt, u16
>> pkt_len, u8 *pbuf)
>>   {
>> -    struct hal_data_8188e *haldata = &adapt->haldata;
>> -
>>       if (pkt_len != INTERRUPT_MSG_FORMAT_LEN) {
>>           DBG_88E("%s Invalid interrupt content length (%d)!\n",
>> __func__, pkt_len);
>>           return;
>>       }
>> -
>> -    /*  HISR */
>> -    memcpy(&haldata->IntArray[0],
>> &pbuf[USB_INTR_CONTENT_HISR_OFFSET], 4);
>> -    memcpy(&haldata->IntArray[1],
>> &pbuf[USB_INTR_CONTENT_HISRE_OFFSET], 4);
>> -
>> -    /*  C2H Event */
>> -    if (pbuf[0] != 0)
>> -        memcpy(&haldata->C2hArray[0],
>> &pbuf[USB_INTR_CONTENT_C2H_OFFSET], 16);
>>   }
>
> This function can be removed totally then, since it does nothing. Not
> sure if function removal fits this patch, but why not :)
>

Hi Pavel,

I've sent v2 that removes the function.

Happy new year! :)
Michael

\
 
 \ /
  Last update: 2022-01-01 09:22    [W:0.050 / U:0.956 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site