iio: tmp007: Fix `name` attribute ABI
authorLars-Peter Clausen <lars@metafoo.de>
Mon, 30 Jan 2017 10:18:25 +0000 (11:18 +0100)
committerJonathan Cameron <jic23@kernel.org>
Mon, 30 Jan 2017 20:38:13 +0000 (20:38 +0000)
The IIO ABI specifies the name field of the IIO device as:

Description of the physical chip / device for device X.
Typically a part number.

The tmp007 driver currently uses the name of the parent device instead.
Change this to the part name to be in accordance with the ABI.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/temperature/tmp007.c

index 24c6c16d169d8391ddacee9639b9ef9dcfbbda9c..f04d0d1f6ac84ae73f5e723dadc4caa9e7a74bc9 100644 (file)
@@ -233,7 +233,7 @@ static int tmp007_probe(struct i2c_client *client,
        data->client = client;
 
        indio_dev->dev.parent = &client->dev;
-       indio_dev->name = dev_name(&client->dev);
+       indio_dev->name = "tmp007";
        indio_dev->modes = INDIO_DIRECT_MODE;
        indio_dev->info = &tmp007_info;