From: Patrice CHOTARD <patrice.chotard@st.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v7 07/10] usb: dwc3: Add dwc3 glue driver support for STi
Date: Tue, 6 Jun 2017 07:26:35 +0000 [thread overview]
Message-ID: <022e7521-55a4-5fe3-fe22-b1b48aeb84e1@st.com> (raw)
In-Reply-To: <0924e557-9234-2b38-9ffc-e68fc8f37378@denx.de>
Hi Marek
On 06/05/2017 01:22 PM, Marek Vasut wrote:
> On 06/05/2017 08:40 AM, Patrice CHOTARD wrote:
>> Hi Marek
>
> Hi,
>
> [...]
>
>>>> diff --git a/include/dwc3-sti-glue.h b/include/dwc3-sti-glue.h
>>>> new file mode 100644
>>>> index 0000000..2083427
>>>> --- /dev/null
>>>> +++ b/include/dwc3-sti-glue.h
>>>> @@ -0,0 +1,43 @@
>>>> +/*
>>>> + * Copyright (c) 2017
>>>> + * Patrice Chotard <patrice.chotard@st.com>
>>>> + *
>>>> + * SPDX-License-Identifier: GPL-2.0+
>>>> + */
>>>> +
>>>> +#ifndef __DWC3_STI_UBOOT_H_
>>>> +#define __DWC3_STI_UBOOT_H_
>>>> +
>>>> +#include <linux/usb/otg.h>
>>>
>>> Does this have to be in a separate header file ?
>>
>> This is needed for enum usb_dr_mode used in int sti_dwc3_init()
>> prototype below.
>
> So just wrap it into dwc3-sti-glue.c ?
>
ok
>>>> +/* glue registers */
>>>> +#define CLKRST_CTRL 0x00
>>>> +#define AUX_CLK_EN BIT(0)
>>>> +#define SW_PIPEW_RESET_N BIT(4)
>>>> +#define EXT_CFG_RESET_N BIT(8)
>>>> +
>>>> +#define XHCI_REVISION BIT(12)
>>>> +
>>>> +#define USB2_VBUS_MNGMNT_SEL1 0x2C
>>>> +#define USB2_VBUS_UTMIOTG 0x1
>>>> +
>>>> +#define SEL_OVERRIDE_VBUSVALID(n) ((n) << 0)
>>>> +#define SEL_OVERRIDE_POWERPRESENT(n) ((n) << 4)
>>>> +#define SEL_OVERRIDE_BVALID(n) ((n) << 8)
>>>> +
>>>> +/* Static DRD configuration */
>>>> +#define USB3_CONTROL_MASK 0xf77
>>>> +
>>>> +#define USB3_DEVICE_NOT_HOST BIT(0)
>>>> +#define USB3_FORCE_VBUSVALID BIT(1)
>>>> +#define USB3_DELAY_VBUSVALID BIT(2)
>>>> +#define USB3_SEL_FORCE_OPMODE BIT(4)
>>>> +#define USB3_FORCE_OPMODE(n) ((n) << 5)
>>>> +#define USB3_SEL_FORCE_DPPULLDOWN2 BIT(8)
>>>> +#define USB3_FORCE_DPPULLDOWN2 BIT(9)
>>>> +#define USB3_SEL_FORCE_DMPULLDOWN2 BIT(10)
>>>> +#define USB3_FORCE_DMPULLDOWN2 BIT(11)
>>>> +
>>>> +int sti_dwc3_init(enum usb_dr_mode mode);
>>>> +
>>>> +#endif /* __DWC3_STI_UBOOT_H_ */
>>>>
>>>
>
>
next prev parent reply other threads:[~2017-06-06 7:26 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-06-01 12:05 [U-Boot] [PATCH v7 00/10] STiH410-B2260: add reset, usb and fastboot support patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 01/10] mmc: sti_sdhci: Rework sti_mmc_core_config() patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 02/10] ARM: dts: stih410-family: Add missing reset_names for mmc1 node patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 03/10] mmc: sti_sdhci: Use reset framework patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 04/10] usb: phy: Add STi USB2 PHY patrice.chotard at st.com
2017-06-02 2:56 ` Simon Glass
2017-06-03 6:08 ` Marek Vasut
2017-06-05 6:58 ` Patrice CHOTARD
2017-06-05 11:21 ` Marek Vasut
2017-06-06 7:16 ` Patrice CHOTARD
2017-06-01 12:05 ` [U-Boot] [PATCH v7 05/10] STiH410-B2260: enable USB Host Networking patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 06/10] STiH410-B2260: enable USB, fastboot, reset, PHY related flags patrice.chotard at st.com
2017-06-01 12:05 ` [U-Boot] [PATCH v7 07/10] usb: dwc3: Add dwc3 glue driver support for STi patrice.chotard at st.com
2017-06-03 6:06 ` Marek Vasut
2017-06-05 6:40 ` Patrice CHOTARD
2017-06-05 11:22 ` Marek Vasut
2017-06-06 7:26 ` Patrice CHOTARD [this message]
2017-06-01 12:05 ` [U-Boot] [PATCH v7 08/10] ARM: dts: STiH410: set DWC3 dual role mode to peripheral patrice.chotard at st.com
2017-06-02 2:56 ` Simon Glass
2017-06-01 12:05 ` [U-Boot] [PATCH v7 09/10] ARM: dts: STiH410: update ehci and ohci compatible patrice.chotard at st.com
2017-06-02 2:56 ` Simon Glass
2017-06-01 12:05 ` [U-Boot] [PATCH v7 10/10] board: STiH410-B2260: add fastboot support patrice.chotard at st.com
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=022e7521-55a4-5fe3-fe22-b1b48aeb84e1@st.com \
--to=patrice.chotard@st.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.