Date: Mon, 14 Jun 2021 18:47:55 GMT From: Emmanuel Vadot <manu@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 6bc8fe8a9f71 - main - arm: allwinner: Add mmc_pwrseq support Message-ID: <202106141847.15EIltTM038279@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by manu: URL: https://cgit.FreeBSD.org/src/commit/?id=6bc8fe8a9f711923253115d2a23b81370ef3e33a commit 6bc8fe8a9f711923253115d2a23b81370ef3e33a Author: Emmanuel Vadot <manu@FreeBSD.org> AuthorDate: 2021-05-26 11:13:33 +0000 Commit: Emmanuel Vadot <manu@FreeBSD.org> CommitDate: 2021-06-14 18:47:37 +0000 arm: allwinner: Add mmc_pwrseq support If a pwrseq is found, set power accordingly. Sponsored by: Diablotin Systems --- sys/arm/allwinner/aw_mmc.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sys/arm/allwinner/aw_mmc.c b/sys/arm/allwinner/aw_mmc.c index 0b3f19aea55f..9f215399e62b 100644 --- a/sys/arm/allwinner/aw_mmc.c +++ b/sys/arm/allwinner/aw_mmc.c @@ -71,6 +71,8 @@ __FBSDID("$FreeBSD$"); #include "mmc_sim_if.h" #endif +#include "mmc_pwrseq_if.h" + #define AW_MMC_MEMRES 0 #define AW_MMC_IRQRES 1 #define AW_MMC_RESSZ 2 @@ -1323,6 +1325,9 @@ aw_mmc_update_ios(device_t bus, device_t child) regulator_disable(sc->mmc_helper.vqmmc_supply); } + if (sc->mmc_helper.mmc_pwrseq) + MMC_PWRSEQ_SET_POWER(sc->mmc_helper.mmc_pwrseq, false); + aw_mmc_reset(sc); break; case power_up: @@ -1339,6 +1344,9 @@ aw_mmc_update_ios(device_t bus, device_t child) if (rv == 0 && reg_status != REGULATOR_STATUS_ENABLED) regulator_enable(sc->mmc_helper.vqmmc_supply); } + + if (sc->mmc_helper.mmc_pwrseq) + MMC_PWRSEQ_SET_POWER(sc->mmc_helper.mmc_pwrseq, true); aw_mmc_init(sc); break; };
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202106141847.15EIltTM038279>