From: Ali Bahar Date: Sat, 3 Sep 2011 19:14:10 +0000 (+0800) Subject: staging: r8712u: Merging Realtek's latest (v2.6.6). Redundant NULL check. X-Git-Tag: next-20111004~7^2~318 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=99f5ff39d24915533d5bcf557e75116c706bd6dd;p=karo-tx-linux.git staging: r8712u: Merging Realtek's latest (v2.6.6). Redundant NULL check. Removed the redundant NULL check in LedControl871x. As noted by Dan Carpenter, the address of a stack variable is never NULL. Signed-off-by: Ali Bahar Signed-off-by: Larry Finger Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8712/rtl8712_led.c b/drivers/staging/rtl8712/rtl8712_led.c index cb1751e95f06..bac56e5caf12 100644 --- a/drivers/staging/rtl8712/rtl8712_led.c +++ b/drivers/staging/rtl8712/rtl8712_led.c @@ -1786,7 +1786,7 @@ void LedControl871x(struct _adapter *padapter, enum LED_CTL_MODE LedAction) { struct led_priv *ledpriv = &(padapter->ledpriv); - if (ledpriv == NULL || ledpriv->bRegUseLed == false) + if (ledpriv->bRegUseLed == false) return; switch (ledpriv->LedStrategy) { case SW_LED_MODE0: