All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Peter Meerwald <pmeerw@pmeerw.net>, linux-iio@vger.kernel.org
Cc: Kravchenko Oleksandr <x0199363@ti.com>,
	Lars-Peter Clausen <lars@metafoo.de>
Subject: Re: [PATCH 2/2] iio:accel:bma180: Make LOW_PASS_FILTER_3DB_FREQUENCY shared_by_type
Date: Sat, 08 Feb 2014 11:40:52 +0000	[thread overview]
Message-ID: <52F617C4.2010303@kernel.org> (raw)
In-Reply-To: <52D12E83.9080807@kernel.org>

On 11/01/14 11:44, Jonathan Cameron wrote:
>
>
> On 10/01/14 21:37, Peter Meerwald wrote:
>> the property is not per-channel, but shared by type
>>
> Now this one is in a sense even more interesting.
>
> 1) Your fix is correct.
> 2) Other than poluting sysfs with extra attributes and setting a bad
>     example, it doesn't actually matter as any attribute is defined
>     as being able to effect any other. e.g. if we had two different
>     filters, one for the z axis and another effecting both x and y
>     we would have to define all 3 as separate.
> 3) In theory correctly written generic userspace code should not care
>     as it should handle both cases without a user being any the wiser.
>     Hence this should fall into the category of being able to change
>     userspace ABI if no one notices...
>
> So what shall we do?
>> Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
>> Cc: Kravchenko Oleksandr <x0199363@ti.com>
Peter, I'm not going to put this one through as a fix as the current interface
is fine, if messy.  Given it's dependency on patch 1 of this series, I'll  wait
for that to propogate through. Could you remind me to apply this if I forget!
>> ---
>>   drivers/iio/accel/bma180.c | 4 ++--
>>   1 file changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/iio/accel/bma180.c b/drivers/iio/accel/bma180.c
>> index bfec313..a7e68c8 100644
>> --- a/drivers/iio/accel/bma180.c
>> +++ b/drivers/iio/accel/bma180.c
>> @@ -451,9 +451,9 @@ static const struct iio_chan_spec_ext_info bma180_ext_info[] = {
>>       .type = IIO_ACCEL,                        \
>>       .modified = 1,                            \
>>       .channel2 = IIO_MOD_##_axis,                    \
>> -    .info_mask_separate = BIT(IIO_CHAN_INFO_RAW) |            \
>> +    .info_mask_separate = BIT(IIO_CHAN_INFO_RAW),            \
>> +    .info_mask_shared_by_type = BIT(IIO_CHAN_INFO_SCALE) |        \
>>           BIT(IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY),    \
>> -    .info_mask_shared_by_type = BIT(IIO_CHAN_INFO_SCALE),        \
>>       .scan_index = AXIS_##_axis,                    \
>>       .scan_type = {                            \
>>           .sign = 's',                        \
>>

  reply	other threads:[~2014-02-08 11:40 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-10 21:37 [PATCH 1/2] iio:accel:bma180: Use modifier instead of index in channel specification Peter Meerwald
2014-01-10 21:37 ` [PATCH 2/2] iio:accel:bma180: Make LOW_PASS_FILTER_3DB_FREQUENCY shared_by_type Peter Meerwald
2014-01-11 11:44   ` Jonathan Cameron
2014-02-08 11:40     ` Jonathan Cameron [this message]
2014-02-15 11:05       ` Jonathan Cameron
2014-01-11 11:39 ` [PATCH 1/2] iio:accel:bma180: Use modifier instead of index in channel specification Jonathan Cameron
2014-01-11 15:25   ` Peter Meerwald
2014-02-08 11:37     ` Jonathan Cameron

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52F617C4.2010303@kernel.org \
    --to=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=pmeerw@pmeerw.net \
    --cc=x0199363@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.