From patchwork Tue Jun 18 15:34:45 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 167178 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp4375395ilk; Tue, 18 Jun 2019 08:35:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqxrZ6u3xmeKtjEDpI7hCdORYhFQKshEd22OJb8s9Fc56weS6N39ESOIyVU9rNT0w2Gx2xcH X-Received: by 2002:a62:187:: with SMTP id 129mr34395501pfb.128.1560872107313; Tue, 18 Jun 2019 08:35:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560872107; cv=none; d=google.com; s=arc-20160816; b=JcwBM9efM7oT5pSRtjgIqGNoB1tsResWXPy/0PMuRa4MVreXhcNRQb23WsJYHA5+gB C4S01fQNBTvoC8XbJ8iXcIjzOJtilRA+LHsT550kLJVDdElxx6tONLATxByWI+8Cr2OH +SvPM/lTLG0/87dBDzr9WYsuNHQ1on2dpvY3pZ/Dga/bYNAQvXiHsdBsWt5tIVy+5+cO HmRaBALeVjWv2LrZ+sUjbaXSns6JeIHps+mHCiDQrJG/qUjs5YvjHlDqGzPM6UyTbGhW APe6Si6YWqauO9w4i+QX2SBtxKzzdcwbx6bghOxPBoDYQpM+2pHJGSxWPQU0Xr4q5hVD C0ng== 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; bh=39AvwfEHlmBtGb6TxK0PyFLzSAjznL8ashWYfCKeN2c=; b=Y/NQWcGo/Rba/SPPr04tbDXZ1bbZKc/xlpBmqt6IDNUjqG+Cg/JDkhg5UpZTRDdaY1 4y9b7XTBDL9LlGkOG4Fl6yWBFJ1iKTBxwD+v3Wkd4TZEGNv1QXUFhrnxBvaPNlHdHZR3 Ae9PO8QiVdTqAHc4lZel6ceVrfb+a1iiT51bRHOEB+Absh0v4O1OYRzZXtgZ+JoDWgcK Z+wvozS17dm/LHvJgDpxc9VN8y/dvGv5AfAU/XTXhGZZj5vNHdkKKq0dd80wn9ovupop 66JwRvFDlmclLMtQIkPMowhMaMsi5gEAB/Kx4pB2ihuyz9xuhXeUKR12wC+/nmfqYOhY Mtbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=DUVUxiby; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a3si13551783plc.132.2019.06.18.08.35.07; Tue, 18 Jun 2019 08:35:07 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-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=@linaro.org header.s=google header.b=DUVUxiby; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729678AbfFRPfG (ORCPT + 2 others); Tue, 18 Jun 2019 11:35:06 -0400 Received: from mail-lj1-f196.google.com ([209.85.208.196]:33393 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729647AbfFRPfG (ORCPT ); Tue, 18 Jun 2019 11:35:06 -0400 Received: by mail-lj1-f196.google.com with SMTP id h10so42617ljg.0 for ; Tue, 18 Jun 2019 08:35:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=39AvwfEHlmBtGb6TxK0PyFLzSAjznL8ashWYfCKeN2c=; b=DUVUxibyDbzeXA/hk3Zo8He9/+aJwnnN/pWh2NoweNxHStKsgrZcL3ZumTlXIZi9dc WeUijBH1Poz8ChLYZL1bKBUZAU3ZR2rj+GsEo6x7xMich3xxY2RV2kmS46NGxJI1MlWJ MRV+/JP6Ow8j7mAt22aZqlyJMo58hJW7C1+l5F2aW3gLhq3E6aifPYIMX50uxHGyRfAj nyDIqPeURa/a7Fy4aPbWw0kn8Ksosu30TGM/Pb52uAWj/Szv97GuIBw2bLOWuedt4IlD CFBVs6KhAozkHAU+vLUcbzP663GUGFkz2FWRwQ9+z//w/fik73WCUrLkrWQCSIWWuAav LI+g== 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:in-reply-to :references; bh=39AvwfEHlmBtGb6TxK0PyFLzSAjznL8ashWYfCKeN2c=; b=BCjQHCjaSot2uG6NXsR7V3ZktBY0M6rnByuv3Y+gSATDY92z/CJWExR4qOO3rHuSnH hkfWSW/kPoIr1IDAcdf27vVFwUBt0jH+E8dph9RnxPd45oxeSPMmu1XsBS2x+WD/Ny8A 4mpazIXUKJ3tnDi+eyi6if4B6K/W+ly65Rs37U6acfnL1ETgkTd3vbLatDdtk4Knvj0X PvjGT4wfb8D7qSyQj6sjni+9r1AvWtLLs9HvYPOlJq+moIrYmlXNMDOwl95h8wUhqKRC v2MxEUfcYEp31qrN5TZgDshezqnaD4MNyZbf7czFXtL6Pp7XyGvzcwgx9nCGvsbnH6Ha EgIQ== X-Gm-Message-State: APjAAAXQ25A+gmb5ELupiNPyricla/GiizX3/TjUbD4LeUtsCYVdAO4e 3FEGsPyfFwS4R3MFcNQUfFBLWQ== X-Received: by 2002:a2e:9c03:: with SMTP id s3mr47966037lji.209.1560872104224; Tue, 18 Jun 2019 08:35:04 -0700 (PDT) Received: from localhost.localdomain (h-158-174-22-210.NA.cust.bahnhof.se. [158.174.22.210]) by smtp.gmail.com with ESMTPSA id d15sm2203121lfq.76.2019.06.18.08.35.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 18 Jun 2019 08:35:03 -0700 (PDT) From: Ulf Hansson To: linux-mmc@vger.kernel.org, Ulf Hansson , Adrian Hunter , Douglas Anderson Cc: Brian Norris , Shawn Lin , Guenter Roeck , Heiko Stuebner , Kalle Valo , Arend Van Spriel , linux-wireless@vger.kernel.org Subject: [PATCH 4/7] mmc: sdio: Drop powered-on re-init at runtime resume and HW reset Date: Tue, 18 Jun 2019 17:34:45 +0200 Message-Id: <20190618153448.27145-5-ulf.hansson@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190618153448.27145-1-ulf.hansson@linaro.org> References: <20190618153448.27145-1-ulf.hansson@linaro.org> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org To use the so called powered-on re-initialization of an SDIO card, the power to the card must obviously have stayed on. If not, the initialization will simply fail. In the runtime suspend case, the card is always powered off. Hence, let's drop the support for powered-on re-initialization during runtime resume, as it doesn't make sense. Moreover, during a HW reset, the point is to cut the power to the card and then do fresh re-initialization. Therefore drop the support for powered-on re-initialization during HW reset. Signed-off-by: Ulf Hansson --- drivers/mmc/core/sdio.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) -- 2.17.1 diff --git a/drivers/mmc/core/sdio.c b/drivers/mmc/core/sdio.c index 29f86c1e9923..a9bfcae8db5b 100644 --- a/drivers/mmc/core/sdio.c +++ b/drivers/mmc/core/sdio.c @@ -1028,13 +1028,7 @@ static int mmc_sdio_resume(struct mmc_host *host) static int mmc_sdio_power_restore(struct mmc_host *host) { - int ret; - - ret = mmc_sdio_reinit_card(host, mmc_card_keep_power(host)); - if (!ret && host->sdio_irqs) - mmc_signal_sdio_irq(host); - - return ret; + return mmc_sdio_reinit_card(host, 0); } static int mmc_sdio_runtime_suspend(struct mmc_host *host)