From patchwork Tue Sep 12 19:01:36 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Maxime Ripard X-Patchwork-Id: 112382 Delivered-To: patch@linaro.org Received: by 10.80.202.13 with SMTP id d13csp31465edi; Tue, 12 Sep 2017 12:13:42 -0700 (PDT) X-Google-Smtp-Source: ADKCNb7ZQhxvNkt6Pox6oSxfrRlYi6GBD8roD2f4vqUHG4un/QDkCjkTsdIpZKZFkxrRMx8hxzig X-Received: by 10.80.169.110 with SMTP id m43mr13631601edc.109.1505243622111; Tue, 12 Sep 2017 12:13:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505243622; cv=none; d=google.com; s=arc-20160816; b=TaGnUNDH7vy1JO+oQC4cyjIBS24YSHt7y+OT2v/2Ds3XCxL28RmVp+hX606tUa/dBZ /V3b1HNHWR3ltz7NHGMDC+j72lC/cYyTH6+oJohjqv1gPlNMt5iyJ/iD0M6ohmwqBBmy pyYex1JNLS5G+gf5mKZrk9fzuKTmxJgS/yTLpOsUOpuPA6k42APz1q6Eph37ZSpune8c daDpG2sE56mXgboZAy3wMYBmhZG/VYnklz2cf5SFJJUJfMfzO8Siv7YqRy5nS9g6/XYk jJggFiQYdUj3xLRYBJNvyHOBLebL1jKJmzWaa1c3cpMjU6M9C+flXCdpjpaQmysEyUbF pSpw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:references:in-reply-to:references :in-reply-to:message-id:date:to:from:arc-authentication-results; bh=ltL+5t19PjmX60baNyq8tXlBhiPHOWsY+5SWohAaWm4=; b=bPg7dlI8/+cxBuAvylwW8nYOzj0RGh8Qkr5yNsLDxnT470kq9r3gtLMugvf4PjbI4k 4m1GHPhFBf8Qc68xvmrkNmLugu82B/NWXsqfV7y2VciIGig2ibWhcUGGYJVbD7KHAhB1 vMSZ9889j2AD6Zf0mNXmmwBfa9fbRu0SucjGHPnMEm4Mj9Cy4OdHyPrmnD0L3c3fDj7K tUWJRfx7ZimKCa+B1o/smgLG+cwRFI1ycoGCwM3UnOe6gPAB3hZJQRIQA3cift5ILZCl wFo/d+7merqrgvm3/QJ80wmj+zj1gSAvpZEKgcMEXKs4OAgFQGNfRns1iCf73HBLOdDO ePaw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id i1si75623edi.127.2017.09.12.12.13.41; Tue, 12 Sep 2017 12:13:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by lists.denx.de (Postfix, from userid 105) id A57CCC22167; Tue, 12 Sep 2017 19:13:35 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id CE93AC21C40; Tue, 12 Sep 2017 19:02:14 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 84495C22181; Tue, 12 Sep 2017 19:01:58 +0000 (UTC) Received: from mail.free-electrons.com (mail.free-electrons.com [62.4.15.54]) by lists.denx.de (Postfix) with ESMTP id 9BE6DC2201E for ; Tue, 12 Sep 2017 19:01:50 +0000 (UTC) Received: by mail.free-electrons.com (Postfix, from userid 110) id 6E710209C0; Tue, 12 Sep 2017 21:01:50 +0200 (CEST) Received: from localhost (LFbn-TOU-1-209-191.w86-201.abo.wanadoo.fr [86.201.56.191]) by mail.free-electrons.com (Postfix) with ESMTPSA id 3DFE720867; Tue, 12 Sep 2017 21:01:50 +0200 (CEST) From: Maxime Ripard To: Tom Rini , Jagan Teki Date: Tue, 12 Sep 2017 21:01:36 +0200 Message-Id: X-Mailer: git-send-email 2.13.5 In-Reply-To: References: In-Reply-To: References: Cc: Thomas Petazzoni , marex@denx.de, u-boot@lists.denx.de, Maxime Ripard Subject: [U-Boot] [PATCH v2 08/14] sunxi: provide default USB gadget setup X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" All the Allwinner boards use the same manufacturer, VID and PID for the gadgets. Make them the defaults to remove some boilerplate from our defconfigs. Reviewed-by: Simon Glass Signed-off-by: Maxime Ripard Reviewed-by: Ɓukasz Majewski --- configs/A13-OLinuXino_defconfig | 3 --- configs/A20-OLinuXino-Lime2-eMMC_defconfig | 3 --- configs/A20-OLinuXino-Lime2_defconfig | 3 --- configs/CHIP_defconfig | 3 --- configs/CHIP_pro_defconfig | 3 --- configs/Cubietruck_defconfig | 3 --- configs/Nintendo_NES_Classic_Edition_defconfig | 3 --- configs/Sinlinx_SinA33_defconfig | 3 --- configs/parrot_r16_defconfig | 3 --- drivers/usb/gadget/Kconfig | 3 +++ 10 files changed, 3 insertions(+), 27 deletions(-) diff --git a/configs/A13-OLinuXino_defconfig b/configs/A13-OLinuXino_defconfig index 2574018d8213..ae790164dff7 100644 --- a/configs/A13-OLinuXino_defconfig +++ b/configs/A13-OLinuXino_defconfig @@ -32,7 +32,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/A20-OLinuXino-Lime2-eMMC_defconfig b/configs/A20-OLinuXino-Lime2-eMMC_defconfig index 5663a824e71b..b136af66b71f 100644 --- a/configs/A20-OLinuXino-Lime2-eMMC_defconfig +++ b/configs/A20-OLinuXino-Lime2-eMMC_defconfig @@ -34,7 +34,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/A20-OLinuXino-Lime2_defconfig b/configs/A20-OLinuXino-Lime2_defconfig index 63d013293690..ebb435f30956 100644 --- a/configs/A20-OLinuXino-Lime2_defconfig +++ b/configs/A20-OLinuXino-Lime2_defconfig @@ -33,7 +33,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/CHIP_defconfig b/configs/CHIP_defconfig index 278039c05573..7d50d0533dcd 100644 --- a/configs/CHIP_defconfig +++ b/configs/CHIP_defconfig @@ -23,8 +23,5 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_OF_LIBFDT_OVERLAY=y diff --git a/configs/CHIP_pro_defconfig b/configs/CHIP_pro_defconfig index edbdefc69ddf..76daf477ec87 100644 --- a/configs/CHIP_pro_defconfig +++ b/configs/CHIP_pro_defconfig @@ -28,8 +28,5 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y CONFIG_OF_LIBFDT_OVERLAY=y diff --git a/configs/Cubietruck_defconfig b/configs/Cubietruck_defconfig index 2d1753645b0f..1b2989d364f6 100644 --- a/configs/Cubietruck_defconfig +++ b/configs/Cubietruck_defconfig @@ -33,7 +33,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/Nintendo_NES_Classic_Edition_defconfig b/configs/Nintendo_NES_Classic_Edition_defconfig index 99f7d30f150d..5986764a14b9 100644 --- a/configs/Nintendo_NES_Classic_Edition_defconfig +++ b/configs/Nintendo_NES_Classic_Edition_defconfig @@ -23,7 +23,4 @@ CONFIG_AXP_ELDO2_VOLT=1800 CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/Sinlinx_SinA33_defconfig b/configs/Sinlinx_SinA33_defconfig index 8c5fc7587909..9299aedd6019 100644 --- a/configs/Sinlinx_SinA33_defconfig +++ b/configs/Sinlinx_SinA33_defconfig @@ -28,7 +28,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/configs/parrot_r16_defconfig b/configs/parrot_r16_defconfig index 4b70fc5687eb..57db9587fe77 100644 --- a/configs/parrot_r16_defconfig +++ b/configs/parrot_r16_defconfig @@ -24,7 +24,4 @@ CONFIG_USB_EHCI_HCD=y CONFIG_USB_MUSB_GADGET=y CONFIG_SYS_USB_EVENT_POLL_VIA_INT_QUEUE=y CONFIG_USB_GADGET=y -CONFIG_USB_GADGET_MANUFACTURER="Allwinner Technology" -CONFIG_USB_GADGET_VENDOR_NUM=0x1f3a -CONFIG_USB_GADGET_PRODUCT_NUM=0x1010 CONFIG_USB_GADGET_DOWNLOAD=y diff --git a/drivers/usb/gadget/Kconfig b/drivers/usb/gadget/Kconfig index ef13bd2edb66..32b9a7e9fe49 100644 --- a/drivers/usb/gadget/Kconfig +++ b/drivers/usb/gadget/Kconfig @@ -38,12 +38,14 @@ if USB_GADGET config USB_GADGET_MANUFACTURER string "Vendor name of the USB device" + default "Allwinner Technology" if ARCH_SUNXI help Vendor name of the USB device emulated, reported to the host device. This is usually either the manufacturer of the device or the SoC. config USB_GADGET_VENDOR_NUM hex "Vendor ID of the USB device" + default 0x1f3a if ARCH_SUNXI help Vendor ID of the USB device emulated, reported to the host device. This is usually the board or SoC vendor's, unless you've registered @@ -51,6 +53,7 @@ config USB_GADGET_VENDOR_NUM config USB_GADGET_PRODUCT_NUM hex "Product ID of the USB device" + default 0x1010 if ARCH_SUNXI help Product ID of the USB device emulated, reported to the host device.