lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
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 netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ