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: <A2CA0424C0A6F04399FB9E1CD98E0304844B776A@US01WEMBX2.internal.synopsys.com>
Date:	Mon, 16 Jun 2014 22:00:42 +0000
From:	Paul Zimmerman <Paul.Zimmerman@...opsys.com>
To:	Joe Perches <joe@...ches.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC:	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	Alan Stern <stern@...land.harvard.edu>,
	"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>
Subject: RE: [PATCH -next 24/26] usb: Use dma_zalloc_coherent

> From: Joe Perches [mailto:joe@...ches.com]
> Sent: Sunday, June 15, 2014 1:38 PM
> 
> Use the zeroing function instead of dma_alloc_coherent & memset(,0,)
> 
> Signed-off-by: Joe Perches <joe@...ches.com>
> ---
>  drivers/usb/dwc2/hcd_ddma.c | 20 +++++++-------------
>  drivers/usb/host/uhci-hcd.c |  7 +++----
>  2 files changed, 10 insertions(+), 17 deletions(-)
> 
> diff --git a/drivers/usb/dwc2/hcd_ddma.c b/drivers/usb/dwc2/hcd_ddma.c
> index 3376177..ab8d7fc 100644
> --- a/drivers/usb/dwc2/hcd_ddma.c
> +++ b/drivers/usb/dwc2/hcd_ddma.c
> @@ -87,17 +87,12 @@ static u16 dwc2_frame_incr_val(struct dwc2_qh *qh)
>  static int dwc2_desc_list_alloc(struct dwc2_hsotg *hsotg, struct dwc2_qh *qh,
>  				gfp_t flags)
>  {
> -	qh->desc_list = dma_alloc_coherent(hsotg->dev,
> -				sizeof(struct dwc2_hcd_dma_desc) *
> -				dwc2_max_desc_num(qh), &qh->desc_list_dma,
> -				flags);
> -
> +	qh->desc_list = dma_zalloc_coherent(hsotg->dev,
> +					    sizeof(struct dwc2_hcd_dma_desc) * dwc2_max_desc_num(qh),
> +					    &qh->desc_list_dma, flags);

This will cause checkpatch to complain about a too-long line, surely?
If you fix that, you can add my acked-by for the dwc2 parts.

-- 
Paul

--
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