[PATCH V3 3/3] net: phy: Make phy_interface_is_rgmii a switch statement

Tom Rini trini at konsulko.com
Sat May 6 16:54:14 CEST 2023

On Fri, Apr 14, 2023 at 05:06:45PM -0500, Nishanth Menon wrote:

> Recent commit 75d28899e3e9 ("net: phy: Synchronize PHY interface modes
> with Linux") reordered the enum definitions. This exposed a problem
> in range checking functions to identify the interface type. Though
> this specific api wasn't impacted (all the RGMII definitions remained
> within range), this experience should be used to never to have to face
> this kind of challenge again.
> While it is possible for the phy drivers to use the enums directly,
> drivers such as dp83867, dp83869, marvell, micrel_ksz90x1 etc use this
> api.
> Reported-by: Tom Rini <trini at konsulko.com>
> Reviewed-by: Marek Vasut <marek.vasut+renesas at mailbox.org>
> Reviewed-by: Marek Behún <kabel at kernel.org>
> Signed-off-by: Nishanth Menon <nm at ti.com>
> Reviewed-by: Ramon Fried <rfried.dev at gmail.com>

Applied to u-boot/master, thanks!

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20230506/15a8d7e9/attachment.sig>

More information about the U-Boot mailing list