From: alm@netcom.com (Andrew Moore)
Subject: printer patches (interruptless driver not included!)
Organization: Netcom - Online Communication Services  (408 241-9760 guest) 
Date: Sat, 21 Nov 1992 02:48:28 GMT


In article <1992Nov20.035734.2949@ultb.isc.rit.edu> you write:
>I recently installed 386bsd on my pc. I downloaded the binary
>distribution from agate.berkeley.edu. But the printer (LPT1) never
>worked. I found out there was no "/dev/lp". I tried to make one with
>"mknod", but I don't know the major and minor device number. In fact, I
>don't even know if my kernel supports the parallel port. I noticed that
>in the MAKEDEV file, the printer part was left blank. Can any one tell
>me how to make my printer work? I'd appreciate it.

Here are some patches to set up the printer.  Read them carefully, and
you should have no problem.  /dev/lp should be linked to /dev/lpt1 when
you finish.  If you print binary data, you may need the interruptless
driver.  It is a drop-in replacement of lpt.c and you need only change
the minor number of /dev/lpt (to 49, say).  But try this first.
-Andrew Moore <alm@netcom.com>

begin 644 eh.cf.lpt.patches
M2&D@3F%T92P*"DEN8VQU9&5D(&)E;&]W(&%R92!B;W1H($-H<FES($9L871T
M97)S)R!A;F0@17)I8R!(875G)W,@<&%T8VAE<R!T;R!T:&4*97AI<W1I;F<@
M,S@V0E-$(&QP="!D<FEV97(N("!#:')I<R=S('!A=&-H('-O;'9E<R!T:&4@
M<')O8FQE;2!O9B!T:&4*<')I;G1E<B!N;W0@8F5I;F<@9F]U;F0@;VX@8F]O
M="!I9B!I="!T=7)N960@;V9F+B @270@86QS;R!A;&QO=W,@=&AE"G!R:6YT
M97(@=&\@8F4@='5R;F5D(&]F9B!A9G1E<B!B;V]T('=I=&AO=70@:6YC:61E
M;G0N"@I);B!A9&1I=&EO;B!T;R!T:&5S92!P871C:&5S+"!Y;W4@;6EG:'0@
M=V%N="!T;R!M96YT:6]N('1H870@=&AE(&9I;&4*+V5T8R]H;W-T<RYL<&0@
M;75S="!B92!S970@87!P<F]P<FEA=&5L>2!A;F0@=&AA="!T:&4@9FEL90HO
M<WES+VDS.#8O8V]N9B]F:6QE<RYI,S@V('-H;W5L9"!I;F-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