From: Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>
To: Inochi Amaoto <inochiama@outlook.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Conor Dooley <conor+dt@kernel.org>,
Minas Harutyunyan <Minas.Harutyunyan@synopsys.com>,
Paul Walmsley <paul.walmsley@sifive.com>,
Palmer Dabbelt <palmer@dabbelt.com>,
Albert Ou <aou@eecs.berkeley.edu>
Cc: Chen Wang <unicorn_wang@outlook.com>,
Liu Gui <kenneth.liu@sophgo.com>,
"linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"linux-riscv@lists.infradead.org"
<linux-riscv@lists.infradead.org>
Subject: Re: [PATCH 2/2] usb: dwc2: add support for Sophgo CV18XX/SG200X series SoC
Date: Tue, 26 Mar 2024 07:31:45 +0000 [thread overview]
Message-ID: <676b59ee-cf7f-03a6-78a1-197cf5a66ec6@synopsys.com> (raw)
In-Reply-To: <IA1PR20MB4953EE73DD36D5FFC81D90EDBB352@IA1PR20MB4953.namprd20.prod.outlook.com>
On 3/26/24 06:37, Inochi Amaoto wrote:
> Add params for DWC2 IP in Sophgo CV18XX/SG200X series SoC.
>
> Signed-off-by: Inochi Amaoto <inochiama@outlook.com>
Acked-by: Minas Harutyunyan <hminas@synopsys.com>
> ---
> drivers/usb/dwc2/params.c | 21 +++++++++++++++++++++
> 1 file changed, 21 insertions(+)
>
> diff --git a/drivers/usb/dwc2/params.c b/drivers/usb/dwc2/params.c
> index eb677c3cfd0b..171fcb34eb75 100644
> --- a/drivers/usb/dwc2/params.c
> +++ b/drivers/usb/dwc2/params.c
> @@ -201,6 +201,25 @@ static void dwc2_set_amcc_params(struct dwc2_hsotg *hsotg)
> p->ahbcfg = GAHBCFG_HBSTLEN_INCR16 << GAHBCFG_HBSTLEN_SHIFT;
> }
>
> +static void dwc2_set_cv1800_params(struct dwc2_hsotg *hsotg)
> +{
> + struct dwc2_core_params *p = &hsotg->params;
> +
> + p->otg_caps.hnp_support = false;
> + p->otg_caps.srp_support = false;
> + p->host_dma = false;
> + p->g_dma = false;
> + p->speed = DWC2_SPEED_PARAM_HIGH;
> + p->phy_type = DWC2_PHY_TYPE_PARAM_UTMI;
> + p->phy_utmi_width = 16;
> + p->ahbcfg = GAHBCFG_HBSTLEN_INCR16 << GAHBCFG_HBSTLEN_SHIFT;
> + p->lpm = false;
> + p->lpm_clock_gating = false;
> + p->besl = false;
> + p->hird_threshold_en = false;
> + p->power_down = DWC2_POWER_DOWN_PARAM_NONE;
> +}
> +
> static void dwc2_set_stm32f4x9_fsotg_params(struct dwc2_hsotg *hsotg)
> {
> struct dwc2_core_params *p = &hsotg->params;
> @@ -295,6 +314,8 @@ const struct of_device_id dwc2_of_match_table[] = {
> .data = dwc2_set_amlogic_a1_params },
> { .compatible = "amcc,dwc-otg", .data = dwc2_set_amcc_params },
> { .compatible = "apm,apm82181-dwc-otg", .data = dwc2_set_amcc_params },
> + { .compatible = "sophgo,cv1800-usb",
> + .data = dwc2_set_cv1800_params },
> { .compatible = "st,stm32f4x9-fsotg",
> .data = dwc2_set_stm32f4x9_fsotg_params },
> { .compatible = "st,stm32f4x9-hsotg" },
> --
> 2.44.0
>
prev parent reply other threads:[~2024-03-26 7:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-26 2:36 [PATCH 0/2] riscv: sophgo: add support for usb controller of CV18XX/SG200X Inochi Amaoto
2024-03-26 2:37 ` [PATCH 1/2] dt-bindings: usb: dwc2: Add support for Sophgo CV18XX/SG200X series SoC Inochi Amaoto
2024-03-26 7:01 ` Krzysztof Kozlowski
2024-03-26 2:37 ` [PATCH 2/2] usb: dwc2: add " Inochi Amaoto
2024-03-26 7:31 ` Minas Harutyunyan [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=676b59ee-cf7f-03a6-78a1-197cf5a66ec6@synopsys.com \
--to=minas.harutyunyan@synopsys.com \
--cc=aou@eecs.berkeley.edu \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=inochiama@outlook.com \
--cc=kenneth.liu@sophgo.com \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=linux-usb@vger.kernel.org \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=robh+dt@kernel.org \
--cc=unicorn_wang@outlook.com \
/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;
as well as URLs for NNTP newsgroup(s).