linux_dsm_epyc7002/drivers/iio/accel
Julia Lawall 7504dfc9e9 iio: common: ssp_sensors: accel: constify iio_info structures
Check for iio_info structures that are only stored in the info field of a
iio_dev structure.  This field is declared const, so iio_info structures
that have this property can be declared as const also.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@r disable optional_qualifier@
identifier i;
position p;
@@
static struct iio_info i@p = { ... };

@ok@
identifier r.i;
struct iio_dev e;
position p;
@@
e.info = &i@p;

@bad@
position p != {r.p,ok.p};
identifier r.i;
struct iio_info e;
@@
e@i@p

@depends on !bad disable optional_qualifier@
identifier r.i;
@@
static
+const
 struct iio_info i = { ... };
// </smpl>

The result of size on this file before the change is:
   text	      data     bss     dec         hex	  filename
   1265        344       0    1609         649
   drivers/iio/accel/ssp_accel_sensor.o

and after the change it is:
   text	     data        bss	    dec	    hex	filename
   1425	      192          0       1617     651
   drivers/iio/accel/ssp_accel_sensor.o

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
2016-09-18 11:56:08 +01:00
..
bma180.c iio: accel: bma180: use iio helper function to guarantee direct mode 2016-08-15 17:12:43 +01:00
bma220_spi.c iio: accel: bma220_spi: set up buffer timestamps for non-zero values 2016-08-15 15:39:18 +01:00
bmc150-accel-core.c iio: accel: bmc150: reset chip at init time 2016-09-03 17:26:14 +01:00
bmc150-accel-i2c.c iio: accel: bmc150: use common definition for regmap conf 2016-04-03 11:24:52 +01:00
bmc150-accel-spi.c iio: accel: bmc150: use common definition for regmap conf 2016-04-03 11:24:52 +01:00
bmc150-accel.h iio: accel: bmc150: use common definition for regmap conf 2016-04-03 11:24:52 +01:00
dmard06.c iio: accel: Add support for Domintech DMARD06 accelerometer 2016-08-21 10:52:02 +01:00
dmard09.c iio: accel: add support for the Domintech DMARD09 3-axis accelerometer 2016-08-21 10:52:08 +01:00
hid-sensor-accel-3d.c iio: accel: hid-sensor-accel-3d: Fix memory leak in probe() 2015-05-17 09:09:05 +01:00
Kconfig iio: accel: kxsd9: Add triggered buffer handling 2016-09-18 11:32:15 +01:00
kxcjk-1013.c iio: accel: kxcjk-1013: add the "KIOX000A" ACPI id 2016-07-24 19:58:40 +01:00
kxsd9-i2c.c iio: accel: kxsd9: Deploy system and runtime PM 2016-09-18 11:35:59 +01:00
kxsd9-spi.c iio: accel: kxsd9: Deploy system and runtime PM 2016-09-18 11:35:59 +01:00
kxsd9.c iio: accel: kxsd9: Support reading a mounting matrix 2016-09-18 11:36:32 +01:00
kxsd9.h iio: accel: kxsd9: Deploy system and runtime PM 2016-09-18 11:35:59 +01:00
Makefile iio: accel: kxsd9: Add I2C transport 2016-09-18 11:29:12 +01:00
mma7455_core.c iio:core: timestamping clock selection support 2016-06-30 19:41:38 +01:00
mma7455_i2c.c iio: accel: add Freescale MMA7455L/MMA7456L 3-axis accelerometer driver 2015-11-01 18:00:35 +00:00
mma7455_spi.c iio: accel: add Freescale MMA7455L/MMA7456L 3-axis accelerometer driver 2015-11-01 18:00:35 +00:00
mma7455.h iio: accel: add Freescale MMA7455L/MMA7456L 3-axis accelerometer driver 2015-11-01 18:00:35 +00:00
mma7660.c iio: accel: Add support for Freescale MMA7660FC 2016-05-04 10:44:17 +01:00
mma8452.c drivers:iio:accel:mma8452: removed unwanted return statements 2016-07-05 21:05:01 +01:00
mma9551_core.c iio: accel: mma9553: fix alignment issues 2015-06-14 16:00:54 +01:00
mma9551_core.h iio: accel: mma9553: fix alignment issues 2015-06-14 16:00:54 +01:00
mma9551.c iio:core: timestamping clock selection support 2016-06-30 19:41:38 +01:00
mma9553.c iio:core: timestamping clock selection support 2016-06-30 19:41:38 +01:00
mxc4005.c iio: remove gpio interrupt probing from drivers that use a single interrupt 2016-04-03 10:27:48 +01:00
mxc6255.c iio: accel: mxc6255: Fix chip-id check 2016-09-12 20:19:16 +01:00
ssp_accel_sensor.c iio: common: ssp_sensors: accel: constify iio_info structures 2016-09-18 11:56:08 +01:00
st_accel_buffer.c iio: st_sensors: switch to a threaded interrupt 2016-05-29 20:21:41 +01:00
st_accel_core.c iio: accel: st_accel: Add lis3l02dq support 2016-07-04 18:07:44 +01:00
st_accel_i2c.c iio: accel: st_accel: Add lis3l02dq support 2016-07-04 18:07:44 +01:00
st_accel_spi.c iio: accel: st_accel: Add lis3l02dq support 2016-07-04 18:07:44 +01:00
st_accel.h iio: accel: st_accel: Add lis3l02dq support 2016-07-04 18:07:44 +01:00
stk8ba50.c iio: remove unused gpio consumer.h include 2016-04-03 10:27:47 +01:00
stk8312.c iio: remove unused gpio consumer.h include 2016-04-03 10:27:47 +01:00