All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC PATCH v1] usb: spl: fix USB errata for FSL SPL targets
Date: Tue, 28 Jun 2016 01:53:07 +0200	[thread overview]
Message-ID: <5771BC63.3020101@denx.de> (raw)
In-Reply-To: <1467068555-12673-1-git-send-email-york.sun@nxp.com>

On 06/28/2016 01:02 AM, York Sun wrote:
> Commit 9262367 moved USB errata workaround to a C file but didn't
> build it for SPL targets.
> 
> Signed-off-by: York Sun <york.sun@nxp.com>
> CC: Sriram Dash <sriram.dash@nxp.com>
> CC: Rajesh Bhagat <rajesh.bhagat@nxp.com>
> 
> ---
> Please review this patch. It fixed the compiling errors introduced by
> 9262367. Not sure if this is the way USB errata should be handled.
> 
>  drivers/Makefile                    | 7 +++++++
>  drivers/usb/common/Makefile         | 8 ++++++--
>  include/configs/km/kmp204x-common.h | 1 +
>  3 files changed, 14 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/Makefile b/drivers/Makefile
> index 1723958..88774ba 100644
> --- a/drivers/Makefile
> +++ b/drivers/Makefile
> @@ -39,6 +39,13 @@ obj-$(CONFIG_OMAP_USB_PHY) += usb/phy/
>  obj-$(CONFIG_SPL_SATA_SUPPORT) += block/
>  obj-$(CONFIG_SPL_USB_HOST_SUPPORT) += block/
>  obj-$(CONFIG_SPL_MMC_SUPPORT) += block/
> +ifdef CONFIG_USB_EHCI_FSL
> +CONFIG_SPL_USB_ERRATA = y
> +endif
> +ifdef CONFIG_USB_XHCI_FSL
> +CONFIG_SPL_USB_ERRATA = y
> +endif
> +obj-$(CONFIG_SPL_USB_ERRATA) += usb/common/

I really dislike the naming here, I'd say just do

obj-$(CONFIG_USB_EHCI_FSL) += usb/common/
obj-$(CONFIG_USB_XHCI_FSL) += usb/common/

>  else
>  
> diff --git a/drivers/usb/common/Makefile b/drivers/usb/common/Makefile
> index aee7e32..f073e1c 100644
> --- a/drivers/usb/common/Makefile
> +++ b/drivers/usb/common/Makefile
> @@ -4,5 +4,9 @@
>  #
>  
>  obj-$(CONFIG_DM_USB) += common.o
> -obj-$(CONFIG_USB_EHCI_FSL) += fsl-dt-fixup.o fsl-errata.o
> -obj-$(CONFIG_USB_XHCI_FSL) += fsl-dt-fixup.o fsl-errata.o
> +obj-$(CONFIG_USB_EHCI_FSL) += fsl-errata.o
> +obj-$(CONFIG_USB_XHCI_FSL) += fsl-errata.o
> +ifndef CONFIG_SPL_BUILD
> +obj-$(CONFIG_USB_EHCI_FSL) += fsl-dt-fixup.o
> +obj-$(CONFIG_USB_XHCI_FSL) += fsl-dt-fixup.o
> +endif

Either the filename is misnamed or this is real broken design.
I would expect that a filename with -dt- in it's name should
depend on CONFIG_*FDT* , but not on CONFIG_SPL_BUILD.

> diff --git a/include/configs/km/kmp204x-common.h b/include/configs/km/kmp204x-common.h
> index 028623d..5bdda22 100644
> --- a/include/configs/km/kmp204x-common.h
> +++ b/include/configs/km/kmp204x-common.h
> @@ -406,6 +406,7 @@ int get_scl(void);
>  #endif
>  
>  #define __USB_PHY_TYPE	utmi
> +#define CONFIG_USB_EHCI_FSL
>  
>  /*
>   * Environment Configuration
> 


-- 
Best regards,
Marek Vasut

  reply	other threads:[~2016-06-27 23:53 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-27 23:02 [U-Boot] [RFC PATCH v1] usb: spl: fix USB errata for FSL SPL targets York Sun
2016-06-27 23:53 ` Marek Vasut [this message]
2016-06-28  7:02   ` Sriram Dash
2016-06-28  8:02     ` Marek Vasut
2016-06-28 15:47     ` york sun
2016-06-29  3:53       ` Sriram Dash
2016-06-29  4:12         ` york sun
2016-06-29 10:27           ` Marek Vasut

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=5771BC63.3020101@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 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.