[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <1217490173.3454.47.camel@pmac.infradead.org>
Date: Thu, 31 Jul 2008 08:42:53 +0100
From: David Woodhouse <dwmw2@...radead.org>
To: David Dillow <dave@...dillows.org>
Cc: Jaswinder Singh <jaswinder@...radead.org>,
LKML <linux-kernel@...r.kernel.org>, becker@...ld.com,
davidpmclean@...oo.com, Jeff Garzik <jeff@...zik.org>,
netdev <netdev@...r.kernel.org>
Subject: Re: [PATCH] typhoon: use request_firmware
On Wed, 2008-07-30 at 23:37 -0400, David Dillow wrote:
> request_firmware()'s mutex is protecting against things inside of that
> subsystem, but offers no protection between the test on typhoon_fw !=
> NULL and the setting of it inside of the firmware loader. That
> requires locking at a higher level.
>
> Anyways, probing is single threaded and I seem to recall it being
> unlikely to be made parallel due to the number issues exposed last
> time, so a minimal comment is fine.
An alternative approach is to make request_firmware() do the duplicate
avoidance for itself. Since we made fw->data const (as 'fw' itself
always was), no users should be changing anything in the requested
firmware. It can be safely reused by generic code.
That simplifies the logic in drivers -- they just request what they
want, as many times as they want it, and don't have to care about the
potential duplication.
--
dwmw2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists