From: Alban Bedel Date: Mon, 20 Apr 2015 11:57:18 +0000 (+0200) Subject: iio:st_sensors: Fix oops when probing SPI devices X-Git-Tag: omap-for-v4.2/soc-pt1-take2~6^2^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8e71c04f863a1754f21b27fb8ecb773d680a0a80;p=pandora-kernel.git iio:st_sensors: Fix oops when probing SPI devices In SPI mode the transfer buffer is locked with a mutex. However this mutex is only initilized after the probe, but some transfer needs to be done in the probe. To fix this bug we move the mutex initialization at the beginning of the device probe. Signed-off-by: Alban Bedel Acked-by: Denis Ciocca Cc: Signed-off-by: Jonathan Cameron --- Reading git-diff-tree failed