Re: [PATCH net-next v4 2/3] net: mdio: Add Cortina CS7542 bus controller

From: Andrew Lunn

Date: Sat Nov 28 2026 - 11:54:16 EST


On Fri, Nov 27, 2026 at 01:14:23PM +0300, Fil Dunsky via B4 Relay wrote:
> From: Fil Dunsky <filipp.dunsky@xxxxxxxxx>
>
> Support Clause 22 reads and writes through the CS7542 management
> interface. Retain the firmware-configured prescaler and unrelated
> configuration bits while enabling manual operation.
>
> Use sleepable polling for the bounded wait in the MDIO bus callbacks.
> Report timeout errors directly without tracking a pending transaction.
> Use managed bus allocation and registration to cover probe failures
> and removal.
>
> Acquire and enable the required APB input before accessing registers,
> and retain it for the lifetime of the registered bus. Managed bus teardown
> runs before the managed clock is disabled. The firmware MDC prescaler is
> preserved; no clock-rate or divisor programming is introduced.
>
> Signed-off-by: Fil Dunsky <filipp.dunsky@xxxxxxxxx>

Reviewed-by: Andrew Lunn <andrew@xxxxxxx>

Andrew