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
| ||
|
Message-ID: <e4c4a448-2f3f-4693-bc5e-1d39ad76d233@lunn.ch> Date: Fri, 11 Aug 2023 16:38:42 +0200 From: Andrew Lunn <andrew@...n.ch> To: "Russell King (Oracle)" <rmk+kernel@...linux.org.uk> Cc: Heiner Kallweit <hkallweit1@...il.com>, Alexandru Ardelean <alexandru.ardelean@...log.com>, Andre Edich <andre.edich@...rochip.com>, Antoine Tenart <atenart@...nel.org>, Baruch Siach <baruch@...s.co.il>, Christophe Leroy <christophe.leroy@....fr>, "David S. Miller" <davem@...emloft.net>, Divya Koppera <Divya.Koppera@...rochip.com>, Eric Dumazet <edumazet@...gle.com>, Florian Fainelli <f.fainelli@...il.com>, Hauke Mehrtens <hauke@...ke-m.de>, Ioana Ciornei <ioana.ciornei@....com>, Jakub Kicinski <kuba@...nel.org>, Jerome Brunet <jbrunet@...libre.com>, Kavya Sree Kotagiri <kavyasree.kotagiri@...rochip.com>, Linus Walleij <linus.walleij@...aro.org>, Marco Felsch <m.felsch@...gutronix.de>, Marek Vasut <marex@...x.de>, Martin Blumenstingl <martin.blumenstingl@...glemail.com>, Mathias Kresin <dev@...sin.me>, Maxim Kochetkov <fido_max@...ox.ru>, Michael Walle <michael@...le.cc>, Neil Armstrong <narmstrong@...libre.com>, Nisar Sayed <Nisar.Sayed@...rochip.com>, Oleksij Rempel <o.rempel@...gutronix.de>, Paolo Abeni <pabeni@...hat.com>, Philippe Schenker <philippe.schenker@...adex.com>, Willy Liu <willy.liu@...ltek.com>, Yuiko Oshino <yuiko.oshino@...rochip.com>, Uwe Kleine-König <u.kleine-koenig@...gutronix.de>, netdev@...r.kernel.org Subject: Re: [PATCH net] net: phy: fix IRQ-based wake-on-lan over hibernate / power off On Fri, Aug 11, 2023 at 11:26:30AM +0100, Russell King (Oracle) wrote: > Uwe reports: > "Most PHYs signal WoL using an interrupt. So disabling interrupts [at > shutdown] breaks WoL at least on PHYs covered by the marvell driver." > > Discussing with Ioana, the problem which was trying to be solved was: > "The board in question is a LS1021ATSN which has two AR8031 PHYs that > share an interrupt line. In case only one of the PHYs is probed and > there are pending interrupts on the PHY#2 an IRQ storm will happen > since there is no entity to clear the interrupt from PHY#2's registers. > PHY#1's driver will get stuck in .handle_interrupt() indefinitely." > > Further confirmation that "the two AR8031 PHYs are on the same MDIO > bus." > > With WoL using interrupts to wake the system, in such a case, the > system will begin booting with an asserted interrupt. Thus, we need to > cope with an interrupt asserted during boot. > > Solve this instead by disabling interrupts during PHY probe. This will > ensure in Ioana's situation that both PHYs of the same type sharing an > interrupt line on a common MDIO bus will have their interrupt outputs > disabled when the driver probes the device, but before we hook in any > interrupt handlers - thus avoiding the interrupt storm. > > A better fix would be for platform firmware to disable the interrupting > devices at source during boot, before control is handed to the kernel. > > Fixes: e2f016cf7751 ("net: phy: add a shutdown procedure") > Link: 20230804071757.383971-1-u.kleine-koenig@...gutronix.de > Reported-by: Uwe Kleine-König <u.kleine-koenig@...gutronix.de> > Signed-off-by: Russell King (Oracle) <rmk+kernel@...linux.org.uk> Reviewed-by: Andrew Lunn <andrew@...n.ch> Andrew
Powered by blists - more mailing lists