All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steve Rae <srae@broadcom.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v1 3/3] usb: gadget: fastboot: Set the Serial Number for Fastboot Gadget
Date: Fri, 13 Feb 2015 11:32:18 -0800	[thread overview]
Message-ID: <54DE5142.1000906@broadcom.com> (raw)
In-Reply-To: <1423809223-24219-3-git-send-email-dileep.katta@linaro.org>



On 15-02-12 10:33 PM, Dileep Katta wrote:
> Configure the serial number using the serial# environment variable
> during the fastboot bind.
>
> This enables "fastboot devices" to return the serial number for
> the attached devices.
>
> Signed-off-by: Dileep Katta <dileep.katta@linaro.org>
> ---
>   drivers/usb/gadget/f_fastboot.c | 5 +++++
>   1 file changed, 5 insertions(+)
>
> diff --git a/drivers/usb/gadget/f_fastboot.c b/drivers/usb/gadget/f_fastboot.c
> index 0d53a61..d114c07 100644
> --- a/drivers/usb/gadget/f_fastboot.c
> +++ b/drivers/usb/gadget/f_fastboot.c
> @@ -136,6 +136,7 @@ static int fastboot_bind(struct usb_configuration *c, struct usb_function *f)
>   	int id;
>   	struct usb_gadget *gadget = c->cdev->gadget;
>   	struct f_fastboot *f_fb = func_to_fastboot(f);
> +	const char *s;
>
>   	/* DYNAMIC interface numbers assignments */
>   	id = usb_interface_id(c, f);
> @@ -161,6 +162,10 @@ static int fastboot_bind(struct usb_configuration *c, struct usb_function *f)
>
>   	hs_ep_out.bEndpointAddress = fs_ep_out.bEndpointAddress;
>
> +	s = getenv("serial#");
> +	if (s)
> +		g_dnl_set_serialnumber((char *)s);
> +
>   	return 0;
>   }
>
>

Acked-by: Steve Rae <srae@broadcom.com>

  reply	other threads:[~2015-02-13 19:32 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-13  6:33 [U-Boot] [PATCH v1 1/3] fastboot: OUT transaction length must be aligned to wMaxPacketSize Dileep Katta
2015-02-13  6:33 ` [U-Boot] [PATCH v1 2/3] fastboot: Correct fastboot_fail and fastboot_okay strings Dileep Katta
2015-02-13 19:19   ` Steve Rae
2015-02-24 10:28   ` Lukasz Majewski
2015-02-13  6:33 ` [U-Boot] [PATCH v1 3/3] usb: gadget: fastboot: Set the Serial Number for Fastboot Gadget Dileep Katta
2015-02-13 19:32   ` Steve Rae [this message]
2015-02-24 10:28   ` Lukasz Majewski
2015-02-13 17:59 ` [U-Boot] [PATCH v2 1/3] fastboot: OUT transaction length must be aligned to wMaxPacketSize Dileep Katta
2015-02-13 19:53   ` Stegmaier, Angela
2015-02-16 20:32     ` [U-Boot] [PATCH v3 " Dileep Katta
2015-02-24 10:28       ` Lukasz Majewski
2016-03-10 23:46         ` [U-Boot] Anyone else having issues with "fastboot flash" - because of this change? Steve Rae
2016-03-11  0:11           ` Steve Rae
2015-02-13 19:53   ` [U-Boot] [PATCH v2 1/3] fastboot: OUT transaction length must be aligned to wMaxPacketSize Steve Rae

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=54DE5142.1000906@broadcom.com \
    --to=srae@broadcom.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.