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:	Tue, 23 Feb 2016 16:22:16 -0800
From:	Doug Anderson <dianders@...omium.org>
To:	John Youn <johnyoun@...opsys.com>
Cc:	Felipe Balbi <balbi@...nel.org>,
	Alan Stern <stern@...land.harvard.edu>,
	Arnd Bergmann <arnd@...db.de>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	"linux-arm-kernel@...ts.infradead.org" 
	<linux-arm-kernel@...ts.infradead.org>,
	Heiko Stuebner <heiko@...ech.de>,
	Stefan Wahren <stefan.wahren@...e.com>,
	Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
	Mathias Nyman <mathias.nyman@...ux.intel.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH RESEND 2/2] usb: dwc2: Move host-specific core functions
 into hcd.c

John,

On Tue, Feb 23, 2016 at 1:33 PM, John Youn <johnyoun@...opsys.com> wrote:

> +u32 dwc2_calc_frame_interval(struct dwc2_hsotg *hsotg)

You seem to have lost the function comments for
dwc2_calc_frame_interval().  Was that intentional?  If not, can you
add them back?


> +/**
> + * dwc2_hc_do_ping() - Starts a PING transfer
> + *
> + * @hsotg: Programming view of DWC_otg controller
> + * @chan:  Information needed to initialize the host channel
> + *
> + * This function should only be called in Slave mode. The Do Ping bit is set in
> + * the HCTSIZ register, then the channel is enabled.
> + */
> +void dwc2_hc_do_ping(struct dwc2_hsotg *hsotg, struct dwc2_host_chan *chan)

Presumably can be static?  ...and remove prototype from "core.h"?


> +/**
> + * dwc2_core_init() - Initializes the DWC_otg controller registers and
> + * prepares the core for device mode or host mode operation
> + *
> + * @hsotg:         Programming view of the DWC_otg controller
> + * @initial_setup: If true then this is the first init for this instance.
> + */
> +int dwc2_core_init(struct dwc2_hsotg *hsotg, bool initial_setup)

Presumably can be static?  ...and remove prototype from "core.h"?


> +/**
> + * dwc2_core_host_init() - Initializes the DWC_otg controller registers for
> + * Host mode
> + *
> + * @hsotg: Programming view of DWC_otg controller
> + *
> + * This function flushes the Tx and Rx FIFOs and flushes any entries in the
> + * request queues. Host channels are reset to ensure that they are ready for
> + * performing transfers.
> + */
> +void dwc2_core_host_init(struct dwc2_hsotg *hsotg)

Presumably can be static?  ...and remove prototype from "core.h"?


Other than those nits, things look good.  I didn't analyze exactly
where you placed all the functions but a quick glance shows that they
seem sanely organized.  :)

I picked these back to my chromeos-3.14 kernel (with many many dwc2
backports) and I confirmed that I can still compile the kernel, boot
it, and use USB.  I also confirmed no warnings were introduced for me.
I'm only testing HOST, not gadget mode.

Feel free to add my Reviewed-by and Tested-by once nits are fixed up.

-Doug

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ