staging: iio: push the main buffer chrdev down to the top level.
[deliverable/linux.git] / drivers / staging / iio / accel / adis16201_core.c
index 2b8c5e9c33e543e4794a73ee2706c4ab4708d684..d16c45959fd3da4ea279ca2ce46a6f381d787311 100644 (file)
@@ -497,7 +497,7 @@ static int __devinit adis16201_probe(struct spi_device *spi)
                goto error_unreg_ring_funcs;
        regdone = 1;
 
-       ret = iio_ring_buffer_register_ex(indio_dev->ring, 0,
+       ret = iio_ring_buffer_register_ex(indio_dev, 0,
                                          adis16201_channels,
                                          ARRAY_SIZE(adis16201_channels));
        if (ret) {
@@ -520,7 +520,7 @@ static int __devinit adis16201_probe(struct spi_device *spi)
 error_remove_trigger:
        adis16201_remove_trigger(indio_dev);
 error_uninitialize_ring:
-       iio_ring_buffer_unregister(indio_dev->ring);
+       iio_ring_buffer_unregister(indio_dev);
 error_unreg_ring_funcs:
        adis16201_unconfigure_ring(indio_dev);
 error_free_dev:
@@ -537,7 +537,7 @@ static int adis16201_remove(struct spi_device *spi)
        struct iio_dev *indio_dev = spi_get_drvdata(spi);
 
        adis16201_remove_trigger(indio_dev);
-       iio_ring_buffer_unregister(indio_dev->ring);
+       iio_ring_buffer_unregister(indio_dev);
        iio_device_unregister(indio_dev);
        adis16201_unconfigure_ring(indio_dev);
 
This page took 0.045305 seconds and 5 git commands to generate.