Home | History | Annotate | Download | only in dev
History log of /src/sys/arch/news68k/dev/zs.c
RevisionDateAuthorComments
 1.34  11-Sep-2021  andvar Add missing double p and d for stopped and overriden accordingly.
Fix few more typos along the way, mainly in copy-pasted comments.
 1.33  07-Aug-2021  thorpej Merge thorpej-cfargs2.
 1.32  24-Apr-2021  thorpej branches: 1.32.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.31  20-Nov-2011  tsutsui branches: 1.31.64;
Add preliminary PROM internal function based framebuffer console support,
which was demonstrated at Open Source Conference 2011 Kansai @ Kyoto
back in July:
http://www.NetBSD.org/gallery/events.html#opensourceconf2011-Kansai

- map 0xc0000000-0xffffffff PA region (which is mirror of PA 0x0-0x3fffffff)
to the same VA via %tt0 and %tt1 registers and move KVA space accordingly
(like luna68k does for its devices)
- save trap #0 vector for PROM function calls in early bootstrap
and register it to trap #14 to call it from kernel for console output
- add dumb romcall based tty attachment taken from src/sys/dev/ofw/ofcons.c
- add rom function call stubs from news68k/stand/common/romcalls.S
- remove IIOV() macro for device registers where now mapped PA==VA via %tt1

XXX: romcons is not enabled yet because there is no generic interface
XXX: to attach wskbd(4) to non wsdisplay(4) devices like this romcons.
 1.30  28-Apr-2008  martin branches: 1.30.34;
Remove clause 3 and 4 from TNF licenses
 1.29  29-Mar-2008  tsutsui branches: 1.29.2; 1.29.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.28  03-Dec-2007  ad branches: 1.28.14;
Interrupt handling changes, in discussion since February:

- Reduce available SPL levels for hardware devices to none, vm, sched, high.
- Acquire kernel_lock only for interrupts at IPL_VM.
- Implement threaded soft interrupts.
 1.27  09-Nov-2007  ad Call zs_lock_init() to set up the chanstate's lock.
 1.26  17-Oct-2007  garbled branches: 1.26.2;
Merge the ppcoea-renovation branch to HEAD.

This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the various ports to eliminate near-identical copies of files in
every tree. Additionally there is a new PIC system that unifies the
interface to interrupt code for all different OEA ppc arches. The work
for this branch was done by a variety of people, too long to list here.

TODO:
bebox still needs work to complete the transition to -renovation.
ofppc still needs a bunch of work, which I will be looking at.
ev64260 still needs to be renovated
amigappc was not attempted.

NOTES:
pmppc was removed as an arch, and moved to a evbppc target.
 1.25  20-May-2007  tsutsui branches: 1.25.8; 1.25.10; 1.25.14;
Call simple_lock_init(9) with proper zs_chanstate otherwise
LOCKDEBUG kernel fails during console zstty attachment.
 1.24  10-Feb-2007  tsutsui branches: 1.24.6; 1.24.8; 1.24.14;
Implement generic softintr(9) support for news68k.
Mostly taken from mvme68k.
 1.23  29-Mar-2006  thorpej Use device_cfdata().
 1.22  11-Dec-2005  christos branches: 1.22.4; 1.22.6; 1.22.8; 1.22.10; 1.22.12;
merge ktrace-lwp.
 1.21  02-Jun-2005  tsutsui branches: 1.21.2;
- add const
- u_char -> uint8_t
- sccport0a is not used as pointer, so make it uint32_t address
- idrom is stored in ROM, so make it const rather than volatile
 1.20  04-Sep-2004  tsutsui - Use ANSI function declarations and make some functions static.
- Some KNF
 1.19  04-Sep-2004  tsutsui Include ioconf.h to declare struct cfdriver.
 1.18  15-Jul-2003  lukem __KERNEL_RCSID()
 1.17  01-May-2003  tsutsui branches: 1.17.2;
Initialize struct consdev more properly.
 1.16  01-May-2003  tsutsui KNF
 1.15  11-Feb-2003  tsutsui Backout previous. <sys/lock.h> is pulled from <sys/tty.h>.
 1.14  10-Feb-2003  tsutsui MI z8530sc driver now requires <sys/lock.h>.
 1.13  28-Jan-2003  pk Provide locking required by the interrupt handlers running at IPL_SERIAL.
 1.12  11-Jan-2003  tsutsui Fix -Wsign-compare warnings.
 1.11  01-Jan-2003  thorpej Use aprint_normal() for cfprint routines.
 1.10  20-Dec-2002  tsutsui Remove __P().
 1.9  02-Oct-2002  thorpej Use CFATTACH_DECL().
 1.8  27-Sep-2002  thorpej Declare all cfattach structures const.
 1.7  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.6  07-Jul-2001  tsutsui branches: 1.6.2; 1.6.8; 1.6.16;
bcopy() -> memcpy() (I guess there is no overlap here)
 1.5  14-Oct-2000  tsutsui branches: 1.5.2;
- Initialize zs chip in zscninit() so that kernel can use
serial console even if the PROM uses bitmap console.
- Remove zs_hwflags since news68k does not have keyboard nor mouse at zs;
check zschan address set in zscninit() to detect console device.
- Use BPS_TO_TCONST() to set baudrate in zs_init_reg[].
- Remove zs_get_chan_addr(), which is not needed anymore.
 1.4  06-Mar-2000  thorpej branches: 1.4.4;
- Implement cnbell() -- ring the console bell. The cn_bell entrypoint
is optional.
- Add cn_bell to statically allocated consdevs as appropriate.
 1.3  08-Feb-2000  tsutsui Add news1200 support.
Based on a patch from Koichi NISHIWAKI <k-nis@ba2.so-net.ne.jp>
 1.2  29-Dec-1999  tsutsui Modify software interrupt handling a bit.
 1.1  09-Dec-1999  tsutsui branches: 1.1.2;
Initial import of news68k port.
 1.1.2.1  27-Dec-1999  wrstuden Pull up to last week's -current.
 1.4.4.1  15-Dec-2000  he Pull up revision 1.5 (requested by tsutsui):
Initialize zs chip in zscninit() so that the kernel can use serial
console even if the PROM uses bitmap console. Remove some dead
code. Use BPS_TO_TCONST() to initialize baudrate.
 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  14-Oct-2000  bouyer file zs.c was added on branch thorpej_scsipi on 2000-11-20 20:16:10 +0000
 1.6.16.1  19-May-2002  gehenna Replace the access to devsw table and the hard-coded majors with devsw API.
 1.6.8.6  15-Jan-2003  thorpej Sync with HEAD.
 1.6.8.5  03-Jan-2003  thorpej Sync with HEAD.
 1.6.8.4  29-Dec-2002  thorpej Sync with HEAD.
 1.6.8.3  18-Oct-2002  nathanw Catch up to -current.
 1.6.8.2  17-Sep-2002  nathanw Catch up to -current.
 1.6.8.1  07-Jul-2001  nathanw file zs.c was added on branch nathanw_sa on 2002-09-17 21:16:12 +0000
 1.6.2.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.17.2.4  10-Nov-2005  skrll Sync with HEAD. Here we go again...
 1.17.2.3  21-Sep-2004  skrll Fix the sync with head I botched.
 1.17.2.2  18-Sep-2004  skrll Sync with HEAD.
 1.17.2.1  03-Aug-2004  skrll Sync with HEAD
 1.21.2.5  07-Dec-2007  yamt sync with head
 1.21.2.4  15-Nov-2007  yamt sync with head.
 1.21.2.3  03-Sep-2007  yamt sync with head.
 1.21.2.2  26-Feb-2007  yamt sync with head.
 1.21.2.1  21-Jun-2006  yamt sync with head.
 1.22.12.1  31-Mar-2006  tron Merge 2006-03-31 NetBSD-current into the "peter-altq" branch.
 1.22.10.1  19-Apr-2006  elad sync with head - hopefully this will work
 1.22.8.1  01-Apr-2006  yamt sync with head.
 1.22.6.1  22-Apr-2006  simonb Sync with head.
 1.22.4.1  09-Sep-2006  rpaulo sync with head
 1.24.14.1  22-May-2007  matt Update to HEAD.
 1.24.8.1  11-Jul-2007  mjf Sync with head.
 1.24.6.2  03-Dec-2007  ad Sync with HEAD.
 1.24.6.1  27-May-2007  ad Sync with head.
 1.25.14.1  13-Nov-2007  bouyer Sync with HEAD
 1.25.10.2  09-Jan-2008  matt sync with HEAD
 1.25.10.1  06-Nov-2007  matt sync with HEAD
 1.25.8.2  09-Dec-2007  jmcneill Sync with HEAD.
 1.25.8.1  11-Nov-2007  joerg Sync with HEAD.
 1.26.2.2  08-Dec-2007  mjf Sync with HEAD.
 1.26.2.1  19-Nov-2007  mjf Sync with HEAD.
 1.28.14.2  02-Jun-2008  mjf Sync with HEAD.
 1.28.14.1  03-Apr-2008  mjf Sync with HEAD.
 1.29.4.1  16-May-2008  yamt sync with head.
 1.29.2.1  18-May-2008  yamt sync with head.
 1.30.34.1  17-Apr-2012  yamt sync with head
 1.31.64.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.32.8.1  04-Aug-2021  thorpej Adapt to CFARGS().

RSS XML Feed