From: Andrew F. Davis Date: Mon, 14 Dec 2015 22:35:57 +0000 (-0600) Subject: iio: Make IIO value formating function globally available. X-Git-Tag: Ubuntu-4.10.0-19.21~4163^2~4^2~4 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=7d2c2acac577959dbbddefefa91d1ba1b80460b3;p=mirror_ubuntu-artful-kernel.git iio: Make IIO value formating function globally available. Make IIO value formating function globally available to allow IIO drivers to output values as the core does. Signed-off-by: Andrew F. Davis Signed-off-by: Jonathan Cameron --- diff --git a/drivers/iio/industrialio-core.c b/drivers/iio/industrialio-core.c index d0a84febd435..a45eb2c53d0f 100644 --- a/drivers/iio/industrialio-core.c +++ b/drivers/iio/industrialio-core.c @@ -470,6 +470,7 @@ ssize_t iio_format_value(char *buf, unsigned int type, int size, int *vals) return 0; } } +EXPORT_SYMBOL_GPL(iio_format_value); static ssize_t iio_read_channel_info(struct device *dev, struct device_attribute *attr, diff --git a/include/linux/iio/iio.h b/include/linux/iio/iio.h index 19c94c9acc81..b5894118755f 100644 --- a/include/linux/iio/iio.h +++ b/include/linux/iio/iio.h @@ -636,6 +636,8 @@ static inline struct dentry *iio_get_debugfs_dentry(struct iio_dev *indio_dev) } #endif +ssize_t iio_format_value(char *buf, unsigned int type, int size, int *vals); + int iio_str_to_fixpoint(const char *str, int fract_mult, int *integer, int *fract);