[i2c] [patch 2.6.21-rc3-git +i2c] i2c EXPORT_SYMBOL cleanup
Jean Delvare
khali at linux-fr.org
Fri Mar 9 22:19:02 CET 2007
On Fri, 9 Mar 2007 08:02:26 -0800, David Brownell wrote:
> On Friday 09 March 2007 6:13 am, Jean Delvare wrote:
>
> > > +EXPORT_SYMBOL_GPL(i2c_bus_type);
> >
> > Any reason why this one doesn't have its "/* exported to i2c-isa */"
> > comment?
>
> Yes. The bus_type symbols are generally exported, so that
> it's easy to answer questions like "is this an I2C device?"
OTOH nobody (but i2c-isa) actually uses it, so it could be seen as
bloat and killed by the unused export police.
> > > /**
> > > * i2c_new_device - instantiate an i2c device for use with a new style driver
> > > @@ -293,6 +294,7 @@ void i2c_adapter_dev_release(struct devi
> > > struct i2c_adapter *adap = to_i2c_adapter(dev);
> > > complete(&adap->dev_released);
> > > }
> > > +EXPORT_SYMBOL_GPL(i2c_adapter_dev_release); /* exported to i2c-isa */
> > >
> > > static ssize_t
> > > show_adapter_name(struct device *dev, struct device_attribute *attr, char *buf)
> > > @@ -311,6 +313,7 @@ struct class i2c_adapter_class = {
> > > .name = "i2c-adapter",
> > > .dev_attrs = i2c_adapter_attrs,
> > > };
> > > +EXPORT_SYMBOL_GPL(i2c_adapter_class); /* exported to i2c-isa */
> >
> > BTW, I think I'll move the declarations of these
> > exported-to-i2c-isa-only symbols from i2c.h to i2c-isa.c itself. Best
> > way to make sure nobody gets tempted to use them. Hopefully we'll
> > remove the exports themselves soon anyway.
>
> One of these days your battle against i2c-isa will be over!!
I certainly hope so :)
--
Jean Delvare
More information about the i2c
mailing list