From: BlaisorBlade <blaisorblade_spam@yahoo.it>
To: Andrew Morton <akpm@osdl.org>
Cc: agk@redhat.com, neilb@cse.unsw.edu.au, linux-kernel@vger.kernel.org
Subject: Re: [patch 1/1] dm: fix printk errors about whether %lu/%Lu is right for sector_t - revised
Date: Mon, 25 Oct 2004 22:55:08 +0200 [thread overview]
Message-ID: <200410252255.08217.blaisorblade_spam@yahoo.it> (raw)
In-Reply-To: <20041022025340.058837f7.akpm@osdl.org>
On Friday 22 October 2004 11:53, Andrew Morton wrote:
> blaisorblade_spam@yahoo.it wrote:
> > The Device Manager code barfs when sector_t is 64bit wide (i.e. an u64)
> > and CONFIG_LBD is off. This happens on printk(), resulting in wrong
> > memory accesses, but also on sscanf(), resulting in overflows (because it
> > uses %lu for a long long in this case). And region_t, chunk_t are
> > typedefs for sector_t, so we have warnings for these, too.
> This patch caused the x86_64 build to puke: "Not allowed to define
> CONFIG_LBD on this architecture" or some such.
Yes, there is an #error directive for this.
Who would ever need to use CONFIG_LBD when sector_t is already 64-bit? So this
is flagged as an error (feel free to remove that, if you know a good reason).
In fact, this is your fault, given both the 2.6.9 kernel and the 2.6.10-rc1
one:
config LBD
bool "Support for Large Block Devices"
depends on X86 || MIPS32 || PPC32 || ARCH_S390_31 || SUPERH
help
Say Y here if you want to attach large (bigger than 2TB) discs to
your machine, or if you want to have a raid or loopback device
bigger than 2TB. Otherwise say N.
So if you define LBD on a x86_64 kernel, you get to keep the pieces.
A make oldconfig would probably help - don't you think so?
> I'd much prefer that you simply remove SECTOR_FORMAT completely.
Impossible - doing a scanf and then copying the value is much uglier. I just
add 5 lines of code to avoid the problem, while removing the silly
HAVE_SECTOR_T trick and moving the CONFIG_LBD handling to arch-independent
code.
--
Paolo Giarrusso, aka Blaisorblade
Linux registered user n. 292729
next prev parent reply other threads:[~2004-10-25 21:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-21 22:45 blaisorblade_spam
2004-10-22 9:53 ` Andrew Morton
2004-10-25 20:55 ` BlaisorBlade [this message]
2004-10-25 21:46 ` Andrew Morton
-- strict thread matches above, loose matches on Subject: below --
2004-10-19 22:46 blaisorblade_spam
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=200410252255.08217.blaisorblade_spam@yahoo.it \
--to=blaisorblade_spam@yahoo.it \
--cc=agk@redhat.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=neilb@cse.unsw.edu.au \
/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
all inboxes | Powered by JetHome®