[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20140318151338.GA8506@thunk.org>
Date: Tue, 18 Mar 2014 11:13:38 -0400
From: tytso@....edu
To: "Ulrich Windl" <Ulrich.Windl@...uni-regensburg.de>
Cc: <linux-kernel@...r.kernel.org>
Subject: Re: Q on ioctl BLKGETSIZE
On Tue, Mar 18, 2014 at 01:17:25PM +0100, Ulrich Windl wrote:
>
> Three questions:
> 1) Shouldn't the manual page says that the sector size of always 512 Bytes, even on new disks with larger sectors?
> 2) Should the real sector size be used for new disks?
The HDD industry is using 512 byte logical sectors (so LBA's are in
units of 512 byte sectors), even for disks with a physical sector size
of 4k (and in the next 4-5 years, they would like to go to 32k
physical sector sizes).
> 3) When using 512-bytes sector size, isn't the capacity limited to 2TB (2^31 kB)?
Yes. That's why we have the BLKGETSIZE64 ioctl.
Example code:
https://git.kernel.org/cgit/fs/ext2/e2fsprogs.git/tree/lib/ext2fs/getsize.c
- Ted
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists