From patchwork Sat Oct 27 09:17:46 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 1654651 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id D8FA83FD4F for ; Sat, 27 Oct 2012 09:20:23 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TS2XA-0007If-LD; Sat, 27 Oct 2012 09:18:24 +0000 Received: from mail-da0-f49.google.com ([209.85.210.49]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1TS2Ww-0007HN-Ut for linux-arm-kernel@lists.infradead.org; Sat, 27 Oct 2012 09:18:11 +0000 Received: by mail-da0-f49.google.com with SMTP id q27so1515860daj.36 for ; Sat, 27 Oct 2012 02:18:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :in-reply-to:references:x-gm-message-state; bh=h2H+yBWZy7UIXla2xtwHBJKpjeAXpdwCToxBCS7rEfo=; b=pGs41tHIaXsYpKInE6HSxzW4PzJOB+DCP/nU9BySwcAkA8woVlVrAid/tqnVJ7YaNI swTsjJeAVTs6IrdS88kWt57VpJdAY3gamoDMW6RUm3GtlPySYw5hebRYdaVX+pBBVH0J vYtGYfn9tbFieHMOvp5CB3Owfu4WSFNcWzscNqQgGF1v+OI4p5GwtyCXbySyAurxTTzY D1FoBxsdvTtE83ahZR1IkJ1fSZkOYOY6qPe2841mXG2hqiUhkyyMOd3x7wKsW9QjpJqh 8+ZF+rgstsL2680R3jPUN+Xaek1E90Crbw3vd4NTbdkkMdZKjrA0PA38qGBznBFStD+z eucA== Received: by 10.66.84.196 with SMTP id b4mr6528706paz.41.1351329488215; Sat, 27 Oct 2012 02:18:08 -0700 (PDT) Received: from localhost ([122.167.99.215]) by mx.google.com with ESMTPS id ms11sm2549617pbc.74.2012.10.27.02.18.05 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 27 Oct 2012 02:18:07 -0700 (PDT) From: Viresh Kumar To: linus.walleij@linaro.org Subject: [PATCH 1/9] pinctrl: SPEAr: Don't update all non muxreg bits on pinctrl_disable Date: Sat, 27 Oct 2012 14:47:46 +0530 Message-Id: <94543a207ee39bfd5b58607f380681b1b7b0b503.1351329224.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-Gm-Message-State: ALoCoQlXOaZanRU6xiEuqfG2bonppKf1PcLypQ2qAKTmxuKwxQK1x4DxYJ+x7IEb4pTxOTr8uhPb X-Spam-Note: CRM114 invocation failed X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.210.49 listed in list.dnswl.org] -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Viresh Kumar , spear-devel@list.st.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Not all bits of a register are used for pinctrl in SPEAr. So only update bits relevant to pinctrl using muxreg->mask. Signed-off-by: Viresh Kumar Acked-by: Linus Walleij --- drivers/pinctrl/spear/pinctrl-spear.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pinctrl/spear/pinctrl-spear.c b/drivers/pinctrl/spear/pinctrl-spear.c index 5d4f44f..b1fd6ee 100644 --- a/drivers/pinctrl/spear/pinctrl-spear.c +++ b/drivers/pinctrl/spear/pinctrl-spear.c @@ -244,7 +244,7 @@ static int spear_pinctrl_endisable(struct pinctrl_dev *pctldev, else temp = ~muxreg->val; - val |= temp; + val |= muxreg->mask & temp; pmx_writel(pmx, val, muxreg->reg); } }