Re: [PATCH 2/3] staging:iio:dac:max517: Convert to channel spec

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/14/2012 3:31 PM, Lars-Peter Clausen wrote:
On 05/12/2012 08:51 PM, Jonathan Cameron wrote:
[...]
-static const struct iio_info max518_info = {
-	.attrs =&max518_attribute_group,
-	.driver_module = THIS_MODULE,
+#define MAX517_CHANNEL(chan) {				\
+	.type = IIO_VOLTAGE,					\
+	.indexed = 1,						\
+	.output = 1,						\
+	.channel = (chan),					\
+	.info_mask = IIO_CHAN_INFO_RAW_SEPARATE_BIT |		\
+	IIO_CHAN_INFO_SCALE_SEPARATE_BIT,			\
I suppose the scan_type acts as kind of documentation, but
it's not really relevant or necessary here... I'd scrap it.

I'd like to keep it, because I think it will be used in the future. E.g. for
buffer output, but also some other things might make use of it.
I'll let it go then...

+	.scan_type = IIO_ST('u', 8, 8, 0),	\
+}


--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux