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]
Message-ID: <f77eda75-70f4-e276-21f7-cb64a65d121f@collabora.com>
Date:   Tue, 18 Jun 2019 10:38:41 +0200
From:   Enric Balletbo i Serra <enric.balletbo@...labora.com>
To:     Nick Crews <ncrews@...omium.org>, bleung@...omium.org
Cc:     linux-kernel@...r.kernel.org, dlaurie@...omium.org,
        djkurtz@...omium.org, dtor@...gle.com, sjg@...omium.org,
        kernel-janitors@...r.kernel.org, dan.carpenter@...cle.com
Subject: Re: [PATCH 1/2] platform/chrome: wilco_ec: Fix unreleased lock in
 event_read()



On 14/6/19 22:56, Nick Crews wrote:
> When copying an event to userspace failed, the event queue
> lock was never released. This fixes that.
> 
> Reported-by: Dan Carpenter <dan.carpenter@...cle.com>
> Signed-off-by: Nick Crews <ncrews@...omium.org>
> ---
>  drivers/platform/chrome/wilco_ec/event.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/platform/chrome/wilco_ec/event.c b/drivers/platform/chrome/wilco_ec/event.c
> index 4d2776f77dbd..1eed55681598 100644
> --- a/drivers/platform/chrome/wilco_ec/event.c
> +++ b/drivers/platform/chrome/wilco_ec/event.c
> @@ -342,7 +342,7 @@ static ssize_t event_read(struct file *filp, char __user *buf, size_t count,
>  				 struct ec_event_entry, list);
>  	n_bytes_written = entry->size;
>  	if (copy_to_user(buf, &entry->event, n_bytes_written))
> -		return -EFAULT;
> +		n_bytes_written = -EFAULT;
>  	list_del(&entry->list);
>  	kfree(entry);
>  	dev_data->num_events--;
> 

Applied for chrome-platform-5.3

Thanks,
~ Enric

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ