lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <7738fcc180e6403ba4d0def0ae7ca31a@realtek.com>
Date:   Thu, 27 Jul 2023 01:44:00 +0000
From:   Ping-Ke Shih <pkshih@...ltek.com>
To:     Martin Blumenstingl <martin.blumenstingl@...glemail.com>
CC:     "Lukas F. Hartmann" <lukas@...re.com>,
        "linux-wireless@...r.kernel.org" <linux-wireless@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "jernej.skrabec@...il.com" <jernej.skrabec@...il.com>,
        "ulf.hansson@...aro.org" <ulf.hansson@...aro.org>,
        "kvalo@...nel.org" <kvalo@...nel.org>,
        "tony0620emma@...il.com" <tony0620emma@...il.com>
Subject: RE: [PATCH] wifi: rtw88: sdio: Honor the host max_req_size in the RX path



> -----Original Message-----
> From: Martin Blumenstingl <martin.blumenstingl@...glemail.com>
> Sent: Thursday, July 27, 2023 1:38 AM
> To: Ping-Ke Shih <pkshih@...ltek.com>
> Cc: Lukas F. Hartmann <lukas@...re.com>; linux-wireless@...r.kernel.org; linux-kernel@...r.kernel.org;
> jernej.skrabec@...il.com; ulf.hansson@...aro.org; kvalo@...nel.org; tony0620emma@...il.com
> Subject: Re: [PATCH] wifi: rtw88: sdio: Honor the host max_req_size in the RX path
> 
> Hello Ping-Ke,
> 
> On Fri, Jul 14, 2023 at 2:34 AM Ping-Ke Shih <pkshih@...ltek.com> wrote:
> [...]
> > > Here are the errors that lead up to this:
> > > http://dump.mntmn.com/rtw88-failure-1h-dmesg.txt
> >
> > Hi Martin,
> >
> > The dmesg shows that
> > "rtw_8822cs mmc2:0001:1: Failed to read 1536 byte(s) from SDIO port 0x000000d1"
> >
> > Shouldn't we return an error code (with proper error handling) instead of
> > just break the loop? Because 'buf' content isn't usable.
> In my opinion we are properly breaking the loop:
> "ret" will be non-zero so the error code is returned from
> rtw_sdio_read_port() to the caller.
> The (only) caller is rtw_sdio_rxfifo_recv() which sees the non-zero
> return code and aborts processing.
> What do you think?

You are correct. 

I check the kernel log again. It might try to read two times for a large packet.

First read is 1536 bytes, but it failed: 
  [ 4002.096664] rtw_8822cs mmc2:0001:1: Failed to read 1536 byte(s) from SDIO port 0x000000d1

Second read is less byte, and it succeed, but skb->data content is incorrect. Then, 
  [ 4002.100140] rtw_8822cs mmc2:0001:1: unused phy status page (3)
  [ 4002.105065] rtw_8822cs mmc2:0001:1: unused phy status page (2)
  [ 4002.110862] ------------[ cut here ]------------
  [ 4002.110868] Rate marked as a VHT rate but data is invalid: MCS: 0, NSS: 0

So, showing total size ('count' argument) might help to find the cause
or a workaround. 

Ping-Ke

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ