Home | History | Annotate | Download | only in isa
History log of /src/sys/arch/i386/isa/lms.c
RevisionDateAuthorComments
 1.58  07-Aug-2021  thorpej Merge thorpej-cfargs2.
 1.57  24-Apr-2021  thorpej branches: 1.57.8;
Merge thorpej-cfargs branch:

Simplify and make extensible the config_search() / config_found() /
config_attach() interfaces: rather than having different variants for
which arguments you want pass along, just have a single call that
takes a variadic list of tag-value arguments.

Adjust all call sites:
- Simplify wherever possible; don't pass along arguments that aren't
actually needed.
- Don't be explicit about what interface attribute is attaching if
the device only has one. (More simplification.)
- Add a config_probe() function to be used in indirect configuiration
situations, making is visibly easier to see when indirect config is
in play, and allowing for future change in semantics. (As of now,
this is just a wrapper around config_match(), but that is an
implementation detail.)

Remove unnecessary or redundant interface attributes where they're not
needed.

There are currently 5 "cfargs" defined:
- CFARG_SUBMATCH (submatch function for direct config)
- CFARG_SEARCH (search function for indirect config)
- CFARG_IATTR (interface attribte)
- CFARG_LOCATORS (locators array)
- CFARG_DEVHANDLE (devhandle_t - wraps OFW, ACPI, etc. handles)

...and a sentinel value CFARG_EOL.

Add some extra sanity checking to ensure that interface attributes
aren't ambiguous.

Use CFARG_DEVHANDLE in MI FDT, OFW, and ACPI code, and macppc and shark
ports to associate those device handles with device_t instance. This
will trickle trough to more places over time (need back-end for pre-OFW
Sun OBP; any others?).
 1.56  01-Jul-2011  dyoung branches: 1.56.68;
#include <sys/bus.h> instead of <machine/bus.h>.
 1.55  04-May-2009  cegger struct device * -> device_t
No functional changes intended.
 1.54  09-Jul-2008  joerg branches: 1.54.8;
device/softc split.
 1.53  04-Apr-2008  cegger branches: 1.53.4; 1.53.6; 1.53.8; 1.53.10;
use aprint_*_dev and device_xname
OK joerg
 1.52  04-Mar-2007  christos branches: 1.52.40;
Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.
 1.51  16-Nov-2006  christos branches: 1.51.4;
__unused removal on arguments; approved by core.
 1.50  12-Nov-2006  plunky Tidy away wsmouse_input() abstractions and update
documentation to include the W direction.
 1.49  12-Oct-2006  christos - sprinkle __unused on function decls.
- fix a couple of unused bugs
- no more -Wno-unused for i386
 1.48  19-Feb-2006  thorpej branches: 1.48.14; 1.48.16;
Use aprint_*().
 1.47  11-Dec-2005  christos branches: 1.47.2; 1.47.4; 1.47.6;
merge ktrace-lwp.
 1.46  03-Feb-2005  perry branches: 1.46.6;
de-__P, partially ANSIfy
 1.45  14-Sep-2004  drochner branches: 1.45.4; 1.45.6;
adapt to ISA "unknown address" namespace separation
 1.44  02-Oct-2002  thorpej branches: 1.44.6;
Tidy up CFATTACH_DECL() formatting.
 1.43  01-Oct-2002  fvdl Merge Bill Sommerfeld's i386 MP branch. This code has some known
caveats, but works quite well in a lot of MP cases, and all
UP cases that I have tested. Parts of this will hopefully be
reworked in the not-too-distant future.
 1.42  27-Sep-2002  thorpej Declare all cfattach structures const.
 1.41  17-Mar-2002  atatat branches: 1.41.4;
Convert ioctl code to use EPASSTHROUGH instead of -1 or ENOTTY for
indicating an unhandled "command". ERESTART is -1, which can lead to
confusion. ERESTART has been moved to -3 and EPASSTHROUGH has been
placed at -4. No ioctl code should now return -1 anywhere. The
ioctl() system call is now properly restartable.
 1.40  07-Jan-2002  thorpej Overhaul of the ISA autoconfiguration code to support direct
configuration of devices logically attached to the ISA bus:

* Change the isa_attach_args to have arrays of io, mem, irq, drq
resources.
* Add a "pnpnames" and a linked list of "pnpcompatnames" to the
isa_attach_args. If either of these members are non-NULL,
direct configuration of the bus is being performed. Add an
ISA_DIRECT_CONFIG() macro to test for this.
* Drivers are not allowed to modify the isa_attach_args unless
direct configuration is not being performed and the probe fucntion
is returning success.
* Adapt device drivers -- currently, all driver probe routines return
"no match" if ISA_DIRECT_CONFIG() evaluates to true.
 1.39  15-Nov-2001  lukem add RCSID
 1.38  08-Jan-2000  takemura branches: 1.38.8; 1.38.10;
Absolute pointing device support.
- Wsmouse_input() get new argument 'flag', which indicates whether x/y/z are
relative or absolute.
- Wsmouse get new io controls, WSMOUSEIO_SCALIBCOORDS and
WSMOUSEIO_GCALIBCOORDS.
 1.37  23-Jan-1999  drochner branches: 1.37.8;
make the busmice work with wscons
 1.36  25-Aug-1998  thorpej Add some braces to make egcs happy.
 1.35  15-Aug-1998  mycroft Make copyright notices with my name consistent.
 1.34  22-Mar-1998  drochner switch to non-BROKEN_INDIRECT_CONFIG
 1.33  12-Jan-1998  thorpej Update for changes to config.
 1.32  19-Oct-1997  mycroft Minor changes to make these more similar again.
 1.31  19-Oct-1997  thorpej Make sure the i/o and/or mem addresses aren't wildcarded (i.e. -1) before
using the address in a bus_space_map() call.
 1.30  21-Oct-1996  thorpej New bus.h implementation/interface:
- No more distinction between i/o-mapped and memory-mapped
devices. It's all "bus space" now, and space tags
differentiate the space with finer grain than the
bus chipset tag.
- Add memory barrier methods.
- Implement space alloc/free methods.
- Implement region read/write methods (like memcpy to/from
bus space).
This interface provides a better abstraction for dealing with
machine-independent chipset drivers.
 1.29  13-Oct-1996  christos backout previous kprintf changes
 1.28  11-Oct-1996  christos printf -> kprintf, sprintf -> ksprintf
 1.27  07-Sep-1996  mycroft Implement poll(2).
 1.26  12-May-1996  mycroft Use intr.h.
 1.25  03-May-1996  christos Prototype fixes.
 1.24  11-Apr-1996  cgd update for addition of a machine-dependent cookie as the first argument
to isa_intr_{,dis}establish().
 1.23  09-Apr-1996  thorpej Convert to use <machine/bus.h>.
 1.22  17-Mar-1996  thorpej New device attachment scheme:

- split softc size and match/attach out from cfdriver into
a new struct cfattach.

- new "attach" directive for files.*. May specify the name of
the cfattach structure, so that devices may be easily attached
to parents with different autoconfiguration semantics.
 1.21  24-Dec-1995  mycroft The IST_* and IPL_* constants are not bus-specific; don't treat them as such.
Change splimp -> splnet in Ethernet, ARCnet, and FDDI drivers.
 1.20  05-Oct-1995  mycroft Use ISA_IPL_TTY, to fix race conditions.
 1.19  17-Apr-1995  cgd clean up several ISA device interfaces: autoconfiguration, header
inclusion, and interrupt configuration. more work still needs to be done,
but it's getting better...
 1.18  03-Jan-1995  mycroft Add interrupt sharing types.
 1.17  18-Nov-1994  mycroft Convert port, IRQ, and DRQ numbers to ints.
 1.16  03-Nov-1994  mycroft Update to match autoconfig code.
 1.15  30-Oct-1994  cgd be more careful with types, also pull in headers where necessary.
 1.14  27-Oct-1994  cgd new RCS ID format.
 1.13  05-May-1994  cgd lots of changes: prototype migration, move lots of variables, definitions,
and structure elements around. kill some unnecessary type and macro
definitions. standardize clock handling. More changes than you'd want.
 1.12  07-Apr-1994  mycroft Implement dynamic IRQ configuration and IRQ sharing. Inline spl*() calls.
Reorganize and clean up the relevant code.
 1.11  30-Mar-1994  mycroft Minor fix to attach messages.
 1.10  29-Mar-1994  mycroft Updates for new autoconfig.
 1.9  06-Mar-1994  mycroft DELAY() --> delay(). This is not a macro.
 1.8  17-Feb-1994  mycroft New versions from magnum branch.
 1.7  20-Dec-1993  mycroft Canonicalize all #includes, and add pio.h where appropriate.
 1.6  02-Aug-1993  mycroft branches: 1.6.2;
Add RCS identifiers, remove some completely useless RCS logs and patchkit
headers, and a few other insignificant changes.
 1.5  27-Jun-1993  andrew Replaced 386BSD conditionals with a NetBSD ones. Fixed a bug in 386BSD
support. Cast arguments to tsleep() and wakeup() to avoid compiler
warnings.
 1.4  14-Jun-1993  mycroft These mice use 4 ports.
 1.3  14-Jun-1993  mycroft Work around a bug in XFree86.
 1.2  14-Jun-1993  mycroft Return EBUSY if device already open.
 1.1  13-Jun-1993  andrew Logitech busmouse driver.
 1.6.2.14  31-Oct-1993  mycroft Turn off interrupts before *forceintr to insure we get an edge.
 1.6.2.13  17-Oct-1993  mycroft No need to stay at spltty() while transferring event data.
 1.6.2.12  16-Oct-1993  mycroft Add missing dv_class entry to cfdrivers, and use dv_xname where appropriate.
 1.6.2.11  12-Oct-1993  mycroft Minor cleanup.
 1.6.2.10  11-Oct-1993  mycroft #include pio.h where needed, and remove cpufunc.h.
 1.6.2.9  07-Oct-1993  mycroft Don't #include isa.h.
 1.6.2.8  06-Oct-1993  mycroft Use standard ring buffer implementation. Use normal read() flag rather than
bit in minor number for non-blocking mode.
 1.6.2.7  01-Oct-1993  mycroft #include "machine/cpu.h"
 1.6.2.6  30-Sep-1993  mycroft Change some uses of IRQUNK to IRQNONE. #include isa.h and icu.h.
 1.6.2.5  30-Sep-1993  mycroft clock.c: Remove unnecessary casts.
com.c: Update for new config. Add bis() and bic() macros like BSDI's.
Add comspeed() and tiocm_xxx2mcr() from BSDI.
comreg.h: Add COM_FREQ, COM_TOLERANCE, and COM_NPORTS.
fd.c: Remove casts and clean up fdioctl().
[lm]ms.c: Add necessary gunk to [lm]ms_softc and remove casts.
 1.6.2.4  29-Sep-1993  mycroft lms.c: Remove sc_button.
mms.c: Reclone from lms.c.
 1.6.2.3  29-Sep-1993  mycroft BLOCK --> NOBLOCK.
 1.6.2.2  29-Sep-1993  mycroft Reset ASLP flag if we get a signal while sleeping in lmsread().
 1.6.2.1  29-Sep-1993  mycroft lms.c: Update for new config.
lpa.c: Defunct.
lpt.c: Update for new config. Fix handling of interrupted writes. Merge code
from lpa driver. Make all operations interruptible. Remove a few other
bogons.
lptreg.h: Add LPT_NPORTS.
pccons.c: Merge changes from trunk.
 1.37.8.1  20-Nov-2000  bouyer Update thorpej_scsipi to -current as of a month ago
A i386 GENERIC kernel compiles without the siop, ahc and bha drivers
(will be updated later). i386 IDE/ATAPI and ncr work, as well as
sparc/esp_sbus. alpha should work as well (untested yet).
siop, ahc and bha will be updated once I've updated the branch to current
-current, as well as machine-dependant code.
 1.38.10.3  10-Oct-2002  jdolecek sync kqueue with -current; this includes merge of gehenna-devsw branch,
merge of i386 MP branch, and part of autoconf rototil work
 1.38.10.2  23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.38.10.1  10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.38.8.5  18-Oct-2002  nathanw Catch up to -current.
 1.38.8.4  01-Apr-2002  nathanw Catch up to -current.
(CVS: It's not just a program. It's an adventure!)
 1.38.8.3  28-Feb-2002  nathanw Catch up to -current.
 1.38.8.2  11-Jan-2002  nathanw More catchup.
 1.38.8.1  08-Jan-2002  nathanw Catch up to -current.
 1.41.4.2  17-Mar-2002  atatat Convert ioctl code to use EPASSTHROUGH instead of -1 or ENOTTY for
indicating an unhandled "command". ERESTART is -1, which can lead to
confusion. ERESTART has been moved to -3 and EPASSTHROUGH has been
placed at -4. No ioctl code should now return -1 anywhere. The
ioctl() system call is now properly restartable.
 1.41.4.1  17-Mar-2002  atatat file lms.c was added on branch sommerfeld_i386mp_1 on 2002-03-17 19:40:42 +0000
 1.44.6.4  04-Feb-2005  skrll Sync with HEAD.
 1.44.6.3  18-Dec-2004  skrll Sync with HEAD.
 1.44.6.2  21-Sep-2004  skrll Fix the sync with head I botched.
 1.44.6.1  18-Sep-2004  skrll Sync with HEAD.
 1.45.6.1  12-Feb-2005  yamt sync with head.
 1.45.4.1  29-Apr-2005  kent sync with -current
 1.46.6.3  03-Sep-2007  yamt sync with head.
 1.46.6.2  30-Dec-2006  yamt sync with head.
 1.46.6.1  21-Jun-2006  yamt sync with head.
 1.47.6.1  22-Apr-2006  simonb Sync with head.
 1.47.4.1  09-Sep-2006  rpaulo sync with head
 1.47.2.1  01-Mar-2006  yamt sync with head.
 1.48.16.2  10-Dec-2006  yamt sync with head.
 1.48.16.1  22-Oct-2006  yamt sync with head
 1.48.14.1  18-Nov-2006  ad Sync with head.
 1.51.4.1  12-Mar-2007  rmind Sync with HEAD.
 1.52.40.2  28-Sep-2008  mjf Sync with HEAD.
 1.52.40.1  02-Jun-2008  mjf Sync with HEAD.
 1.53.10.1  19-Oct-2008  haad Sync with HEAD.
 1.53.8.1  18-Jul-2008  simonb Sync with head.
 1.53.6.1  18-Sep-2008  wrstuden Sync with wrstuden-revivesa-base-2.
 1.53.4.2  16-May-2009  yamt sync with head
 1.53.4.1  04-May-2009  yamt sync with head.
 1.54.8.3  27-Aug-2011  jym Sync with HEAD. Most notably: uvm/pmap work done by rmind@, and MP Xen
work of cherry@.

No regression observed on suspend/restore.
 1.54.8.2  01-Nov-2009  jym Sync with HEAD.
 1.54.8.1  13-May-2009  jym Sync with HEAD.

Commit is split, to avoid a "too many arguments" protocol error.
 1.56.68.1  21-Mar-2021  thorpej Give config_found() the same variadic arguments treatment as
config_search(). This commit only adds the CFARG_EOL sentinel
to the existing config_found() calls. Conversion of config_found_sm_loc()
and config_found_ia() call sites will be in subsequent commits.
 1.57.8.1  04-Aug-2021  thorpej Adapt to CFARGS().

RSS XML Feed