Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1215346

Re: [PATCH V4 2/2] PM / OPP: Fix static checker warning (broken 64bit big endian systems)

Path csiph.com!eternal-september.org!feeder.eternal-september.org!weretis.net!feeder4.news.weretis.net!feeder1.news.weretis.net!newsfeed.CARNet.hr!news.spin.it!bofh.it!news.nic.it!robomod
From "Rafael J. Wysocki" <rjw@rjwysocki.net>
Newsgroups linux.kernel
Subject Re: [PATCH V4 2/2] PM / OPP: Fix static checker warning (broken 64bit big endian systems)
Date Fri, 28 Aug 2015 15:50:04 +0200
Message-ID <q2scA-4SC-25@gated-at.bofh.it> (permalink)
References <pWC4V-2z5-1@gated-at.bofh.it> <pYt7c-Gw-9@gated-at.bofh.it>
X-Original-To Viresh Kumar <viresh.kumar@linaro.org>
User-Agent KMail/4.11.5 (Linux/4.1.0-rc5+; KDE/4.11.5; x86_64; ; )
MIME-Version 1.0
Content-Transfer-Encoding 7Bit
Content-Type text/plain; charset="utf-8"
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 25
Organization linux.* mail to news gateway
X-Original-Cc linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org, dan.carpenter@oracle.com, nm@ti.com, sboyd@codeaurora.org, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Len Brown <len.brown@intel.com>, open list <linux-kernel@vger.kernel.org>, Pavel Machek <pavel@ucw.cz>
X-Original-Date Fri, 28 Aug 2015 16:14:33 +0200
X-Original-Message-ID <20319405.E46lXZHqyF@vostro.rjw.lan>
X-Original-References <fac7aa53b304bbff1ff22f65670e05e5e6dc6396.1439376998.git.viresh.kumar@linaro.org> <0a41aca3107cea2d9fac3f4536e5c7f4acd90f7d.1439818955.git.viresh.kumar@linaro.org>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1215346

Show key headers only | View raw


On Monday, August 17, 2015 07:20:20 PM Viresh Kumar wrote:
> Dan Carpenter reported (generated with static checker):
> 
> drivers/base/power/opp.c:949 _opp_add_static_v2()
> warn: passing casted pointer '&new_opp->clock_latency_ns' to
> 'of_property_read_u32()' 64 vs 32.
> 
> This code will break on 64 bit, big endian machines.
> 
> Fix this by reading the value in a u32 type variable first and then
> assigning it to the unsigned long variable.
> 
> Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
> Suggested-by: Stephen Boyd <sboyd@codeaurora.org>
> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>

I've applied this and the [1/2], thanks!

Rafael

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

Re: [PATCH V4 2/2] PM / OPP: Fix static checker warning (broken 64bit big endian systems) "Rafael J. Wysocki" <rjw@rjwysocki.net> - 2015-08-28 15:50 +0200

csiph-web