From patchwork Wed Dec 2 06:36:18 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ricky WU X-Patchwork-Id: 11944799 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.7 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 09DDEC64E8A for ; Wed, 2 Dec 2020 06:37:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id AAB4422206 for ; Wed, 2 Dec 2020 06:37:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728642AbgLBGhf (ORCPT ); Wed, 2 Dec 2020 01:37:35 -0500 Received: from rtits2.realtek.com ([211.75.126.72]:34689 "EHLO rtits2.realtek.com.tw" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726485AbgLBGhf (ORCPT ); Wed, 2 Dec 2020 01:37:35 -0500 Authenticated-By: X-SpamFilter-By: ArmorX SpamTrap 5.73 with qID 0B26aWX81027830, This message is accepted by code: ctloc85258 Received: from mail.realtek.com (rtexmb01.realtek.com.tw[172.21.6.94]) by rtits2.realtek.com.tw (8.15.2/2.70/5.88) with ESMTPS id 0B26aWX81027830 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128 verify=NOT); Wed, 2 Dec 2020 14:36:32 +0800 Received: from RTEXMBS01.realtek.com.tw (172.21.6.36) by RTEXMB01.realtek.com.tw (172.21.6.94) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2044.4; Wed, 2 Dec 2020 14:36:23 +0800 Received: from localhost (172.22.88.222) by RTEXMBS01.realtek.com.tw (172.21.6.36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2106.2; Wed, 2 Dec 2020 14:36:23 +0800 From: To: , , , , , , , , , , , Subject: [PATCH v2 3/4] mmc: rtsx: fix sdmmc_switch_voltage return bug Date: Wed, 2 Dec 2020 14:36:18 +0800 Message-ID: <20201202063618.18402-1-ricky_wu@realtek.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-Originating-IP: [172.22.88.222] X-ClientProxiedBy: RTEXH365.realtek.com.tw (172.21.6.37) To RTEXMBS01.realtek.com.tw (172.21.6.36) Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org From: Ricky Wu fixed bug: return err always return rtsx_pci_write_register() return code not for callback function _switch_voltage() Signed-off-by: Ricky Wu --- drivers/mmc/host/rtsx_pci_sdmmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/rtsx_pci_sdmmc.c b/drivers/mmc/host/rtsx_pci_sdmmc.c index eb395e144207..93be9fa97098 100644 --- a/drivers/mmc/host/rtsx_pci_sdmmc.c +++ b/drivers/mmc/host/rtsx_pci_sdmmc.c @@ -1249,7 +1249,7 @@ static int sdmmc_switch_voltage(struct mmc_host *mmc, struct mmc_ios *ios) out: /* Stop toggle SD clock in idle */ - err = rtsx_pci_write_register(pcr, SD_BUS_STAT, + rtsx_pci_write_register(pcr, SD_BUS_STAT, SD_CLK_TOGGLE_EN | SD_CLK_FORCE_STOP, 0); mutex_unlock(&pcr->pcr_mutex);