* [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data
@ 2022-09-12 13:23 Prathamesh Shete
2022-09-12 13:23 ` [PATCH 2/2] mmc: sdhci-tegra: Use actual clock rate for SW tuning correction Prathamesh Shete
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Prathamesh Shete @ 2022-09-12 13:23 UTC (permalink / raw)
To: adrian.hunter, ulf.hansson, thierry.reding, jonathanh, p.zabel,
linux-mmc, linux-tegra, linux-kernel
Cc: anrao, smangipudi, pshete
Create new SoC data structure for T23x platforms.
Signed-off-by: Aniruddha Tvs Rao <anrao@nvidia.com>
Signed-off-by: Prathamesh Shete <pshete@nvidia.com>
---
drivers/mmc/host/sdhci-tegra.c | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
index 2d2d8260c681..136c045d8f01 100644
--- a/drivers/mmc/host/sdhci-tegra.c
+++ b/drivers/mmc/host/sdhci-tegra.c
@@ -1525,7 +1525,8 @@ static const struct sdhci_pltfm_data sdhci_tegra186_pdata = {
SDHCI_QUIRK_NO_HISPD_BIT |
SDHCI_QUIRK_BROKEN_ADMA_ZEROLEN_DESC |
SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN,
- .quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN,
+ .quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN |
+ SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER,
.ops = &tegra186_sdhci_ops,
};
@@ -1556,7 +1557,21 @@ static const struct sdhci_tegra_soc_data soc_data_tegra194 = {
.max_tap_delay = 139,
};
+static const struct sdhci_tegra_soc_data soc_data_tegra234 = {
+ .pdata = &sdhci_tegra186_pdata,
+ .dma_mask = DMA_BIT_MASK(39),
+ .nvquirks = NVQUIRK_NEEDS_PAD_CONTROL |
+ NVQUIRK_HAS_PADCALIB |
+ NVQUIRK_DIS_CARD_CLK_CONFIG_TAP |
+ NVQUIRK_ENABLE_SDR50 |
+ NVQUIRK_ENABLE_SDR104 |
+ NVQUIRK_HAS_TMCLK,
+ .min_tap_delay = 95,
+ .max_tap_delay = 111,
+};
+
static const struct of_device_id sdhci_tegra_dt_match[] = {
+ { .compatible = "nvidia,tegra234-sdhci", .data = &soc_data_tegra234 },
{ .compatible = "nvidia,tegra194-sdhci", .data = &soc_data_tegra194 },
{ .compatible = "nvidia,tegra186-sdhci", .data = &soc_data_tegra186 },
{ .compatible = "nvidia,tegra210-sdhci", .data = &soc_data_tegra210 },
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH 2/2] mmc: sdhci-tegra: Use actual clock rate for SW tuning correction
2022-09-12 13:23 [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Prathamesh Shete
@ 2022-09-12 13:23 ` Prathamesh Shete
2022-09-12 14:49 ` [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Jon Hunter
2022-09-12 23:18 ` kernel test robot
2 siblings, 0 replies; 4+ messages in thread
From: Prathamesh Shete @ 2022-09-12 13:23 UTC (permalink / raw)
To: adrian.hunter, ulf.hansson, thierry.reding, jonathanh, p.zabel,
linux-mmc, linux-tegra, linux-kernel
Cc: anrao, smangipudi, pshete
Ensure tegra_host member "curr_clk_rate" holds the actual clock rate
instead of requested clock rate for proper use during tuning correction
algorithm.
Fixes: ea8fc5953e8b ("mmc: tegra: update hw tuning process")
Signed-off-by: Aniruddha TVS Rao <anrao@nvidia.com>
Signed-off-by: Prathamesh Shete <pshete@nvidia.com>
---
drivers/mmc/host/sdhci-tegra.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
index 136c045d8f01..3a3d188e8c65 100644
--- a/drivers/mmc/host/sdhci-tegra.c
+++ b/drivers/mmc/host/sdhci-tegra.c
@@ -773,7 +773,7 @@ static void tegra_sdhci_set_clock(struct sdhci_host *host, unsigned int clock)
dev_err(dev, "failed to set clk rate to %luHz: %d\n",
host_clk, err);
- tegra_host->curr_clk_rate = host_clk;
+ tegra_host->curr_clk_rate = clk_get_rate(pltfm_host->clk);
if (tegra_host->ddr_signaling)
host->max_clk = host_clk;
else
--
2.17.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data
2022-09-12 13:23 [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Prathamesh Shete
2022-09-12 13:23 ` [PATCH 2/2] mmc: sdhci-tegra: Use actual clock rate for SW tuning correction Prathamesh Shete
@ 2022-09-12 14:49 ` Jon Hunter
2022-09-12 23:18 ` kernel test robot
2 siblings, 0 replies; 4+ messages in thread
From: Jon Hunter @ 2022-09-12 14:49 UTC (permalink / raw)
To: Prathamesh Shete, adrian.hunter, ulf.hansson, thierry.reding,
p.zabel, linux-mmc, linux-tegra, linux-kernel
Cc: anrao, smangipudi
On 12/09/2022 14:23, Prathamesh Shete wrote:
> Create new SoC data structure for T23x platforms.
Always helpful to say why we need to add new SoC data. Ie. what is
different?
> Signed-off-by: Aniruddha Tvs Rao <anrao@nvidia.com>
> Signed-off-by: Prathamesh Shete <pshete@nvidia.com>
> ---
> drivers/mmc/host/sdhci-tegra.c | 17 ++++++++++++++++-
> 1 file changed, 16 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
> index 2d2d8260c681..136c045d8f01 100644
> --- a/drivers/mmc/host/sdhci-tegra.c
> +++ b/drivers/mmc/host/sdhci-tegra.c
> @@ -1525,7 +1525,8 @@ static const struct sdhci_pltfm_data sdhci_tegra186_pdata = {
> SDHCI_QUIRK_NO_HISPD_BIT |
> SDHCI_QUIRK_BROKEN_ADMA_ZEROLEN_DESC |
> SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN,
> - .quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN,
> + .quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN |
> + SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER,
> .ops = &tegra186_sdhci_ops,
> };
>
> @@ -1556,7 +1557,21 @@ static const struct sdhci_tegra_soc_data soc_data_tegra194 = {
> .max_tap_delay = 139,
> };
>
> +static const struct sdhci_tegra_soc_data soc_data_tegra234 = {
> + .pdata = &sdhci_tegra186_pdata,
> + .dma_mask = DMA_BIT_MASK(39),
> + .nvquirks = NVQUIRK_NEEDS_PAD_CONTROL |
> + NVQUIRK_HAS_PADCALIB |
> + NVQUIRK_DIS_CARD_CLK_CONFIG_TAP |
> + NVQUIRK_ENABLE_SDR50 |
> + NVQUIRK_ENABLE_SDR104 |
> + NVQUIRK_HAS_TMCLK,
> + .min_tap_delay = 95,
> + .max_tap_delay = 111,
> +};
> +
> static const struct of_device_id sdhci_tegra_dt_match[] = {
> + { .compatible = "nvidia,tegra234-sdhci", .data = &soc_data_tegra234 },
> { .compatible = "nvidia,tegra194-sdhci", .data = &soc_data_tegra194 },
> { .compatible = "nvidia,tegra186-sdhci", .data = &soc_data_tegra186 },
> { .compatible = "nvidia,tegra210-sdhci", .data = &soc_data_tegra210 },
--
nvpublic
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data
2022-09-12 13:23 [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Prathamesh Shete
2022-09-12 13:23 ` [PATCH 2/2] mmc: sdhci-tegra: Use actual clock rate for SW tuning correction Prathamesh Shete
2022-09-12 14:49 ` [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Jon Hunter
@ 2022-09-12 23:18 ` kernel test robot
2 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2022-09-12 23:18 UTC (permalink / raw)
To: Prathamesh Shete, adrian.hunter, ulf.hansson, thierry.reding,
jonathanh, p.zabel, linux-mmc, linux-tegra, linux-kernel
Cc: kbuild-all, anrao, smangipudi, pshete
Hi Prathamesh,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on tegra/for-next]
[also build test ERROR on linus/master v6.0-rc5 next-20220912]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Prathamesh-Shete/mmc-sdhci-tegra-Separate-T19x-and-T23x-SoC-data/20220912-212611
base: https://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux.git for-next
config: m68k-allmodconfig (https://download.01.org/0day-ci/archive/20220913/202209130728.VPH1SdRJ-lkp@intel.com/config)
compiler: m68k-linux-gcc (GCC) 12.1.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/intel-lab-lkp/linux/commit/d1a916947a4fb73d2982138d4e35dc50b4d19b3c
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Prathamesh-Shete/mmc-sdhci-tegra-Separate-T19x-and-T23x-SoC-data/20220912-212611
git checkout d1a916947a4fb73d2982138d4e35dc50b4d19b3c
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=m68k SHELL=/bin/bash drivers/mmc/host/
If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
>> drivers/mmc/host/sdhci-tegra.c:1529:20: error: 'SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER' undeclared here (not in a function)
1529 | SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vim +/SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER +1529 drivers/mmc/host/sdhci-tegra.c
1521
1522 static const struct sdhci_pltfm_data sdhci_tegra186_pdata = {
1523 .quirks = SDHCI_QUIRK_BROKEN_TIMEOUT_VAL |
1524 SDHCI_QUIRK_SINGLE_POWER_WRITE |
1525 SDHCI_QUIRK_NO_HISPD_BIT |
1526 SDHCI_QUIRK_BROKEN_ADMA_ZEROLEN_DESC |
1527 SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN,
1528 .quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN |
> 1529 SDHCI_QUIRK2_ISSUE_CMD_DAT_RESET_TOGETHER,
1530 .ops = &tegra186_sdhci_ops,
1531 };
1532
--
0-DAY CI Kernel Test Service
https://01.org/lkp
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-09-12 23:19 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-12 13:23 [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Prathamesh Shete
2022-09-12 13:23 ` [PATCH 2/2] mmc: sdhci-tegra: Use actual clock rate for SW tuning correction Prathamesh Shete
2022-09-12 14:49 ` [PATCH 1/2] mmc: sdhci-tegra: Separate T19x and T23x SoC data Jon Hunter
2022-09-12 23:18 ` kernel test robot
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).