3rd set of IIO fixes for the 4.6 cycle.
* ak8975 - fix a null pointer exception if an interrupt occurs during probe. - fix a maybe-unitialized warning. * at91-sama5d2 - fix a crash on removal of the module. -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQIcBAABCAAGBQJXHmHrAAoJEFSFNJnE9BaI8nAQALJLXFmHy1pF51F+lHoOnUf0 Uezdtydg8dzRoLFn85Ky3IxUGGBnEf6UHMAbIplisNCEodOCs6LITJNqU9kUrJdB mWR/6JQPSzH6CpOK0qpGrZ8wTiDT/8YwbD+4TEUkmPf+eZ/jZblmoxpWcl3z2FsW 4ju9w9xtq+Fj0msPmhrb19goAFG0lc6R4B01XnbO16zzGO13Ps98LvRSOXUfH0j8 +OUWSC/teOVa7Fs+iBbB2vLuoZH2jLZJE/xKCOCh3A/SqXYB3SqrkVPZFIqYWGOp Sdq3ErcWG3qsMMojbeBLWD+lNro/mxTKp0uEsGFZnyj7N0xizsrnBsW8KwDAEgxf fHYZ1RuXVokQbJEebb1H2ArkGAPjPtpVZknbsR20oWXFplLNEOZ0ugN9Atd3JR7t 4pY0ZUxyLqcGyQLDx1RKgkp8dA3pXCZd2kQI2fDxcuDOC38mmx21A+Wk5Ef+xuyP MOcIHcOFBV+YEwnVi7wDq04jfgnqs3SLAQdWhIS0JWvwSi/aJBCnhmsQ5kQ5lpkD e8HjYja8fzyIJPXeF7ixbrlkpws4C+3wdm+C10yjuIrQ7TsHmpcdX27oWGDNHUB2 xDHUmQYa5D3dlOhdn71RK4RNVKrNcvF30NEDiCT5strA+bagxApNgZxk9vizxPMi zHfqDynVk/2dGDcedNo7 =VS4P -----END PGP SIGNATURE----- Merge tag 'iio-fixes-for-4.6c' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus Jonathan writes: 3rd set of IIO fixes for the 4.6 cycle. * ak8975 - fix a null pointer exception if an interrupt occurs during probe. - fix a maybe-unitialized warning. * at91-sama5d2 - fix a crash on removal of the module.
This commit is contained in:
commit
431adc0aec
|
@ -451,6 +451,8 @@ static int at91_adc_probe(struct platform_device *pdev)
|
||||||
if (ret)
|
if (ret)
|
||||||
goto vref_disable;
|
goto vref_disable;
|
||||||
|
|
||||||
|
platform_set_drvdata(pdev, indio_dev);
|
||||||
|
|
||||||
ret = iio_device_register(indio_dev);
|
ret = iio_device_register(indio_dev);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
goto per_clk_disable_unprepare;
|
goto per_clk_disable_unprepare;
|
||||||
|
|
|
@ -462,6 +462,8 @@ static int ak8975_setup_irq(struct ak8975_data *data)
|
||||||
int rc;
|
int rc;
|
||||||
int irq;
|
int irq;
|
||||||
|
|
||||||
|
init_waitqueue_head(&data->data_ready_queue);
|
||||||
|
clear_bit(0, &data->flags);
|
||||||
if (client->irq)
|
if (client->irq)
|
||||||
irq = client->irq;
|
irq = client->irq;
|
||||||
else
|
else
|
||||||
|
@ -477,8 +479,6 @@ static int ak8975_setup_irq(struct ak8975_data *data)
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
init_waitqueue_head(&data->data_ready_queue);
|
|
||||||
clear_bit(0, &data->flags);
|
|
||||||
data->eoc_irq = irq;
|
data->eoc_irq = irq;
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
|
@ -732,7 +732,7 @@ static int ak8975_probe(struct i2c_client *client,
|
||||||
int eoc_gpio;
|
int eoc_gpio;
|
||||||
int err;
|
int err;
|
||||||
const char *name = NULL;
|
const char *name = NULL;
|
||||||
enum asahi_compass_chipset chipset;
|
enum asahi_compass_chipset chipset = AK_MAX_TYPE;
|
||||||
|
|
||||||
/* Grab and set up the supplied GPIO. */
|
/* Grab and set up the supplied GPIO. */
|
||||||
if (client->dev.platform_data)
|
if (client->dev.platform_data)
|
||||||
|
|
Loading…
Reference in New Issue