All of lore.kernel.org
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Jean-Francois Moine <moinejf@free.fr>
Cc: devel@driverdev.osuosl.org, alsa-devel@alsa-project.org,
	Daniel Vetter <daniel@ffwll.ch>, Takashi Iwai <tiwai@suse.de>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	dri-devel@lists.freedesktop.org,
	Sascha Hauer <kernel@pengutronix.de>,
	linux-arm-kernel@lists.infradead.org,
	linux-media@vger.kernel.org
Subject: Re: [PATCH RFC 0/2] drivers/base: simplify simple DT-based components
Date: Fri, 7 Feb 2014 18:59:11 +0000	[thread overview]
Message-ID: <20140207185911.GG26684@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <20140207194204.4d4326bd@armhf>

On Fri, Feb 07, 2014 at 07:42:04PM +0100, Jean-Francois Moine wrote:
> On Fri, 7 Feb 2014 17:33:26 +0000
> Russell King - ARM Linux <linux@arm.linux.org.uk> wrote:
> 
> > On Fri, Feb 07, 2014 at 06:11:08PM +0100, Jean-Francois Moine wrote:
> > > This patch series tries to simplify the code of simple devices in case
> > > they are part of componentised subsystems, are declared in a DT, and
> > > are not using the component bin/unbind functions.
> > 
> > I wonder - I said earlier today that this works absolutely fine without
> > modification with DT, so why are you messing about with it adding DT
> > support?
> > 
> > This is totally the wrong approach.  The idea is that this deals with
> > /devices/ and /devices/ only.  It groups up /devices/.
> > 
> > It's up to the add_component callback to the master device to decide
> > how to deal with that.
> > 
> > > Jean-Francois Moine (2):
> > >   drivers/base: permit base components to omit the bind/unbind ops
> > 
> > And this patch has me wondering if you even understand how to use
> > this...  The master bind/unbind callbacks are the ones which establish
> > the "card" based context with the subsystem.
> > 
> > Please, before buggering up this nicely designed implementation, please
> > /first/ look at the imx-drm rework which was posted back in early January
> > which illustrates how this is used in a DT context - which is something
> > I've already pointed you at once today already.
> 
> As I told in a previous mail, your code works fine in my DT-based
> Cubox. I am rewriting the TDA988x as a normal encoder/connector, and,
> yes, the bind/unbind functions are useful in this case.

So, which bit of "I've already got that" was missed?

> But you opened a door. In a DT context, you know that the probe_defer
> mechanism does not work correctly. Your work permits to solve delicate
> cases: your component_add tells exactly when a device is available, and
> the master bind callback is the green signal for the device waiting for
> its resources. Indeed, your system was not created for such a usage,
> but it works as it is (anyway, the component bind/unbind functions may
> be empty...).

Sorry.  Deferred probe does work, it's been tested with imx-drm, not
only from the master component but also the sub-components.  There's
no problem here.

And no component bind/unbind function should ever be empty.

Again, I put it to you that you don't understand this layer.

-- 
FTTC broadband for 0.8mile line: 5.8Mbps down 500kbps up.  Estimation
in database were 13.1 to 19Mbit for a good line, about 7.5+ for a bad.
Estimate before purchase was "up to 13.2Mbit".

WARNING: multiple messages have this Message-ID (diff)
From: linux@arm.linux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH RFC 0/2] drivers/base: simplify simple DT-based components
Date: Fri, 7 Feb 2014 18:59:11 +0000	[thread overview]
Message-ID: <20140207185911.GG26684@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <20140207194204.4d4326bd@armhf>

On Fri, Feb 07, 2014 at 07:42:04PM +0100, Jean-Francois Moine wrote:
> On Fri, 7 Feb 2014 17:33:26 +0000
> Russell King - ARM Linux <linux@arm.linux.org.uk> wrote:
> 
> > On Fri, Feb 07, 2014 at 06:11:08PM +0100, Jean-Francois Moine wrote:
> > > This patch series tries to simplify the code of simple devices in case
> > > they are part of componentised subsystems, are declared in a DT, and
> > > are not using the component bin/unbind functions.
> > 
> > I wonder - I said earlier today that this works absolutely fine without
> > modification with DT, so why are you messing about with it adding DT
> > support?
> > 
> > This is totally the wrong approach.  The idea is that this deals with
> > /devices/ and /devices/ only.  It groups up /devices/.
> > 
> > It's up to the add_component callback to the master device to decide
> > how to deal with that.
> > 
> > > Jean-Francois Moine (2):
> > >   drivers/base: permit base components to omit the bind/unbind ops
> > 
> > And this patch has me wondering if you even understand how to use
> > this...  The master bind/unbind callbacks are the ones which establish
> > the "card" based context with the subsystem.
> > 
> > Please, before buggering up this nicely designed implementation, please
> > /first/ look at the imx-drm rework which was posted back in early January
> > which illustrates how this is used in a DT context - which is something
> > I've already pointed you at once today already.
> 
> As I told in a previous mail, your code works fine in my DT-based
> Cubox. I am rewriting the TDA988x as a normal encoder/connector, and,
> yes, the bind/unbind functions are useful in this case.

So, which bit of "I've already got that" was missed?

> But you opened a door. In a DT context, you know that the probe_defer
> mechanism does not work correctly. Your work permits to solve delicate
> cases: your component_add tells exactly when a device is available, and
> the master bind callback is the green signal for the device waiting for
> its resources. Indeed, your system was not created for such a usage,
> but it works as it is (anyway, the component bind/unbind functions may
> be empty...).

Sorry.  Deferred probe does work, it's been tested with imx-drm, not
only from the master component but also the sub-components.  There's
no problem here.

And no component bind/unbind function should ever be empty.

Again, I put it to you that you don't understand this layer.

-- 
FTTC broadband for 0.8mile line: 5.8Mbps down 500kbps up.  Estimation
in database were 13.1 to 19Mbit for a good line, about 7.5+ for a bad.
Estimate before purchase was "up to 13.2Mbit".

WARNING: multiple messages have this Message-ID (diff)
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Jean-Francois Moine <moinejf@free.fr>
Cc: devel@driverdev.osuosl.org, alsa-devel@alsa-project.org,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	dri-devel@lists.freedesktop.org, Takashi Iwai <tiwai@suse.de>,
	Sascha Hauer <kernel@pengutronix.de>,
	linux-arm-kernel@lists.infradead.org,
	linux-media@vger.kernel.org, Daniel Vetter <daniel@ffwll.ch>
Subject: Re: [PATCH RFC 0/2] drivers/base: simplify simple DT-based components
Date: Fri, 7 Feb 2014 18:59:11 +0000	[thread overview]
Message-ID: <20140207185911.GG26684@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <20140207194204.4d4326bd@armhf>

On Fri, Feb 07, 2014 at 07:42:04PM +0100, Jean-Francois Moine wrote:
> On Fri, 7 Feb 2014 17:33:26 +0000
> Russell King - ARM Linux <linux@arm.linux.org.uk> wrote:
> 
> > On Fri, Feb 07, 2014 at 06:11:08PM +0100, Jean-Francois Moine wrote:
> > > This patch series tries to simplify the code of simple devices in case
> > > they are part of componentised subsystems, are declared in a DT, and
> > > are not using the component bin/unbind functions.
> > 
> > I wonder - I said earlier today that this works absolutely fine without
> > modification with DT, so why are you messing about with it adding DT
> > support?
> > 
> > This is totally the wrong approach.  The idea is that this deals with
> > /devices/ and /devices/ only.  It groups up /devices/.
> > 
> > It's up to the add_component callback to the master device to decide
> > how to deal with that.
> > 
> > > Jean-Francois Moine (2):
> > >   drivers/base: permit base components to omit the bind/unbind ops
> > 
> > And this patch has me wondering if you even understand how to use
> > this...  The master bind/unbind callbacks are the ones which establish
> > the "card" based context with the subsystem.
> > 
> > Please, before buggering up this nicely designed implementation, please
> > /first/ look at the imx-drm rework which was posted back in early January
> > which illustrates how this is used in a DT context - which is something
> > I've already pointed you at once today already.
> 
> As I told in a previous mail, your code works fine in my DT-based
> Cubox. I am rewriting the TDA988x as a normal encoder/connector, and,
> yes, the bind/unbind functions are useful in this case.

So, which bit of "I've already got that" was missed?

> But you opened a door. In a DT context, you know that the probe_defer
> mechanism does not work correctly. Your work permits to solve delicate
> cases: your component_add tells exactly when a device is available, and
> the master bind callback is the green signal for the device waiting for
> its resources. Indeed, your system was not created for such a usage,
> but it works as it is (anyway, the component bind/unbind functions may
> be empty...).

Sorry.  Deferred probe does work, it's been tested with imx-drm, not
only from the master component but also the sub-components.  There's
no problem here.

And no component bind/unbind function should ever be empty.

Again, I put it to you that you don't understand this layer.

-- 
FTTC broadband for 0.8mile line: 5.8Mbps down 500kbps up.  Estimation
in database were 13.1 to 19Mbit for a good line, about 7.5+ for a bad.
Estimate before purchase was "up to 13.2Mbit".

  reply	other threads:[~2014-02-07 18:59 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-07 17:11 [PATCH RFC 0/2] drivers/base: simplify simple DT-based components Jean-Francois Moine
2014-02-07 17:11 ` Jean-Francois Moine
2014-02-07 17:11 ` Jean-Francois Moine
2014-02-07 15:55 ` [PATCH RFC 1/2] drivers/base: permit base components to omit the bind/unbind ops Jean-Francois Moine
2014-02-07 15:55   ` Jean-Francois Moine
2014-02-07 15:55   ` Jean-Francois Moine
2014-02-07 17:34   ` Russell King - ARM Linux
2014-02-07 17:34     ` Russell King - ARM Linux
2014-02-07 17:34     ` Russell King - ARM Linux
2014-02-07 16:53 ` [PATCH RFC 2/2] drivers/base: declare phandle DT nodes as components Jean-Francois Moine
2014-02-07 16:53   ` Jean-Francois Moine
2014-02-07 17:43   ` Russell King - ARM Linux
2014-02-07 17:43     ` Russell King - ARM Linux
2014-02-07 17:43     ` Russell King - ARM Linux
2014-02-07 17:33 ` [PATCH RFC 0/2] drivers/base: simplify simple DT-based components Russell King - ARM Linux
2014-02-07 17:33   ` Russell King - ARM Linux
2014-02-07 17:33   ` Russell King - ARM Linux
2014-02-07 18:42   ` Jean-Francois Moine
2014-02-07 18:42     ` Jean-Francois Moine
2014-02-07 18:59     ` Russell King - ARM Linux [this message]
2014-02-07 18:59       ` Russell King - ARM Linux
2014-02-07 18:59       ` Russell King - ARM Linux
2014-02-08  0:23       ` Russell King - ARM Linux
2014-02-08  0:23         ` Russell King - ARM Linux
2014-02-08  0:23         ` Russell King - ARM Linux
2014-02-07 20:23 ` Russell King - ARM Linux
2014-02-07 20:23   ` Russell King - ARM Linux
2014-02-07 20:23   ` Russell King - ARM Linux
2014-02-09  9:22   ` Jean-Francois Moine
2014-02-09  9:22     ` Jean-Francois Moine
2014-02-09  9:22     ` Jean-Francois Moine
2014-02-09 10:04     ` Russell King - ARM Linux
2014-02-09 10:04       ` Russell King - ARM Linux
2014-02-09 10:04       ` Russell King - ARM Linux

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=20140207185911.GG26684@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=alsa-devel@alsa-project.org \
    --cc=daniel@ffwll.ch \
    --cc=devel@driverdev.osuosl.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-media@vger.kernel.org \
    --cc=moinejf@free.fr \
    --cc=tiwai@suse.de \
    /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.