From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: David Miller <davem@davemloft.net>,
rdreier@cisco.com, Geert.Uytterhoeven@sonycom.com, hpa@zytor.com,
linux-kernel@vger.kernel.org, mingo@elte.hu,
yhlu.kernel@gmail.com, akpm@linux-foundation.org
Subject: Re: [PATCH] Fix broken debug output reserve_region_with_split()
Date: Fri, 17 Oct 2008 16:00:27 +1100 [thread overview]
Message-ID: <1224219627.7654.80.camel@pasglop> (raw)
In-Reply-To: <alpine.LFD.2.00.0810162109570.3438@nehalem.linux-foundation.org>
On Thu, 2008-10-16 at 21:18 -0700, Linus Torvalds wrote:
>
> Sure, but I don't think we agree on what it would be. And quite frankly,
> it might depend on the resource.
>
> For example, in traditional PCI, PIO resources would easily want to use
> %04x, which MMIO would use %08x. Sure, Linux _allows_ for bigger resources
> (ie you can have even PIO resources with the full 64-bit data), but it's
> not what you'd expect for any traditional stuff, and so it makes sense to
> make PIO resources show as %04x to get the old-fashioned resources shown
> in an expected manner.
Well, I was proposing that in the patch comments I think :-) We can do
some more specific formatting details in there based on the resource
flags, though we might also need some arch ifdef's in there.
It's better I think than having callers get it wrong in hundreds of
different ways.
> We can do it inside the %pR code itself (just look at IORESOURCE_IO vs
> IORESOURCE_MEM), and maybe that's even the right approach. Maybe we want
> to even add flag bits, and show things like "IORESOURCE_PREFETCH" as a
> small marking automatically. But maybe people want to make it explicit.
I've been going on/off about the flags and decided to leave them alone
for now unless somebody comes up with a nice way to handle them. But
that doesn't mean we can't -use- the flags as you suggested to adjust
the format of the output.
The only little nit here is that the amount of digits needed for PIO is
fairly arch specific. So I might just stick an few ifdef's for the 4
possible cases (4, 8 and 16 digits) and let arch maintainers fix them up
(I'll default to 16 for everybody except x86 -> 4 and ppc -> 8).
As for the 36 bits trick of sparc32, I'll let DaveM do another arch hack
in there for now until he sorts it out.
I'll do a patch in a minute...
Cheers,
Ben.
next prev parent reply other threads:[~2008-10-17 5:00 UTC|newest]
Thread overview: 46+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-14 0:53 [PATCH] Fix broken debug output reserve_region_with_split() Benjamin Herrenschmidt
2008-10-14 1:04 ` H. Peter Anvin
2008-10-14 1:14 ` Yinghai Lu
2008-10-14 1:16 ` H. Peter Anvin
2008-10-14 1:34 ` David Miller
2008-10-14 1:41 ` Benjamin Herrenschmidt
2008-10-14 1:41 ` Benjamin Herrenschmidt
2008-10-14 1:45 ` David Miller
2008-10-14 2:15 ` Benjamin Herrenschmidt
2008-10-14 2:54 ` H. Peter Anvin
2008-10-14 3:47 ` Benjamin Herrenschmidt
2008-10-14 5:38 ` David Miller
2008-10-16 8:30 ` Geert Uytterhoeven
2008-10-16 8:38 ` David Miller
2008-10-16 9:02 ` H. Peter Anvin
2008-10-17 3:02 ` Benjamin Herrenschmidt
2008-10-17 3:06 ` Benjamin Herrenschmidt
2008-10-17 3:13 ` Roland Dreier
2008-10-17 3:31 ` Benjamin Herrenschmidt
2008-10-17 3:49 ` Linus Torvalds
2008-10-17 4:04 ` David Miller
2008-10-17 4:18 ` Linus Torvalds
2008-10-17 5:00 ` Benjamin Herrenschmidt [this message]
2008-10-17 5:24 ` David Miller
2008-10-17 5:12 ` Benjamin Herrenschmidt
2008-10-17 5:21 ` Benjamin Herrenschmidt
2008-10-17 10:13 ` Olivier Galibert
2008-10-17 15:54 ` Linus Torvalds
2008-10-17 20:30 ` H. Peter Anvin
2008-10-17 20:54 ` Linus Torvalds
2008-10-17 21:03 ` Benjamin Herrenschmidt
2008-10-17 21:11 ` Linus Torvalds
2008-10-17 21:45 ` Benjamin Herrenschmidt
2008-10-20 3:37 ` Benjamin Herrenschmidt
2008-10-17 5:21 ` David Miller
2008-10-17 6:36 ` Benjamin Herrenschmidt
2008-10-17 6:39 ` H. Peter Anvin
2008-10-17 6:47 ` David Miller
2008-10-17 6:51 ` H. Peter Anvin
2008-10-17 15:51 ` Linus Torvalds
2008-10-17 20:06 ` David Miller
2008-10-17 4:05 ` Benjamin Herrenschmidt
2008-10-17 6:36 ` H. Peter Anvin
2008-10-17 3:39 ` Yinghai Lu
2008-10-17 3:46 ` Benjamin Herrenschmidt
2008-10-17 6:38 ` H. Peter Anvin
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=1224219627.7654.80.camel@pasglop \
--to=benh@kernel.crashing.org \
--cc=Geert.Uytterhoeven@sonycom.com \
--cc=akpm@linux-foundation.org \
--cc=davem@davemloft.net \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rdreier@cisco.com \
--cc=torvalds@linux-foundation.org \
--cc=yhlu.kernel@gmail.com \
/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