public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* staging/rtl8712: unhandled default case in SwLedOn function.
@ 2012-05-02 20:10 joseph daniel
  2012-05-02 20:12 ` joseph daniel
  0 siblings, 1 reply; 6+ messages in thread
From: joseph daniel @ 2012-05-02 20:10 UTC (permalink / raw)
  To: Larry Finger, Florian Schilhabel, Greg Kroah-Hartman, Ali Bahar,
	linux-kernel, devel

Hi kernel developers,

In the function SwLedOn in rtl8712_led.c, we put the bLedOn = true,
even if its a default case. may be we need to return? or BUG()?.

the code listing is:

if ((padapter->bSurpriseRemoved == true) ||
        (padapter->bDriverStopped == true))
        return;
    LedCfg = r8712_read8(padapter, LEDCFG);
    switch (pLed->LedPin) {
    case LED_PIN_GPIO0:
        break;
    case LED_PIN_LED0:
        /* SW control led0 on.*/
        r8712_write8(padapter, LEDCFG, LedCfg&0xf0);
        break;
    case LED_PIN_LED1:
        /* SW control led1 on.*/
        r8712_write8(padapter, LEDCFG, LedCfg&0x0f);
        break;
    default:
        break;
    }
    pLed->bLedOn = true;

Thanks,
Dev.

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-05-03  7:23 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-02 20:10 staging/rtl8712: unhandled default case in SwLedOn function joseph daniel
2012-05-02 20:12 ` joseph daniel
2012-05-02 20:20   ` Greg Kroah-Hartman
2012-05-02 20:36   ` Larry Finger
2012-05-03  3:35     ` joseph daniel
2012-05-03  7:26     ` Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox