From: Minkyu Kang <mk7.kang@samsung.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] EXYNOS5: Add function to enable exynos5420 usbdev phy ctrl
Date: Fri, 13 Feb 2015 17:25:49 +0900 [thread overview]
Message-ID: <54DDB50D.5040903@samsung.com> (raw)
In-Reply-To: <1421815892-13160-1-git-send-email-jy0922.shim@samsung.com>
On 21/01/15 13:51, Joonyoung Shim wrote:
> Exynos5420 has different registers with other exynos5 SoCs to control
> usb device phy, so need separated function to enable exynos5420 usb
> device phy.
>
> Signed-off-by: Joonyoung Shim <jy0922.shim@samsung.com>
> ---
> I used "usbdev" instead of "usbdrd" on function name because registers
> name prefix is usbdev_.
>
> arch/arm/cpu/armv7/exynos/power.c | 28 ++++++++++++++++++++++++++--
> 1 file changed, 26 insertions(+), 2 deletions(-)
>
> diff --git a/arch/arm/cpu/armv7/exynos/power.c b/arch/arm/cpu/armv7/exynos/power.c
> index 1520d64..1b12051 100644
> --- a/arch/arm/cpu/armv7/exynos/power.c
> +++ b/arch/arm/cpu/armv7/exynos/power.c
> @@ -102,10 +102,34 @@ static void exynos5_set_usbdrd_phy_ctrl(unsigned int enable)
> }
> }
>
> +static void exynos5420_set_usbdev_phy_ctrl(unsigned int enable)
> +{
> + struct exynos5420_power *power =
> + (struct exynos5420_power *)samsung_get_base_power();
> +
> + if (enable) {
> + /* Enabling USBDEV_PHY */
> + setbits_le32(&power->usbdev_phy_control,
> + POWER_USB_DRD_PHY_CTRL_EN);
> + setbits_le32(&power->usbdev1_phy_control,
> + POWER_USB_DRD_PHY_CTRL_EN);
> + } else {
> + /* Disabling USBDEV_PHY */
> + clrbits_le32(&power->usbdev_phy_control,
> + POWER_USB_DRD_PHY_CTRL_EN);
> + clrbits_le32(&power->usbdev1_phy_control,
> + POWER_USB_DRD_PHY_CTRL_EN);
> + }
> +}
> +
> void set_usbdrd_phy_ctrl(unsigned int enable)
> {
> - if (cpu_is_exynos5())
> - exynos5_set_usbdrd_phy_ctrl(enable);
> + if (cpu_is_exynos5()) {
> + if (proid_is_exynos5420() || proid_is_exynos5800())
> + exynos5420_set_usbdev_phy_ctrl(enable);
> + else
> + exynos5_set_usbdrd_phy_ctrl(enable);
> + }
> }
>
> static void exynos5_dp_phy_control(unsigned int enable)
>
applied to u-boot-samsung.
Thank,
Minkyu Kang.
prev parent reply other threads:[~2015-02-13 8:25 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-21 4:51 [U-Boot] [PATCH] EXYNOS5: Add function to enable exynos5420 usbdev phy ctrl Joonyoung Shim
2015-02-13 8:25 ` Minkyu Kang [this message]
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=54DDB50D.5040903@samsung.com \
--to=mk7.kang@samsung.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.