[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20141125134901.GF7712@sirena.org.uk>
Date: Tue, 25 Nov 2014 13:49:01 +0000
From: Mark Brown <broonie@...nel.org>
To: Lars-Peter Clausen <lars@...afoo.de>
Cc: Jean-Francois Moine <moinejf@...e.fr>,
Liam Girdwood <lgirdwood@...il.com>,
Russell King <linux@....linux.org.uk>,
alsa-devel@...a-project.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v3] ASoC: Remove 'const' from the device_node pointers
On Tue, Nov 25, 2014 at 02:36:15PM +0100, Lars-Peter Clausen wrote:
> On 11/25/2014 02:13 PM, Mark Brown wrote:
> >So, we're not holding references here (we're just doing comparisons, the
> >references need to be owned before we get into the core)
> The core itself will only do the comparisons and it is the board drivers
> responsibility to get and put the references. Making the pointers non const
> allows the board driver to use them to put the reference once the card has
> been unregistered rather than having to keep a separate set of pointers
Wouldn't it be even better to have managed OF references and not need to
explicitly dereference at all? Otherwise every time something uses
managed resources for the card or component we've got a (marginal
admittedly) reference management bug.
> around. This should probably be mentioned in the commit message though.
Yes, it really should - this is really what I'm getting at here since
I'm frequently having to push back on difficult to understand changes
here.
> >I'm not seeing anything here removing casts?
> This patch used to be part of a two part series where the second patch
> removed the casts. This patch as already been applied though.
We don't have warnings at the minute...
Download attachment "signature.asc" of type "application/pgp-signature" (474 bytes)
Powered by blists - more mailing lists