diff mbox

[U-Boot,09/12] usb: kconfig: usb keyboard kconfig

Message ID 1437661179-32128-10-git-send-email-nikita@compulab.co.il
State Awaiting Upstream
Delegated to: Stefano Babic
Headers show

Commit Message

Nikita Kiryanov July 23, 2015, 2:19 p.m. UTC
Add Kconfig options for USB keyboard and use them for cm-fx6.

Cc: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
Cc: Igor Grinberg <grinberg@compulab.co.il>
Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
---
 configs/cm_fx6_defconfig |  2 ++
 drivers/usb/Kconfig      | 27 +++++++++++++++++++++++++++
 include/configs/cm_fx6.h |  2 --
 3 files changed, 29 insertions(+), 2 deletions(-)

Comments

Nikita Kiryanov July 26, 2015, 8:18 a.m. UTC | #1
On Thu, Jul 23, 2015 at 05:01:24PM +0200, Marek Vasut wrote:
> On Thursday, July 23, 2015 at 04:19:36 PM, Nikita Kiryanov wrote:
> > Add Kconfig options for USB keyboard and use them for cm-fx6.
> > 
> > Cc: Marek Vasut <marex@denx.de>
> > Cc: Stefano Babic <sbabic@denx.de>
> > Cc: Igor Grinberg <grinberg@compulab.co.il>
> > Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
> > ---
> >  configs/cm_fx6_defconfig |  2 ++
> >  drivers/usb/Kconfig      | 27 +++++++++++++++++++++++++++
> >  include/configs/cm_fx6.h |  2 --
> >  3 files changed, 29 insertions(+), 2 deletions(-)
> > 
> 
> Same here :)
>

Coming up...
Igor Grinberg July 26, 2015, 5:37 p.m. UTC | #2
On 07/23/15 17:19, Nikita Kiryanov wrote:
> Add Kconfig options for USB keyboard and use them for cm-fx6.
> 
> Cc: Marek Vasut <marex@denx.de>
> Cc: Stefano Babic <sbabic@denx.de>
> Cc: Igor Grinberg <grinberg@compulab.co.il>
> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>

Acked-by: Igor Grinberg <grinberg@compulab.co.il>

> ---
>  configs/cm_fx6_defconfig |  2 ++
>  drivers/usb/Kconfig      | 27 +++++++++++++++++++++++++++
>  include/configs/cm_fx6.h |  2 --
>  3 files changed, 29 insertions(+), 2 deletions(-)
> 
> diff --git a/configs/cm_fx6_defconfig b/configs/cm_fx6_defconfig
> index 07a84bb..f0fd48c 100644
> --- a/configs/cm_fx6_defconfig
> +++ b/configs/cm_fx6_defconfig
> @@ -20,3 +20,5 @@ CONFIG_CMD_USB=y
>  CONFIG_USB_EHCI_HCD=y
>  CONFIG_USB_EHCI_MX6=y
>  CONFIG_USB_STORAGE=y
> +CONFIG_USB_KEYBOARD=y
> +CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP=y
> diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig
> index 637ef3d..04289f2 100644
> --- a/drivers/usb/Kconfig
> +++ b/drivers/usb/Kconfig
> @@ -59,4 +59,31 @@ config USB_STORAGE
>  	  Say Y here if you want to connect USB mass storage devices to your
>  	  board's USB port.
>  
> +config USB_KEYBOARD
> +	bool "USB Keyboard support"
> +	---help---
> +	  Say Y here if you want to use a USB keyboard for U-Boot command line
> +	  input.
> +
> +if USB_KEYBOARD
> +
> +choice
> +	prompt "USB keyboard polling"
> +	optional
> +	---help---
> +	  Enable a polling mechanism for USB keyboard.
> +
> +	config SYS_USB_EVENT_POLL
> +		bool "Interrupt polling"
> +
> +	config SYS_USB_EVENT_POLL_VIA_INT_QUEUE
> +		bool "Poll via interrupt queue"
> +
> +	config SYS_USB_EVENT_POLL_VIA_CONTROL_EP
> +		bool "Poll via control EP"
> +
> +endchoice
> +
> +endif
> +
>  endif
> diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h
> index 9f69322..059004c 100644
> --- a/include/configs/cm_fx6.h
> +++ b/include/configs/cm_fx6.h
> @@ -202,8 +202,6 @@
>  #define CONFIG_MXC_USB_FLAGS		0
>  #define CONFIG_USB_MAX_CONTROLLER_COUNT	2
>  #define CONFIG_EHCI_HCD_INIT_AFTER_RESET	/* For OTG port */
> -#define CONFIG_USB_KEYBOARD
> -#define CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP
>  #define CONFIG_SYS_STDIO_DEREGISTER
>  
>  /* I2C */
>
Stefano Babic Aug. 2, 2015, 8:54 a.m. UTC | #3
On 23/07/2015 16:19, Nikita Kiryanov wrote:
> Add Kconfig options for USB keyboard and use them for cm-fx6.
> 
> Cc: Marek Vasut <marex@denx.de>
> Cc: Stefano Babic <sbabic@denx.de>
> Cc: Igor Grinberg <grinberg@compulab.co.il>
> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
> ---
>  configs/cm_fx6_defconfig |  2 ++
>  drivers/usb/Kconfig      | 27 +++++++++++++++++++++++++++
>  include/configs/cm_fx6.h |  2 --
>  3 files changed, 29 insertions(+), 2 deletions(-)
> 
> diff --git a/configs/cm_fx6_defconfig b/configs/cm_fx6_defconfig
> index 07a84bb..f0fd48c 100644
> --- a/configs/cm_fx6_defconfig
> +++ b/configs/cm_fx6_defconfig
> @@ -20,3 +20,5 @@ CONFIG_CMD_USB=y
>  CONFIG_USB_EHCI_HCD=y
>  CONFIG_USB_EHCI_MX6=y
>  CONFIG_USB_STORAGE=y
> +CONFIG_USB_KEYBOARD=y
> +CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP=y
> diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig
> index 637ef3d..04289f2 100644
> --- a/drivers/usb/Kconfig
> +++ b/drivers/usb/Kconfig
> @@ -59,4 +59,31 @@ config USB_STORAGE
>  	  Say Y here if you want to connect USB mass storage devices to your
>  	  board's USB port.
>  
> +config USB_KEYBOARD
> +	bool "USB Keyboard support"
> +	---help---
> +	  Say Y here if you want to use a USB keyboard for U-Boot command line
> +	  input.
> +
> +if USB_KEYBOARD
> +
> +choice
> +	prompt "USB keyboard polling"
> +	optional
> +	---help---
> +	  Enable a polling mechanism for USB keyboard.
> +
> +	config SYS_USB_EVENT_POLL
> +		bool "Interrupt polling"
> +
> +	config SYS_USB_EVENT_POLL_VIA_INT_QUEUE
> +		bool "Poll via interrupt queue"
> +
> +	config SYS_USB_EVENT_POLL_VIA_CONTROL_EP
> +		bool "Poll via control EP"
> +
> +endchoice
> +
> +endif
> +
>  endif
> diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h
> index 9f69322..059004c 100644
> --- a/include/configs/cm_fx6.h
> +++ b/include/configs/cm_fx6.h
> @@ -202,8 +202,6 @@
>  #define CONFIG_MXC_USB_FLAGS		0
>  #define CONFIG_USB_MAX_CONTROLLER_COUNT	2
>  #define CONFIG_EHCI_HCD_INIT_AFTER_RESET	/* For OTG port */
> -#define CONFIG_USB_KEYBOARD
> -#define CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP
>  #define CONFIG_SYS_STDIO_DEREGISTER
>  
>  /* I2C */
> 

Applied to u-boot-imx, thanks !

Best regards,
Stefano Babic
diff mbox

Patch

diff --git a/configs/cm_fx6_defconfig b/configs/cm_fx6_defconfig
index 07a84bb..f0fd48c 100644
--- a/configs/cm_fx6_defconfig
+++ b/configs/cm_fx6_defconfig
@@ -20,3 +20,5 @@  CONFIG_CMD_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_EHCI_MX6=y
 CONFIG_USB_STORAGE=y
+CONFIG_USB_KEYBOARD=y
+CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP=y
diff --git a/drivers/usb/Kconfig b/drivers/usb/Kconfig
index 637ef3d..04289f2 100644
--- a/drivers/usb/Kconfig
+++ b/drivers/usb/Kconfig
@@ -59,4 +59,31 @@  config USB_STORAGE
 	  Say Y here if you want to connect USB mass storage devices to your
 	  board's USB port.
 
+config USB_KEYBOARD
+	bool "USB Keyboard support"
+	---help---
+	  Say Y here if you want to use a USB keyboard for U-Boot command line
+	  input.
+
+if USB_KEYBOARD
+
+choice
+	prompt "USB keyboard polling"
+	optional
+	---help---
+	  Enable a polling mechanism for USB keyboard.
+
+	config SYS_USB_EVENT_POLL
+		bool "Interrupt polling"
+
+	config SYS_USB_EVENT_POLL_VIA_INT_QUEUE
+		bool "Poll via interrupt queue"
+
+	config SYS_USB_EVENT_POLL_VIA_CONTROL_EP
+		bool "Poll via control EP"
+
+endchoice
+
+endif
+
 endif
diff --git a/include/configs/cm_fx6.h b/include/configs/cm_fx6.h
index 9f69322..059004c 100644
--- a/include/configs/cm_fx6.h
+++ b/include/configs/cm_fx6.h
@@ -202,8 +202,6 @@ 
 #define CONFIG_MXC_USB_FLAGS		0
 #define CONFIG_USB_MAX_CONTROLLER_COUNT	2
 #define CONFIG_EHCI_HCD_INIT_AFTER_RESET	/* For OTG port */
-#define CONFIG_USB_KEYBOARD
-#define CONFIG_SYS_USB_EVENT_POLL_VIA_CONTROL_EP
 #define CONFIG_SYS_STDIO_DEREGISTER
 
 /* I2C */