Re: [PATCH v8 2/6] i2c: i801: Use a different adapter-name for IDF adapters

Wolfram Sang
2024-08-14T18:35:11Z

[-- Attachment #1: Type: text/plain, Size: 821 bytes --]

Hi Andi, Hans, all,

> > + /*
> > + * adapter.name is used by platform code to find the main I801 adapter
> > + * to instantiante i2c_clients, do not change.
> > + */
> > snprintf(priv->adapter.name, sizeof(priv->adapter.name),
> > - "SMBus I801 adapter at %04lx", priv->smba);
> > + "SMBus %s adapter at %04lx",
> > + (priv->features & FEATURE_IDF) ? "I801 IDF" : "I801",
> > + priv->smba);
> > +
>
> do you have any comment here?

I have been scratching my head about this patch for a while. I still
think that it is quite fragile to base features on this naming. The
comment above helps, but I still have a bad feeling about it.

I noticed now that the i801 driver does not use the algo_data field so
far. Has it been considered to put a flag there?

Happy hacking,

Wolfram

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]