On Wed, 19 Mar 2025, Colin Foster wrote: > On Wed, Mar 19, 2025 at 01:30:51PM +0100, Rasmus Villemoes wrote: > > diff --git a/drivers/mfd/ocelot-core.c b/drivers/mfd/ocelot-core.c > > index 41aff27088548..78b5fe15efdd2 100644 > > --- a/drivers/mfd/ocelot-core.c > > +++ b/drivers/mfd/ocelot-core.c > > @@ -200,10 +200,12 @@ static const struct mfd_cell vsc7512_devs[] = { > > static void ocelot_core_try_add_regmap(struct device *dev, > > const struct resource *res) > > { > > + struct ocelot_ddata *ddata = dev_get_drvdata(dev); > > + > > if (dev_get_regmap(dev, res->name)) > > return; > > > > - ocelot_spi_init_regmap(dev, res); > > + ddata->init_regmap(dev, res); > > I remember changing this from function pointers to the direct function > call during initial development, per Lee's suggestion. I like it though, > and I'm glad to see multiple users now. Yeah, we're still not going to be putting call-backs into device data. Either pass the differentiating config through to the core driver or handle the differentiation inside the *-i2c.c / *-spi.c files. -- Lee Jones [李琼斯]