From patchwork Thu Feb 13 14:09:06 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ulf Hansson X-Patchwork-Id: 24599 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oa0-f70.google.com (mail-oa0-f70.google.com [209.85.219.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 25D63202E2 for ; Thu, 13 Feb 2014 14:09:23 +0000 (UTC) Received: by mail-oa0-f70.google.com with SMTP id m1sf43988998oag.9 for ; Thu, 13 Feb 2014 06:09:22 -0800 (PST) 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=I8ncRIMhW0PZoqmfuW3zM2PVXWGCf1nQP43Q2rkFVT0=; b=WrY+1tNetvaJRnhOMgnfpN9F5gb7RmGz+/yg/FRkk3A+nwoB31K+ubI4Oq0vjqJw1P gI4CCFc5fI42DX9fsNVsyv14LJwn7smUhswav6ynAcKJY+ptNo/IRVBIzmgX7QdBJ1KG JWZCXW0DfREJm/tf+0QlQqub3Q3CpTnSqD6cAUloaN4zCMzjbYM4d66OrkJ2BHl6jBgS PuTkasSZRhLgO/9mvrUL+VSQBNJUTMzHB7Hl9Ei3U0q6N7KaeqNhzperbmiCYIyr0d5l lCckWqWFP23fk5h4WslVYDhx0GD5ofJAGPyMkeVSxsjgkEU0tB5ZBLwAF5gqpaukblL1 U4BQ== X-Gm-Message-State: ALoCoQkXMS1XvSZUjnFQkx62ldKEKdYaQOQfmpL693ULbAbEOvMuJmzFgswstR0BDlE09YKtZ+hM X-Received: by 10.182.65.168 with SMTP id y8mr559929obs.38.1392300562054; Thu, 13 Feb 2014 06:09:22 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.82.148 with SMTP id h20ls1958137qgd.36.gmail; Thu, 13 Feb 2014 06:09:21 -0800 (PST) X-Received: by 10.58.90.131 with SMTP id bw3mr5561veb.63.1392300561885; Thu, 13 Feb 2014 06:09:21 -0800 (PST) Received: from mail-ve0-f177.google.com (mail-ve0-f177.google.com [209.85.128.177]) by mx.google.com with ESMTPS id ls10si682681vec.95.2014.02.13.06.09.21 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 13 Feb 2014 06:09:21 -0800 (PST) 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 jz11so8394208veb.22 for ; Thu, 13 Feb 2014 06:09:21 -0800 (PST) X-Received: by 10.220.89.4 with SMTP id c4mr18257vcm.53.1392300561794; Thu, 13 Feb 2014 06:09:21 -0800 (PST) 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 u4csp28415vcz; Thu, 13 Feb 2014 06:09:21 -0800 (PST) X-Received: by 10.180.107.136 with SMTP id hc8mr6680083wib.11.1392300560406; Thu, 13 Feb 2014 06:09:20 -0800 (PST) Received: from mail-we0-f169.google.com (mail-we0-f169.google.com [74.125.82.169]) by mx.google.com with ESMTPS id e6si3902329wiw.43.2014.02.13.06.09.19 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 13 Feb 2014 06:09:20 -0800 (PST) Received-SPF: neutral (google.com: 74.125.82.169 is neither permitted nor denied by best guess record for domain of ulf.hansson@linaro.org) client-ip=74.125.82.169; Received: by mail-we0-f169.google.com with SMTP id t61so7612996wes.28 for ; Thu, 13 Feb 2014 06:09:19 -0800 (PST) X-Received: by 10.194.60.233 with SMTP id k9mr1509085wjr.55.1392300559816; Thu, 13 Feb 2014 06:09:19 -0800 (PST) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id q15sm4823177wjw.18.2014.02.13.06.09.18 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 13 Feb 2014 06:09:19 -0800 (PST) From: Ulf Hansson To: Russell King , linux-arm-kernel@lists.infradead.org Cc: Alessandro Rubini , Linus Walleij , Wolfram Sang , Chris Ball , Mark Brown , linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org, linux-spi@vger.kernel.org, linux-mmc@vger.kernel.org, Ulf Hansson Subject: [PATCH V2 16/17] i2c: nomadik: Remove busy check for transfers at suspend late Date: Thu, 13 Feb 2014 15:09:06 +0100 Message-Id: <1392300547-23365-5-git-send-email-ulf.hansson@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1392300547-23365-1-git-send-email-ulf.hansson@linaro.org> References: <1392300547-23365-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: , We should never be busy performing transfers at suspend late, thus there are no reason to check for it. Cc: Alessandro Rubini Cc: Linus Walleij Cc: Wolfram Sang Signed-off-by: Ulf Hansson --- Changes in v2: Rebased on top of latest i2c-nomadik branch. --- drivers/i2c/busses/i2c-nomadik.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/drivers/i2c/busses/i2c-nomadik.c b/drivers/i2c/busses/i2c-nomadik.c index 80b0fd3..8a5dc57b 100644 --- a/drivers/i2c/busses/i2c-nomadik.c +++ b/drivers/i2c/busses/i2c-nomadik.c @@ -167,7 +167,6 @@ struct i2c_nmk_client { * @stop: stop condition. * @xfer_complete: acknowledge completion for a I2C message. * @result: controller propogated result. - * @busy: Busy doing transfer. */ struct nmk_i2c_dev { struct i2c_vendor_data *vendor; @@ -185,7 +184,6 @@ struct nmk_i2c_dev { int stop; struct completion xfer_complete; int result; - bool busy; }; /* controller's abort causes */ @@ -671,8 +669,6 @@ static int nmk_i2c_xfer(struct i2c_adapter *i2c_adap, struct nmk_i2c_dev *dev = i2c_get_adapdata(i2c_adap); int j; - dev->busy = true; - pm_runtime_get_sync(&dev->adev->dev); /* Attempt three times to send the message queue */ @@ -697,8 +693,6 @@ static int nmk_i2c_xfer(struct i2c_adapter *i2c_adap, pm_runtime_put_sync(&dev->adev->dev); - dev->busy = false; - /* return the no. messages processed */ if (status) return status; @@ -888,9 +882,6 @@ static int nmk_i2c_suspend_late(struct device *dev) struct amba_device *adev = to_amba_device(dev); struct nmk_i2c_dev *nmk_i2c = amba_get_drvdata(adev); - if (nmk_i2c->busy) - return -EBUSY; - pinctrl_pm_select_sleep_state(dev); return 0; @@ -997,7 +988,6 @@ static int nmk_i2c_probe(struct amba_device *adev, const struct amba_id *id) goto err_no_mem; } dev->vendor = vendor; - dev->busy = false; dev->adev = adev; nmk_i2c_of_probe(np, dev);