Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'staging-4.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging

Pull staging and IIO driver fixes from Greg KH:
"Here are some IIO and staging driver fixes for 4.5-rc3.

All of them, except one, are for IIO drivers, and one is for a speakup
driver fix caused by some earlier patches, to resolve a reported build
failure"

* tag 'staging-4.5-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
Staging: speakup: Fix allyesconfig build on mn10300
iio: dht11: Use boottime
iio: ade7753: avoid uninitialized data
iio: pressure: mpl115: fix temperature offset sign
iio: imu: Fix dependencies for !HAS_IOMEM archs
staging: iio: Fix dependencies for !HAS_IOMEM archs
iio: adc: Fix dependencies for !HAS_IOMEM archs
iio: inkern: fix a NULL dereference on error
iio:adc:ti_am335x_adc Fix buffered mode by identifying as software buffer.
iio: light: acpi-als: Report data as processed
iio: dac: mcp4725: set iio name property in sysfs
iio: add HAS_IOMEM dependency to VF610_ADC
iio: add IIO_TRIGGER dependency to STK8BA50
iio: proximity: lidar: correct return value
iio-light: Use a signed return type for ltr501_match_samp_freq()

+32 -14
+1
drivers/iio/accel/Kconfig
··· 213 213 config STK8BA50 214 214 tristate "Sensortek STK8BA50 3-Axis Accelerometer Driver" 215 215 depends on I2C 216 + depends on IIO_TRIGGER 216 217 help 217 218 Say yes here to get support for the Sensortek STK8BA50 3-axis 218 219 accelerometer.
+3
drivers/iio/adc/Kconfig
··· 175 175 config EXYNOS_ADC 176 176 tristate "Exynos ADC driver support" 177 177 depends on ARCH_EXYNOS || ARCH_S3C24XX || ARCH_S3C64XX || (OF && COMPILE_TEST) 178 + depends on HAS_IOMEM 178 179 help 179 180 Core support for the ADC block found in the Samsung EXYNOS series 180 181 of SoCs for drivers such as the touchscreen and hwmon to use to share ··· 208 207 config IMX7D_ADC 209 208 tristate "IMX7D ADC driver" 210 209 depends on ARCH_MXC || COMPILE_TEST 210 + depends on HAS_IOMEM 211 211 help 212 212 Say yes here to build support for IMX7D ADC. 213 213 ··· 411 409 config VF610_ADC 412 410 tristate "Freescale vf610 ADC driver" 413 411 depends on OF 412 + depends on HAS_IOMEM 414 413 select IIO_BUFFER 415 414 select IIO_TRIGGERED_BUFFER 416 415 help
+1 -1
drivers/iio/adc/ti_am335x_adc.c
··· 289 289 goto error_kfifo_free; 290 290 291 291 indio_dev->setup_ops = setup_ops; 292 - indio_dev->modes |= INDIO_BUFFER_HARDWARE; 292 + indio_dev->modes |= INDIO_BUFFER_SOFTWARE; 293 293 294 294 return 0; 295 295
+1
drivers/iio/dac/mcp4725.c
··· 300 300 data->client = client; 301 301 302 302 indio_dev->dev.parent = &client->dev; 303 + indio_dev->name = id->name; 303 304 indio_dev->info = &mcp4725_info; 304 305 indio_dev->channels = &mcp4725_channel; 305 306 indio_dev->num_channels = 1;
+4 -4
drivers/iio/humidity/dht11.c
··· 117 117 if (((hum_int + hum_dec + temp_int + temp_dec) & 0xff) != checksum) 118 118 return -EIO; 119 119 120 - dht11->timestamp = ktime_get_real_ns(); 120 + dht11->timestamp = ktime_get_boot_ns(); 121 121 if (hum_int < 20) { /* DHT22 */ 122 122 dht11->temperature = (((temp_int & 0x7f) << 8) + temp_dec) * 123 123 ((temp_int & 0x80) ? -100 : 100); ··· 145 145 146 146 /* TODO: Consider making the handler safe for IRQ sharing */ 147 147 if (dht11->num_edges < DHT11_EDGES_PER_READ && dht11->num_edges >= 0) { 148 - dht11->edges[dht11->num_edges].ts = ktime_get_real_ns(); 148 + dht11->edges[dht11->num_edges].ts = ktime_get_boot_ns(); 149 149 dht11->edges[dht11->num_edges++].value = 150 150 gpio_get_value(dht11->gpio); 151 151 ··· 164 164 int ret, timeres; 165 165 166 166 mutex_lock(&dht11->lock); 167 - if (dht11->timestamp + DHT11_DATA_VALID_TIME < ktime_get_real_ns()) { 167 + if (dht11->timestamp + DHT11_DATA_VALID_TIME < ktime_get_boot_ns()) { 168 168 timeres = ktime_get_resolution_ns(); 169 169 if (DHT11_DATA_BIT_HIGH < 2 * timeres) { 170 170 dev_err(dht11->dev, "timeresolution %dns too low\n", ··· 279 279 return -EINVAL; 280 280 } 281 281 282 - dht11->timestamp = ktime_get_real_ns() - DHT11_DATA_VALID_TIME - 1; 282 + dht11->timestamp = ktime_get_boot_ns() - DHT11_DATA_VALID_TIME - 1; 283 283 dht11->num_edges = -1; 284 284 285 285 platform_set_drvdata(pdev, iio);
+1 -1
drivers/iio/imu/inv_mpu6050/Kconfig
··· 5 5 config INV_MPU6050_IIO 6 6 tristate "Invensense MPU6050 devices" 7 7 depends on I2C && SYSFS 8 + depends on I2C_MUX 8 9 select IIO_BUFFER 9 10 select IIO_TRIGGERED_BUFFER 10 - select I2C_MUX 11 11 help 12 12 This driver supports the Invensense MPU6050 devices. 13 13 This driver can also support MPU6500 in MPU6050 compatibility mode
+2
drivers/iio/inkern.c
··· 349 349 350 350 void iio_channel_release(struct iio_channel *channel) 351 351 { 352 + if (!channel) 353 + return; 352 354 iio_device_put(channel->indio_dev); 353 355 kfree(channel); 354 356 }
+4 -2
drivers/iio/light/acpi-als.c
··· 54 54 .realbits = 32, 55 55 .storagebits = 32, 56 56 }, 57 - .info_mask_separate = BIT(IIO_CHAN_INFO_RAW), 57 + /* _RAW is here for backward ABI compatibility */ 58 + .info_mask_separate = BIT(IIO_CHAN_INFO_RAW) | 59 + BIT(IIO_CHAN_INFO_PROCESSED), 58 60 }, 59 61 }; 60 62 ··· 154 152 s32 temp_val; 155 153 int ret; 156 154 157 - if (mask != IIO_CHAN_INFO_RAW) 155 + if ((mask != IIO_CHAN_INFO_PROCESSED) && (mask != IIO_CHAN_INFO_RAW)) 158 156 return -EINVAL; 159 157 160 158 /* we support only illumination (_ALI) so far. */
+1 -1
drivers/iio/light/ltr501.c
··· 180 180 {500000, 2000000} 181 181 }; 182 182 183 - static unsigned int ltr501_match_samp_freq(const struct ltr501_samp_table *tab, 183 + static int ltr501_match_samp_freq(const struct ltr501_samp_table *tab, 184 184 int len, int val, int val2) 185 185 { 186 186 int i, freq;
+1 -1
drivers/iio/pressure/mpl115.c
··· 117 117 *val = ret >> 6; 118 118 return IIO_VAL_INT; 119 119 case IIO_CHAN_INFO_OFFSET: 120 - *val = 605; 120 + *val = -605; 121 121 *val2 = 750000; 122 122 return IIO_VAL_INT_PLUS_MICRO; 123 123 case IIO_CHAN_INFO_SCALE:
+1 -1
drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
··· 87 87 88 88 ret = i2c_transfer(client->adapter, msg, 2); 89 89 90 - return (ret == 2) ? 0 : ret; 90 + return (ret == 2) ? 0 : -EIO; 91 91 } 92 92 93 93 static int lidar_smbus_xfer(struct lidar_data *data, u8 reg, u8 *val, int len)
+1
drivers/staging/iio/adc/Kconfig
··· 6 6 config AD7606 7 7 tristate "Analog Devices AD7606 ADC driver" 8 8 depends on GPIOLIB || COMPILE_TEST 9 + depends on HAS_IOMEM 9 10 select IIO_BUFFER 10 11 select IIO_TRIGGERED_BUFFER 11 12 help
+10 -2
drivers/staging/iio/meter/ade7753.c
··· 217 217 static int ade7753_reset(struct device *dev) 218 218 { 219 219 u16 val; 220 + int ret; 220 221 221 - ade7753_spi_read_reg_16(dev, ADE7753_MODE, &val); 222 + ret = ade7753_spi_read_reg_16(dev, ADE7753_MODE, &val); 223 + if (ret) 224 + return ret; 225 + 222 226 val |= BIT(6); /* Software Chip Reset */ 223 227 224 228 return ade7753_spi_write_reg_16(dev, ADE7753_MODE, val); ··· 347 343 static int ade7753_stop_device(struct device *dev) 348 344 { 349 345 u16 val; 346 + int ret; 350 347 351 - ade7753_spi_read_reg_16(dev, ADE7753_MODE, &val); 348 + ret = ade7753_spi_read_reg_16(dev, ADE7753_MODE, &val); 349 + if (ret) 350 + return ret; 351 + 352 352 val |= BIT(4); /* AD converters can be turned off */ 353 353 354 354 return ade7753_spi_write_reg_16(dev, ADE7753_MODE, val);
+1 -1
drivers/staging/speakup/Kconfig
··· 1 1 menu "Speakup console speech" 2 2 3 3 config SPEAKUP 4 - depends on VT 4 + depends on VT && !MN10300 5 5 tristate "Speakup core" 6 6 ---help--- 7 7 This is the Speakup screen reader. Think of it as a