Re: [i2c] [PATCH 19 1/5] Implement module aliasing for i2c totranslate from device tree names

From: Stephen Rothwell
Date: Fri Jan 11 2008 - 22:48:04 EST


Hi Jon,

On Fri, 11 Jan 2008 22:00:42 -0500 "Jon Smirl" <jonsmirl@xxxxxxxxx> wrote:
>
> +++ b/drivers/hwmon/f75375s.c
> @@ -117,7 +117,7 @@ struct f75375_data {
> static int f75375_attach_adapter(struct i2c_adapter *adapter);
> static int f75375_detect(struct i2c_adapter *adapter, int address, int kind);
> static int f75375_detach_client(struct i2c_client *client);
> -static int f75375_probe(struct i2c_client *client);
> +static int f75375_probe(struct i2c_client *client, const struct
> i2c_device_id *id);

Looks like your mail client has wrapped this. Also in various later
spots.

> +++ b/drivers/i2c/i2c-core.c
> @@ -47,6 +47,19 @@ static DEFINE_IDR(i2c_adapter_idr);
>
> /* ------------------------------------------------------------------------- */
>
> +static const struct i2c_device_id *i2c_match_id(
> + const struct i2c_device_id *id, struct i2c_client *client)

Any reason that the "client" argument is not const as well?

> +++ b/include/linux/i2c.h
> @@ -141,11 +141,10 @@ struct i2c_driver {
>
> struct device_driver driver;
> struct list_head list;
> + struct i2c_device_id *id_table;

Any reason that this is not const? Making it const would allow divers to
make their tables const.

These are just small things (apart from the wrapping) that can be fixed
up with followup patches.

--
Cheers,
Stephen Rothwell sfr@xxxxxxxxxxxxxxxx
http://www.canb.auug.org.au/~sfr/

Attachment: pgp00000.pgp
Description: PGP signature