From: Ivan T. Ivanov Date: Wed, 22 Oct 2014 15:29:43 +0000 (+0300) Subject: iio: inkern: Add of_xlate function to struct iio_info X-Git-Tag: omap-for-v3.19/fixes-rc1~73^2~446^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=acd8256723f286b7217801fbed24503f8565b91e;p=pandora-kernel.git iio: inkern: Add of_xlate function to struct iio_info When #iio-cells is greater than '0', the driver could provide a custom of_xlate function that reads the *args* and returns the appropriate index in registered IIO channels array. Add simple translation function, suitable for the most 1:1 mapped channels in IIO chips, and use it when driver did not provide custom implementation. Signed-off-by: Ivan T. Ivanov Reviewed-by: Lars-Peter Clausen Signed-off-by: Jonathan Cameron --- Reading git-diff-tree failed