Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp447590ybt; Fri, 10 Jul 2020 04:08:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxon62nDRxwU9FYqwJmO6foT9mSKjQc6ODWtI12LN8menc47asCYrAW+IEHyo99B+hMBkyu X-Received: by 2002:a17:906:c459:: with SMTP id ck25mr63698478ejb.177.1594379333345; Fri, 10 Jul 2020 04:08:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594379333; cv=none; d=google.com; s=arc-20160816; b=D+ohtAUnaV6hESKzMdIx3EhqFOSW/3BtpmIE3G3uikQVN6gQLK5x9nRMd1z+er0JhG Vii9IBAQO8pFBED5UO6aQ6h/q8NPnXddICA09dFjeJ1RQlpWLiHfeot27QNtf2RWSHvC 3S0MuAjZu90EuDrBSUbLvRajuBDqMoTU9Ur5tRvog06ITOLti/nnz/43VTAHbBeFKqZq gFptwqbt1Ij/adELXCvLnIh0BWwNhl3JS1amcK0QFhkNT1G+Uv6MUZKqbXCXckCp7EvA +zsyB8bTIijLxmx0+mx54uYAwNlpn4VWuHaqBWFUBZWTALd65ibR8uZ0jV4WiwX7sJyl jjpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=ti/RasPzpDQfCkU80y2QxpiPoAPRKGJkYJCcdL+0vLs=; b=IBSGTFmTTKzEyRN0EnH3/ngjgYMI4WA6liuaqNvHiNbBm6C6GvIzTbda8n90YSYSH3 iT8tIZOdERMkOe37cE6VEm57yiGtVyXzrGvWBIheR7YJq7lIpgyVjSoXvcGMZIEaWzc3 Scxs7ooLGa1gx01MlxsB8+pSNR76jnk/fVDBpNzT4hOi8E9GHOqyVLcu+n1eUs5TcOea v4P/Qk/ToyVuS/Izb9arn9u0K99S1wkTkBQvIMYmUxvkWUqiVK+LbM6PAIXG8acW/AVK p7MhJbwne0G7yCNMuzfqGR07VRz5ALCqa8GRT0YtrW23OZ0rj0prt3plx5CrWrowz2ey orUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="VWqB2c/2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id pk22si3511666ejb.235.2020.07.10.04.08.29; Fri, 10 Jul 2020 04:08:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="VWqB2c/2"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727948AbgGJLH5 (ORCPT + 99 others); Fri, 10 Jul 2020 07:07:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40910 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726496AbgGJLHz (ORCPT ); Fri, 10 Jul 2020 07:07:55 -0400 Received: from mail-pf1-x441.google.com (mail-pf1-x441.google.com [IPv6:2607:f8b0:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 595EBC08C5DC; Fri, 10 Jul 2020 04:07:55 -0700 (PDT) Received: by mail-pf1-x441.google.com with SMTP id 1so2392694pfn.9; Fri, 10 Jul 2020 04:07:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ti/RasPzpDQfCkU80y2QxpiPoAPRKGJkYJCcdL+0vLs=; b=VWqB2c/2mD7N1CybHi64Z60T58eMyCTiWHXE8zz0z9JBKZDY5XwX1tpqaq+i9EYfCP 1EpnQonma3W/bIwCu1unJEghezBdiUwX3/2UkMfe/++zgyFLq64DKoevEDW6xhqe08D9 tcvj6bMqcHaAY9M8Vo1q6tSAW9b+xt5y662KQkj8qIWYgtFcuUv5DCtBrkuv4lFJx34r nWTiIlsvWNuNJPWhmtZUJy5c1QdPhhtN9vXq1WV9TOwCxUfMAIC6a5EaXjskUUN4XHBL 71lA/nmBaZKU2VykKgTwOEfifooqU5xxcIKq7YETToMwaYvXiyYpYtmRxq47gEtkV8m0 kMuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ti/RasPzpDQfCkU80y2QxpiPoAPRKGJkYJCcdL+0vLs=; b=UOBFXekIGJTQJRhthTJwJJYM3/fEyM29zGtPuaQ+Qyoy+6iF+eWNwcpVpZt8zp+nUU e60cluVw3qD/AGqaJWwBZwefYasHxQ0enwQTE/iW+ynZRdhFxutQaYiuO/WnudKP9sNs hTLzXYQKSGYyyT5QyXxJOCKAJsd/158NAdN/ssjpZ/k3XY9F0lb/O9YQeL94hEDm2WIv jXsAYzhUl7WYZSfJlAJTnO2tq3SsqjtPBdFQHnXr23ygSwLzUpDH1GzDrnQe2P197BAj iqQrCegwjZaZzwMSxcXr6cN4BcWQOmG6VBfvS48Ph8ZTatVbYTqy0u3F3zVsiaKhPaEm 99/g== X-Gm-Message-State: AOAM531ehw4PQqJvFNTVvfaR6x6S5WiS9hy4QJxm4C9ZiI/nBfW5a9+j eLjlrJtpUxD62lM9bfAvzsI= X-Received: by 2002:a63:5fcc:: with SMTP id t195mr48796424pgb.56.1594379274962; Fri, 10 Jul 2020 04:07:54 -0700 (PDT) Received: from gli-arch.genesyslogic.com.tw (60-251-58-169.HINET-IP.hinet.net. [60.251.58.169]) by smtp.gmail.com with ESMTPSA id g3sm5581621pfq.19.2020.07.10.04.07.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Jul 2020 04:07:54 -0700 (PDT) From: Ben Chuang To: adrian.hunter@intel.com, ulf.hansson@linaro.org Cc: linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org, ben.chuang@genesyslogic.com.tw, takahiro.akashi@linaro.org, greg.tu@genesyslogic.com.tw, Ben Chuang Subject: [RFC PATCH V3 03/21] mmc: core: UHS-II support, skip set_chip_select() Date: Fri, 10 Jul 2020 19:08:38 +0800 Message-Id: <20200710110838.29018-1-benchuanggli@gmail.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: AKASHI Takahiro mmc_set_chip_select() should be called only in UHS-I mode, and not for UHS-II mode. Signed-off-by: Ben Chuang Signed-off-by: AKASHI Takahiro --- drivers/mmc/core/core.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 85c83c82ad0c..c6540d56646b 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -898,8 +898,10 @@ static inline void mmc_set_ios(struct mmc_host *host) */ void mmc_set_chip_select(struct mmc_host *host, int mode) { - host->ios.chip_select = mode; - mmc_set_ios(host); + if (!(host->flags & MMC_UHS2_INITIALIZED)) { + host->ios.chip_select = mode; + mmc_set_ios(host); + } } /* -- 2.27.0