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: <BN8PR13MB26111D51332B5A716328079599B50@BN8PR13MB2611.namprd13.prod.outlook.com>
Date:   Sat, 23 May 2020 05:44:29 +0000
From:   Sagar Kadam <sagar.kadam@...ive.com>
To:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "linux-riscv@...ts.infradead.org" <linux-riscv@...ts.infradead.org>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>
CC:     "palmer@...belt.com" <palmer@...belt.com>,
        Paul Walmsley <paul.walmsley@...ive.com>,
        "atish.patra@....com" <atish.patra@....com>
Subject: RE: [PATCH v1 0/3] fix macb phy probe failure if phy-reset is not
 handled

Hello,

A gentle reminder. Any suggestions here?

BR,
Sagar

> -----Original Message-----
> From: Sagar Kadam <sagar.kadam@...ive.com>
> Sent: Wednesday, May 13, 2020 7:27 PM
> To: linux-kernel@...r.kernel.org; linux-riscv@...ts.infradead.org;
> devicetree@...r.kernel.org; robh+dt@...nel.org
> Cc: palmer@...belt.com; Paul Walmsley <paul.walmsley@...ive.com>;
> atish.patra@....com; Sagar Kadam <sagar.kadam@...ive.com>
> Subject: [PATCH v1 0/3] fix macb phy probe failure if phy-reset is not
> handled
> 
> HiFive Unleashed is having VSC8541-01 ethernet phy device and requires a
> specific reset sequence of 0-1-0-1 in order to use it in unmanaged mode.
> This series addresses a corner case where phy reset is not handled by boot
> stages prior to linux.
> Somewhat similar unreliable phy probe failure was reported and discussed
> here [1].
> The macb driver fails to detect the ethernet phy device if the bootloader
> doesn't provide a proper reset sequence to the phy device or the phy itself
> is in some invalid state. Currently, the FSBL is resetting the phy device, and
> so there is no issue observed in the linux network setup.
> 
> The series is based on linux-5.7-rc5.
> Patch 1: Add the OUI to the phy dt node to fix issue of missing mdio device
> Patch 2 and 3:
> 	Resetting phy needs GPIO support so add to dt and defconfig.
> 
> [1] https://lkml.org/lkml/2018/11/29/154
> 
> To reproduce the issue:
> 1. Comment out VSC8541 reset sequence in fsbl/main.c
>    from within the freedom-u540-c000-bootloader.
> 2. Build and flash fsbl.bin to micro sdcard.
> 
> Boot the board and bootlog will show network setup failure messages as:
> 
> [  1.069474] libphy: MACB_mii_bus: probed [  1.073092] mdio_bus
> 10090000.ethernet-ffffffff: MDIO device at address 0
> 	       is missing
> .....
> [  1.979252] macb 10090000.ethernet eth0: Could not attach PHY (-19)
> 
> 3. Now apply the series build, and boot kernel.
> 4. MACB and VSC8541 driver get successfully probed and the network is set
>    without any failure.
> 
> 
> So irrespective of whether the prior stages handle the phy reset sequence,
> the probing is successful in both the cases of cold boot and warm boot.
> 
> Change History:
> ===============================
> V1:
> -Ignore 4th patch as suggested and so removed it from the series.
> -Verified this series on 5.7-rc5.
> 
> V0: Base RFC patch. Verified on 5.7-rc2
> 
> 
> Sagar Shrikant Kadam (3):
>   dts: phy: fix missing mdio device and probe failure of vsc8541-01
>     device
>   dts: phy: add GPIO number and active state used for phy reset
>   riscv: defconfig: enable gpio support for HiFive Unleashed
> 
>  arch/riscv/boot/dts/sifive/hifive-unleashed-a00.dts | 2 ++
>  arch/riscv/configs/defconfig                        | 2 ++
>  2 files changed, 4 insertions(+)
> 
> --
> 2.7.4

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ