lkml.org 
[lkml]   [2021]   [Aug]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH RFC 3/3] staging: r8188eu: add error argument to read_macreg
From
Date
On 8/21/21 2:18 AM, Phillip Potter wrote:
> On Fri, 2021-08-20 at 20:07 +0300, Pavel Skripkin wrote:
>> Since read_macreg() calls rtw_read*() internally we should tell
>> callers about an error on the read side.
>>
>> Signed-off-by: Pavel Skripkin <paskripkin@gmail.com>
>> ---
>>  drivers/staging/r8188eu/core/rtw_mp.c    | 9 ++++-----
>>  drivers/staging/r8188eu/include/rtw_mp.h | 2 +-
>>  2 files changed, 5 insertions(+), 6 deletions(-)
>>
>> diff --git a/drivers/staging/r8188eu/core/rtw_mp.c
>> b/drivers/staging/r8188eu/core/rtw_mp.c
>> index 601a1fd5d4e7..6bbea1cc364a 100644
>> --- a/drivers/staging/r8188eu/core/rtw_mp.c
>> +++ b/drivers/staging/r8188eu/core/rtw_mp.c
>> @@ -7,20 +7,19 @@
>>  #include "../include/odm_precomp.h"
>>  #include "../include/rtl8188e_hal.h"
>>
>> -u32 read_macreg(struct adapter *padapter, u32 addr, u32 sz)
>> +u32 read_macreg(struct adapter *padapter, u32 addr, u32 sz, int
>> *error)
>
> Dear Pavel,
>
> Correct me if I'm wrong, but this read_macreg function seems to be
> completely unused by the rest of the driver. Rather than changing the
> signature to do error handling, maybe it would be better to just remove
> it?
>
> That is just my view though, would be interested to see what others
> think - perhaps it could come in handy at some point.
>

yes, this function is unused for now, but I am aware about plans for
this function :) If no one has plans for it, it can be removed.


With regards,
Pavel Skripkin

\
 
 \ /
  Last update: 2021-08-21 12:39    [W:0.099 / U:0.104 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site