From patchwork Thu Jan 23 14:20:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 23623 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-gg0-f198.google.com (mail-gg0-f198.google.com [209.85.161.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id D812A20307 for ; Thu, 23 Jan 2014 14:20:14 +0000 (UTC) Received: by mail-gg0-f198.google.com with SMTP id x14sf1526361ggx.5 for ; Thu, 23 Jan 2014 06:20:14 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe:content-type:content-transfer-encoding; bh=QjpdHFu8pxj+z7Cs7B5/B8Ujhwufx+rYCBxohUHkybk=; b=ZLlEhbys8zxnl2o4DtLeiHda5w4AVlawXw8PLmn4LX6YmFWWySRtfCa87l9jTaU6hr WW8cY6km/g3V4LimT+hkazAvQ80/PFWh4TuioPVsDel3dqhhJsdh8Gzq9j9Tb/4AY9Km 9B1X4LwJ/mNnxT9g2yx6Fc3J5Zb0kc3G5kowNOrbA+bdiydjljAJhq+g6/Y1P/Hx8bNU M4iZi+VocWbBUa8dk870pBdE8G8fJ5uOHFQrsnBFkQw/jrvv/+olrbc6GBcUw4TgJSL7 RTMrYRQGKZQrLtISmU+2ePEtsT4/Ux6srUyrJr2CywkF9SDzvuKoeUpCzZV5QC4ehOqo NlxQ== X-Gm-Message-State: ALoCoQl6CcRJ7AYQYRJrw05LXhcwCLBo2IZ5Oh1PfZoDSuhHQxayPe+N+zCZuLphnNEy2yrs5iK7 X-Received: by 10.58.155.36 with SMTP id vt4mr3133226veb.31.1390486813966; Thu, 23 Jan 2014 06:20:13 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.127.178 with SMTP id nh18ls301933qeb.35.gmail; Thu, 23 Jan 2014 06:20:13 -0800 (PST) X-Received: by 10.220.2.199 with SMTP id 7mr421976vck.4.1390486813837; Thu, 23 Jan 2014 06:20:13 -0800 (PST) Received: from mail-vc0-f169.google.com (mail-vc0-f169.google.com [209.85.220.169]) by mx.google.com with ESMTPS id ja16si6737947vec.50.2014.01.23.06.20.13 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 23 Jan 2014 06:20:13 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.169 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.169; Received: by mail-vc0-f169.google.com with SMTP id hq11so1091760vcb.28 for ; Thu, 23 Jan 2014 06:20:13 -0800 (PST) X-Received: by 10.58.85.133 with SMTP id h5mr4699491vez.4.1390486813477; Thu, 23 Jan 2014 06:20:13 -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 u4csp29831vcz; Thu, 23 Jan 2014 06:20:12 -0800 (PST) X-Received: by 10.180.72.195 with SMTP id f3mr7813319wiv.61.1390486807552; Thu, 23 Jan 2014 06:20:07 -0800 (PST) Received: from mail-wg0-f53.google.com (mail-wg0-f53.google.com [74.125.82.53]) by mx.google.com with ESMTPS id ok5si9285336wic.12.2014.01.23.06.20.07 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 23 Jan 2014 06:20:07 -0800 (PST) Received-SPF: neutral (google.com: 74.125.82.53 is neither permitted nor denied by best guess record for domain of linus.walleij@linaro.org) client-ip=74.125.82.53; Received: by mail-wg0-f53.google.com with SMTP id y10so1516321wgg.8 for ; Thu, 23 Jan 2014 06:20:07 -0800 (PST) X-Received: by 10.180.95.162 with SMTP id dl2mr8040246wib.17.1390486807080; Thu, 23 Jan 2014 06:20:07 -0800 (PST) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id y13sm22693070wjr.8.2014.01.23.06.20.05 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Jan 2014 06:20:06 -0800 (PST) From: Linus Walleij To: Liam Girdwood , Mark Brown , linux-kernel@vger.kernel.org Cc: Lee Jones , Linus Walleij Subject: [PATCH] regulator: ab3100: cast fix Date: Thu, 23 Jan 2014 15:20:01 +0100 Message-Id: <1390486801-4839-1-git-send-email-linus.walleij@linaro.org> X-Mailer: git-send-email 1.8.4.2 MIME-Version: 1.0 X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: linus.walleij@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.169 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 AB3100 regulator driver emits a warning when compiled on 64bit systems like this: drivers/regulator/ab3100.c: In function ‘ab3100_regulator_of_probe’: srivers/regulator/ab3100.c:649:4: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] As the int is a different size than the 64bit pointer used to pass regulator data. Switch to using an unsigned long as ID passed for the regulator to get rid of the warning. Reported-by: Lee Jones Signed-off-by: Linus Walleij --- drivers/regulator/ab3100.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/regulator/ab3100.c b/drivers/regulator/ab3100.c index 77b46d0b37a6..e10febe9ec34 100644 --- a/drivers/regulator/ab3100.c +++ b/drivers/regulator/ab3100.c @@ -498,7 +498,7 @@ static int ab3100_regulator_register(struct platform_device *pdev, struct ab3100_platform_data *plfdata, struct regulator_init_data *init_data, struct device_node *np, - int id) + unsigned long id) { struct regulator_desc *desc; struct ab3100_regulator *reg; @@ -646,7 +646,7 @@ ab3100_regulator_of_probe(struct platform_device *pdev, struct device_node *np) err = ab3100_regulator_register( pdev, NULL, ab3100_regulator_matches[i].init_data, ab3100_regulator_matches[i].of_node, - (int) ab3100_regulator_matches[i].driver_data); + (unsigned long)ab3100_regulator_matches[i].driver_data); if (err) { ab3100_regulators_remove(pdev); return err;