lkml.org 
[lkml]   [2000]   [Sep]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: reading 1 hardsector size, not one block size


On Sat, 30 Sep 2000, Andre Hedrick wrote:

> Now how do you access beyond the limits of the FS/Partition?

How about /dev/hda? If you are talking about absolute block addresses you
are way below the partitioning level.

> We are narrowing to point that appears to make zero sense, until you
> realize that what is reported to Linux as capacity is less than reality.

So set blksize_size and blk_size to whatever your driver can serve (sorry
about the typo in the previous posting - blksize_size is sector size and
blk_size is the number of sectors). VFS _will_ believe whatever your
driver says.

> You can only make Linux access the stuff that knows about.
> Thus, assume single partition and completely used, well all that you know
> about and can access because of restrictions not known to you, because
> nobody told you they were there.
>
> Recall the 30GB drive de-stroked to 15GB:
>
> Linux can only find the first 15GB, how to you get to the other 15GB if
> you can legally get there? Your method above can not do it, can it?

Yes, it can, if your driver sets blksize_size correctly. _All_ information
about device size is taken from that array and it's driver's business to
put there whatever it believes to be the device size.

Again, for the VFS/filesystems/etc. "device size" means only one
thing: "driver told us not to give it requests with ->sector greater than
that number". That's it. Put 30*1024*1024*1024/512 there and kernel will
believe that disk is 30Gb (but then you'ld better be ready to serve such
requests, indeed).

It's entirely driver business - you tell the kernel how large sector
numbers you are ready to deal with and you are done.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:38    [W:0.062 / U:5.988 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site