From: "Jaehoon Chung" <jh80.chung@samsung.com>
To: "'Yang Xiwen'" <forbidden405@outlook.com>,
"'Peng Fan'" <peng.fan@nxp.com>
Cc: <u-boot@lists.denx.de>
Subject: RE: [PATCH v2 3/3] mmc: hi6220_dw_mmc: add fifoth_val to private data and set it in .probe
Date: Mon, 15 Apr 2024 16:00:03 +0900 [thread overview]
Message-ID: <008701da8f02$8a73ea90$9f5bbfb0$@samsung.com> (raw)
In-Reply-To: <SEZPR06MB6959CC3A9319816B2DFA8AA7963D2@SEZPR06MB6959.apcprd06.prod.outlook.com>
Hi,
> -----Original Message-----
> From: Yang Xiwen <forbidden405@outlook.com>
> Sent: Wednesday, April 3, 2024 10:22 AM
> To: Jaehoon Chung <jh80.chung@samsung.com>; Peng Fan <peng.fan@nxp.com>
> Cc: u-boot@lists.denx.de
> Subject: Re: [PATCH v2 3/3] mmc: hi6220_dw_mmc: add fifoth_val to private data and set it in .probe
>
> On 4/3/2024 8:43 AM, Jaehoon Chung wrote:
> > Hi
> >
> > On 2/1/24 23:05, Yang Xiwen via B4 Relay wrote:
> >> From: Yang Xiwen <forbidden405@outlook.com>
> >>
> >> The value defaults to 0 and is ignored by dw_mmc code, so the other
> >> users are not affected.
> >>
> >> Setting this explicitly fixes some weird reading error found on Hi3798MV200.
> >>
> >> Fixes: 8a5dc8140e62 ("mmc: hi6220_dw_mmc: add compatible for HC2910 support")
> >>
> >> Signed-off-by: Yang Xiwen <forbidden405@outlook.com>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
> >> ---
> >> drivers/mmc/hi6220_dw_mmc.c | 11 ++++++++++-
> >> 1 file changed, 10 insertions(+), 1 deletion(-)
> >>
> >> diff --git a/drivers/mmc/hi6220_dw_mmc.c b/drivers/mmc/hi6220_dw_mmc.c
> >> index a4b8072976..dc0210402b 100644
> >> --- a/drivers/mmc/hi6220_dw_mmc.c
> >> +++ b/drivers/mmc/hi6220_dw_mmc.c
> >> @@ -37,6 +37,7 @@ struct hi6220_dwmmc_priv_data {
> >> struct hisi_mmc_data {
> >> unsigned int clock;
> >> bool use_fifo;
> >> + u32 fifoth_val;
> >> };
> >>
> >> static int hi6220_dwmmc_of_to_plat(struct udevice *dev)
> >> @@ -125,6 +126,7 @@ static int hi6220_dwmmc_probe(struct udevice *dev)
> >> host->mmc = &plat->mmc;
> >>
> >> host->fifo_mode = mmc_data->use_fifo;
> >> + host->fifoth_val = mmc_data->fifoth_val;
> >> host->mmc->priv = &priv->host;
> >> upriv->mmc = host->mmc;
> >> host->mmc->dev = dev;
> >> @@ -154,13 +156,20 @@ static const struct hisi_mmc_data hi6220_mmc_data = {
> >> .use_fifo = false,
> >> };
> >>
> >> +static const struct hisi_mmc_data hi3798mv2x_mmc_data = {
> >> + .clock = 50000000,
> >> + .use_fifo = false,
> >> + // FIFO depth is 256
> > Removed unnecessary comment.
>
>
> Will do. It seems that this should also apply to hi3798cv200-dw-mshc.
> tests are needed from cv200 users.
In future, It can be removed. Others looks good to me.
Best Regards,
Jaehoon Chung
>
>
> >
> > Best Regards,
> > Jaehoon Chung
> >
> >> + .fifoth_val = MSIZE(4) | RX_WMARK(0x7f) | TX_WMARK(0x80),
> >> +};
> >> +
> >> static const struct udevice_id hi6220_dwmmc_ids[] = {
> >> { .compatible = "hisilicon,hi6220-dw-mshc",
> >> .data = (ulong)&hi6220_mmc_data },
> >> { .compatible = "hisilicon,hi3798cv200-dw-mshc",
> >> .data = (ulong)&hi6220_mmc_data },
> >> { .compatible = "hisilicon,hi3798mv200-dw-mshc",
> >> - .data = (ulong)&hi6220_mmc_data },
> >> + .data = (ulong)&hi3798mv2x_mmc_data },
> >> { .compatible = "hisilicon,hi3660-dw-mshc",
> >> .data = (ulong)&hi3660_mmc_data },
> >> { }
>
>
> --
> Regards,
> Yang Xiwen
prev parent reply other threads:[~2024-04-15 7:00 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-02-01 14:05 [PATCH v2 0/3] mmc: hi6220-dwmmc: handle resets and clocks Yang Xiwen via B4 Relay
2024-02-01 14:05 ` [PATCH v2 1/3] mmc: hi6220-dwmmc: handle clocks and resets if CONFIG_CLK and CONFIG_DM_RESET enabled Yang Xiwen via B4 Relay
2024-04-03 0:39 ` Jaehoon Chung
2024-04-03 1:16 ` Yang Xiwen
2024-04-15 6:57 ` Jaehoon Chung
2024-02-01 14:05 ` [PATCH v2 2/3] mmc: dw_mmc: Don't return error if data busy timeout Yang Xiwen via B4 Relay
2024-04-03 0:41 ` Jaehoon Chung
2024-04-03 1:19 ` Yang Xiwen
2024-04-15 6:58 ` Jaehoon Chung
2024-02-01 14:05 ` [PATCH v2 3/3] mmc: hi6220_dw_mmc: add fifoth_val to private data and set it in .probe Yang Xiwen via B4 Relay
2024-04-03 0:43 ` Jaehoon Chung
2024-04-03 1:22 ` Yang Xiwen
2024-04-15 7:00 ` Jaehoon Chung [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='008701da8f02$8a73ea90$9f5bbfb0$@samsung.com' \
--to=jh80.chung@samsung.com \
--cc=forbidden405@outlook.com \
--cc=peng.fan@nxp.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox