Subject: AW: [PATCH 9/9] net: mdio: realtek-rtl9300: Link I/O functions in info structure

From: "Markus Stockhausen" <[email-masked]>
Date: Tue, 19 May 2026 22:40:40 +0200

> Von: Andrew Lunn <[email-masked]> 
> Gesendet: Dienstag, 19. Mai 2026 22:17
> An: Markus Stockhausen <[email-masked]>
> Betreff: Re: [PATCH 9/9] net: mdio: realtek-rtl9300: Link I/O functions in
info structure
> ... 
> > Patch 5 tries to explain the sharing concept:
> > 
> > - A generic access function will always run the same way
> > - The info structure tells it where to write (registers)
> > - The indidivual access function tells it what to write (data) 
>
> What to write is a u16. What else is there, given this is MDIO?

With what I meant all required register data to write. 
E.g. see downstream

static int rtmd_930x_write_c45(struct mii_bus *bus, u32 pn, u32 devnum, u32
regnum, u32 val)
{
	struct rtmd_command_data cmd_data = {
		.c45_data = RTMD_C45_DATA(devnum, regnum),
		.io_data = val,
		.port_mask_low = BIT(pn),
	};

	return rtmd_run_cmd(bus, RTMD_930X_CMD_WRITE_C45, &cmd_data, NULL);
}

Markus