All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lee Jones <lee.jones-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
To: Shiraz Hashim <shiraz.hashim-qxv4g6HH51o@public.gmane.org>
Cc: sameo-VuQAYsv1563Yd54FQh9/CA@public.gmane.org,
	Viresh Kumar
	<viresh.kumar-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org,
	spear-devel-nkJGhpqTU55BDgjK7y7TUQ@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH V2 2/2] mfd: stmpe: Extend DT support in stmpe driver
Date: Fri, 23 Nov 2012 09:33:52 +0000	[thread overview]
Message-ID: <20121123093352.GC17471@gmail.com> (raw)
In-Reply-To: <20121123034557.GB5384-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>

On Fri, 23 Nov 2012, Shiraz Hashim wrote:

> On Thu, Nov 22, 2012 at 10:31:48PM +0530, Viresh Kumar wrote:
> > On 22 November 2012 21:16, Lee Jones <lee.jones@linaro.org> wrote:
> > > The STMPE GPIO controller can't be used by Device Tree yet in
> > > any case, because it doesn't have an IRQ domain. This is
> > > compulsory, or it won't work. Have you tried to test this
> > > functionality yet?
> > 
> > I don't have SPEAr board to test it anymore. I have moved out of
> > ST now and working in linaro as ARM asignee. Just pushing these
> > as an part time activity.
> > 
> > Though ST guys would have tested stmpe, but stmpe-gpio, i am not
> > sure about.
> 
> Let me bring some more information here. I totally understand
> Jones concerns, but the way stmpe (and may be other mfd devices)
> are handled is this that the parent block (i.e. stmpe) decides on
> the variants (say by probing device itself) and then prepares
> associated data for the (probed) variant and creates a platform
> device for the same.

I realise this, but now we're using Device Tree, there's no need
to stuff pdata in the parent driver now. It's better that the
child devices are self sufficient.

> For the interrupts case also, it is stmpe which registers the
> irq domain. This is because, stmpe driver probes variant and
> populates its platform data and stmpe-gpio may not be aware of the
> variant it serves. At the same time, it (stmpe) needs few of the
> (virtual) interrupts for its internal purpose also.

I know. I wrote the IRQ domain for STMPE. ;)

STMPE needs its own one too, which I will work on now.

STMPE-GPIO doesn't need to be aware of anything, the device
which wishes to use its GPIOs/IRQs will reference it from
Device Tree in the manor previously explained.

> Hence stmpe passes irq_base to the stmpe-gpio driver while
> allocating and registering irq domain by itself.

Not anymore it doesn't. There are no irq_base:s with DT. All
IRQs are dynamic, hence why STMPE requires its own domain to
play with. I can fix that.

> With this approach we have tested the functionality on SPEAr
> platform.

You'll need to test it again with the new DT approach too. :)

-- 
Lee Jones
Linaro ST-Ericsson Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
_______________________________________________
devicetree-discuss mailing list
devicetree-discuss@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/devicetree-discuss

WARNING: multiple messages have this Message-ID (diff)
From: Lee Jones <lee.jones@linaro.org>
To: Shiraz Hashim <shiraz.hashim@st.com>
Cc: Viresh Kumar <viresh.kumar@linaro.org>,
	sameo@linux.intel.com, devicetree-discuss@lists.ozlabs.org,
	linux-kernel@vger.kernel.org, spear-devel@list.st.com,
	Vipul Kumar Samar <vipulkumar.samar@st.com>
Subject: Re: [PATCH V2 2/2] mfd: stmpe: Extend DT support in stmpe driver
Date: Fri, 23 Nov 2012 09:33:52 +0000	[thread overview]
Message-ID: <20121123093352.GC17471@gmail.com> (raw)
In-Reply-To: <20121123034557.GB5384@localhost.localdomain>

On Fri, 23 Nov 2012, Shiraz Hashim wrote:

> On Thu, Nov 22, 2012 at 10:31:48PM +0530, Viresh Kumar wrote:
> > On 22 November 2012 21:16, Lee Jones <lee.jones@linaro.org> wrote:
> > > The STMPE GPIO controller can't be used by Device Tree yet in
> > > any case, because it doesn't have an IRQ domain. This is
> > > compulsory, or it won't work. Have you tried to test this
> > > functionality yet?
> > 
> > I don't have SPEAr board to test it anymore. I have moved out of
> > ST now and working in linaro as ARM asignee. Just pushing these
> > as an part time activity.
> > 
> > Though ST guys would have tested stmpe, but stmpe-gpio, i am not
> > sure about.
> 
> Let me bring some more information here. I totally understand
> Jones concerns, but the way stmpe (and may be other mfd devices)
> are handled is this that the parent block (i.e. stmpe) decides on
> the variants (say by probing device itself) and then prepares
> associated data for the (probed) variant and creates a platform
> device for the same.

I realise this, but now we're using Device Tree, there's no need
to stuff pdata in the parent driver now. It's better that the
child devices are self sufficient.

> For the interrupts case also, it is stmpe which registers the
> irq domain. This is because, stmpe driver probes variant and
> populates its platform data and stmpe-gpio may not be aware of the
> variant it serves. At the same time, it (stmpe) needs few of the
> (virtual) interrupts for its internal purpose also.

I know. I wrote the IRQ domain for STMPE. ;)

STMPE needs its own one too, which I will work on now.

STMPE-GPIO doesn't need to be aware of anything, the device
which wishes to use its GPIOs/IRQs will reference it from
Device Tree in the manor previously explained.

> Hence stmpe passes irq_base to the stmpe-gpio driver while
> allocating and registering irq domain by itself.

Not anymore it doesn't. There are no irq_base:s with DT. All
IRQs are dynamic, hence why STMPE requires its own domain to
play with. I can fix that.

> With this approach we have tested the functionality on SPEAr
> platform.

You'll need to test it again with the new DT approach too. :)

-- 
Lee Jones
Linaro ST-Ericsson Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

  parent reply	other threads:[~2012-11-23  9:33 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-22  5:10 [PATCH V2 1/2] mfd: stmpe: Use devm_*() routines Viresh Kumar
2012-11-22  5:10 ` Viresh Kumar
     [not found] ` <f1d508c64a01dfd492a1ab1fda28af4b7647d8ab.1353560936.git.viresh.kumar-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2012-11-22  5:10   ` [PATCH V2 2/2] mfd: stmpe: Extend DT support in stmpe driver Viresh Kumar
2012-11-22  5:10     ` Viresh Kumar
     [not found]     ` <b81641051dad9660b72b0028d001e5620d901160.1353560936.git.viresh.kumar-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2012-11-22 11:24       ` Lee Jones
2012-11-22 11:24         ` Lee Jones
     [not found]         ` <20121122112451.GE4328-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-11-22 13:54           ` Viresh Kumar
2012-11-22 13:54             ` Viresh Kumar
     [not found]             ` <CAKohpo=F91sZ7St3XVXqwAEgmSWXjAxxXwRs1RD5qPyW99P1vA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-11-22 15:46               ` Lee Jones
2012-11-22 15:46                 ` Lee Jones
     [not found]                 ` <20121122154612.GC10986-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-11-22 17:01                   ` Viresh Kumar
2012-11-22 17:01                     ` Viresh Kumar
2012-11-23  3:45                     ` Shiraz Hashim
2012-11-23  3:45                       ` Shiraz Hashim
     [not found]                       ` <20121123034557.GB5384-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org>
2012-11-23  9:33                         ` Lee Jones [this message]
2012-11-23  9:33                           ` Lee Jones
2012-11-23  9:23                     ` Lee Jones
2012-11-22 18:31           ` Viresh Kumar
2012-11-22 18:31             ` Viresh Kumar
2012-11-23  9:39             ` Lee Jones
2012-11-23  4:29           ` Viresh Kumar
2012-11-23  4:29             ` Viresh Kumar
2012-11-23  9:36             ` Lee Jones
2012-11-23 12:39               ` Viresh Kumar
2012-11-23 15:43                 ` Lee Jones
2012-11-23 15:45                   ` Viresh Kumar
2012-11-22 10:27   ` [PATCH V2 1/2] mfd: stmpe: Use devm_*() routines Lee Jones
2012-11-22 10:27     ` Lee Jones
     [not found]     ` <20121122102710.GD4328-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-11-22 10:30       ` Viresh Kumar
2012-11-22 10:30         ` Viresh Kumar
2012-11-22 17:10       ` Viresh Kumar
2012-11-22 17:10         ` Viresh Kumar
     [not found]         ` <CAKohpo=gctcd5+bZ8xeJn-Cx3=+=+uxaCzEoZhFmp+XaJSpf9Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-11-23  9:40           ` Lee Jones
2012-11-23  9:40             ` Lee Jones
2012-11-23  9:42             ` Lee Jones
2012-11-23  9:44             ` Viresh Kumar
2012-11-23 11:03 ` Samuel Ortiz

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=20121123093352.GC17471@gmail.com \
    --to=lee.jones-qsej5fyqhm4dnm+yrofe0a@public.gmane.org \
    --cc=devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=sameo-VuQAYsv1563Yd54FQh9/CA@public.gmane.org \
    --cc=shiraz.hashim-qxv4g6HH51o@public.gmane.org \
    --cc=spear-devel-nkJGhpqTU55BDgjK7y7TUQ@public.gmane.org \
    --cc=viresh.kumar-QSEj5FYQhm4dnm+yROfE0A@public.gmane.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 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.