Re: [PATCH v4 00/14] port power control fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 31 Jan 2014, Dan Williams wrote:

> Toggling port power currently leads to three unintended disconnect
> scenarios that are addressed by this rework of port power recovery and
> usb device resume:
> 
> 1/ Superspeed devices downgrade to their hispeed connection: fix this by
>    preventing superspeed poweroff until the peer port is suspended.
>    This depends on the ability to identify peer ports (patches 1-4), and
>    then patch 5 implements the policy.
> 
> 2/ khubd prematurely disconnects ports that are in the process of
>    being resumed or reset.  khubd now ignores ports in the
>    pm-runtime-suspended state (patch 9) and holds a lock to synchronize the port
>    status changes of usb_port_{suspend|resume} (patch 11).
> 
> 3/ Superspeed devices fail to reconnect: Seen during repeated toggles of
>    the port power state.  Fixed by forcing a full recovery cycle of the
>    usb_device before allowing the next suspend / khubd run (patch 12).
>    Also, for devices that live lock on reconnect the port runtime resume
>    path now has the capability to force a reset-resume to be a
>    warm-reset-resume (patch 13).

I haven't gone through all this in any detail.  But a couple of things 
stand out immediately, matters of style.

Although the USB stack still has plenty of old code with multiline
comments looking this this:

	/* blah blah blah
	 * blah blah blah
	 */

the accepted style is that all new code should appear like this:

	/*
	 * blah blah blah
	 * blah blah blah
	 */

Also, the style for indentation througout most of the USB stack is that
continuation lines are indented by two tab stops beyond the first line
of the statement.  They are not aligned with opening parentheses of
function calls or anything like that.

Alan Stern


--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux