Linux IIO development
 help / color / mirror / Atom feed
From: Philippe De Muyter <phdm@macq.eu>
To: Lorenzo Bianconi <lorenzo@kernel.org>
Cc: Jonathan Cameron <Jonathan.Cameron@huawei.com>,
	linux-iio@vger.kernel.org
Subject: Re: sysfs mount_matrix for st_lsm6dsx gyro
Date: Fri, 13 Jan 2023 15:45:44 +0100	[thread overview]
Message-ID: <20230113144544.GA32740@frolo.macqel> (raw)
In-Reply-To: <Y7/vu7IwRmQS7CSf@lore-desk>

On Thu, Jan 12, 2023 at 12:32:11PM +0100, Lorenzo Bianconi wrote:
> > I have followed Jonathan's proposal and added this simple patch in
> > the definition of the ST_LSM6DSX_CHANNEL macro :
> > 
> > diff --git a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx.h b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx.h
> > index d80ba2e688ed..9d18145d5041 100644
> > --- a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx.h
> > +++ b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx.h
> > @@ -96,6 +96,7 @@ enum st_lsm6dsx_hw_id {
> >  		.storagebits = 16,                                      \
> >  		.endianness = IIO_LE,                                   \
> > 	},                                                              \
> > +	.ext_info = st_lsm6dsx_accel_ext_info,                          \
> >  }
> 
> I am fine with this approach, probably having a per-sensor mount_matrix is
> unnecessary. Can you please just rename st_lsm6dsx_accel_ext_info in
> st_lsm6dsx_ext_info?
> 

The compilation fails because there is already something different with
that same name in drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c

 drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c:715:30: error: conflicting type qualifiers for ‘st_lsm6dsx_ext_info’
  static const struct iio_info st_lsm6dsx_ext_info = {
                               ^~~~~~~~~~~~~~~~~~~
 In file included from drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c:31:0:
 drivers/iio/imu/st_lsm6dsx/st_lsm6dsx.h:498:46: note: previous definition of ‘st_lsm6dsx_ext_info’ was here
 struct iio_chan_spec_ext_info __maybe_unused st_lsm6dsx_ext_info[] = {


Best regards

Philippe

  parent reply	other threads:[~2023-01-13 14:59 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-11 12:09 sysfs mount_matrix for st_lsm6dsx gyro Philippe De Muyter
2023-01-11 17:17 ` Jonathan Cameron
2023-01-12  9:51   ` Lorenzo Bianconi
2023-01-12 11:27     ` Philippe De Muyter
2023-01-12 11:32       ` Lorenzo Bianconi
2023-01-12 15:19         ` Jonathan Cameron
2023-01-13 14:45         ` Philippe De Muyter [this message]
2023-01-12 10:12   ` Lorenzo Bianconi

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=20230113144544.GA32740@frolo.macqel \
    --to=phdm@macq.eu \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=linux-iio@vger.kernel.org \
    --cc=lorenzo@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox