This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: load data from floppy


davidw@dedasys.com (David N. Welton) writes:

> Nick Garnett <nickg@ecoscentric.com> writes:
> 
> > davidw@dedasys.com (David N. Welton) writes:
> 
> [ floppy driver ]
> 
> > > I managed to beat the relevant Minix code into shape to do what I
> > > need.  Would this be of any interest to you guys?  I'm sure it
> > > needs an expert hand to really bring it up to snuff, but it does
> > > work for reading a floppy.  The license is the new BSD-style Minix
> > > license.
> 
> > It would certainly be worth looking at. We also need to make sure
> > that way you are using it matches with the (currently very vague)
> > ideas I have about how block devices should work.
> 
> Which are?

See my exchange with Gary on the maintainers list.

> 
> I have another question.  The underlying Minix code that I am working
> on top of doesn't want to deal with read/write sizes or positions that
> are not multiples of 512 (SECTOR_SIZE).
> 
> I think a good interface should hide that, but on the other hand, that
> might force some uglies.  If, for instance, you want to read less than
> a full 512, the driver is going to have to allocate a full 512 itself,
> and then copy it over.  That seems kind of wasteful, especially if the
> size is much larger.
> 
> Any thoughts on how to get around that kind of limitation?  I'm going
> to keep hacking at it myself... I've got a few ideas.

Fixing it to operate solely in 512 byte sectors is the simplest and
most straightforward approach. I see no need to jump through hoops to
pretend that it works in any other way. Disks are too big these days
for a 32bit byte offset to work, and I would prefer to avoid too much
use of 64 bit values -- especially where we might have to do
arithmetic to extract sector offsets/sizes.


> > As for the license -- this needs to be looked at by someone who can
> > assess it properly (not me!).
> 
> Included at the end of this message (not sure if I sent it the other
> time).  Looks like there are a few other things in eCos with BSD style
> licenses...

I'll leave inspection of this to those more expert than I.


-- 
Nick Garnett                    eCos Kernel Architect
http://www.ecoscentric.com      The eCos and RedBoot experts


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]