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.

+5 -3
+2
drivers/iio/adc/at91-sama5d2_adc.c
··· 451 if (ret) 452 goto vref_disable; 453 454 ret = iio_device_register(indio_dev); 455 if (ret < 0) 456 goto per_clk_disable_unprepare;
··· 451 if (ret) 452 goto vref_disable; 453 454 + platform_set_drvdata(pdev, indio_dev); 455 + 456 ret = iio_device_register(indio_dev); 457 if (ret < 0) 458 goto per_clk_disable_unprepare;
+3 -3
drivers/iio/magnetometer/ak8975.c
··· 462 int rc; 463 int irq; 464 465 if (client->irq) 466 irq = client->irq; 467 else ··· 479 return rc; 480 } 481 482 - init_waitqueue_head(&data->data_ready_queue); 483 - clear_bit(0, &data->flags); 484 data->eoc_irq = irq; 485 486 return rc; ··· 732 int eoc_gpio; 733 int err; 734 const char *name = NULL; 735 - enum asahi_compass_chipset chipset; 736 737 /* Grab and set up the supplied GPIO. */ 738 if (client->dev.platform_data)
··· 462 int rc; 463 int irq; 464 465 + init_waitqueue_head(&data->data_ready_queue); 466 + clear_bit(0, &data->flags); 467 if (client->irq) 468 irq = client->irq; 469 else ··· 477 return rc; 478 } 479 480 data->eoc_irq = irq; 481 482 return rc; ··· 732 int eoc_gpio; 733 int err; 734 const char *name = NULL; 735 + enum asahi_compass_chipset chipset = AK_MAX_TYPE; 736 737 /* Grab and set up the supplied GPIO. */ 738 if (client->dev.platform_data)