Skip to content

Commit

Permalink
iio: Make IIO value formating function globally available.
Browse files Browse the repository at this point in the history
Make IIO value formating function globally available to allow IIO drivers
to output values as the core does.

Signed-off-by: Andrew F. Davis <afd@ti.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
  • Loading branch information
Andrew F. Davis authored and Jonathan Cameron committed Dec 22, 2015
1 parent e60378c commit 7d2c2ac
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions drivers/iio/industrialio-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
2 changes: 2 additions & 0 deletions include/linux/iio/iio.h
Original file line number Diff line number Diff line change
Expand Up @@ -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);

Expand Down

0 comments on commit 7d2c2ac

Please sign in to comment.