lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 20 Jul 2012 22:08:21 +0545
From:	"devendra.aaru" <devendra.aaru@...il.com>
To:	"Kim, Milo" <Milo.Kim@...com>
Cc:	Bryan Wu <bryan.wu@...onical.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] leds: add new lp8788 led driver

Hi,

I think a mutex_unlock is missed out,

On Fri, Jul 20, 2012 at 2:28 PM, Kim, Milo <Milo.Kim@...com> wrote:
> +
> +static void lp8788_led_work(struct work_struct *work)
> +{
> +       struct lp8788_led *led = container_of(work, struct lp8788_led, work);
> +       enum lp8788_isink_number num = led->isink_num;
> +       int enable;
> +       u8 val = led->brightness;
> +
> +       mutex_lock(&led->lock);
> +
> +       switch (num) {
> +       case LP8788_ISINK_1:
> +       case LP8788_ISINK_2:
> +       case LP8788_ISINK_3:
> +               lp8788_write_byte(led->lp, lp8788_pwm_addr[num], val);
> +               break;
> +       default:
                    missed mutex_unlock
> +               return;
> +       }
> +
> +       enable = (val > 0) ? 1 : 0;
> +       if (enable != led->on)
> +               lp8788_led_enable(led, num, enable);
> +
> +       mutex_unlock(&led->lock);
> +}
> +

Thanks,
Devendra
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ