Message ID | 20190326134700.24800-1-andriy.shevchenko@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [v1] iio: Make possible to include driver.h first | expand |
On Tue, 26 Mar 2019 15:47:00 +0200 Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote: > If we put headers alphabetically sorted in the IIO driver, > the compilation will abort because of unknown type to handle. > > Simple add a forward declaration of opaque struct iio_dev. > > Suggested-by: Jonathan Cameron <jic23@kernel.org> > Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Applied, Thanks, Jonathan > --- > include/linux/iio/driver.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/linux/iio/driver.h b/include/linux/iio/driver.h > index 7dfb10ee2669..f54a7bcdefe3 100644 > --- a/include/linux/iio/driver.h > +++ b/include/linux/iio/driver.h > @@ -11,6 +11,7 @@ > #ifndef _IIO_INKERN_H_ > #define _IIO_INKERN_H_ > > +struct iio_dev; > struct iio_map; > > /**
diff --git a/include/linux/iio/driver.h b/include/linux/iio/driver.h index 7dfb10ee2669..f54a7bcdefe3 100644 --- a/include/linux/iio/driver.h +++ b/include/linux/iio/driver.h @@ -11,6 +11,7 @@ #ifndef _IIO_INKERN_H_ #define _IIO_INKERN_H_ +struct iio_dev; struct iio_map; /**
If we put headers alphabetically sorted in the IIO driver, the compilation will abort because of unknown type to handle. Simple add a forward declaration of opaque struct iio_dev. Suggested-by: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> --- include/linux/iio/driver.h | 1 + 1 file changed, 1 insertion(+)