UPSTREAM: usb: Make USB persist default configurable
authorJulius Werner <jwerner@chromium.org>
Wed, 13 Mar 2013 22:57:31 +0000 (15:57 -0700)
committerChromeBot <chrome-bot@google.com>
Wed, 24 Apr 2013 17:59:41 +0000 (10:59 -0700)
commit5df7b44eb8b40e551d74a551d5b47dd00e3667a5
tree0b848df1e4acd42212e7020fc30bda77e3b7753a
parent7e1da659a573f5fb6ace37597355cbf51bc02e30
UPSTREAM: usb: Make USB persist default configurable

Commit 9214d1d8 set the USB persist flag as a default for all devices.
This might be desirable for some distributions, but it certainly has its
trade-offs... most importantly, it can significantly increase system
resume time, because the kernel blocks on resuming (and sometimes
resetting) USB devices before it unfreezes userspace.

This patch introduces a new config option CONFIG_USB_DEFAULT_PERSIST,
which allows distributions to make this decision on their own without
the need to carry a custom patch or revert the kernel's setting in
userspace.

[edited the Kconfig help text a bit - gregkh]

Signed-off-by: Julius Werner <jwerner@chromium.org>
Cc: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 4f48203881ce947a0cbd8ae7b1a1a1b04aaa3766)
Cherry picked from upstream's gregkh/usb.git/usb-next

Conflicts:
    drivers/usb/core/Kconfig (trivial merge with old deprecated configs)
    drivers/usb/core/quirks.c (renamed USB_QUIRK_RESET to the older
            USB_QUIRK_RESET_MORPHS)

BUG=None
TEST=None

Change-Id: Ib63d2ed955e2916598d5ecd2d75aab9260594368
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/49015
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Sameer Nanda <snanda@chromium.org>
drivers/usb/core/Kconfig
drivers/usb/core/quirks.c