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] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACVXFVPs-TSoep3T_Pn3PgNEKWYSCiRNSnNOD66TcERUQJmmeA@mail.gmail.com>
Date:	Fri, 28 Sep 2012 22:07:22 +0800
From:	Ming Lei <ming.lei@...onical.com>
To:	Russell King - ARM Linux <linux@....linux.org.uk>
Cc:	anish singh <anish198519851985@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	linux-kernel@...r.kernel.org, stable@...r.kernel.org
Subject: Re: [PATCH] driver core: fix possible missing of device probe

On Fri, Sep 28, 2012 at 9:55 PM, Russell King - ARM Linux
<linux@....linux.org.uk> wrote:
>> I do not mention threads case in one CPU because the context in
>> which device_add runs will always see the driver added into
>
> There you go again.  Look at my _much_ better description of the problem
> and you'll notice that device_add has nothing to do with this.

OK, I explain it again:

CPU0						CPU1

driver_register
	...
	bus_add_driver
		driver_attach
						device_add(devb)

		klist_add_tail(klist_drivers)

When device_add(devb) is run just after completion of driver_attach
and before klist_add_tail(klist_drivers), the 'devb' can't be probed
in device_add because the driver hasn't been added into bus,
and it wasn't be probed in driver_attach because driver_attach didn't
see the device in the bus.

So the 'devb' will be missed to be probed in the bus, won't it?


Thanks,
--
Ming Lei
--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ