All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: Anand Ashok Dumbre <ANANDASH@xilinx.com>
Cc: Jonathan Cameron <jic23@kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Lars-Peter Clausen <lars@metafoo.de>,
	linux-iio <linux-iio@vger.kernel.org>, git <git@xilinx.com>,
	Michal Simek <michals@xilinx.com>,
	Peter Meerwald <pmeerw@pmeerw.net>,
	devicetree <devicetree@vger.kernel.org>,
	Manish Narani <MNARANI@xilinx.com>
Subject: Re: [PATCH v8 2/4] iio: adc: Add Xilinx AMS driver
Date: Mon, 15 Nov 2021 14:13:43 +0200	[thread overview]
Message-ID: <CAHp75VeemaMFCLncFAF24RU6kEbj=9F3w5LWjA-o-uky=pO=5w@mail.gmail.com> (raw)
In-Reply-To: <BY5PR02MB6916142EBF6AE18E49273A94A9989@BY5PR02MB6916.namprd02.prod.outlook.com>

On Mon, Nov 15, 2021 at 1:59 PM Anand Ashok Dumbre <ANANDASH@xilinx.com> wrote:

...

> > > > +             ams->pl_base = of_iomap(node, 0);
> > >
> > > Hmm. So of_iomap() leaves us dependent on dt specific calls. Whilst it
> > > doesn't exactly look hard to create a generic version covering at
> > > least dt and acpi I don' think there is an equivalent acpi function currently
> > defined.
> > >
> > > Andy, do you think this is a good thing to add to the generic firmware
> > > node handling?  It's a bit specialist as most of the time this will be
> > > wrapped up in the platform device handling or similar rather than being in a
> > child node like this.
> >
> > I saw this issue previously somewhere else and we can do something about
> > it.
> > But first (before going to ACPI guts) we may indeed introduce a basic
> > skeleton under fwnode API for this.
> >
> > Something like
> >
> > void __iomem *fwnode_iomap(...)
> > {
> >   if (is_of_node(fwnode))
> >     return of_iomap();
> >   return NULL;
> > }
> > EXPORT_SYMBOL_GPL(fwnode_iomap);
> >
> > At least it will allow drivers to make them property provider agnostic.
> >
> > Okay, I checked the current version of the ACPI specification and the
> > proposed DTS here. With above API and something like
> >
> > Device (AMS0) {
> >   Name (_CRS, ...)
> >   ...
> >   Device (PLMN) {
> >     Name (_CRS, ...)
> >   }
> >   Device (PSMN) {
> >     Name (_CRS, ...)
> >   }
> > }
> >
> > we may get the resource from the corresponding fwnode's _CRS object
>
> Just to be sure, do I need to do anything for this in this iteration?

Can you provide a helper to drivers/base/property.h for the X-node
iomap() to be agnostic?

(X - SW, FW, ...)

-- 
With Best Regards,
Andy Shevchenko

  reply	other threads:[~2021-11-15 12:14 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-08 21:05 [PATCH v8 0/4] Add Xilinx AMS Driver Anand Ashok Dumbre
2021-11-08 21:05 ` [PATCH v8 1/4] arm64: zynqmp: DT: Add Xilinx AMS node Anand Ashok Dumbre
2021-11-15  9:29   ` Michal Simek
2021-11-08 21:05 ` [PATCH v8 2/4] iio: adc: Add Xilinx AMS driver Anand Ashok Dumbre
2021-11-08 22:55   ` Randy Dunlap
2021-11-09 10:01     ` Anand Ashok Dumbre
2021-11-13 16:17   ` Jonathan Cameron
2021-11-13 18:36     ` Andy Shevchenko
2021-11-15 11:59       ` Anand Ashok Dumbre
2021-11-15 12:13         ` Andy Shevchenko [this message]
2021-11-15 10:58     ` Anand Ashok Dumbre
2021-11-08 21:05 ` [PATCH v8 3/4] dt-bindings: iio: adc: Add Xilinx AMS binding documentation Anand Ashok Dumbre
2021-11-12 15:20   ` Rob Herring
2021-11-15 10:50     ` Anand Ashok Dumbre
2021-11-08 21:05 ` [PATCH v8 4/4] MAINTAINERS: Add maintainer for xilinx-ams Anand Ashok Dumbre

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='CAHp75VeemaMFCLncFAF24RU6kEbj=9F3w5LWjA-o-uky=pO=5w@mail.gmail.com' \
    --to=andy.shevchenko@gmail.com \
    --cc=ANANDASH@xilinx.com \
    --cc=MNARANI@xilinx.com \
    --cc=devicetree@vger.kernel.org \
    --cc=git@xilinx.com \
    --cc=jic23@kernel.org \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michals@xilinx.com \
    --cc=pmeerw@pmeerw.net \
    /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.