18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0
28c2ecf20Sopenharmony_ci#
38c2ecf20Sopenharmony_ci# USB Core configuration
48c2ecf20Sopenharmony_ci#
58c2ecf20Sopenharmony_ciconfig USB_ANNOUNCE_NEW_DEVICES
68c2ecf20Sopenharmony_ci	bool "USB announce new devices"
78c2ecf20Sopenharmony_ci	help
88c2ecf20Sopenharmony_ci	  Say Y here if you want the USB core to always announce the
98c2ecf20Sopenharmony_ci	  idVendor, idProduct, Manufacturer, Product, and SerialNumber
108c2ecf20Sopenharmony_ci	  strings for every new USB device to the syslog.  This option is
118c2ecf20Sopenharmony_ci	  usually used by distro vendors to help with debugging and to
128c2ecf20Sopenharmony_ci	  let users know what specific device was added to the machine
138c2ecf20Sopenharmony_ci	  in what location.
148c2ecf20Sopenharmony_ci
158c2ecf20Sopenharmony_ci	  If you do not want this kind of information sent to the system
168c2ecf20Sopenharmony_ci	  log, or have any doubts about this, say N here.
178c2ecf20Sopenharmony_ci
188c2ecf20Sopenharmony_cicomment "Miscellaneous USB options"
198c2ecf20Sopenharmony_ci
208c2ecf20Sopenharmony_ciconfig USB_DEFAULT_PERSIST
218c2ecf20Sopenharmony_ci	bool "Enable USB persist by default"
228c2ecf20Sopenharmony_ci	default y
238c2ecf20Sopenharmony_ci	help
248c2ecf20Sopenharmony_ci	  Say N here if you don't want USB power session persistence
258c2ecf20Sopenharmony_ci	  enabled by default.  If you say N it will make suspended USB
268c2ecf20Sopenharmony_ci	  devices that lose power get reenumerated as if they had been
278c2ecf20Sopenharmony_ci	  unplugged, causing any mounted filesystems to be lost.  The
288c2ecf20Sopenharmony_ci	  persist feature can still be enabled for individual devices
298c2ecf20Sopenharmony_ci	  through the power/persist sysfs node. See
308c2ecf20Sopenharmony_ci	  Documentation/driver-api/usb/persist.rst for more info.
318c2ecf20Sopenharmony_ci
328c2ecf20Sopenharmony_ci	  If you have any questions about this, say Y here, only say N
338c2ecf20Sopenharmony_ci	  if you know exactly what you are doing.
348c2ecf20Sopenharmony_ci
358c2ecf20Sopenharmony_ciconfig USB_FEW_INIT_RETRIES
368c2ecf20Sopenharmony_ci	bool "Limit USB device initialization to only a few retries"
378c2ecf20Sopenharmony_ci	help
388c2ecf20Sopenharmony_ci	  When a new USB device is detected, the kernel tries very hard
398c2ecf20Sopenharmony_ci	  to initialize and enumerate it, with lots of nested retry loops.
408c2ecf20Sopenharmony_ci	  This almost always works, but when it fails it can take a long time.
418c2ecf20Sopenharmony_ci	  This option tells the kernel to make only a few retry attempts,
428c2ecf20Sopenharmony_ci	  so that the total time required for a failed initialization is
438c2ecf20Sopenharmony_ci	  no more than 30 seconds (as required by the USB OTG spec).
448c2ecf20Sopenharmony_ci
458c2ecf20Sopenharmony_ci	  Say N here unless you require new-device enumeration failure to
468c2ecf20Sopenharmony_ci	  occur within 30 seconds (as might be needed in an embedded
478c2ecf20Sopenharmony_ci	  application).
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ciconfig USB_DYNAMIC_MINORS
508c2ecf20Sopenharmony_ci	bool "Dynamic USB minor allocation"
518c2ecf20Sopenharmony_ci	help
528c2ecf20Sopenharmony_ci	  If you say Y here, the USB subsystem will use dynamic minor
538c2ecf20Sopenharmony_ci	  allocation for any device that uses the USB major number.
548c2ecf20Sopenharmony_ci	  This means that you can have more than 16 of a single type
558c2ecf20Sopenharmony_ci	  of device (like USB printers).
568c2ecf20Sopenharmony_ci
578c2ecf20Sopenharmony_ci	  If you are unsure about this, say N here.
588c2ecf20Sopenharmony_ci
598c2ecf20Sopenharmony_ciconfig USB_OTG
608c2ecf20Sopenharmony_ci	bool "OTG support"
618c2ecf20Sopenharmony_ci	depends on PM
628c2ecf20Sopenharmony_ci	help
638c2ecf20Sopenharmony_ci	  The most notable feature of USB OTG is support for a
648c2ecf20Sopenharmony_ci	  "Dual-Role" device, which can act as either a device
658c2ecf20Sopenharmony_ci	  or a host. The initial role is decided by the type of
668c2ecf20Sopenharmony_ci	  plug inserted and can be changed later when two dual
678c2ecf20Sopenharmony_ci	  role devices talk to each other.
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci	  Select this only if your board has Mini-AB/Micro-AB
708c2ecf20Sopenharmony_ci	  connector.
718c2ecf20Sopenharmony_ci
728c2ecf20Sopenharmony_ciconfig USB_OTG_PRODUCTLIST
738c2ecf20Sopenharmony_ci	bool "Rely on OTG and EH Targeted Peripherals List"
748c2ecf20Sopenharmony_ci	depends on USB
758c2ecf20Sopenharmony_ci	help
768c2ecf20Sopenharmony_ci	  If you say Y here, the "otg_productlist.h" file will be used as a
778c2ecf20Sopenharmony_ci	  product list, so USB peripherals not listed there will be
788c2ecf20Sopenharmony_ci	  rejected during enumeration.  This behavior is required by the
798c2ecf20Sopenharmony_ci	  USB OTG and EH specification for all devices not on your product's
808c2ecf20Sopenharmony_ci	  "Targeted Peripherals List".  "Embedded Hosts" are likewise
818c2ecf20Sopenharmony_ci	  allowed to support only a limited number of peripherals.
828c2ecf20Sopenharmony_ci
838c2ecf20Sopenharmony_ciconfig USB_OTG_DISABLE_EXTERNAL_HUB
848c2ecf20Sopenharmony_ci	bool "Disable external hubs"
858c2ecf20Sopenharmony_ci	depends on USB_OTG || EXPERT
868c2ecf20Sopenharmony_ci	help
878c2ecf20Sopenharmony_ci	  If you say Y here, then Linux will refuse to enumerate
888c2ecf20Sopenharmony_ci	  external hubs.  OTG hosts are allowed to reduce hardware
898c2ecf20Sopenharmony_ci	  and software costs by not supporting external hubs.  So
908c2ecf20Sopenharmony_ci	  are "Embedded Hosts" that don't offer OTG support.
918c2ecf20Sopenharmony_ci
928c2ecf20Sopenharmony_ciconfig USB_OTG_FSM
938c2ecf20Sopenharmony_ci	tristate "USB 2.0 OTG FSM implementation"
948c2ecf20Sopenharmony_ci	depends on USB && USB_OTG
958c2ecf20Sopenharmony_ci	select USB_PHY
968c2ecf20Sopenharmony_ci	help
978c2ecf20Sopenharmony_ci	  Implements OTG Finite State Machine as specified in On-The-Go
988c2ecf20Sopenharmony_ci	  and Embedded Host Supplement to the USB Revision 2.0 Specification.
998c2ecf20Sopenharmony_ci
1008c2ecf20Sopenharmony_ciconfig USB_LEDS_TRIGGER_USBPORT
1018c2ecf20Sopenharmony_ci	tristate "USB port LED trigger"
1028c2ecf20Sopenharmony_ci	depends on USB && LEDS_TRIGGERS
1038c2ecf20Sopenharmony_ci	help
1048c2ecf20Sopenharmony_ci	  This driver allows LEDs to be controlled by USB events. Enabling this
1058c2ecf20Sopenharmony_ci	  trigger allows specifying list of USB ports that should turn on LED
1068c2ecf20Sopenharmony_ci	  when some USB device gets connected.
1078c2ecf20Sopenharmony_ci
1088c2ecf20Sopenharmony_ciconfig USB_AUTOSUSPEND_DELAY
1098c2ecf20Sopenharmony_ci	int "Default autosuspend delay"
1108c2ecf20Sopenharmony_ci	depends on USB
1118c2ecf20Sopenharmony_ci	default 2
1128c2ecf20Sopenharmony_ci	help
1138c2ecf20Sopenharmony_ci	  The default autosuspend delay in seconds.  Can be overridden
1148c2ecf20Sopenharmony_ci	  with the usbcore.autosuspend command line or module parameter.
1158c2ecf20Sopenharmony_ci
1168c2ecf20Sopenharmony_ci	  The default value Linux has always had is 2 seconds.  Change
1178c2ecf20Sopenharmony_ci	  this value if you want a different delay and cannot modify
1188c2ecf20Sopenharmony_ci	  the command line or module parameter.
119