This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project. See the Cygwin home page for more information.
[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index] [Subject Index] [Author Index] [Thread Index]

Re: Again about physical disks.



> This is a known 'feature' of w95;
> the article "PRB: DeviceIoControl Int 13h Does Not Support Hard Disks"
> http://support.microsoft.com/support/kb/articles/q137/1/76.asp
> describes the problem and presents the code for a workaround.
> It's *ugly* - you have to use 'flat thunks'.
>
> So the short answer is *yes*, you can read disk-blocks from
> cygwin-compiled code, but *no*, it's not easy, and

> you'll need to be significantly motivated....
I am :-)))

So, if I understand well, the workaround is to make a 16bit DLL for disk IO,
and then call it from 32bit code using so caled "thunk"s.  Well, I suppose
that it works with MSVC, and that example given there will compile with MSVC
(I don't have it, and don't WANT to heve it, so I can't test).  But is all
this feasible under CygWin???  That is, can I compile 16bit DLL using
cygwin???!!!  How???

And even if I compile the dll elsewhere (say under MSVC or Borland), will it
be possible later to use this 16bit DLL in cygwin program???  Are there
"thunks" under CygWin???

Or, finally, the only solution is to made both a 16bit DLL and a 32bit DLL
(using the 16bit one via thunks) under MSVC and then use the 32bit one from
CygWin???

IF this IS the case, then the reading of a physical sector from a physical
disk will finally NOT REALLY be done under CygWin, and so both the short and
long answers will be NO!!! :-)

Regards,
                Serguei.
___________________________________________________________________________
Serguei DACHIAN
Laboratoire de Statistique et Processus,
Universite du Maine, Av. Olivier Messiaen
72085 Le Mans CEDEX 9, FRANCE
Tel.   : +33 (0)2 43 83 37 18
Fax.   : +33 (0)2 43 83 35 79
E-mail : Serguei.Dachian@univ-lemans.fr
WWW    : http://www.univ-lemans.fr/sciences/statist/cvs/thesard.html#dachian


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com