提交 56d95f31 编写于 作者: G Greg Kroah-Hartman

USB: gadget: ci13xx_pci: remove unneeded check in ci13xxx_pci_probe()

As pointed out by Dan Carpenter, the check for NULL for the id variable
is no longer needed, especially as we just dereferenced it a few lines
earlier, causing an oops if it really was NULL.

This was caused by 62bb84ed: "usb: gadget: ci13xxx: convert to
platform device".
Reported-by: NDan Carpenter <dan.carpenter@oracle.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 f639554b
......@@ -51,9 +51,6 @@ static int __devinit ci13xxx_pci_probe(struct pci_dev *pdev,
struct resource res[3];
int retval = 0, nres = 2;
if (id == NULL)
return -EINVAL;
retval = pci_enable_device(pdev);
if (retval)
goto done;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册