mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Martin Schwidefsky <schwidefsky@de.ibm.com>
To: linux-kernel@vger.kernel.org
Subject: hd_geometry question.
Date: Mon, 1 Jul 2002 18:02:07 +0200	[thread overview]
Message-ID: <200207011802.07212.schwidefsky@de.ibm.com> (raw)

Hi,
I have a question about the start field in the hd_geometry structure. We used

	geo->start = device->major_info->gendisk.part[MINOR(kdev)].start_sect
		>> device->sizes.s2b_shift;

in the old dasd driver but now we use

	geo.start = get_start_sect(kdev);

to set the start field. One variant is wrong because the start sector differ if
the block size is not 512 byte. The first variant calculates the start sector
based on physical blocks (e.g. with 4096 bytes instead of 512 bytes). The
second variant calulcates a "soft" start sector based on logical 512 byte
blocks. Whats correct, first or second variant ?? I tend to favor the first
variant because struct hd_geometry describes the physical geometry
(number of heads, sectors, cylinders and start sector) but I am not 100%
sure about it.

blue skies,
  Martin.


             reply	other threads:[~2002-07-01 16:03 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-01 16:02 Martin Schwidefsky [this message]
2002-07-01 19:19 ` Andre Hedrick
2002-07-01 19:58 ` Andries Brouwer
2002-07-02  9:16 Martin Schwidefsky
2002-07-02 10:50 ` jw schultz
2002-07-03  0:20 ` Andries Brouwer
2002-07-03 23:48   ` Roman Zippel
2002-07-04  9:09     ` Andries Brouwer
2002-07-04 22:15       ` Andre Hedrick
2002-07-08 18:55     ` Alan Cox
2002-07-03  8:13 Martin Schwidefsky
2002-07-03  9:37 ` Andries Brouwer

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=200207011802.07212.schwidefsky@de.ibm.com \
    --to=schwidefsky@de.ibm.com \
    --cc=linux-kernel@vger.kernel.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

all inboxes | Powered by JetHome®