From: R.E.Wolff@BitWizard.nl (Rogier Wolff)
To: mingo@redhat.com,
Linux kernel mailing list <linux-kernel@vger.kernel.org>,
viro@math.psu.edu
Subject: RAID superblock....
Date: Sun, 10 Mar 2002 14:28:57 +0100 (MET) [thread overview]
Message-ID: <200203101328.OAA15987@cave.bitwizard.nl> (raw)
Hi,
The MD code I see doing:
488 sb_offset = calc_dev_sboffset(rdev->dev, rdev->mddev, 1);
489 rdev->sb_offset = sb_offset;
490 fsync_dev(dev);
491 set_blocksize (dev, MD_SB_BYTES);
492 bh = bread (dev, sb_offset / MD_SB_BLOCKS, MD_SB_BYTES);
where sb_offset is calculated as:
290 if (blk_size[MAJOR(dev)])
291 size = blk_size[MAJOR(dev)][MINOR(dev)];
Now, for aguments sake, I have a 4k disk. I'd expect the size to be 4
(1k blocks, according to the comment near the definition of blk_size).
Thus the "bread" would effectively try to read the block at offset 4k.
That would be past the end of my mini-disk, right?
I would have expected a "-1" in there somewhere, to get the last block
of the dev, and not the block just past the end of the drive.
Anyway on the old machine, I still cannot find the raid superblock by
hand, but the drives now mount, so the kernel must have been able to
locate them somehow......
The machine is still running 2.4.16 + IDE patches for 48 bit
addressing.
The working machine is an 850MHz PIII w/384Mb RAM, the non-working
machine is an AMD 1800+ MP w/1G RAM (with another one of those
processors sitting idle close by)...
Roger.
--
** R.E.Wolff@BitWizard.nl ** http://www.BitWizard.nl/ ** +31-15-2137555 **
*-- BitWizard writes Linux device drivers for any device you may have! --*
* There are old pilots, and there are bold pilots.
* There are also old, bald pilots.
next reply other threads:[~2002-03-10 13:29 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-10 13:28 Rogier Wolff [this message]
2002-03-10 23:34 ` Neil Brown
[not found] <20001025171255.26384.qmail@web6104.mail.yahoo.com>
[not found] ` <Pine.LNX.4.21.0010261534490.9868-100000@server.serve.me.nl>
2000-10-26 16:19 ` Wakko Warner
2000-10-29 10:40 ` Peter Samuelson
2000-10-29 13:36 ` Igmar Palsenberg
2000-10-29 12:52 ` Wakko Warner
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=200203101328.OAA15987@cave.bitwizard.nl \
--to=r.e.wolff@bitwizard.nl \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=viro@math.psu.edu \
/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®