Revert "rsi: fix potential null dereference in rsi_probe()"
authorJohan Hovold <johan@kernel.org>
Fri, 4 Oct 2019 14:44:21 +0000 (16:44 +0200)
committerKalle Valo <kvalo@codeaurora.org>
Wed, 9 Oct 2019 08:23:45 +0000 (11:23 +0300)
This reverts commit f170d44bc4ec2feae5f6206980e7ae7fbf0432a0.

USB core will never call a USB-driver probe function with a NULL
device-id pointer.

Reverting before removing the existing checks in order to document this
and prevent the offending commit from being "autoselected" for stable.

Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/rsi/rsi_91x_usb.c

index 23a1d00..760eaff 100644 (file)
@@ -793,7 +793,7 @@ static int rsi_probe(struct usb_interface *pfunction,
                adapter->device_model = RSI_DEV_9116;
        } else {
                rsi_dbg(ERR_ZONE, "%s: Unsupported RSI device id 0x%x\n",
-                       __func__, id ? id->idProduct : 0x0);
+                       __func__, id->idProduct);
                goto err1;
        }