* [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC [not found] <CGME20220111232902epcas1p1eb1f0919acbe30299305458f881dc175@epcas1p1.samsung.com> @ 2022-01-11 23:29 ` Jaehoon Chung 2022-01-12 6:53 ` Minkyu Kang 0 siblings, 1 reply; 5+ messages in thread From: Jaehoon Chung @ 2022-01-11 23:29 UTC (permalink / raw) To: u-boot Cc: peng.fan, haibo.chen, festevam, yangbo.lu, michael, sean.anderson, Jaehoon Chung From: Sean Anderson <sean.anderson@seco.com> U-boot prefers DM_MMC + BLK for MMC. Now eSDHC driver has already support it, so let's force to use it. - Drop non-BLK support for DM_MMC introduced by below patch. 66fa035 mmc: fsl_esdhc: fix probe issue without CONFIG_BLK enabled - Support only DM_MMC + BLK (assuming BLK is always enabled for DM_MMC). - Use DM_MMC instead of BLK for conditional compile. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> Signed-off-by: Sean Anderson <sean.anderson@seco.com> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> --- drivers/mmc/fsl_esdhc_imx.c | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/drivers/mmc/fsl_esdhc_imx.c b/drivers/mmc/fsl_esdhc_imx.c index 4c06361beefd..85cd72a79698 100644 --- a/drivers/mmc/fsl_esdhc_imx.c +++ b/drivers/mmc/fsl_esdhc_imx.c @@ -39,10 +39,6 @@ #include <dm/ofnode.h> #include <linux/iopoll.h> -#if !CONFIG_IS_ENABLED(BLK) -#include "mmc_private.h" -#endif - #ifndef ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE #ifdef CONFIG_FSL_USDHC #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 @@ -58,7 +54,6 @@ DECLARE_GLOBAL_DATA_PTR; IRQSTATEN_DEBE | IRQSTATEN_BRR | IRQSTATEN_BWR | \ IRQSTATEN_DINT) #define MAX_TUNING_LOOP 40 -#define ESDHC_DRIVER_STAGE_VALUE 0xffffffff struct fsl_esdhc { uint dsaddr; /* SDMA system address register */ @@ -157,7 +152,7 @@ struct fsl_esdhc_priv { unsigned int clock; unsigned int mode; unsigned int bus_width; -#if !CONFIG_IS_ENABLED(BLK) +#if !CONFIG_IS_ENABLED(DM_MMC) struct mmc *mmc; #endif struct udevice *dev; @@ -1510,9 +1505,6 @@ static int fsl_esdhc_probe(struct udevice *dev) struct esdhc_soc_data *data = (struct esdhc_soc_data *)dev_get_driver_data(dev); struct mmc *mmc; -#if !CONFIG_IS_ENABLED(BLK) - struct blk_desc *bdesc; -#endif int ret; #if CONFIG_IS_ENABLED(OF_PLATDATA) @@ -1611,25 +1603,6 @@ static int fsl_esdhc_probe(struct udevice *dev) mmc = &plat->mmc; mmc->cfg = &plat->cfg; mmc->dev = dev; -#if !CONFIG_IS_ENABLED(BLK) - mmc->priv = priv; - - /* Setup dsr related values */ - mmc->dsr_imp = 0; - mmc->dsr = ESDHC_DRIVER_STAGE_VALUE; - /* Setup the universal parts of the block interface just once */ - bdesc = mmc_get_blk_desc(mmc); - bdesc->if_type = IF_TYPE_MMC; - bdesc->removable = 1; - bdesc->devnum = mmc_get_next_devnum(); - bdesc->block_read = mmc_bread; - bdesc->block_write = mmc_bwrite; - bdesc->block_erase = mmc_berase; - - /* setup initial part type */ - bdesc->part_type = mmc->cfg->part_type; - mmc_list_add(mmc); -#endif upriv->mmc = mmc; @@ -1740,14 +1713,12 @@ static const struct udevice_id fsl_esdhc_ids[] = { { /* sentinel */ } }; -#if CONFIG_IS_ENABLED(BLK) static int fsl_esdhc_bind(struct udevice *dev) { struct fsl_esdhc_plat *plat = dev_get_plat(dev); return mmc_bind(dev, &plat->mmc, &plat->cfg); } -#endif U_BOOT_DRIVER(fsl_esdhc) = { .name = "fsl_esdhc", @@ -1755,9 +1726,7 @@ U_BOOT_DRIVER(fsl_esdhc) = { .of_match = fsl_esdhc_ids, .of_to_plat = fsl_esdhc_of_to_plat, .ops = &fsl_esdhc_ops, -#if CONFIG_IS_ENABLED(BLK) .bind = fsl_esdhc_bind, -#endif .probe = fsl_esdhc_probe, .plat_auto = sizeof(struct fsl_esdhc_plat), .priv_auto = sizeof(struct fsl_esdhc_priv), -- 2.29.0 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC 2022-01-11 23:29 ` [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC Jaehoon Chung @ 2022-01-12 6:53 ` Minkyu Kang 0 siblings, 0 replies; 5+ messages in thread From: Minkyu Kang @ 2022-01-12 6:53 UTC (permalink / raw) To: Jaehoon Chung Cc: U-Boot Mailing List, Peng Fan, haibo.chen, festevam, yangbo.lu, michael, sean.anderson Hi! On Wed, 12 Jan 2022 at 08:29, Jaehoon Chung <jh80.chung@samsung.com> wrote: > From: Sean Anderson <sean.anderson@seco.com> > > U-boot prefers DM_MMC + BLK for MMC. Now eSDHC driver has already > support it, so let's force to use it. > > - Drop non-BLK support for DM_MMC introduced by below patch. > 66fa035 mmc: fsl_esdhc: fix probe issue without CONFIG_BLK enabled > > - Support only DM_MMC + BLK (assuming BLK is always enabled for DM_MMC). > > - Use DM_MMC instead of BLK for conditional compile. > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> > Signed-off-by: Sean Anderson <sean.anderson@seco.com> > Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com> > --- > drivers/mmc/fsl_esdhc_imx.c | 33 +-------------------------------- > 1 file changed, 1 insertion(+), 32 deletions(-) > > Reviewed-by: Minkyu Kang <mk7.kang@samsung.com> -- Thanks, Minkyu Kang. ^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 00/12] fsl_esdhc_imx: port several patches from fsl_esdhc
@ 2021-11-23 20:03 Sean Anderson
2022-01-04 16:16 ` [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC Sean Anderson
0 siblings, 1 reply; 5+ messages in thread
From: Sean Anderson @ 2021-11-23 20:03 UTC (permalink / raw)
To: u-boot, Peng Fan, Jaehoon Chung
Cc: Haibo Chen, Fabio Estevam, Yangbo Lu, Michael Walle,
Sean Anderson, Simon Glass
This series ports some of the patches from fsl_esdhc to fsl_esdhc_imx.
Because these drivers share a common lineage, many of these patches
apply with minor changes. For each one, I have noted the originating
commit in the style of linux stable backports. Where I have had to
modify patches, I have noted the changes I have made before my SoB.
In fa33d20749 ("mmc: split fsl_esdhc driver for i.MX"), Yangbo says
> For the two series processors, the eSDHCs are becoming more and more
> different
However, these drivers are still extremely similar; the differences
between them are not major. NXP has not done a good job of porting
patches which apply to both drivers. This causes the fsl_esdhc_imx
driver to rot, as the fsl_esdhc gets more general fixes. For this
reason, I think that the fsl_esdhc_imx driver should be removed unless
NXP can commit to creating series like this which port patches which
apply to both drivers.
Changes in v3:
- Drop Kconfig BLK dependency
- Fix build error caused by unconverted OF_PLATDATA code
- Replace more #ifdefs by if
Changes in v2:
- Use a switch statement instead of ifs for max_bus_width
- Only default to 8 bit width when max_bus_width is not set
Sean Anderson (12):
mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC
mmc: fsl_esdhc_imx: remove redundant DM_MMC checking
mmc: fsl_esdhc_imx: fix voltage validation
mmc: fsl_esdhc_imx: clean up bus width configuration code
mmc: fsl_esdhc_imx: drop redundant code for non-removable feature
mmc: fsl_esdhc_imx: fix mmc->clock with actual clock
mmc: fsl_esdhc_imx: simplify 64bit check for SDMA transfers
mmc: fsl_esdhc_imx: use dma-mapping API
mmc: fsl_esdhc_imx: simplify esdhc_setup_data()
mmc: fsl_esdhc_imx: replace most #ifdefs by IS_ENABLED()
mmc: fsl_esdhc_imx: Replace more #ifdefs by if
mmc: fsl_esdhc_imx: set sysctl register for clock initialization
drivers/mmc/fsl_esdhc_imx.c | 643 ++++++++++++++----------------------
include/fsl_esdhc_imx.h | 14 +-
2 files changed, 263 insertions(+), 394 deletions(-)
--
2.25.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC 2021-11-23 20:03 [PATCH v3 00/12] fsl_esdhc_imx: port several patches from fsl_esdhc Sean Anderson @ 2022-01-04 16:16 ` Sean Anderson 2022-01-11 1:14 ` Jaehoon Chung 0 siblings, 1 reply; 5+ messages in thread From: Sean Anderson @ 2022-01-04 16:16 UTC (permalink / raw) To: u-boot, Peng Fan, Jaehoon Chung Cc: Haibo Chen, Fabio Estevam, Yangbo Lu, Michael Walle, Sean Anderson [ fsl_esdhc commit 41dec2fe99512e941261594f522b2e7d485c314b ] U-boot prefers DM_MMC + BLK for MMC. Now eSDHC driver has already support it, so let's force to use it. - Drop non-BLK support for DM_MMC introduced by below patch. 66fa035 mmc: fsl_esdhc: fix probe issue without CONFIG_BLK enabled - Support only DM_MMC + BLK (assuming BLK is always enabled for DM_MMC). - Use DM_MMC instead of BLK for conditional compile. Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> Signed-off-by: Sean Anderson <sean.anderson@seco.com> --- Changes in v3: - Drop Kconfig BLK dependency drivers/mmc/fsl_esdhc_imx.c | 33 +-------------------------------- 1 file changed, 1 insertion(+), 32 deletions(-) diff --git a/drivers/mmc/fsl_esdhc_imx.c b/drivers/mmc/fsl_esdhc_imx.c index 4c06361bee..85cd72a796 100644 --- a/drivers/mmc/fsl_esdhc_imx.c +++ b/drivers/mmc/fsl_esdhc_imx.c @@ -39,10 +39,6 @@ #include <dm/ofnode.h> #include <linux/iopoll.h> -#if !CONFIG_IS_ENABLED(BLK) -#include "mmc_private.h" -#endif - #ifndef ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE #ifdef CONFIG_FSL_USDHC #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 @@ -58,7 +54,6 @@ DECLARE_GLOBAL_DATA_PTR; IRQSTATEN_DEBE | IRQSTATEN_BRR | IRQSTATEN_BWR | \ IRQSTATEN_DINT) #define MAX_TUNING_LOOP 40 -#define ESDHC_DRIVER_STAGE_VALUE 0xffffffff struct fsl_esdhc { uint dsaddr; /* SDMA system address register */ @@ -157,7 +152,7 @@ struct fsl_esdhc_priv { unsigned int clock; unsigned int mode; unsigned int bus_width; -#if !CONFIG_IS_ENABLED(BLK) +#if !CONFIG_IS_ENABLED(DM_MMC) struct mmc *mmc; #endif struct udevice *dev; @@ -1510,9 +1505,6 @@ static int fsl_esdhc_probe(struct udevice *dev) struct esdhc_soc_data *data = (struct esdhc_soc_data *)dev_get_driver_data(dev); struct mmc *mmc; -#if !CONFIG_IS_ENABLED(BLK) - struct blk_desc *bdesc; -#endif int ret; #if CONFIG_IS_ENABLED(OF_PLATDATA) @@ -1611,25 +1603,6 @@ static int fsl_esdhc_probe(struct udevice *dev) mmc = &plat->mmc; mmc->cfg = &plat->cfg; mmc->dev = dev; -#if !CONFIG_IS_ENABLED(BLK) - mmc->priv = priv; - - /* Setup dsr related values */ - mmc->dsr_imp = 0; - mmc->dsr = ESDHC_DRIVER_STAGE_VALUE; - /* Setup the universal parts of the block interface just once */ - bdesc = mmc_get_blk_desc(mmc); - bdesc->if_type = IF_TYPE_MMC; - bdesc->removable = 1; - bdesc->devnum = mmc_get_next_devnum(); - bdesc->block_read = mmc_bread; - bdesc->block_write = mmc_bwrite; - bdesc->block_erase = mmc_berase; - - /* setup initial part type */ - bdesc->part_type = mmc->cfg->part_type; - mmc_list_add(mmc); -#endif upriv->mmc = mmc; @@ -1740,14 +1713,12 @@ static const struct udevice_id fsl_esdhc_ids[] = { { /* sentinel */ } }; -#if CONFIG_IS_ENABLED(BLK) static int fsl_esdhc_bind(struct udevice *dev) { struct fsl_esdhc_plat *plat = dev_get_plat(dev); return mmc_bind(dev, &plat->mmc, &plat->cfg); } -#endif U_BOOT_DRIVER(fsl_esdhc) = { .name = "fsl_esdhc", @@ -1755,9 +1726,7 @@ U_BOOT_DRIVER(fsl_esdhc) = { .of_match = fsl_esdhc_ids, .of_to_plat = fsl_esdhc_of_to_plat, .ops = &fsl_esdhc_ops, -#if CONFIG_IS_ENABLED(BLK) .bind = fsl_esdhc_bind, -#endif .probe = fsl_esdhc_probe, .plat_auto = sizeof(struct fsl_esdhc_plat), .priv_auto = sizeof(struct fsl_esdhc_priv), -- 2.25.1 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC 2022-01-04 16:16 ` [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC Sean Anderson @ 2022-01-11 1:14 ` Jaehoon Chung 2022-01-11 16:15 ` Sean Anderson 0 siblings, 1 reply; 5+ messages in thread From: Jaehoon Chung @ 2022-01-11 1:14 UTC (permalink / raw) To: Sean Anderson, u-boot, Peng Fan Cc: Haibo Chen, Fabio Estevam, Yangbo Lu, Michael Walle Dear Sean, On 1/5/22 1:16 AM, Sean Anderson wrote: > [ fsl_esdhc commit 41dec2fe99512e941261594f522b2e7d485c314b ] > > U-boot prefers DM_MMC + BLK for MMC. Now eSDHC driver has already > support it, so let's force to use it. > > - Drop non-BLK support for DM_MMC introduced by below patch. > 66fa035 mmc: fsl_esdhc: fix probe issue without CONFIG_BLK enabled > > - Support only DM_MMC + BLK (assuming BLK is always enabled for DM_MMC). > > - Use DM_MMC instead of BLK for conditional compile. Thanks for resend this. But it can't apply your patch from patchwork directly. https://patchwork.ozlabs.org/project/uboot/patch/17862939-c7b1-310e-d98e-ce68f776ee40@seco.com/ If you're ok, I will apply after modified your patch. Best Regards, Jaehoon Chung > > Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> > Signed-off-by: Sean Anderson <sean.anderson@seco.com> > --- > > Changes in v3: > - Drop Kconfig BLK dependency > > drivers/mmc/fsl_esdhc_imx.c | 33 +-------------------------------- > 1 file changed, 1 insertion(+), 32 deletions(-) > > diff --git a/drivers/mmc/fsl_esdhc_imx.c b/drivers/mmc/fsl_esdhc_imx.c > index 4c06361bee..85cd72a796 100644 > --- a/drivers/mmc/fsl_esdhc_imx.c > +++ b/drivers/mmc/fsl_esdhc_imx.c > @@ -39,10 +39,6 @@ > #include <dm/ofnode.h> > #include <linux/iopoll.h> > -#if !CONFIG_IS_ENABLED(BLK) > -#include "mmc_private.h" > -#endif > - > #ifndef ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE > #ifdef CONFIG_FSL_USDHC > #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 > @@ -58,7 +54,6 @@ DECLARE_GLOBAL_DATA_PTR; > IRQSTATEN_DEBE | IRQSTATEN_BRR | IRQSTATEN_BWR | \ > IRQSTATEN_DINT) > #define MAX_TUNING_LOOP 40 > -#define ESDHC_DRIVER_STAGE_VALUE 0xffffffff > struct fsl_esdhc { > uint dsaddr; /* SDMA system address register */ > @@ -157,7 +152,7 @@ struct fsl_esdhc_priv { > unsigned int clock; > unsigned int mode; > unsigned int bus_width; > -#if !CONFIG_IS_ENABLED(BLK) > +#if !CONFIG_IS_ENABLED(DM_MMC) > struct mmc *mmc; > #endif > struct udevice *dev; > @@ -1510,9 +1505,6 @@ static int fsl_esdhc_probe(struct udevice *dev) > struct esdhc_soc_data *data = > (struct esdhc_soc_data *)dev_get_driver_data(dev); > struct mmc *mmc; > -#if !CONFIG_IS_ENABLED(BLK) > - struct blk_desc *bdesc; > -#endif > int ret; > #if CONFIG_IS_ENABLED(OF_PLATDATA) > @@ -1611,25 +1603,6 @@ static int fsl_esdhc_probe(struct udevice *dev) > mmc = &plat->mmc; > mmc->cfg = &plat->cfg; > mmc->dev = dev; > -#if !CONFIG_IS_ENABLED(BLK) > - mmc->priv = priv; > - > - /* Setup dsr related values */ > - mmc->dsr_imp = 0; > - mmc->dsr = ESDHC_DRIVER_STAGE_VALUE; > - /* Setup the universal parts of the block interface just once */ > - bdesc = mmc_get_blk_desc(mmc); > - bdesc->if_type = IF_TYPE_MMC; > - bdesc->removable = 1; > - bdesc->devnum = mmc_get_next_devnum(); > - bdesc->block_read = mmc_bread; > - bdesc->block_write = mmc_bwrite; > - bdesc->block_erase = mmc_berase; > - > - /* setup initial part type */ > - bdesc->part_type = mmc->cfg->part_type; > - mmc_list_add(mmc); > -#endif > upriv->mmc = mmc; > @@ -1740,14 +1713,12 @@ static const struct udevice_id fsl_esdhc_ids[] = { > { /* sentinel */ } > }; > -#if CONFIG_IS_ENABLED(BLK) > static int fsl_esdhc_bind(struct udevice *dev) > { > struct fsl_esdhc_plat *plat = dev_get_plat(dev); > return mmc_bind(dev, &plat->mmc, &plat->cfg); > } > -#endif > U_BOOT_DRIVER(fsl_esdhc) = { > .name = "fsl_esdhc", > @@ -1755,9 +1726,7 @@ U_BOOT_DRIVER(fsl_esdhc) = { > .of_match = fsl_esdhc_ids, > .of_to_plat = fsl_esdhc_of_to_plat, > .ops = &fsl_esdhc_ops, > -#if CONFIG_IS_ENABLED(BLK) > .bind = fsl_esdhc_bind, > -#endif > .probe = fsl_esdhc_probe, > .plat_auto = sizeof(struct fsl_esdhc_plat), > .priv_auto = sizeof(struct fsl_esdhc_priv), ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC 2022-01-11 1:14 ` Jaehoon Chung @ 2022-01-11 16:15 ` Sean Anderson 0 siblings, 0 replies; 5+ messages in thread From: Sean Anderson @ 2022-01-11 16:15 UTC (permalink / raw) To: Jaehoon Chung, u-boot, Peng Fan Cc: Haibo Chen, Fabio Estevam, Yangbo Lu, Michael Walle On 1/10/22 8:14 PM, Jaehoon Chung wrote: > Dear Sean, > > On 1/5/22 1:16 AM, Sean Anderson wrote: >> [ fsl_esdhc commit 41dec2fe99512e941261594f522b2e7d485c314b ] >> >> U-boot prefers DM_MMC + BLK for MMC. Now eSDHC driver has already >> support it, so let's force to use it. >> >> - Drop non-BLK support for DM_MMC introduced by below patch. >> 66fa035 mmc: fsl_esdhc: fix probe issue without CONFIG_BLK enabled >> >> - Support only DM_MMC + BLK (assuming BLK is always enabled for DM_MMC). >> >> - Use DM_MMC instead of BLK for conditional compile. > > > Thanks for resend this. But it can't apply your patch from patchwork directly. > https://patchwork.ozlabs.org/project/uboot/patch/17862939-c7b1-310e-d98e-ce68f776ee40@seco.com/ > > If you're ok, I will apply after modified your patch. That's fine; looks like it got mangled a bit by my mail client. --Sean > >> >> Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com> >> Signed-off-by: Sean Anderson <sean.anderson@seco.com> >> --- >> >> Changes in v3: >> - Drop Kconfig BLK dependency >> >> drivers/mmc/fsl_esdhc_imx.c | 33 +-------------------------------- >> 1 file changed, 1 insertion(+), 32 deletions(-) >> >> diff --git a/drivers/mmc/fsl_esdhc_imx.c b/drivers/mmc/fsl_esdhc_imx.c >> index 4c06361bee..85cd72a796 100644 >> --- a/drivers/mmc/fsl_esdhc_imx.c >> +++ b/drivers/mmc/fsl_esdhc_imx.c >> @@ -39,10 +39,6 @@ >> #include <dm/ofnode.h> >> #include <linux/iopoll.h> >> -#if !CONFIG_IS_ENABLED(BLK) >> -#include "mmc_private.h" >> -#endif >> - >> #ifndef ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE >> #ifdef CONFIG_FSL_USDHC >> #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE 1 >> @@ -58,7 +54,6 @@ DECLARE_GLOBAL_DATA_PTR; >> IRQSTATEN_DEBE | IRQSTATEN_BRR | IRQSTATEN_BWR | \ >> IRQSTATEN_DINT) >> #define MAX_TUNING_LOOP 40 >> -#define ESDHC_DRIVER_STAGE_VALUE 0xffffffff >> struct fsl_esdhc { >> uint dsaddr; /* SDMA system address register */ >> @@ -157,7 +152,7 @@ struct fsl_esdhc_priv { >> unsigned int clock; >> unsigned int mode; >> unsigned int bus_width; >> -#if !CONFIG_IS_ENABLED(BLK) >> +#if !CONFIG_IS_ENABLED(DM_MMC) >> struct mmc *mmc; >> #endif >> struct udevice *dev; >> @@ -1510,9 +1505,6 @@ static int fsl_esdhc_probe(struct udevice *dev) >> struct esdhc_soc_data *data = >> (struct esdhc_soc_data *)dev_get_driver_data(dev); >> struct mmc *mmc; >> -#if !CONFIG_IS_ENABLED(BLK) >> - struct blk_desc *bdesc; >> -#endif >> int ret; >> #if CONFIG_IS_ENABLED(OF_PLATDATA) >> @@ -1611,25 +1603,6 @@ static int fsl_esdhc_probe(struct udevice *dev) >> mmc = &plat->mmc; >> mmc->cfg = &plat->cfg; >> mmc->dev = dev; >> -#if !CONFIG_IS_ENABLED(BLK) >> - mmc->priv = priv; >> - >> - /* Setup dsr related values */ >> - mmc->dsr_imp = 0; >> - mmc->dsr = ESDHC_DRIVER_STAGE_VALUE; >> - /* Setup the universal parts of the block interface just once */ >> - bdesc = mmc_get_blk_desc(mmc); >> - bdesc->if_type = IF_TYPE_MMC; >> - bdesc->removable = 1; >> - bdesc->devnum = mmc_get_next_devnum(); >> - bdesc->block_read = mmc_bread; >> - bdesc->block_write = mmc_bwrite; >> - bdesc->block_erase = mmc_berase; >> - >> - /* setup initial part type */ >> - bdesc->part_type = mmc->cfg->part_type; >> - mmc_list_add(mmc); >> -#endif >> upriv->mmc = mmc; >> @@ -1740,14 +1713,12 @@ static const struct udevice_id fsl_esdhc_ids[] = { >> { /* sentinel */ } >> }; >> -#if CONFIG_IS_ENABLED(BLK) >> static int fsl_esdhc_bind(struct udevice *dev) >> { >> struct fsl_esdhc_plat *plat = dev_get_plat(dev); >> return mmc_bind(dev, &plat->mmc, &plat->cfg); >> } >> -#endif >> U_BOOT_DRIVER(fsl_esdhc) = { >> .name = "fsl_esdhc", >> @@ -1755,9 +1726,7 @@ U_BOOT_DRIVER(fsl_esdhc) = { >> .of_match = fsl_esdhc_ids, >> .of_to_plat = fsl_esdhc_of_to_plat, >> .ops = &fsl_esdhc_ops, >> -#if CONFIG_IS_ENABLED(BLK) >> .bind = fsl_esdhc_bind, >> -#endif >> .probe = fsl_esdhc_probe, >> .plat_auto = sizeof(struct fsl_esdhc_plat), >> .priv_auto = sizeof(struct fsl_esdhc_priv), > ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2022-01-12 6:53 UTC | newest] Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <CGME20220111232902epcas1p1eb1f0919acbe30299305458f881dc175@epcas1p1.samsung.com> 2022-01-11 23:29 ` [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC Jaehoon Chung 2022-01-12 6:53 ` Minkyu Kang 2021-11-23 20:03 [PATCH v3 00/12] fsl_esdhc_imx: port several patches from fsl_esdhc Sean Anderson 2022-01-04 16:16 ` [RESEND PATCH v3 01/12] mmc: fsl_esdhc_imx: make BLK as hard requirement of DM_MMC Sean Anderson 2022-01-11 1:14 ` Jaehoon Chung 2022-01-11 16:15 ` Sean Anderson
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.