[U-Boot] [PATCH 2/2] asm-generic: global_data: change timebase_l/h to unsigned int
Simon Glass
sjg at chromium.org
Tue May 2 11:27:39 UTC 2017
Hi Peng,
On 25 April 2017 at 14:51, Peng Fan <peng.fan at nxp.com> wrote:
> Hi Simon,
>
>> -----Original Message-----
>> From: sjg at google.com [mailto:sjg at google.com] On Behalf Of Simon Glass
>> Sent: Monday, April 24, 2017 11:38 AM
>> To: Peng Fan <peng.fan at nxp.com>
>> Cc: U-Boot Mailing List <u-boot at lists.denx.de>; Tom Rini
>> <trini at konsulko.com>; Eddie Cai <eddie.cai.linux at gmail.com>; Jagan Teki
>> <jteki at openedev.com>; york sun <york.sun at nxp.com>; Robert P. J. Day
>> <rpjday at crashcourse.ca>; Michal Simek <michal.simek at xilinx.com>
>> Subject: Re: [PATCH 2/2] asm-generic: global_data: change timebase_l/h to
>> unsigned int
>>
>> Hi Peng,
>>
>> On 19 April 2017 at 19:10, Peng Fan <peng.fan at nxp.com> wrote:
>> > Change type of timebase_l/h to unsigned int.
>>
>> What is the motivation for this, please?
>
> From lib/time.c: ((uint64_t)gd->timebase_h << 32) | gd->timebase_l;
>
> This piece code is based on that timebase_h and timebase_l are 32bits width, I think.
> But unsigned long are 64bits width on ARM64. I am not sure, but I suppose same case
> on other archs.
OK I see. I suspect it would make more sense to have a single 64-bit
value on 64-bit machines, but perhaps that is a separate point.
Reviewed-by: Simon Glass <sjg at chromium.org>
>
> Thanks,
> Peng.
>
>>
>> >
>> > Signed-off-by: Peng Fan <peng.fan at nxp.com>
>> > Cc: Simon Glass <sjg at chromium.org>
>> > Cc: Eddie Cai <eddie.cai.linux at gmail.com>
>> > Cc: Jagan Teki <jteki at openedev.com>
>> > Cc: York Sun <york.sun at nxp.com>
>> > Cc: "Robert P. J. Day" <rpjday at crashcourse.ca>
>> > Cc: Michal Simek <michal.simek at xilinx.com>
>> > Cc: Tom Rini <trini at konsulko.com>
>> > ---
>> >
>> > Buildman shows the following build failure, but not related this patch.
>> > aarch64: + orangepi_pc2
>> > x86: + qemu-x86_64 qemu-x86_efi_payload64 chromebook_link64
>> >
>> > include/asm-generic/global_data.h | 4 ++--
>> > 1 file changed, 2 insertions(+), 2 deletions(-)
>> >
>>
>> Regards,
>> Simon
More information about the U-Boot
mailing list