Commit Graph

196 Commits

Author SHA1 Message Date
Alfred Perlstein
29f194457c Fix instances of macros with improperly parenthasized arguments.
Verified by: md5
2002-11-09 12:55:07 +00:00
John Baldwin
8d667a42c4 d_read_t functions return an int, not a ssize_t. (Considering the fact
that read(2) returns a ssize_t perhaps this is a bug in d_read_t?)
2002-11-07 17:26:38 +00:00
John Baldwin
a885bb6007 Warning fixes for sizeof(int) != sizeof(void *). 2002-11-07 17:25:33 +00:00
John Baldwin
9e14a48a03 - Make 'irq' intptr_t instead of uintptr_t so it handles a value of -1
properly.
- Add a cast to quiet a printf warning.
2002-11-07 17:20:58 +00:00
Poul-Henning Kamp
668b05c376 Remove empty #if*/#endif clauses. 2002-09-21 08:44:51 +00:00
Philippe Charnier
93b0017f88 Replace various spelling with FALLTHROUGH which is lint()able 2002-08-25 13:23:09 +00:00
Peter Wemm
daefef7cae Fix warnings due to macro varargs. 2002-05-24 06:32:18 +00:00
Poul-Henning Kamp
7bf758bff0 Simplify the RFC2783 and PPS_SYNC timestamp collection API. 2002-04-26 20:24:28 +00:00
Bernd Walter
338cad62ab This makes ppbus childs like lpt and ppi succesfully connect to more
than just the first ppbus.
The child drivers always tried to attach unit 0.

Reviewed by:	gallatin
Approved by:	gallatin
2002-04-07 22:06:20 +00:00
Nicolas Souchu
c17d43407f Major rework of the iicbus/smbus framework:
- VIA chipset SMBus controllers added
	- alpm driver updated
	- Support for dynamic modules added
	- bktr FreeBSD smbus updated but not tested
	- cleanup
2002-03-23 15:49:15 +00:00
Peter Wemm
0d87e7d007 Fix some gcc-3.1+ warnings:
warning: deprecated use of label at end of compound statement
umass.c:2626:46: multi-line string literals are deprecated
2002-03-19 23:20:21 +00:00
Warner Losh
d7e53105ec Make this driver a better citizen by moving dev creation and
other initialization into attach from probe.  Also hide a few
printfs behind a bootverbose.

approved in principle by: phk
2001-12-19 19:37:31 +00:00
David E. O'Brien
6e551fb628 Update to C99, s/__FUNCTION__/__func__/,
also don't use ANSI string concatenation.
2001-12-10 08:09:49 +00:00
Poul-Henning Kamp
bd61b8e81d Give the pps driver an additional 8 inputs if we can persuade the
ppc to go into EPP mode.  These 8 inputs are timestamped in polled
loop so their resolution will be nanoseconds but their granularity
will only be 1/hz.
2001-09-22 16:34:59 +00:00
Julian Elischer
b40ce4165d KSE Milestone 2
Note ALL MODULES MUST BE RECOMPILED
make the kernel aware that there are smaller units of scheduling than the
process. (but only allow one thread per process at this time).
This is functionally equivalent to teh previousl -current except
that there is a thread associated with each process.

Sorry john! (your next MFC will be a doosie!)

Reviewed by: peter@freebsd.org, dillon@freebsd.org

X-MFC after:    ha ha ha ha
2001-09-12 08:38:13 +00:00
Nicolas Souchu
334a17f09a Translate various ppbus sequences into microsequences to limit
overhead of abstraction layers.

Submitted by:	jcm@FreeBSD-uk.eu.org
2001-06-23 06:51:52 +00:00
Peter Wemm
1ae2c6005e -Wunused cleanup 2001-06-12 07:01:27 +00:00
Poul-Henning Kamp
77a7881dac Style fixes from Sascha
PR:		16551
Submitted by:	Sascha Schumann <sascha@schumann.cx>
2001-06-06 21:00:01 +00:00
Alfred Perlstein
8cf6ffcf6d make code use strxxx() calls
Glanced at by: imp
2001-04-01 07:36:28 +00:00
Poul-Henning Kamp
f83880518b Send the remains (such as I have located) of "block major numbers" to
the bit-bucket.
2001-03-26 12:41:29 +00:00
Nicolas Souchu
a138e28335 Discard extra status information if -1. This has been breaking the
PS/2 mode for ZIP+ drives for a long time. Thanks Jonathon.

Submitted by:	j mckitrick <jcm@FreeBSD-uk.eu.org>
2001-01-25 13:07:55 +00:00
Nicolas Souchu
adb50a3799 Cleanup and improve mode detection. Now, you should get what you actually
want according to the modes set with the ppc(4) flags. Especially, it
should fix some problems with mode detection of parallel chipsets
configured to EPP but which have timing troubles with the drives. In such
a case, the driver should now fall back to slower modes (PS2, NIBBLE).
2001-01-02 21:29:06 +00:00
David Malone
7cc0979fd6 Convert more malloc+bzero to malloc+M_ZERO.
Submitted by:	josh@zipperup.org
Submitted by:	Robert Drehmel <robd@gmx.net>
2000-12-08 21:51:06 +00:00
Poul-Henning Kamp
959b7375ed Staticize some malloc M_ instances. 2000-12-08 20:09:00 +00:00
Poul-Henning Kamp
7891600907 Don't use a private malloc(9) type for something this M_DEVBUFish.
Noticed long time ago by:	bde
2000-12-07 22:33:12 +00:00
Jonathan Lemon
df5e198723 Lock down the network interface queues. The queue mutex must be obtained
before adding/removing packets from the queue.  Also, the if_obytes and
if_omcasts fields should only be manipulated under protection of the mutex.

IF_ENQUEUE, IF_PREPEND, and IF_DEQUEUE perform all necessary locking on
the queue.  An IF_LOCK macro is provided, as well as the old (mutex-less)
versions of the macros in the form _IF_ENQUEUE, _IF_QFULL, for code which
needs them, but their use is discouraged.

Two new macros are introduced: IF_DRAIN() to drain a queue, and IF_HANDOFF,
which takes care of locking/enqueue, and also statistics updating/start
if necessary.
2000-11-25 07:35:38 +00:00
Poul-Henning Kamp
db7e3af111 Remove unneeded #include <machine/clock.h> 2000-10-15 14:19:01 +00:00
Doug Rabson
530f610f02 A quote from the ia64 compiler:
`char' is promoted to `int' when passed through `...'
	(so you should pass `int' not `char' to `va_arg')
2000-10-10 14:18:50 +00:00
Nick Hibma
ef36241a4a Remove an unused variable warning. 2000-07-18 20:16:36 +00:00
Nick Hibma
677cec5b04 Fix the detection of parallel port Zip drives.
Submitted by:	j mckitrick <jcm@freebsd-uk.eu.org>
Reviewed by:	nsouchu
2000-07-18 20:16:16 +00:00
Peter Wemm
52044d2673 Unused include: #include "pps.h" 2000-06-10 11:14:19 +00:00
David E. O'Brien
907774ca1a Match the include protection with the install location. 2000-05-20 05:45:04 +00:00
David E. O'Brien
74cf6eb61b Rather than use a MD lpt.h, we now use the MI lptio.h. 2000-05-19 18:23:48 +00:00
Nick Hibma
c47eb96cb5 If PERIPH_1284 is not defined, don't even bother calling the BUS_*_INTR
functions.

If it is defined, check whether bus_alloc_resource has succeeded. If it
hasn't, it is in polled mode. Mike Nowlin reports that this change makes
the geek port (whatever _that_ is :-) work again on his machine.

Submitted by:	Mike Nowlin <mike@argos.org>
2000-05-07 20:46:49 +00:00
Nick Hibma
0c42807c05 Confusing comment. 2000-05-05 14:10:25 +00:00
Poul-Henning Kamp
5856c95848 Don't use getebuf() unless you really need a struct buf. Malloc will
do fine in this case.
2000-05-05 07:50:53 +00:00
Poul-Henning Kamp
eb95c536ad Remove unneeded #include <sys/kernel.h> 2000-04-29 15:36:14 +00:00
Nick Hibma
7fe1aaca86 make the example compile again.
The makefile contains a reference to /sys/dev/ppbus. What really should
be done is copy the header files to /usr/include/sys/dev/ppbus.

PR:	            kern/16767
Submitted by:	   Jin Guojun (FTG staff) <jin@gracie.lbl.gov>
2000-04-27 21:08:24 +00:00
Poul-Henning Kamp
3389ae9350 Remove ~25 unneeded #include <sys/conf.h>
Remove ~60 unneeded #include <sys/malloc.h>
2000-04-19 14:58:28 +00:00
Poul-Henning Kamp
ed6aff7387 Remove unneeded <sys/buf.h> includes.
Due to some interesting cpp tricks in lockmgr, the LINT kernel shrinks
by 924 bytes.
2000-04-18 15:15:39 +00:00
Doug Rabson
f7b7769172 * Factor out the object system from new-bus so that it can be used by
non-device code.
* Re-implement the method dispatch to improve efficiency. The new system
  takes about 40ns for a method dispatch on a 300Mhz PII which is only
  10ns slower than a direct function call on the same hardware.

This changes the new-bus ABI slightly so make sure you re-compile any
driver modules which you use.
2000-04-08 14:17:18 +00:00
Jonathan Lemon
9c117130a5 If we can't allocate an IRQ resource, fail in the attach routine. 2000-04-07 00:09:24 +00:00
Nick Hibma
9011b59b70 Add automatic rescan on connect. This happens already if the drive is
connected during boot and the vpo module is in the kernel/loaded.

In the case where the module is loaded at some later stage with kldload,
the CAM bus is now rescanned as well.
2000-04-04 22:15:13 +00:00
Poul-Henning Kamp
91266b96c4 Isolate the Timecounter internals in their own two files.
Make the public interface more systematically named.

Remove the alternate method, it doesn't do any good, only ruins performance.

Add counters to profile the usage of the 8 access functions.

Apply the beer-ware to my code.

The weird +/- counts are caused by two repocopies behind the scenes:
	kern/kern_clock.c -> kern/kern_tc.c
	sys/time.h -> sys/timetc.h
(thanks peter!)
2000-03-20 14:09:06 +00:00
Brian Feldman
3841bf81f7 I _HATE_ crashes. The lptread() call needs to check LP_BYPASS, because
if one tries to use read() on an LP_BYPASS'd dev_t, the softc will be
initialized mainly with NULLs, so...
2000-03-15 03:23:04 +00:00
Sheldon Hearn
4ca7c740a6 Fix buffer overrun in pcfclock_read(). The submitter is the original
author of the affected code.

PR:		16552
Submitted by:	Sascha Schumann <sascha@schumann.cx>
Approved by:	jkh
2000-02-20 09:08:33 +00:00
Peter Wemm
84a5b01504 Fix two warnings. 2000-02-13 03:03:31 +00:00
Nicolas Souchu
249a96889e Fix system hang when printer locks on missing paper
(also called the "printer fiasco")

Approved by: jkh
2000-02-08 21:46:27 +00:00
Doug Rabson
150630c449 Make this lot build on alpha. 2000-01-25 22:23:48 +00:00
Peter Wemm
0f063508d7 Some newbus-inspired tidy-ups. Use device_identify() rather than scanning
the resource table to locate children.  The 'at ppbus?' can go again.
Remove a few #if Nxxx > 0' type things, config arranges this for us.
Move the newbus method glue next to the DRIVER_MODULE() stuff so we
don't need extra prototypes.
Don't set device descriptions until after the possibility of the probe
returning an error.
Remove all cdevsw_add() calls, all the drivers that did this also use
make_dev() correctly, so it's not required.
A couple of other minor nits.
2000-01-23 14:41:04 +00:00
Jordan K. Hubbard
6417807e8b Add parallel port clock driver.
Submitted by:	Sascha Schumann <sascha@schumann.cx>
2000-01-19 18:19:16 +00:00
Peter Wemm
99904c75f7 Make this compile - missing ")"; 2000-01-14 15:54:45 +00:00
Nicolas Souchu
bdcee5cff6 ppi needs to use a bus method to get this rather than peering inside the
1284 stuff.

Submitted by: Peter Wemm <peter@netplex.com.au>
2000-01-14 08:03:15 +00:00
Nicolas Souchu
0f210c922b Port of ppbus standalone framework to the newbus system.
Note1: the correct interrupt level is invoked correctly for each driver.
       For this purpose, drivers request the bus before being able to
       call BUS_SETUP_INTR and BUS_TEARDOWN_INTR call is forced by the ppbus
       core when drivers release it. Thus, when BUS_SETUP_INTR is called
       at ppbus driver level, ppbus checks that the caller owns the
       bus and stores the interrupt handler cookie (in order to unregister
       it later).

       Printing is impossible while plip link is up is still TRUE.
       vpo (ZIP driver) and lpt are make in such a way that
       using the ZIP and printing concurrently is permitted is also TRUE.

Note2: specific chipset detection is not done by default. PPC_PROBE_CHIPSET
       is now needed to force chipset detection. If set, the flags 0x40
       still avoid detection at boot.

Port of the pcf(4) driver to the newbus system (was previously directly
connected to the rootbus and attached by a bogus pcf_isa_probe function).
2000-01-14 00:18:06 +00:00
Peter Wemm
664a31e496 Change #ifdef KERNEL to #ifdef _KERNEL in the public headers. "KERNEL"
is an application space macro and the applications are supposed to be free
to use it as they please (but cannot).  This is consistant with the other
BSD's who made this change quite some time ago.  More commits to come.
1999-12-29 04:46:21 +00:00
Eivind Eklund
6852838006 Incorrect NULL -> 0 1999-12-20 17:50:24 +00:00
Matthew N. Dodd
fe0d408987 Remove the 'ivars' arguement to device_add_child() and
device_add_child_ordered().  'ivars' may now be set using the
device_set_ivars() function.

This makes it easier for us to change how arbitrary data structures are
associated with a device_t.  Eventually we won't be modifying device_t
to add additional pointers for ivars, softc data etc.

Despite my best efforts I've probably forgotten something so let me know
if this breaks anything.  I've been running with this change for months
and its been quite involved actually isolating all the changes from
the rest of the local changes in my tree.

Reviewed by:	peter, dfr
1999-12-03 08:41:24 +00:00
Nick Hibma
fc56bfd8a7 Print more verbose debugging output
Clean up computation of parameters.
1999-10-05 20:29:00 +00:00
Poul-Henning Kamp
d6a0e38a1b Remove five now unused fields from struct cdevsw. They should never
have been there in the first place.  A GENERIC kernel shrinks almost 1k.

Add a slightly different safetybelt under nostop for tty drivers.

Add some missing FreeBSD tags
1999-09-25 18:24:47 +00:00
Poul-Henning Kamp
46783fb897 Remove NBPF conditionality of bpf calls in most of our network drivers.
This means that we will not have to have a bpf and a non-bpf version
of our driver modules.

This does not open any security hole, because the bpf core isn't loadable

The drivers left unchanged are the "cross platform" drivers where the respective
maintainers are urged to DTRT, whatever that may be.

Add a couple of missing FreeBSD tags.
1999-09-25 12:06:01 +00:00
Peter Wemm
c3aac50f28 $Id$ -> $FreeBSD$ 1999-08-28 01:08:13 +00:00
Poul-Henning Kamp
9dcbe2404a Convert DEVFS hooks in (most) drivers to make_dev().
Diskslice/label code not yet handled.

Vinum, i4b, alpha, pc98 not dealt with (left to respective Maintainers)

Add the correct hook for devfs to kern_conf.c

The net result of this excercise is that a lot less files depends on DEVFS,
and devtoname() gets more sensible output in many cases.

A few drivers had minor additional cleanups performed relating to cdevsw
registration.

A few drivers don't register a cdevsw{} anymore, but only use make_dev().
1999-08-23 20:59:21 +00:00
Poul-Henning Kamp
f04626ff22 Add pin-numbers for easy reference. 1999-08-18 20:45:57 +00:00
Poul-Henning Kamp
1a03ce6c63 Remove compile time limit on number of devices. 1999-08-08 22:25:46 +00:00
Poul-Henning Kamp
fca3f34ff8 Passing the unit number to an interrupt routing is kind of narrowminded,
add a way to get the entire struct ppb_device back.
1999-08-08 22:25:21 +00:00
Matthew N. Dodd
15317dd875 Alter the behavior of sys/kern/subr_bus.c:device_print_child()
- device_print_child() either lets the BUS_PRINT_CHILD
	  method produce the entire device announcement message or
	  it prints "foo0: not found\n"

Alter sys/kern/subr_bus.c:bus_generic_print_child() to take on
the previous behavior of device_print_child() (printing the
"foo0: <FooDevice 1.1>" bit of the announce message.)

Provide bus_print_child_header() and bus_print_child_footer()
to actually print the output for bus_generic_print_child().
These functions should be used whenever possible (unless you can
just use bus_generic_print_child())

The BUS_PRINT_CHILD method now returns int instead of void.

Modify everything else that defines or uses a BUS_PRINT_CHILD
method to comply with the above changes.

	- Devices are 'on' a bus, not 'at' it.
	- If a custom BUS_PRINT_CHILD method does the same thing
	  as bus_generic_print_child(), use bus_generic_print_child()
	- Use device_get_nameunit() instead of both
	  device_get_name() and device_get_unit()
	- All BUS_PRINT_CHILD methods return the number of
	  characters output.

Reviewed by: dfr, peter
1999-07-29 01:03:04 +00:00
Dag-Erling Smørgrav
6b5ca0d83e Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
Nick Hibma
25d210e317 Remove unused variable and computation, possibly leading to a
divide by zero fault.

Possible fix for PR12041

PR:		12041
Submitted-By:	J.Hudson@massey.ac.nz
Reviewed-By:	nsouch
1999-06-26 14:42:17 +00:00
Peter Wemm
b42a56cd10 GC unused prototype 1999-06-03 22:03:35 +00:00
Poul-Henning Kamp
2447bec829 Simplify cdevsw registration.
The cdevsw_add() function now finds the major number(s) in the
struct cdevsw passed to it.  cdevsw_add_generic() is no longer
needed, cdevsw_add() does the same thing.

cdevsw_add() will print an message if the d_maj field looks bogus.

Remove nblkdev and nchrdev variables.  Most places they were used
bogusly.  Instead check a dev_t for validity by seeing if devsw()
or bdevsw() returns NULL.

Move bdevsw() and devsw() functions to kern/kern_conf.c

Bump __FreeBSD_version to 400006

This commit removes:
        72 bogus makedev() calls
        26 bogus SYSINIT functions

if_xe.c bogusly accessed cdevsw[], author/maintainer please fix.

I4b and vinum not changed.  Patches emailed to authors.  LINT
probably broken until they catch up.
1999-05-31 11:29:30 +00:00
Poul-Henning Kamp
4e2f199e0c This commit should be a extensive NO-OP:
Reformat and initialize correctly all "struct cdevsw".

        Initialize the d_maj and d_bmaj fields.

        The d_reset field was not removed, although it is never used.

I used a program to do most of this, so all the files now use the
same consistent format.  Please keep it that way.

Vinum and i4b not modified, patches emailed to respective authors.
1999-05-30 16:53:49 +00:00
Doug Rabson
566643e39e Move the declaration of the interrupt type from the driver structure
to the BUS_SETUP_INTR call.
1999-05-08 21:59:43 +00:00
Peter Wemm
3cca27dac6 GC unused pps_drvinit() declaration 1999-05-06 22:03:14 +00:00
Kenneth D. Merry
db15b5b790 The base transfer speed for the parallel port bus is 93K/sec, not 3.3MB/sec.
Submitted by:	Nick Hibma <hibma@skylink.it>
1999-05-06 21:14:49 +00:00
Kenneth D. Merry
169b302922 Take out calls to cam_sim_set_basexfer_speed(), the base transfer speed is
now returned in the path inquiry CCB.

Submitted by:	Nick Hibma <hibma@skylink.it>
1999-05-06 21:12:58 +00:00
Kenneth D. Merry
9deea8574e Add a number of interrelated CAM feature enhancements and bug fixes.
NOTE:  These changes will require recompilation of any userland
applications, like cdrecord, xmcd, etc., that use the CAM passthrough
interface.  A make world is recommended.

camcontrol.[c8]:
 - We now support two new commands, "tags" and "negotiate".

	- The tags commands allows users to view the number of tagged
	  openings for a device as well as a number of other related
	  parameters, and it allows users to set tagged openings for
	  a device.

	- The negotiate command allows users to enable and disable
	  disconnection and tagged queueing, set sync rates, offsets
	  and bus width.  Note that not all of those features are
	  available for all controllers.  Only the adv, ahc, and ncr
	  drivers fully support all of the features at this point.
	  Some cards do not allow the setting of sync rates, offsets and
	  the like, and some of the drivers don't have any facilities to
	  do so.  Some drivers, like the adw driver, only support enabling
	  or disabling sync negotiation, but do not support setting sync
	  rates.

 - new description in the camcontrol man page of how to format a disk
 - cleanup of the camcontrol inquiry command
 - add support in the 'devlist' command for skipping unconfigured devices if
   -v was not specified on the command line.
 - make use of the new base_transfer_speed in the path inquiry CCB.
 - fix CCB bzero cases

cam_xpt.c, cam_sim.[ch], cam_ccb.h:

 - new flags on many CCB function codes to designate whether they're
   non-immediate, use a user-supplied CCB, and can only be passed from
   userland programs via the xpt device.  Use these flags in the transport
   layer and pass driver to categorize CCBs.

 - new flag in the transport layer device matching code for device nodes
   that indicates whether a device is unconfigured

 - bump the CAM version from 0x10 to 0x11

 - Change the CAM ioctls to use the version as their group code, so we can
   force users to recompile code even when the CCB size doesn't change.

 - add + fill in a new value in the path inquiry CCB, base_transfer_speed.
   Remove a corresponding field from the cam_sim structure, and add code to
   every SIM to set this field to the proper value.

 - Fix the set transfer settings code in the transport layer.

scsi_cd.c:

 - make some variables volatile instead of just casting them in various
   places
 - fix a race condition in the changer code
 - attach unless we get a "logical unit not supported" error.  This should
   fix all of the cases where people have devices that return weird errors
   when they don't have media in the drive.

scsi_da.c:

 - attach unless we get a "logical unit not supported" error

scsi_pass.c:

 - for immediate CCBs, just malloc a CCB to send the user request in.  This
   gets rid of the 'held' count problem in camcontrol tags.

scsi_pass.h:

 - change the CAM ioctls to use the CAM version as their group code.

adv driver:

 - Allow changing the sync rate and offset separately.

adw driver

 - Allow changing the sync rate and offset separately.

aha driver:

 - Don't return CAM_REQ_CMP for SET_TRAN_SETTINGS CCBs.

ahc driver:

 - Allow setting offset and sync rate separately

bt driver:

 - Don't return CAM_REQ_CMP for SET_TRAN_SETTINGS CCBs.

NCR driver:

 - Fix the ultra/ultra 2 negotiation bug
 - allow setting both the sync rate and offset separately

Other HBA drivers:
 - Put code in to set the base_transfer_speed field for
   XPT_GET_TRAN_SETTINGS CCBs.

Reviewed by:	gibbs, mjacob (isp), imp (aha)
1999-05-06 20:16:39 +00:00
Dmitrij Tejblum
604359cf9b s/static foo_devsw_installed = 0;/static int foo_devsw_installed;/.
(Edited automatically)
1999-04-28 10:54:24 +00:00
Poul-Henning Kamp
477f9db33d Allow multiple opens. 1999-04-25 08:58:10 +00:00
Eivind Eklund
505ab9b86b Staticize. 1999-04-11 02:55:52 +00:00
Peter Wemm
5734634f4c Make ppbus compile under egcs. I'm not sure about this casting-to-union-
-containing-the-type stuff, but gcc seemed to do it implicitly..
1999-04-05 15:43:11 +00:00
Poul-Henning Kamp
aefda6c59c Reduce Bruce-filter verbosity. 1999-03-13 16:22:18 +00:00
Poul-Henning Kamp
32c203577a Make even more of the PPSAPI implementations generic.
FLL support in hardpps()

Various magic shuffles and improved comments

Style fixes from Bruce.
1999-03-11 15:09:51 +00:00
Nicolas Souchu
17b5923dbb Move away from lpt.h data structure definition that only lpt.c relies on.
Remove if_plip.c dependency to lpt.h.
1999-02-14 16:19:16 +00:00
Nicolas Souchu
fdf94d1afe Rename nlpt to lpt.
Remove from ppi.c the old depreciated module stuff.
Print info when if_plip can't use interrupts.
1999-02-14 12:00:00 +00:00
Dag-Erling Smørgrav
8f84257ed7 Generate correct DLT_NULL headers before passing packets to bpf.
Do not modify m_len before passing mbuf chains to bpf.
Don't forget to pass packets to bpf when running in Crynwr mode (LINK0).

Partially based on a patch by Bill Fenner <fenner@freebsd.org>.

PR:             bin/7241
1999-02-08 14:12:38 +00:00
Dag-Erling Smørgrav
9539cd4d92 Bring in the simplified port probe from src/sys/i386/isa/lpt.c 1999-02-08 13:55:43 +00:00
Nicolas Souchu
c9ab07382c Fix compile warnings about missing braces around static initialization of unions. 1999-01-31 11:52:04 +00:00
Nicolas Souchu
20240fa3ad Distinguish EPP address/data register. Add EPP address register access to ppi.
Change microseq offsets. Previously, offsets of the program counter where
added to the index of the current microinstruction. Make them rely on the
index of the next executed microinstruction.

Suggested by: Luigi Rizzo <luigi@labinfo.iet.unipi.it>
1999-01-30 15:35:39 +00:00
Matthew Dillon
d254af07a1 Fix warnings in preparation for adding -Wall -Wcast-qual to the
kernel compile
1999-01-27 21:50:00 +00:00
Matthew Dillon
b4e36adf1c Fix warnings preparing for -Wall -Wcast-qual
Also disable one usb module in LINT due to fatal compilation errors,
    temporary.
1999-01-27 20:09:21 +00:00
Matthew Dillon
a56d629240 Fix PPBPRI #define - it was missing parenthesis which messed up a
call to tsleep() in dev/ppbus/ppbconf.c.  Also fixup initializers.
1999-01-27 19:44:05 +00:00
Nicolas Souchu
7b7bf77e65 Replace DEBUG by PLIP_DEBUG option 1999-01-23 17:07:49 +00:00
Nicolas Souchu
78534d41e1 Terminate negociation if Ext. link negociation succeeds. This avoids
the unknown mode panic during boot probe.
1999-01-14 21:38:16 +00:00
John Polstra
0ec81012da Replace includes of <sys/kernel.h> with includes of
<sys/linker_set.h> in those files that use only the linker set
definitions.
1999-01-14 06:22:10 +00:00
Nicolas Souchu
2dcc537bfe Fix missing \n in boot printfs. Add more mode detection if bootverbose. 1999-01-11 21:22:41 +00:00
Nicolas Souchu
a7006f894f Fix broken low level ppb_rxxx() return type: char becomes u_char.
Submitted by: Bruce Evans <bde@zeta.org.au>

Some ppb bootup printfs simplified.
1999-01-10 16:41:14 +00:00
Nicolas Souchu
bc35c17446 Major ppbus commit with:
+ ECP parallel port chipset FIFO detection
	+ DMA+FIFO parallel I/O handled as chipset specific
	+ nlpt updated in order to use the above enhanced parallel I/O.
	  Use 'lptcontrol -e' to use enhanced I/O
	+ Various options documented in LINT
	+ Full IEEE1284 NIBBLE and BYTE modes support. See ppbus(4) for
	  an overview of the IEEE1284 standard
	+ Detection of PnP parallel devices at boot
	+ Read capability added to nlpt driver to get IEEE1284 compliant
	  printer status with a simple 'cat /dev/lpt0'
	+ IEEE1284 peripheral emulation added to BYTE mode. Two computers
	  may dialog according to IEEE1284 signaling method.
	  See PERIPH_1284 option and /sys/dev/ppbus/ppi.c

All this code is supposed to provide basic functions for IEEE1284 programming.
ppi.c and nlpt.c may act as examples.
1999-01-10 12:04:56 +00:00
Nicolas Souchu
24063475b4 Fix Linux compatible mode. ppb_rxxx() calls are chars, inb() is int. 1999-01-09 18:10:37 +00:00
Nicolas Souchu
26af4d7d6a Fix the disappearing da0 problem.
Submited by: Doug Rabson <dfr@nlsystems.com>
1999-01-09 18:05:46 +00:00
Archie Cobbs
f1d19042b0 The "easy" fixes for compiling the kernel -Wunused: remove unreferenced static
and local variables, goto labels, and functions declared but not defined.
1998-12-07 21:58:50 +00:00