iio: mxs-lradc: Fix misuse of iio->trig
authorMarek Vasut <marex@denx.de>
Sat, 29 Jun 2013 21:20:00 +0000 (22:20 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 27 Sep 2013 00:18:05 +0000 (17:18 -0700)
commitabea758371f89b0cdb5f0b2dad24674e0148f2ee
tree1558279d712cfc5e3617eeeec16cd4d380926ce4
parent6b844e7d601f709942cf15e5f5808953f5382402
iio: mxs-lradc: Fix misuse of iio->trig

commit e1b1fa66a0398f0b52ae79a2bdc7de87c205d074 upstream.

The struct iio_dev .trig field is to be used only by the IIO core,
the driver shall not fill this field. This fixes ugly crash when
the driver is compiled as a module and the module is rmmod'd.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Fabio Estevam <fabio.estevam@freescale.com>
Cc: Jonathan Cameron <jic23@kernel.org>
Cc: Shawn Guo <shawn.guo@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/iio/adc/mxs-lradc.c