Re: [PATCH] platform/x86: wmi: fix potential null pointer dereferences

From: Darren Hart
Date: Sat Jan 26 2019 - 15:44:13 EST


On Tue, Jan 22, 2019 at 09:03:01PM +0100, Mattias Jacobsson wrote:
> In the function wmi_dev_match() there are three variables that
> potentially can result in a null pointer dereference. Namely:

Is this something you have observed? This gets called when a new driver
registered for each unassociated device on the bus, so I'm not
immediately seeing how dev or driver would end up being NULL here.

See: Documentation/driver-model/bus.txt

--
Darren Hart
VMware Open Source Technology Center