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 for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date:   Fri, 20 Jul 2018 11:17:59 +0300
From:   Mathias Nyman <mathias.nyman@...el.com>
To:     iq_132@...a.com, gregkh@...uxfoundation.org
Cc:     linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
        Zheng Xiaowei <zhengxiaowei@...jie.com.cn>
Subject: Re: [PATCH] usb: xhci: Fix memory leak in xhci_endpoint_reset()

On 09.07.2018 10:12, iq_132@...a.com wrote:
> 
> From: Zheng Xiaowei <zhengxiaowei@...jie.com.cn>
> 
> If td_list is not empty the cfg_cmd will not be freed,
> call xhci_free_command to free it.
> 
> Signed-off-by: Zheng Xiaowei <zhengxiaowei@...jie.com.cn>
> ---
>   drivers/usb/host/xhci.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
> index 2f4850f..68e6132 100644
> --- a/drivers/usb/host/xhci.c
> +++ b/drivers/usb/host/xhci.c
> @@ -3051,6 +3051,7 @@ static void xhci_endpoint_reset(struct usb_hcd *hcd,
>   	if (!list_empty(&ep->ring->td_list)) {
>   		dev_err(&udev->dev, "EP not empty, refuse reset\n");
>   		spin_unlock_irqrestore(&xhci->lock, flags);
> +		xhci_free_command(xhci, cfg_cmd);
>   		goto cleanup;
>   	}
>   	xhci_queue_stop_endpoint(xhci, stop_cmd, udev->slot_id, ep_index, 0);
> 

Thanks, adding to queue

-Mathias

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ