check_region() patch for floppy.c

Claus-Justus Heine (claus@momo.math.rwth-aachen.de)
10 Mar 1997 13:06:27 +0100


--pgp-sign-Multipart_Mon_Mar_10_13:06:21_1997-1
Content-Type: multipart/mixed;
boundary="Multipart_Mon_Mar_10_13:06:21_1997-1"
Content-Transfer-Encoding: 7bit

--Multipart_Mon_Mar_10_13:06:21_1997-1
Content-Type: text/plain; charset=US-ASCII

Hi!

Below I've included a small patch to the floppy driver that makes it
check for IO regions before doing any hardware probing. There could be
conflicts between the floppy driver and the ftape driver when
accidentally trying to access a floppy disk while the ftape driver was
using the tape drive (or vice versa). My latest development version of
the ftape driver also uses the check_region() calls before accessing
hardware registers s.t. those conflicts should be solved.

Hopefully the patch doesn't hose up the floppy driver. It works for
me, though. That patch is against 2.1.28. It applies also to 2.0.29,
but I only tested it with 2.1.28.

Cheers

Claus

--Multipart_Mon_Mar_10_13:06:21_1997-1
Content-Type: application/octet-stream
Content-Disposition: attachment; filename="floppy.c.dif"
Content-Transfer-Encoding: x-uue

begin 644 floppy.c.dif
M+2TM(&QI;G5X+3(N,2XR."]D<FEV97)S+V)L;V-K+V9L;W!P>2YC"4UO;B!-
M87(@,3`@,3(Z,C0Z-#8@,3DY-PHK*RL@;&EN=7@M,BXQ+V1R:79E<G,O8FQO
M8VLO9FQO<'!Y+F,)5V5D($IA;B`R.2`R,CHS,CHQ,B`Q.3DW"D!`("TS.3DY
M+#$P("LS.3DY+#$R($!`"B`)"0EC;VYT:6YU93L*(`D)?0H@"BLC:68@,`H@
M"0ER97%U97-T7W)E9VEO;BA&1$-3+3YA9&1R97-S+"`V+"`B9FQO<'!Y(BD[
M"B`)"7)E<75E<W1?<F5G:6]N*$9$0U,M/F%D9')E<W,K-RP@,2P@(F9L;W!P
M>2!$25(B*3L*(`D)+RH@861D<F5S<R`K(#8@:7,@<F5S97)V960L(&%N9"!M
M87D@8F4@=&%K96X@8GD@241%+@H@"0D@*B!5;F9O<G1U;F%T96QY+"!!9&%P
M=&5C(&1O97-N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I.R`@+RH@879O:60@:6UM961I871E(&EN=&5R<G5P="`J+PHK"B`)
M9F]R("AF9&,@/2`P.R!F9&,@/"!.7T9$0SL@9F1C*RLI"B`)"6EF("A&1$-3
M+3YA9&1R97-S("$]("TQ*0H@"0D)9F1?;W5T8BA&1$-3+3YD;W(L($9$7T1/
M4BD["D!`("TT,#<P+#8@*S0P.30L-R!`0`H@"B!S=&%T:6,@=F]I9"!F;&]P
M<'E?<F5L96%S95]I<G%?86YD7V1M82AV;VED*0H@>PHK"6EN="!O;&1?9F1C
M.PH@(VEF9&5F($9,3U!065]304Y)5%E?0TA%0TL*("-I9FYD968@7U]S<&%R
M8U]?"B`):6YT(&1R:79E.PI`0"`M-#$Q.2PV("LT,30T+#$S($!`"B`):68@
M*&9L;W!P>5]T<2YS>6YC*0H@"0EP<FEN=&LH(G1A<VL@<75E=64@<W1I;&P@
M86-T:79E7&XB*3L*("-E;F1I9@HK"6]L9%]F9&,@/2!F9&,["BL)9F]R("AF
M9&,@/2`P.R!F9&,@/"!.7T9$0SL@9F1C*RLI"BL)"6EF("A&1$-3+3YA9&1R
M97-S("$]("TQ*2!["BL)"0ER96QE87-E7W)E9VEO;BA&1$-3+3YA9&1R97-S
M+"`V*3L**PD)"7)E;&5A<V5?<F5G:6]N*$9$0U,M/F%D9')E<W,K-RP@,2D[
M"BL)"7T**PEF9&,@/2!O;&1?9F1C.PH@"4U/1%]$14-?55-%7T-/54Y4.PH@
$?0H@"GT*
`
end

--Multipart_Mon_Mar_10_13:06:21_1997-1
Content-Type: text/plain; charset=US-ASCII

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




--Multipart_Mon_Mar_10_13:06:21_1997-1--

--pgp-sign-Multipart_Mon_Mar_10_13:06:21_1997-1
Content-Type: application/pgp-signature
Content-Transfer-Encoding: 7bit

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

iQCVAwUBMyP5Q9o/s1zPE7AdAQFDOQP8CdLI3Kfixj41/YtGqeH0fmTuWGROrCgI
ykOwThkbItVW7bEONYFeumr6QPnOsxy6UYFxygGE9wDlpxtv2E8WKeFq3n+hrQ54
YE4K21EzkrZ+lJlb13XPXj97sGfkfNy4x2q1BqYXnq5pzr2ZYMpPQg/cIegayTVc
nMqlPaqfdc8=
=b3fC
-----END PGP MESSAGE-----

--pgp-sign-Multipart_Mon_Mar_10_13:06:21_1997-1--