From patchwork Fri Aug 1 16:48:55 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Brown X-Patchwork-Id: 34729 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oi0-f70.google.com (mail-oi0-f70.google.com [209.85.218.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 2278A20540 for ; Fri, 1 Aug 2014 17:21:39 +0000 (UTC) Received: by mail-oi0-f70.google.com with SMTP id u20sf18799545oif.1 for ; Fri, 01 Aug 2014 10:21:38 -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:date :message-id:subject:sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=+dQKLxjGBa782ICQT1ClgJxXIkJnUl9uywsbOwTM+N4=; b=Ah03qWsKDaDaC65QcfmttcN5ZmsmEgiCmyE6cNkntbSQorVoseggdH10CzoKY5pvuY ba4hNvM1f/MRF5MBVHa8/S4dCxBluWgeQ6Z60hx/Gx4PUzB3U6hVqdCfsPgSgyQCv88n TPUcWY8GYiXhd5smNzV+/9SC39nF4ziVR/e9bUhNLmDWaFbmsjFRoTAyigMPsOKI5Spd HebFo3N7p9UB/N3mcP7H+8MBGYp6vftpz4MMqldVYYbi+GBa3J2e8gK1Tb6pPOgDvqY1 jkyl1DIDyXDHmyesVl2KkA9bcxwGHxgIkRejqEQjc1F3sPE/CgRYrrSPStzFhhHb1mP/ eO7g== X-Gm-Message-State: ALoCoQn6yEZcUI2iKl+/Ms2gH19kxHpS1JfKulGnwI1Qt/6f6Ri1pt+lwHB1Lh8eBdlXLc41NsB7 X-Received: by 10.50.126.9 with SMTP id mu9mr2599194igb.6.1406913698503; Fri, 01 Aug 2014 10:21:38 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.88.85 with SMTP id s79ls1496016qgd.22.gmail; Fri, 01 Aug 2014 10:21:38 -0700 (PDT) X-Received: by 10.52.239.6 with SMTP id vo6mr6862104vdc.59.1406913698422; Fri, 01 Aug 2014 10:21:38 -0700 (PDT) Received: from mail-vc0-f172.google.com (mail-vc0-f172.google.com [209.85.220.172]) by mx.google.com with ESMTPS id t2si7894157vcs.89.2014.08.01.10.21.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 01 Aug 2014 10:21:38 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.172 as permitted sender) client-ip=209.85.220.172; Received: by mail-vc0-f172.google.com with SMTP id im17so7228739vcb.3 for ; Fri, 01 Aug 2014 10:21:38 -0700 (PDT) X-Received: by 10.52.144.14 with SMTP id si14mr3194203vdb.95.1406913698354; Fri, 01 Aug 2014 10:21:38 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp126832vcb; Fri, 1 Aug 2014 10:21:37 -0700 (PDT) X-Received: by 10.70.103.238 with SMTP id fz14mr7876272pdb.153.1406913697503; Fri, 01 Aug 2014 10:21:37 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gy1si10502919pbd.29.2014.08.01.10.21.37 for ; Fri, 01 Aug 2014 10:21:37 -0700 (PDT) Received-SPF: none (google.com: linux-spi-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755597AbaHARVc (ORCPT + 2 others); Fri, 1 Aug 2014 13:21:32 -0400 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:39901 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755486AbaHARVb (ORCPT ); Fri, 1 Aug 2014 13:21:31 -0400 Received: from 94.197.121.167.threembb.co.uk ([94.197.121.167] helo=finisterre) by mezzanine.sirena.org.uk with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1XDGWC-0006fL-PH; Fri, 01 Aug 2014 17:21:29 +0000 Received: from broonie by finisterre with local (Exim 4.82_1-5b7a7c0-XX) (envelope-from ) id 1XDG0m-0004Ue-Ni; Fri, 01 Aug 2014 17:48:56 +0100 From: Mark Brown To: Linus Walleij Cc: linux-spi@vger.kernel.org, linaro-kernel@lists.linaro.org, Mark Brown Date: Fri, 1 Aug 2014 17:48:55 +0100 Message-Id: <1406911735-17239-1-git-send-email-broonie@kernel.org> X-Mailer: git-send-email 2.0.0 X-SA-Exim-Connect-IP: 94.197.121.167 X-SA-Exim-Mail-From: broonie@sirena.org.uk X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on mezzanine.sirena.org.uk X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, TVD_RCVD_IP autolearn=ham version=3.3.2 Subject: [PATCH] spi/pl022: Explicitly truncate large bitmask X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Sender: linux-spi-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-spi@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: broonie@kernel.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.172 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Mark Brown When building on 64 bit architectures the use of bitwise negation generates constants larger than 32 bits which won't fit in u32s used to represent 32 bit register values on the device. Explicitly cast to let the compiler know that the higher bits are not significant and can be discarded. Signed-off-by: Mark Brown Reviewed-by: Linus Walleij --- drivers/spi/spi-pl022.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/spi/spi-pl022.c b/drivers/spi/spi-pl022.c index 66d2ae2..1189cfd 100644 --- a/drivers/spi/spi-pl022.c +++ b/drivers/spi/spi-pl022.c @@ -1417,7 +1417,7 @@ static void do_interrupt_dma_transfer(struct pl022 *pl022) * Default is to enable all interrupts except RX - * this will be enabled once TX is complete */ - u32 irqflags = ENABLE_ALL_INTERRUPTS & ~SSP_IMSC_MASK_RXIM; + u32 irqflags = (u32)(ENABLE_ALL_INTERRUPTS & ~SSP_IMSC_MASK_RXIM); /* Enable target chip, if not already active */ if (!pl022->next_msg_cs_active)