linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paul Turner <pjt@google.com>
To: Ingo Molnar <mingo@kernel.org>
Cc: Fabio Estevam <festevam@gmail.com>,
	mingo@redhat.com, peterz@infradead.org,
	linux-kernel@vger.kernel.org,
	Fabio Estevam <fabio.estevam@freescale.com>
Subject: Re: [PATCH v2] sched: Fix print format for u64
Date: Fri, 25 Jan 2013 08:06:56 -0800	[thread overview]
Message-ID: <CAPM31RK7txVP9vbDCWFLLshh_98Y-8-T-Vt0C6vZ10Sni4n28g@mail.gmail.com> (raw)
In-Reply-To: <20130125080656.GB25314@gmail.com>

On Fri, Jan 25, 2013 at 12:06 AM, Ingo Molnar <mingo@kernel.org> wrote:
>
> * Paul Turner <pjt@google.com> wrote:
>
>> On Thu, Jan 24, 2013 at 11:19 PM, Ingo Molnar <mingo@kernel.org> wrote:
>> >
>> > * Fabio Estevam <festevam@gmail.com> wrote:
>> >
>> >> On Thu, Jan 24, 2013 at 12:19 PM, Ingo Molnar <mingo@kernel.org> wrote:
>> >>
>> >> > I suppose - is this patch warning-free both on 64-bit and 32-bit
>> >> > systems?
>> >>
>> >> Yes, just confirmed that this patch is warning-free on both 64-bit and
>> >> 32-bit machines.
>> >
>> > Apparently it's not all good, see the warning attached below.
>>
>> Yeah this patch is broken; this is not properly fixable as is without
>> #ifdefs (or fixing the insanity that is atomic64_read).
>>
>> Specifically:
>>
>> On some architectures (e.g. x86_64) atomic64_read is typed long
>> On some others (e.g. x86-32) it's typed long long
>> On yet others (e.g. arm) it's typed u64
>
> Hm, cannot we type atomic64_read() to u64 on x86-64 as well, and
> fix other architectures? How widespread is this problem, have
> you checked that perhaps?

I have not looked at how much fall-out this would cause.  Ideally
someone with a cross-compiing tool-chain or from the specific arches
could take ownership of cleaning up their atomic64 implementations to
avoid introducing more build pain.

Theoretically, given the list above x86-64 is actually the outlier in
assuming that it's just a long type; perhaps we can gain sufficient
mileage by changing only the x86-64 implementation; which is much
easier for us to validate :-).

>
> I'm all for clean, consistent types instead of #ifdef or
> temporary variable uglies.

Yes I agree this would be the best solution.

>
> Thanks,
>
>         Ingo

  reply	other threads:[~2013-01-25 16:14 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-25 11:24 [PATCH v2] sched: Fix print format for u64 Fabio Estevam
2013-01-11  1:30 ` Fabio Estevam
2013-01-24 14:19   ` Ingo Molnar
2013-01-24 14:47     ` Fabio Estevam
2013-01-25  7:19       ` Ingo Molnar
2013-01-25  7:31         ` Paul Turner
2013-01-25  8:06           ` Ingo Molnar
2013-01-25 16:06             ` Paul Turner [this message]
2013-01-24 20:22 ` [tip:sched/urgent] " tip-bot for Fabio Estevam

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAPM31RK7txVP9vbDCWFLLshh_98Y-8-T-Vt0C6vZ10Sni4n28g@mail.gmail.com \
    --to=pjt@google.com \
    --cc=fabio.estevam@freescale.com \
    --cc=festevam@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).