Re: ftape-3.xx-970321 and floppy with 2.1.31

Claus-Justus Heine (claus@momo.math.rwth-aachen.de)
07 Apr 1997 21:21:21 +0200


-----BEGIN PGP SIGNED MESSAGE-----

Guilhem Lavaux <ylavaux@pratique.fr> writes:

>
> Hi !
>
> I noticed floppy driver and ftape driver wants to allocate the same
> regions at the same time. I know floppy mustn't work while ftape works.
> But the floppy driver allocates these regions at the init and ftape when
> the device is opened. I think that floppy must do this too !

No, you're thoughts are wrong. The floppy driver is definitely
broken. Please have a look at the ftape.c.dif file in patches/2.x.x of
the ftape distribution. The floppy driver not even checks if another
driver already uses the io regions. EVEN WORSE. The floppy driver
already does hardware probing, i.e. accesses those regions before even
allocating them. What a mess!!!

I've patched the floppy driver to

a) don't access io regions before allocating them with
request_region()
b) do a check_region() before a request_region() and bail out if the
region is already in use
c) release the io regions with release_region() while they aren't
needed s.t. other drivers (i.e. ftape) can make use of
check_region() to test whether the floppy controller is currently
available.

It is all in the patch contained in the ftape distribution.
The final version, ftape-3.03, will have a compile switch that makes
it ignore the broken floppy driver's weird behavior.

> At the moment if I want to make work my tape driver, I need to remove
> the call to check_region() else the ftape driver aborts.

Ok, you're using a development version of ftape, so it's perfectly
okay to hack it to get it to work.

Thanks for the feedback! And don't forget to upgrade to the latest
development versions and to the final ftape-3.03 when it is released
in a few days.

Cheers

Claus

- --
Claus-Justus Heine
claus@momo.math.rwth-aachen.de
http://samuel.math.rwth-aachen.de/~LBFM/claus

PGP Public Key:
http://samuel.math.rwth-aachen.de/~LBFM/claus/claus-public-key.asc

Ftape - the Linux Floppy Tape Project
WWW : http://samuel.math.rwth-aachen.de/~LBFM/claus/ftape
Mailing-list: linux-tape@vger.rutgers.edu
Newsgroup : linux.dev.tape

-----BEGIN PGP SIGNATURE-----
Version: 2.6.3i
Charset: latin1
Comment: Processed by Mailcrypt 3.4, an Emacs/PGP interface

iQCVAwUBM0lJLdo/s1zPE7AdAQEIFwQAozuyNaFxtO+pZY3IixxR1yQ79RJJ150P
Q+4q4VUFMcLdWoDuzaC49SqKmtiukT4RuDxD13ayqC0HjNeE+/8rohfgCR4SqBcW
393ml8eNdZvFIWA6uIY1RoCOA6AmO1mVVv4X08SWZOGnrEOZKtARCEDFSlKpbuBC
IcRM35oPt18=
=yXmP
-----END PGP SIGNATURE-----