Re: [PATCH v6 1/2] staging: rtl8723bs: update _rtw_pktfile_read() to return error codes
From: Greg KH
Date: Tue Jan 27 2026 - 09:35:57 EST
On Fri, Jan 23, 2026 at 02:41:24AM +0900, Minu Jin wrote:
> The function _rtw_pktfile_read() currently returns a uint and clamps
> the requested read length if it exceeds the remaining data. This
> behavior makes it impossible to propagate error codes from internal
> calls like skb_copy_bits() and leads to incomplete data processing.
>
> This patch updates the function to:
> 1. Return -EINVAL if the remaining data is less than the requested length,
> ensuring callers always get the full amount of data they expect.
>
> 2. Propagate the negative error code from skb_copy_bits().
>
> 3. Change the return type from uint to int to support these error codes.
>
> To avoid breaking git bisect, this patch also updates all call sites
> (set_qos, update_attrib, and rtw_xmitframe_coalesce) in the same commit.
> By doing so, the error-producing function and its error-handling callers
> remain in sync, preventing runtime failures at this commit point.
>
> Signed-off-by: Minu Jin <s9430939@xxxxxxxxx>
> ---
> drivers/staging/rtl8723bs/core/rtw_xmit.c | 44 ++++++++++++++-----
> .../staging/rtl8723bs/hal/rtl8723bs_xmit.c | 6 +--
> .../staging/rtl8723bs/include/xmit_osdep.h | 2 +-
> drivers/staging/rtl8723bs/os_dep/xmit_linux.c | 21 +++++----
> 4 files changed, 50 insertions(+), 23 deletions(-)
Does not apply to my tree :(
Please rebase the series and resend.
thanks,
greg k-h