blob: 6ce4f7bead8f754d0e3f1a8000b8f99c80ee90a7 [file] [log] [blame]
From 77c73be105818791f80eeb230e82c8e2901036de Mon Sep 17 00:00:00 2001
From: Johan Hovold <johan@kernel.org>
Date: Fri, 4 Oct 2019 16:44:21 +0200
Subject: [PATCH] Revert "rsi: fix potential null dereference in rsi_probe()"
commit c5dcf8f0e850a504235a0af51f73d51b6ddc0933 upstream.
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>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
diff --git a/drivers/net/wireless/rsi/rsi_91x_usb.c b/drivers/net/wireless/rsi/rsi_91x_usb.c
index d6cdabef264d..4b9e406b8461 100644
--- a/drivers/net/wireless/rsi/rsi_91x_usb.c
+++ b/drivers/net/wireless/rsi/rsi_91x_usb.c
@@ -805,7 +805,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;
}
--
2.7.4