Home | History | Annotate | Download | only in apbus
History log of /src/sys/arch/newsmips/apbus/zs_ap.c
RevisionDateAuthorComments
 1.32  07-Aug-2021  thorpej Merge thorpej-cfargs2.
 1.31  24-Apr-2021  thorpej branches: 1.31.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.30  19-Oct-2018  tsutsui branches: 1.30.14;
Reorganize APbus zs(4) console handling.

- set sccport0a address on early startup and use it for cnputc and cngetc
- explicitly initialize zs chip in the cninit function so that zs console
can be used even if it is not initialized by PROM firmware

Tested on both news50000 and news4000.
 1.29  14-Oct-2018  tsutsui Add NWS-4000 support.

Based on nonaka@'s porting effort back in 2002.
See announcement on port-newsmips@ for more details:
http://mail-index.netbsd.org/port-newsmips/2018/10/13/msg000231.html
 1.28  30-Sep-2018  tsutsui Avoid reference of APbus workarea that can't be read via kvm(3).
 1.27  26-Jun-2010  tsutsui branches: 1.27.58; 1.27.60;
Um, fix botch in previous.
 1.26  26-Jun-2010  tsutsui Pull a similar fix from sparc/dev/zs.c rev 1.119:
Establish interrupt handlers with proper softc per each zs device
rather than sharing them among all zs devices and searching softc
in handlers, to avoid possible recursive lock.
 1.25  28-Apr-2008  martin branches: 1.25.20; 1.25.22;
Remove clause 3 and 4 from TNF licenses
 1.24  29-Mar-2008  tsutsui branches: 1.24.2; 1.24.4;
Split softc and device_t for zsc(4) and its children.

XXX we should restructure MI APIs and make it really machine independent.
 1.23  26-Nov-2007  ad branches: 1.23.14;
Use the softint API.
 1.22  09-Nov-2007  ad Call zs_lock_init() to set up the chanstate's lock.
 1.21  08-Mar-2007  he branches: 1.21.2; 1.21.18; 1.21.20; 1.21.24; 1.21.26;
Cast to char* before doing pointer arithmetic.
 1.20  04-Mar-2007  christos Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.
 1.19  28-Mar-2006  thorpej branches: 1.19.14;
Use device_unit().
 1.18  11-Dec-2005  christos branches: 1.18.4; 1.18.6; 1.18.8; 1.18.10; 1.18.12;
merge ktrace-lwp.
 1.17  06-Feb-2005  tsutsui branches: 1.17.6;
Misc cleanup:
- ANSI function decls
- remove __P()
- u_intNN_t -> uintNN_t
- remove register decls
- bcopy -> memcpy, strcpy
- bzero -> memset
- bcmp -> memcmp
- use malloc(9) with M_ZERO
- some KNF
etc.
 1.16  15-Jul-2003  lukem branches: 1.16.8; 1.16.10;
__KERNEL_RCSID()
 1.15  25-May-2003  tsutsui branches: 1.15.2;
Add MI softintr(9) support with common mips/softintr.c.
 1.14  09-May-2003  tsutsui Remove bogus comments.
 1.13  26-Apr-2003  tsutsui - Move some common declarations into z8530var.h.
- Fix struct consdev properly.
- Remove register declarations.
- some more KNF.
 1.12  19-Apr-2003  tsutsui TAB/space cleanup.
 1.11  11-Feb-2003  tsutsui Backout previous. <sys/lock.h> is pulled from <sys/tty.h>.
 1.10  10-Feb-2003  tsutsui MI z8530sc driver now requires <sys/lock.h>.
 1.9  28-Jan-2003  pk Provide locking required by the interrupt handlers running at IPL_SERIAL.
 1.8  02-Oct-2002  thorpej Use CFATTACH_DECL().
 1.7  27-Sep-2002  thorpej Declare all cfattach structures const.
 1.6  06-Sep-2002  gehenna Merge the gehenna-devsw branch into the trunk.

This merge changes the device switch tables from static array to
dynamically generated by config(8).

- All device switches is defined as a constant structure in device drivers.

- The new grammer ``device-major'' is introduced to ``files''.

device-major <prefix> char <num> [block <num>] [<rules>]

- All device major numbers must be listed up in port dependent majors.<arch>
by using this grammer.

- Added the new naming convention.
The name of the device switch must be <prefix>_[bc]devsw for auto-generation
of device switch tables.

- The backward compatibility of loading block/character device
switch by LKM framework is broken. This is necessary to convert
from block/character device major to device name in runtime and vice versa.

- The restriction to assign device major by LKM is completely removed.
We don't need to reserve LKM entries for dynamic loading of device switch.

- In compile time, device major numbers list is packed into the kernel and
the LKM framework will refer it to assign device major number dynamically.
 1.5  12-Oct-2000  onoe branches: 1.5.2; 1.5.6; 1.5.10; 1.5.18;
change the type of the apbus interrupt handler from void to int
for each driver to indicate the interrupt has been handled or not.
 1.4  06-Mar-2000  thorpej - Implement cnbell() -- ring the console bell. The cn_bell entrypoint
is optional.
- Add cn_bell to statically allocated consdevs as appropriate.
 1.3  26-Dec-1999  tsubai Use software interrupt.
 1.2  23-Dec-1999  tsubai * Apply updates from Shimizu-san received after the initial commit.
* G/C unused.
* Many cosmetic changes.
* etc...
 1.1  22-Dec-1999  tsubai First cut of news5000 support.
Mostly from SHIMIZU Ryo <dejiko@di.gi.charat.org>.
 1.5.18.1  19-May-2002  gehenna Replace the access to devsw table and the hard-coded majors with devsw API.
 1.5.10.2  18-Oct-2002  nathanw Catch up to -current.
 1.5.10.1  17-Sep-2002  nathanw Catch up to -current.
 1.5.6.1  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.5.2.2  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.5.2.1  12-Oct-2000  bouyer file zs_ap.c was added on branch thorpej_scsipi on 2000-11-20 20:17:17 +0000
 1.15.2.4  06-Feb-2005  skrll Sync with HEAD.
 1.15.2.3  21-Sep-2004  skrll Fix the sync with head I botched.
 1.15.2.2  18-Sep-2004  skrll Sync with HEAD.
 1.15.2.1  03-Aug-2004  skrll Sync with HEAD
 1.16.10.1  12-Feb-2005  yamt sync with head.
 1.16.8.1  29-Apr-2005  kent sync with -current
 1.17.6.4  07-Dec-2007  yamt sync with head
 1.17.6.3  15-Nov-2007  yamt sync with head.
 1.17.6.2  03-Sep-2007  yamt sync with head.
 1.17.6.1  21-Jun-2006  yamt sync with head.
 1.18.12.1  31-Mar-2006  tron Merge 2006-03-31 NetBSD-current into the "peter-altq" branch.
 1.18.10.1  19-Apr-2006  elad sync with head - hopefully this will work
 1.18.8.1  01-Apr-2006  yamt sync with head.
 1.18.6.1  22-Apr-2006  simonb Sync with head.
 1.18.4.1  09-Sep-2006  rpaulo sync with head
 1.19.14.1  12-Mar-2007  rmind Sync with HEAD.
 1.21.26.2  08-Dec-2007  mjf Sync with HEAD.
 1.21.26.1  19-Nov-2007  mjf Sync with HEAD.
 1.21.24.1  13-Nov-2007  bouyer Sync with HEAD
 1.21.20.1  09-Jan-2008  matt sync with HEAD
 1.21.18.2  27-Nov-2007  joerg Sync with HEAD. amd64 Xen support needs testing.
 1.21.18.1  11-Nov-2007  joerg Sync with HEAD.
 1.21.2.1  03-Dec-2007  ad Sync with HEAD.
 1.23.14.2  02-Jun-2008  mjf Sync with HEAD.
 1.23.14.1  03-Apr-2008  mjf Sync with HEAD.
 1.24.4.2  11-Aug-2010  yamt sync with head.
 1.24.4.1  16-May-2008  yamt sync with head.
 1.24.2.1  18-May-2008  yamt sync with head.
 1.25.22.1  03-Jul-2010  rmind sync with head
 1.25.20.1  17-Aug-2010  uebayasi Sync with HEAD.
 1.27.60.1  10-Jun-2019  christos Sync with HEAD
 1.27.58.1  20-Oct-2018  pgoyette Sync with head
 1.30.14.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.31.8.1  04-Aug-2021  thorpej Adapt to CFARGS().

RSS XML Feed