alistair23-linux/drivers/staging/iio
Somya Anand b62a569e4a Staging: iio: Change data type to u16 to avoid unnecessary typecast
In the adis16220_read16bit() function we earlier used a s16 value 'val'
which is used by the adis_read_reg_16 function to read data and takes a
u16 value as a parameter.

So, this patch changes the data type of 'val' from s16 to u16. It is safe
to remove the extra sign extension, since the user of the function uses it
to read a 10 unsigned value which will lead to the same result in both cases.
Further this patch removes the unnecessary typecast for the simplification of
code. In addition to this, initialization of 'val' to 0 is also dropped. This is
due to the fact that not initializing helps the compiler provide useful warnings
if the code gets changed to return an otherwise uninitialized result.

Signed-off-by: Somya Anand <somyaanand214@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-09 13:18:04 +01:00
..
accel Staging: iio: Change data type to u16 to avoid unnecessary typecast 2015-03-09 13:18:04 +01:00
adc First round of fixes for IIO in the 4.0 cycle. Note a followup 2015-02-28 07:15:09 -08:00
addac staging: iio: addac: annotate Kconfig entries with module name information 2014-10-20 10:29:08 +08:00
cdc staging: iio: cdc: Don't put an else right after a return 2014-09-19 17:49:39 -07:00
Documentation Staging: iio: Added define guards where needed 2015-03-06 09:54:33 -08:00
frequency Staging: iio: Added define guards where needed 2015-03-06 09:54:33 -08:00
gyro Staging: iio: gyro: Added description for config symbol. 2014-10-20 10:29:08 +08:00
impedance-analyzer staging: iio: ad5933: fix format string warnings 2015-01-25 22:55:34 +00:00
light Staging: iio: clean dev_err logging 2015-03-06 15:55:36 -08:00
magnetometer staging: iio: hmc5843: Set iio name property in sysfs 2015-03-06 17:06:30 -08:00
meter Staging: iio: Added define guards where needed 2015-03-06 09:54:33 -08:00
resolver Merge 4.0-rc3 into staging-next 2015-03-09 08:13:01 +01:00
trigger Staging patches for 3.19-rc1 2014-12-15 18:06:13 -08:00
iio_dummy_evgen.c iio: dummy: Add virtual registers for dummy device 2014-11-22 11:05:44 +00:00
iio_dummy_evgen.h iio: dummy: Add virtual registers for dummy device 2014-11-22 11:05:44 +00:00
iio_simple_dummy.c staging: Remove <linux/moduleparam.h> header. 2015-03-01 17:09:52 -08:00
iio_simple_dummy.h staging: iio: dummy: fix compile error when not using buffering 2015-01-01 12:20:52 +00:00
iio_simple_dummy_buffer.c iio: kfifo: Remove unused argument in iio_kfifo_allocate 2014-12-26 11:20:38 +00:00
iio_simple_dummy_events.c iio: core: Remove IIO_EV_TYPE_INSTANCE 2015-01-27 18:49:55 +00:00
Kconfig kconfig: use bool instead of boolean for type definition attributes 2015-01-07 13:08:04 +01:00
Makefile
ring_hw.h staging: iio: Add #include guards to header files 2014-09-28 22:19:04 -04:00
TODO