lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20181024141008.30312-1-michael.thalmeier@hale.at>
Date:   Wed, 24 Oct 2018 16:10:08 +0200
From:   Michael Thalmeier <michael.thalmeier@...e.at>
To:     Roman Peniaev <r.peniaev@...il.com>,
        Sascha Hauer <s.hauer@...gutronix.de>,
        Ulf Hansson <ulf.hansson@...aro.org>
Cc:     linux-kernel@...r.kernel.org, linux-mmc@...r.kernel.org,
        michael@...lmeier.at
Subject: [PATCH] Revert "mmc: mxs: fix card detection in case of 'broken-cd' flag set"

This reverts commit 6f726f495f2d ("mmc: mxs: fix card detection in case of 'broken-cd' flag set").

Since mxs_mmc_probe always sets MMC_CAP_NEEDS_POLL unconditionally, card
detect is not working properly any more since commit 6f726f495f2d.
Instead of querying the card detect status mxs_mmc_get_cd now always
returns 1 which causes probing commands being sent to the mmc card.

The expected behaviour of commit 6f726f495f2d should be reachable by setting
broken_cd instead.

Signed-off-by: Michael Thalmeier <michael.thalmeier@...e.at>
---
 drivers/mmc/host/mxs-mmc.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/mmc/host/mxs-mmc.c b/drivers/mmc/host/mxs-mmc.c
index add1e70..cfdae61 100644
--- a/drivers/mmc/host/mxs-mmc.c
+++ b/drivers/mmc/host/mxs-mmc.c
@@ -86,8 +86,7 @@ static int mxs_mmc_get_cd(struct mmc_host *mmc)
 	if (ret >= 0)
 		return ret;
 
-	present = mmc->caps & MMC_CAP_NEEDS_POLL ||
-		!(readl(ssp->base + HW_SSP_STATUS(ssp)) &
+	present = !(readl(ssp->base + HW_SSP_STATUS(ssp)) &
 			BM_SSP_STATUS_CARD_DETECT);
 
 	if (mmc->caps2 & MMC_CAP2_CD_ACTIVE_HIGH)
-- 
2.9.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ