Commit 6d858708 authored by Jakub Kicinski's avatar Jakub Kicinski
Browse files

Merge branch 'net-ethernet-freescale-use-pa-to-format-resource_size_t'

Simon Horman says:

====================
net: ethernet: freescale: Use %pa to format resource_size_t

This short series addersses the formatting of variables of
type resource_size_t in freescale drivers.

The correct format string for resource_size_t is %pa which
acts on the address of the variable to be formatted [1].

[1] https://elixir.bootlin.com/linux/v6.11.3/source/Documentation/core-api/printk-formats.rst#L229



These problems were introduced by
commit 9d9326d3 ("phy: Change mii_bus id field to a string")

Reported-by: default avatarGeert Uytterhoeven <geert@linux-m68k.org>
Closes: https://lore.kernel.org/netdev/711d7f6d-b785-7560-f4dc-c6aad2cce99@linux-m68k.org/


Reviewed-by: default avatarDaniel Machon <daniel.machon@microchip.com>
====================

Link: https://patch.msgid.link/20241014-net-pa-fmt-v1-0-dcc9afb8858b@kernel.org


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parents b1a39cd8 45fe45fa
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -94,7 +94,7 @@ static int mpc52xx_fec_mdio_probe(struct platform_device *of)
		goto out_free;
	}

	snprintf(bus->id, MII_BUS_ID_SIZE, "%x", res.start);
	snprintf(bus->id, MII_BUS_ID_SIZE, "%pa", &res.start);
	bus->priv = priv;

	bus->parent = dev;
+1 −1
Original line number Diff line number Diff line
@@ -123,7 +123,7 @@ static int fs_mii_bitbang_init(struct mii_bus *bus, struct device_node *np)
	 * we get is an int, and the odds of multiple bitbang mdio buses
	 * is low enough that it's not worth going too crazy.
	 */
	snprintf(bus->id, MII_BUS_ID_SIZE, "%x", res.start);
	snprintf(bus->id, MII_BUS_ID_SIZE, "%pa", &res.start);

	data = of_get_property(np, "fsl,mdio-pin", &len);
	if (!data || len != 4)