From patchwork Wed Jan 17 16:28:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 124851 Delivered-To: patch@linaro.org Received: by 10.46.62.1 with SMTP id l1csp107490lja; Wed, 17 Jan 2018 08:41:24 -0800 (PST) X-Google-Smtp-Source: ACJfBovKuyqroSktqgUJliWmFZm3DmLnQ2lAT8GUzhhfaw2caLukoLP8sJmf5TsiWjn8iRICTbD9 X-Received: by 10.159.206.138 with SMTP id bg10mr9590335plb.162.1516207284365; Wed, 17 Jan 2018 08:41:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516207284; cv=none; d=google.com; s=arc-20160816; b=KtD3z9N4ZYKasagyyXSBABz0ZPD2wDhvbPpwUkQX/bt3e/PG68iRgpG1xVNkpq9Ky3 vt9KSRKWbrfjFwFYVl/TSr+4EWQFRX9/HaOjVD7cVHsmnETlQ3X8WXReTShwwJXK01D5 h8gUvuLCJleu2pb735VwFeuztW4XVcF0RaOa2QuBSCtfIU/mXIRVeYBntr14SjWZ4bBU rS4bAFrENSrcdeerxaRzPyyJamEEm7d2bS1gdbNlCgwJD9n8R/fY2wORy+axp/Y+NwDg Ag11kK/w6fOTGmitD4Fy2IrKNKzOfcFTZnYwFAhOblNkOUkh1uE/qN6MO5ud8pzjKcIx 1z9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter :arc-authentication-results; bh=L9EulqWhq+y57VE20j/UDd9nxM56xbkQbD4kGgD7dUo=; b=d9BS3//nyp3YDYktxXLORESu+IFVVxcJGaIILyDNgsXKhj0hizGutEEB4JssvMbWPG 1wDOyH5/05fzU0IcJK20SFF7LWVUrUyiBqB2WmD+eC4Y8inRbJdC7FrANlY50QdlmMm+ ZZ2ko0dVpGbE+1du+7h2YLeqgEcJ+VaDvh9lKBYJTaRfgyFRFvHJ3ZtFp2uhYaazjzMz x4SQvvHvUyYIAZg9ZmIzGUweSYsuyeu3HuzcrHPPw0C4blzuKunKNgWAbyytS01YLQ5m jzg1GJFqiHU05CHQuXA2l8skJ8bxctp+RWkEtyC8rs1LywyUm2lAzKenynnaUt2MMubr kK7g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=FqVgNZ66; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z20si4777327pfj.118.2018.01.17.08.41.24; Wed, 17 Jan 2018 08:41:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=FqVgNZ66; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932198AbeAQQlW (ORCPT + 28 others); Wed, 17 Jan 2018 11:41:22 -0500 Received: from conuserg-08.nifty.com ([210.131.2.75]:36684 "EHLO conuserg-08.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753822AbeAQQ3d (ORCPT ); Wed, 17 Jan 2018 11:29:33 -0500 Received: from grover.sesame (FL1-125-199-20-195.osk.mesh.ad.jp [125.199.20.195]) (authenticated) by conuserg-08.nifty.com with ESMTP id w0HGSIL2014790; Thu, 18 Jan 2018 01:28:33 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-08.nifty.com w0HGSIL2014790 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1516206513; bh=L9EulqWhq+y57VE20j/UDd9nxM56xbkQbD4kGgD7dUo=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FqVgNZ66ZhNcAi8D/ubAj2OWK2p+Tznq1wPPbRzk5fvcW/aRZlwjStMjSkGZXSxFl bdBag39jG+dV/XRFTRlCVK64GOK759kyx8ZilYk9GTd7miJ7X37Pi20GbrYZ6UhsjH BLRaq47l2xMydLIyU3fBFtv7XJ/5g4+aca/SnErSNl9r9EcMUDLFwMa8SYyaAA6/oj Y0PUQ5NVDi5/aF3ueq6cRle8DYRx94W85BeGRmHUZlKagdcuSUAqeKvqUPs2ME2QuO E2bSAC+AA7NY/aBnuiQFYkM6HAYKdP1ETiWZG/Rh0ZfEB+fH0UWAlUEs3tFIxKSBYL 7ypmuQUdPtoGQ== X-Nifty-SrcIP: [125.199.20.195] From: Masahiro Yamada To: linux-mmc@vger.kernel.org, Wolfram Sang Cc: Ulf Magnusson , Geert Uytterhoeven , Simon Horman , Yoshihiro Shimoda , linux-renesas-soc@vger.kernel.org, Masahiro Yamada , linux-kernel@vger.kernel.org, Ulf Hansson Subject: [PATCH v3 16/16] mmc: tmio: remove useless TMIO_MASK_CMD handling in tmio_mmc_host_probe() Date: Thu, 18 Jan 2018 01:28:16 +0900 Message-Id: <1516206496-16612-17-git-send-email-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516206496-16612-1-git-send-email-yamada.masahiro@socionext.com> References: <1516206496-16612-1-git-send-email-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org TMIO_MASK_CMD is properly enabled in tmio_mmc_start_command(). We have no reason to set it up in tmio_mmc_host_probe(). (If we really wanted to set it in the probe, we would have to do likewise when resuming.) Even worse, the following code is extremely confusing: _host->sdcard_irq_mask &= ~irq_mask; The logic is opposite between "->sdcard_irq_mask" and "irq_mask". The intention is not clear at a glance. Signed-off-by: Masahiro Yamada --- Changes in v3: None Changes in v2: - Newly added drivers/mmc/host/tmio_mmc_core.c | 3 --- 1 file changed, 3 deletions(-) -- 2.7.4 diff --git a/drivers/mmc/host/tmio_mmc_core.c b/drivers/mmc/host/tmio_mmc_core.c index 494f0b3..b75a51b 100644 --- a/drivers/mmc/host/tmio_mmc_core.c +++ b/drivers/mmc/host/tmio_mmc_core.c @@ -1209,7 +1209,6 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *_host) struct tmio_mmc_data *pdata = _host->pdata; struct mmc_host *mmc = _host->mmc; int ret; - u32 irq_mask = TMIO_MASK_CMD; /* * Check the sanity of mmc->f_min to prevent tmio_mmc_set_clock() from @@ -1291,8 +1290,6 @@ int tmio_mmc_host_probe(struct tmio_mmc_host *_host) _host->sdcard_irq_mask = sd_ctrl_read16_and_16_as_32(_host, CTL_IRQ_MASK); tmio_mmc_disable_mmc_irqs(_host, TMIO_MASK_ALL); - _host->sdcard_irq_mask &= ~irq_mask; - if (_host->native_hotplug) tmio_mmc_enable_mmc_irqs(_host, TMIO_STAT_CARD_REMOVE | TMIO_STAT_CARD_INSERT);