From patchwork Mon Sep 16 14:17:44 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 20341 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-yh0-f69.google.com (mail-yh0-f69.google.com [209.85.213.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id C5DB524694 for ; Mon, 16 Sep 2013 14:18:09 +0000 (UTC) Received: by mail-yh0-f69.google.com with SMTP id c41sf4487913yho.4 for ; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=NYM9tNoQo3nxoFmu/pOhmbgyX7QzjkuClVcnT3+S+Cg=; b=IlXuS6HknBdoxnsON2d7MvJwB+n+jb3YR76D0dRF+i1/mdpL+OB8rJ82n0hcXsKDob gsCMa6wX0S/nGYYgrP+2f23Beg3nTHFqymIXrhLYYIk0oOzTkEr2gGzaVRJEcF+OV4na gGbgQzlqmRt+xdJm9WLSx5NA9j9zoA8hhrdGULbzdeWk5I4tG5lzv5AwLKXruLYeFyRW eHR2ZY75yA4bUHWQHUcqXDLl3kCImKnQpLNm8w4IIDgHSl/X2fOQPwaKCy5nLINDNruX F4WIbZDp4OBz06Cbcjo1s5h03HwyFCv49oHhiZo673ekBNW30PWHlck4ZEdrZ5n3x/L9 t8Xg== X-Gm-Message-State: ALoCoQlEj9YhkCvkz9BxM56taA5kNqVS+byuhBoUrM9IkL3662ZPcFAN80OZGHezKRKTJ8eIzAfN X-Received: by 10.236.69.35 with SMTP id m23mr10895532yhd.6.1379341089560; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.28.10 with SMTP id x10ls2384511qeg.20.gmail; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) X-Received: by 10.58.171.4 with SMTP id aq4mr767574vec.26.1379341089404; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) Received: from mail-ve0-f177.google.com (mail-ve0-f177.google.com [209.85.128.177]) by mx.google.com with ESMTPS id nr7si3040689vec.103.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 16 Sep 2013 07:18:09 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.177 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.177; Received: by mail-ve0-f177.google.com with SMTP id db12so2930273veb.22 for ; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) X-Received: by 10.58.155.6 with SMTP id vs6mr412696veb.32.1379341089100; Mon, 16 Sep 2013 07:18:09 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp99349vcz; Mon, 16 Sep 2013 07:18:08 -0700 (PDT) X-Received: by 10.152.2.4 with SMTP id 4mr25239802laq.0.1379341087084; Mon, 16 Sep 2013 07:18:07 -0700 (PDT) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx.google.com with ESMTPS id m1si10002488lae.10.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 16 Sep 2013 07:18:07 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.215.54 is neither permitted nor denied by best guess record for domain of ulf.hansson@linaro.org) client-ip=209.85.215.54; Received: by mail-la0-f54.google.com with SMTP id ea20so3144359lab.41 for ; Mon, 16 Sep 2013 07:18:06 -0700 (PDT) X-Received: by 10.152.37.166 with SMTP id z6mr2483815laj.25.1379341086537; Mon, 16 Sep 2013 07:18:06 -0700 (PDT) Received: from linaro-ulf.lan (90-231-160-185-no158.tbcn.telia.com. [90.231.160.185]) by mx.google.com with ESMTPSA id ur6sm13161703lbc.5.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 16 Sep 2013 07:18:05 -0700 (PDT) From: Ulf Hansson To: linux-mmc@vger.kernel.org, Chris Ball Cc: Prasanna NAVARATNA , Ulf Hansson Subject: [PATCH 3/7] mmc: core: Remove unnecessary retry mechanism at SDIO attach Date: Mon, 16 Sep 2013 16:17:44 +0200 Message-Id: <1379341068-27097-4-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1379341068-27097-1-git-send-email-ulf.hansson@linaro.org> References: <1379341068-27097-1-git-send-email-ulf.hansson@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ulf.hansson@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.177 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , The retry and fallback mechanism when failing to switch to 1.8V signaling voltage is handled by the SDIO card init function. Thus we can remove the duplicated old code from the attach function. Signed-off-by: Ulf Hansson --- drivers/mmc/core/sdio.c | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) diff --git a/drivers/mmc/core/sdio.c b/drivers/mmc/core/sdio.c index 15cbc418..26b1316 100644 --- a/drivers/mmc/core/sdio.c +++ b/drivers/mmc/core/sdio.c @@ -1175,17 +1175,9 @@ int mmc_attach_sdio(struct mmc_host *host) host->ocr |= R4_18V_PRESENT; err = mmc_sdio_init_card(host, host->ocr, NULL, 0); - if (err) { - if (err == -EAGAIN) { - /* - * Retry initialization with S18R set to 0. - */ - host->ocr &= ~R4_18V_PRESENT; - err = mmc_sdio_init_card(host, host->ocr, NULL, 0); - } - if (err) - goto err; - } + if (err) + goto err; + card = host->card; /*