From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from saturn.retrosnub.co.uk ([178.18.118.26]:59696 "EHLO saturn.retrosnub.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751345Ab3LKSpx (ORCPT ); Wed, 11 Dec 2013 13:45:53 -0500 From: Jonathan Cameron To: linux-iio@vger.kernel.org Cc: lars@metafoo.de, pmeerw@pmeerw.net, o.v.kravchenko@globallogic.com, stigge@antcom.de, Jonathan Cameron Subject: [PATCH 23/24] staging:iio:ad799x replaces IIO_ST macro with explicit entries to struct scan_type Date: Wed, 11 Dec 2013 18:45:41 +0000 Message-Id: <1386787542-19666-24-git-send-email-jic23@kernel.org> In-Reply-To: <1386787542-19666-1-git-send-email-jic23@kernel.org> References: <1386787542-19666-1-git-send-email-jic23@kernel.org> Sender: linux-iio-owner@vger.kernel.org List-Id: linux-iio@vger.kernel.org IIO_ST is going away as it is a pain to maintain. As an i2c driver, multi byte words will be read by the driver in the native cpu endianness. Signed-off-by: Jonathan Cameron --- drivers/staging/iio/adc/ad799x_core.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/staging/iio/adc/ad799x_core.c b/drivers/staging/iio/adc/ad799x_core.c index 5ea36410f716..45e64d8bf29b 100644 --- a/drivers/staging/iio/adc/ad799x_core.c +++ b/drivers/staging/iio/adc/ad799x_core.c @@ -409,7 +409,13 @@ static const struct iio_event_spec ad799x_events[] = { .info_mask_separate = BIT(IIO_CHAN_INFO_RAW), \ .info_mask_shared_by_type = BIT(IIO_CHAN_INFO_SCALE), \ .scan_index = (_index), \ - .scan_type = IIO_ST('u', _realbits, 16, 12 - (_realbits)), \ + .scan_type = { \ + .sign = 'u', \ + .realbits = (_realbits), \ + .storagebits = 16, \ + .shift = 12 - (_realbits), \ + .endianness = IIO_CPU, \ + }, \ .event_spec = _ev_spec, \ .num_event_specs = _num_ev_spec, \ } -- 1.8.4.2