From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC 01/10] New board-specific USB initialization interface
Date: Sun, 11 Aug 2013 20:04:51 +0200 [thread overview]
Message-ID: <201308112004.51765.marex@denx.de> (raw)
In-Reply-To: <1375786242-11734-2-git-send-email-m.zalega@samsung.com>
Dear Mateusz Zalega,
> This commit unifies board-specific USB initialization implementations
> under one symbol (usb_board_init), declaration of which is available in
> usb.h.
>
> Signed-off-by: Mateusz Zalega <m.zalega@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> Reviewed-by: Lukasz Majewski <l.majewski@samsung.com>
> Cc: Marek Vasut <marex@denx.de>
> ---
> common/cmd_dfu.c | 5 ++---
> common/cmd_usb_mass_storage.c | 3 ++-
> common/usb.c | 5 +++++
> drivers/usb/host/ehci-omap.c | 8 +-------
> drivers/usb/host/ehci-tegra.c | 2 +-
> drivers/usb/host/ohci-hcd.c | 4 ++--
> drivers/usb/host/ohci.h | 12 +++++-------
> include/g_dnl.h | 2 --
> include/usb.h | 17 ++++++++++++++++-
> include/usb_mass_storage.h | 12 +++++-------
> 10 files changed, 39 insertions(+), 31 deletions(-)
[...]
> --- a/include/usb.h
> +++ b/include/usb.h
> @@ -165,10 +165,25 @@ int submit_int_msg(struct usb_device *dev, unsigned
> long pipe, void *buffer,
>
> extern void udc_disconnect(void);
>
> -#else
> +#elif !defined(CONFIG_USB_GADGET)
> #error USB Lowlevel not defined
> #endif
>
> +/* You can initialize platform's USB host, device or both
> + * capabilities by passing this enum as an argument to
> + * board_usb_init().
> + */
The comment style is wrong, please fix. Did the patchset pass checkpatch ?
/*
* multi
* line
* comment
*/
> +enum board_usb_init_type {
> + USB_INIT_ALL,
> + USB_INIT_HOST,
> + USB_INIT_DEVICE
> +};
> +
> +/* board-specific hardware initialization, called by
> + * usb drivers and u-boot commands
> + */
> +int board_usb_init(enum board_usb_init_type what_to_init);
> +
> #ifdef CONFIG_USB_STORAGE
>
> #define USB_MAX_STOR_DEV 5
> diff --git a/include/usb_mass_storage.h b/include/usb_mass_storage.h
> index 35cdcc3..de31b0e 100644
> --- a/include/usb_mass_storage.h
> +++ b/include/usb_mass_storage.h
> @@ -30,13 +30,11 @@ struct ums_board_info {
> struct ums_device ums_dev;
> };
>
> -extern void board_usb_init(void);
> -
> -extern int fsg_init(struct ums_board_info *);
> -extern void fsg_cleanup(void);
> -extern struct ums_board_info *board_ums_init(unsigned int,
> +int fsg_init(struct ums_board_info *);
> +void fsg_cleanup(void);
> +struct ums_board_info *board_ums_init(unsigned int,
> unsigned int, unsigned int);
> -extern int usb_gadget_handle_interrupts(void);
> -extern int fsg_main_thread(void *);
> +int usb_gadget_handle_interrupts(void);
> +int fsg_main_thread(void *);
>
> #endif /* __USB_MASS_STORAGE_H__ */
Best regards,
Marek Vasut
next prev parent reply other threads:[~2013-08-11 18:04 UTC|newest]
Thread overview: 64+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-06 10:50 [U-Boot] [RFC 00/10] New board-specific USB initialization interface Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 01/10] " Mateusz Zalega
2013-08-07 16:23 ` Stephen Warren
2013-08-11 18:04 ` Marek Vasut [this message]
2013-08-12 9:33 ` Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 02/10] nvidia, tegra: new USB hardware init interface Mateusz Zalega
2013-08-07 16:26 ` Stephen Warren
2013-08-06 10:50 ` [U-Boot] [RFC 03/10] Voipac PXA270: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 04/10] Trizeps IV: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 05/10] Colibri PXA270: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 06/10] icpdas lp8x4x: " Mateusz Zalega
2013-08-11 18:07 ` Marek Vasut
2013-08-06 10:50 ` [U-Boot] [RFC 07/10] esd pmc440: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 08/10] esd apc405: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 09/10] balloon3: " Mateusz Zalega
2013-08-06 10:50 ` [U-Boot] [RFC 10/10] canyonlands: " Mateusz Zalega
2013-08-06 11:40 ` [U-Boot] [RFC 00/10] New board-specific USB initialization interface Wolfgang Denk
2013-08-07 15:57 ` Mateusz Zalega
2013-08-07 16:59 ` Mateusz Zalega
2013-08-07 17:01 ` Wolfgang Denk
2013-08-20 13:35 ` [U-Boot] [PATCH] usb: new board-specific USB init interface Mateusz Zalega
2013-08-21 3:33 ` Marek Vasut
2013-08-21 10:22 ` Mateusz Zalega
2013-08-21 13:08 ` Marek Vasut
2013-08-22 10:32 ` Mateusz Zalega
2013-08-22 19:37 ` Marek Vasut
2013-08-26 10:41 ` Mateusz Zalega
2013-08-27 19:50 ` Marek Vasut
2013-08-21 8:33 ` [U-Boot] [PATCH v2] " Mateusz Zalega
2013-08-27 15:51 ` Mateusz Zalega
2013-09-03 10:41 ` [U-Boot] [PATCH v3] " Mateusz Zalega
2013-09-05 15:50 ` Marek Vasut
2013-09-05 17:37 ` Mateusz Zalega
2013-09-05 17:51 ` Marek Vasut
2013-09-06 11:22 ` Mateusz Zalega
2013-09-06 11:24 ` Marek Vasut
2013-09-06 11:36 ` Mateusz Zalega
2013-09-06 11:40 ` Marek Vasut
2013-09-06 12:17 ` Mateusz Zalega
2013-09-15 14:21 ` Marek Vasut
2013-09-16 8:27 ` Mateusz Zalega
2013-09-10 15:10 ` [U-Boot] [PATCH v4] " Mateusz Zalega
2013-09-15 16:44 ` Marek Vasut
2013-09-16 9:10 ` Mateusz Zalega
2013-09-16 14:24 ` Marek Vasut
2013-09-17 16:11 ` Igor Grinberg
2013-09-18 10:58 ` Mateusz Zalega
2013-09-19 13:34 ` Marek Vasut
2013-09-19 13:40 ` Marek Vasut
2013-09-19 14:34 ` Marek Vasut
2013-09-24 11:54 ` Minkyu Kang
2013-09-24 13:15 ` Marek Vasut
2013-09-25 11:01 ` Mateusz Zalega
2013-09-26 1:50 ` Marek Vasut
2013-09-26 10:04 ` Mateusz Zalega
2013-10-02 19:11 ` [U-Boot] [PATCH v5] " Mateusz Zalega
2013-10-03 15:16 ` Marek Vasut
2013-10-04 17:22 ` [U-Boot] [PATCH v6] " Mateusz Zalega
2013-10-05 0:48 ` Troy Kisky
2013-10-07 10:32 ` Mateusz Zalega
2013-10-08 0:09 ` Troy Kisky
2013-10-08 10:31 ` Marek Vasut
2013-10-06 13:55 ` Marek Vasut
[not found] <52027F05.3010309@samsung.com>
2013-08-07 17:09 ` [U-Boot] [RFC 01/10] New board-specific USB initialization interface Mateusz Zalega
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=201308112004.51765.marex@denx.de \
--to=marex@denx.de \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox