* [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error
@ 2023-02-17 0:38 Vladimir Oltean
2023-02-17 0:46 ` Vladimir Oltean
2023-02-17 0:54 ` Colin Foster
0 siblings, 2 replies; 3+ messages in thread
From: Vladimir Oltean @ 2023-02-17 0:38 UTC (permalink / raw)
To: netdev
Cc: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Claudiu Manoil, Alexandre Belloni, UNGLinuxDriver, Andrew Lunn,
Florian Fainelli, Colin Foster, Lee Jones
When compiling a kernel which has both CONFIG_NET_DSA_MSCC_OCELOT_EXT
and CONFIG_MSCC_OCELOT_SWITCH enabled, the following error message will
be printed:
[ 5.266588] Error: Driver 'ocelot-switch' is already registered, aborting...
Rename the ocelot_ext.c driver to "ocelot-ext-switch" to avoid the name
duplication, and update the mfd_cell entry for its resources.
Fixes: 3d7316ac81ac ("net: dsa: ocelot: add external ocelot switch control")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
---
drivers/mfd/ocelot-core.c | 2 +-
drivers/net/dsa/ocelot/ocelot_ext.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/mfd/ocelot-core.c b/drivers/mfd/ocelot-core.c
index c2224f8a16c0..9cccf54fc9c8 100644
--- a/drivers/mfd/ocelot-core.c
+++ b/drivers/mfd/ocelot-core.c
@@ -190,7 +190,7 @@ static const struct mfd_cell vsc7512_devs[] = {
.num_resources = ARRAY_SIZE(vsc7512_serdes_resources),
.resources = vsc7512_serdes_resources,
}, {
- .name = "ocelot-switch",
+ .name = "ocelot-ext-switch",
.of_compatible = "mscc,vsc7512-switch",
.num_resources = ARRAY_SIZE(vsc7512_switch_resources),
.resources = vsc7512_switch_resources,
diff --git a/drivers/net/dsa/ocelot/ocelot_ext.c b/drivers/net/dsa/ocelot/ocelot_ext.c
index f10271b973b2..6893f03cd392 100644
--- a/drivers/net/dsa/ocelot/ocelot_ext.c
+++ b/drivers/net/dsa/ocelot/ocelot_ext.c
@@ -438,7 +438,7 @@ MODULE_DEVICE_TABLE(of, ocelot_ext_switch_of_match);
static struct platform_driver ocelot_ext_switch_driver = {
.driver = {
- .name = "ocelot-switch",
+ .name = "ocelot-ext-switch",
.of_match_table = of_match_ptr(ocelot_ext_switch_of_match),
},
.probe = ocelot_ext_probe,
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error
2023-02-17 0:38 [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error Vladimir Oltean
@ 2023-02-17 0:46 ` Vladimir Oltean
2023-02-17 0:54 ` Colin Foster
1 sibling, 0 replies; 3+ messages in thread
From: Vladimir Oltean @ 2023-02-17 0:46 UTC (permalink / raw)
To: netdev
Cc: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
Claudiu Manoil, Alexandre Belloni, UNGLinuxDriver, Andrew Lunn,
Florian Fainelli, Colin Foster, Lee Jones
On Fri, Feb 17, 2023 at 02:38:45AM +0200, Vladimir Oltean wrote:
> When compiling a kernel which has both CONFIG_NET_DSA_MSCC_OCELOT_EXT
> and CONFIG_MSCC_OCELOT_SWITCH enabled, the following error message will
> be printed:
>
> [ 5.266588] Error: Driver 'ocelot-switch' is already registered, aborting...
>
> Rename the ocelot_ext.c driver to "ocelot-ext-switch" to avoid the name
> duplication, and update the mfd_cell entry for its resources.
>
> Fixes: 3d7316ac81ac ("net: dsa: ocelot: add external ocelot switch control")
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
> ---
Patch will have to be resent because I wrote it on top of Colin's patch
set and I forgot to rebase:
https://patchwork.kernel.org/project/netdevbpf/cover/20230216075321.2898003-1-colin.foster@in-advantage.com/
Will wait for feedback before resending.
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error
2023-02-17 0:38 [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error Vladimir Oltean
2023-02-17 0:46 ` Vladimir Oltean
@ 2023-02-17 0:54 ` Colin Foster
1 sibling, 0 replies; 3+ messages in thread
From: Colin Foster @ 2023-02-17 0:54 UTC (permalink / raw)
To: Vladimir Oltean
Cc: netdev, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni, Claudiu Manoil, Alexandre Belloni, UNGLinuxDriver,
Andrew Lunn, Florian Fainelli, Lee Jones
On Fri, Feb 17, 2023 at 02:38:45AM +0200, Vladimir Oltean wrote:
> When compiling a kernel which has both CONFIG_NET_DSA_MSCC_OCELOT_EXT
> and CONFIG_MSCC_OCELOT_SWITCH enabled, the following error message will
> be printed:
>
> [ 5.266588] Error: Driver 'ocelot-switch' is already registered, aborting...
>
> Rename the ocelot_ext.c driver to "ocelot-ext-switch" to avoid the name
> duplication, and update the mfd_cell entry for its resources.
>
> Fixes: 3d7316ac81ac ("net: dsa: ocelot: add external ocelot switch control")
> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Yes, I notice that as well now.
Thanks for the fix! I know my original patch set messed up Lee's tree
(apologies again) but if this goes through net-next I don't think there
should be any issues.
Acked-by: Colin Foster <colin.foster@in-advantage.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-02-17 0:54 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-17 0:38 [PATCH net-next] net: mscc: ocelot: fix duplicate driver name error Vladimir Oltean
2023-02-17 0:46 ` Vladimir Oltean
2023-02-17 0:54 ` Colin Foster
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox