Home | History | Annotate | only in /src/sys/arch/newsmips/include
History log of /src/sys/arch/newsmips/include
RevisionDateAuthorComments
 1.39 30-Nov-2024  christos Create a new header lwp_private.h to contain _lwp_getprivate_fast,
_lwp_gettcb_fast, _lwp_settcb and remove them from mcontext.h, so that:
1. we don't need special hacks to hide them
2. we can include <lwp.h> where needed to get the necessary prototypes
without redefining them locally.
 1.38 12-Jul-2018  maxv branches: 1.38.36;
Remove the kernel PMC code. Sent yesterday on tech-kern@.

This change:

* Removes "options PERFCTRS", the associated includes, and the associated
ifdefs. In doing so, it removes several XXXSMPs in the MI code, which is
good.

* Removes the PMC code of ARM XSCALE.

* Removes all the pmc.h files. They were all empty, except for ARM XSCALE.

* Reorders the x86 PMC code not to rely on the legacy pmc.h file. The
definitions are put in sysarch.h.

* Removes the kern/sys_pmc.c file, and along with it, the sys_pmc_control
and sys_pmc_get_info syscalls. They are marked as OBSOL in kern,
netbsd32 and rump.

* Removes the pmc_evid_t and pmc_ctr_t types.

* Removes all the associated man pages. The sets are marked as obsolete.
 1.37 21-Dec-2015  christos branches: 1.37.16; 1.37.18;
Add mips fenv.h (From FreeBSD)
 1.36 23-Jul-2014  alnsn branches: 1.36.4;
Rename sljitarch.h to sljit_machdep.h.
 1.35 25-Nov-2012  alnsn branches: 1.35.10;
Add sljitarch.h to all mips machines.
 1.34 17-Jul-2011  joerg branches: 1.34.2; 1.34.12;
Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
 1.33 12-Aug-2009  matt Nuke a.out support for MIPS.
 1.32 18-Feb-2007  tsutsui branches: 1.32.46;
Install mutex.h and rwlock.h.
 1.31 26-Jul-2006  drochner branches: 1.31.10;
don't install <machine/db_machdep.h>, this is kernel only
 1.30 11-Dec-2005  christos branches: 1.30.4; 1.30.8;
merge ktrace-lwp.
 1.29 01-Aug-2004  uch branches: 1.29.12;
add NEWSMIPS_WSDISPLAYIO_GINFO ioctl to get frame buffer stride.
 1.28 08-May-2004  kleink Factor out W{CHAR,INT}_{MAX,MIN} into their own header file.
 1.27 18-Jan-2003  thorpej branches: 1.27.2;
Merge the nathanw_sa branch.
 1.26 26-Nov-2002  lukem Remove KDIR=, since SYS_INCLUDE=symlinks and KDIR are not supported any more.
 1.25 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.24 07-Aug-2002  briggs Implement pmc(9) -- An interface to hardware performance monitoring
counters. These counters do not exist on all CPUs, but where they
do exist, can be used for counting events such as dcache misses that
would otherwise be difficult or impossible to instrument by code
inspection or hardware simulation.

pmc(9) is meant to be a general interface. Initially, the Intel XScale
counters are the only ones supported.
 1.23 11-Jul-2002  jdolecek do not install apbus.h, apcall.h, romcall.h
 1.22 15-Apr-2001  kleink branches: 1.22.2; 1.22.8; 1.22.16; 1.22.18;
Add definitions of C99 integer format conversion macros.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.21 15-Apr-2001  kleink Add definitions of C99 specified-width integer type limits.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.20 14-Apr-2001  kleink Add definitions of C99 integer constant macros.
Tidy Makefiles up a little.
 1.19 14-Apr-2001  kleink Add definitions of C99 minimum-width and greatest-width integer types.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.18 13-Nov-2000  tsubai branches: 1.18.2;
No longer used.
 1.17 26-Jun-2000  kleink Add <machine/int_types.h>, which provides namespace-pure definitions
of exact-width integer types.
 1.16 29-Apr-2000  thorpej Require that each each MACHINE/MACHINE_ARCH supply a lock.h. This file
contains the values __SIMPLELOCK_LOCKED and __SIMPLELOCK_UNLOCKED, which
replace the old SIMPLELOCK_LOCKED and SIMPLELOCK_UNLOCKED. These files
are also required to supply inline functions __cpu_simple_lock(),
__cpu_simple_lock_try(), and __cpu_simple_unlock() if locking is to be
supported on that platform (i.e. if MULTIPROCESSOR is defined in the
_KERNEL case). Change these functions to take an int * (&alp->lock_data)
rather than the struct simplelock * itself.

These changes make it possible for userland to use the locking primitives
by including <machine/lock.h>.
 1.15 30-Mar-2000  soren Add asm.h like other ports.
 1.14 17-Mar-2000  tron Install "machineendian_machdep.h".
 1.13 23-Dec-1999  kleink C99: Define a NAN macro in <math.h> which evaulates to a constant expression of
a single-precision quiet NaN; only to be defined on platforms that do support
this value.
 1.12 22-Dec-1999  tsubai First cut of news5000 support.
Mostly from SHIMIZU Ryo <dejiko@di.gi.charat.org>.
 1.11 09-Nov-1999  kleink Per discussion on tech-toolchain, remove MIPS-specific <machine/elf.h> header;
all the information is available from <sys/exec_elf.h>.
 1.10 30-Aug-1999  mrg branches: 1.10.2; 1.10.4; 1.10.8;
install ieee.h
 1.9 08-Jul-1999  tsubai Define ROM monitor interfaces.
 1.8 30-Mar-1999  soda branches: 1.8.4;
regdef.h
 1.7 13-Mar-1999  drochner g/c regdef.h
 1.6 17-Feb-1999  tsubai Use mips/varargs.h.
 1.5 12-Feb-1999  tsubai Add missing backslash.
 1.4 31-Jan-1999  castor Remove genpubasym.cf stuff
 1.3 15-Jan-1999  bouyer Move the bswap functions from libutil to libc (this bups the
minor of libc and the major of libutil). For little-endian architectures
merge the bnswap() assembly versions with nto* and hton* using symbols
aliasing. Use symbol renaming for the bswap function in this case to avoid
namespace pollution.
Declare bswap* in machine/bswap.h, not machine/endian.h. For little-endian
machines, common code for inline macros go in machine/byte_swap.h
Sync libkern with libc.
Adjust #include in kernel sources for machine/bswap.h.
 1.2 15-Jan-1999  castor allow generated kernel includes and support mips pubassym.cf mechanism
 1.1 12-Jun-1998  cgd Rework the way kernel include files are installed. In the new method,
as with user-land programs, include files are installed by each directory
in the tree that has includes to install. (This allows more flexibility
as to what gets installed, makes 'partial installs' easier, and gives us
more options as to which machines' includes get installed at any given
time.) The old SYS_INCLUDES={symlinks,copies} behaviours are _both_
still supported, though at least one bug in the 'symlinks' case is
fixed by this change. Include files can't be build before installation,
so directories that have includes as targets (e.g. dev/pci) have to move
those targets into a different Makefile.
 1.8.4.1 02-Aug-1999  thorpej Update from trunk.
 1.10.8.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.10.4.1 15-Nov-1999  fvdl Sync with -current
 1.10.2.3 21-Apr-2001  bouyer Sync with HEAD
 1.10.2.2 22-Nov-2000  bouyer Sync with HEAD.
 1.10.2.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.18.2.1 21-Jun-2001  nathanw Catch up to -current.
 1.22.18.1 11-Jul-2002  thorpej pullup-1-6 ticket #479 (jdolecek).

Original log message:
do not install apbus.h, apcall.h, romcall.h
 1.22.16.3 31-Aug-2002  gehenna catch up with -current.
 1.22.16.2 16-Jul-2002  gehenna catch up with -current.
 1.22.16.1 19-May-2002  gehenna Remove port-dependent conf.h.
 1.22.8.6 11-Dec-2002  thorpej Sync with HEAD.
 1.22.8.5 17-Sep-2002  nathanw Catch up to -current.
 1.22.8.4 13-Aug-2002  nathanw Catch up to -current.
 1.22.8.3 01-Aug-2002  nathanw Catch up to -current.
 1.22.8.2 17-Nov-2001  wdk mcontext support for MIPS based ports.
 1.22.8.1 15-Apr-2001  wdk file Makefile was added on branch nathanw_sa on 2001-11-17 23:12:10 +0000
 1.22.2.2 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.22.2.1 06-Sep-2002  jdolecek sync kqueue branch with HEAD
 1.27.2.4 21-Sep-2004  skrll Fix the sync with head I botched.
 1.27.2.3 18-Sep-2004  skrll Sync with HEAD.
 1.27.2.2 05-Aug-2004  skrll Fix some merge mistakes.
 1.27.2.1 03-Aug-2004  skrll Sync with HEAD
 1.29.12.2 26-Feb-2007  yamt sync with head.
 1.29.12.1 30-Dec-2006  yamt sync with head.
 1.30.8.1 11-Aug-2006  yamt sync with head
 1.30.4.1 09-Sep-2006  rpaulo sync with head
 1.31.10.1 27-Feb-2007  yamt - sync with head.
- move sched_changepri back to kern_synch.c as it doesn't know PPQ anymore.
 1.32.46.1 19-Aug-2009  yamt sync with head.
 1.34.12.3 03-Dec-2017  jdolecek update from HEAD
 1.34.12.2 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.34.12.1 25-Feb-2013  tls resync with head
 1.34.2.1 16-Jan-2013  yamt sync with (a bit old) head
 1.35.10.1 10-Aug-2014  tls Rebase.
 1.36.4.1 27-Dec-2015  skrll Sync with HEAD (as of 26th Dec)
 1.37.18.1 10-Jun-2019  christos Sync with HEAD
 1.37.16.1 28-Jul-2018  pgoyette Sync with HEAD
 1.38.36.1 02-Aug-2025  perseant Sync with HEAD
 1.9 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.8 11-Dec-2005  christos branches: 1.8.164; 1.8.166;
merge ktrace-lwp.
 1.7 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.
 1.6 18-Oct-2000  onoe branches: 1.6.24;
Move APbus dependent unmapped DMA address stuff from bus.c to apbus.c
Support DMA mapping table with NEWSMIPS_DMAMAP_MAPTBL flag for APbus
(MAPTBL is not tested yet).
 1.5 12-Oct-2000  onoe Add address for free running 1MHz 1counter.
Add registers for APbus I/F gatearray.
 1.4 23-Dec-1999  tsubai * Apply updates from Shimizu-san received after the initial commit.
* G/C unused.
* Many cosmetic changes.
* etc...
 1.3 22-Dec-1999  tsubai First cut of news5000 support.
Mostly from SHIMIZU Ryo <dejiko@di.gi.charat.org>.
 1.2 15-Feb-1999  hubertf branches: 1.2.8;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.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.6.24.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.6.24.2 18-Sep-2004  skrll Sync with HEAD.
 1.6.24.1 03-Aug-2004  skrll Sync with HEAD
 1.8.166.1 10-Jun-2019  christos Sync with HEAD
 1.8.164.1 20-Oct-2018  pgoyette Sync with head
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2 12-Aug-2009  matt Nuke a.out support for MIPS.
 1.1 18-Feb-1998  tsubai branches: 1.1.154; 1.1.168;
Initial import of NetBSD/news.
 1.1.168.1 24-Oct-2010  jym Sync with HEAD
 1.1.154.1 19-Aug-2009  yamt sync with head.
 1.7 19-Oct-2018  tsutsui 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.6 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.5 11-Dec-2005  christos branches: 1.5.164; 1.5.166;
merge ktrace-lwp.
 1.4 06-Feb-2005  tsutsui 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.3 03-Dec-2000  matt branches: 1.3.24; 1.3.32; 1.3.34;
Make this stuff compile with -wstrict-prototpes -wmissing-prototypes.
More use of prototypes inside includes should be done.
 1.2 23-Dec-1999  tsubai branches: 1.2.6;
* 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.2.6.3 08-Dec-2000  bouyer Sync with HEAD.
 1.2.6.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.2.6.1 23-Dec-1999  bouyer file apbus.h was added on branch thorpej_scsipi on 2000-11-20 20:17:23 +0000
 1.3.34.1 12-Feb-2005  yamt sync with head.
 1.3.32.1 29-Apr-2005  kent sync with -current
 1.3.24.1 06-Feb-2005  skrll Sync with HEAD.
 1.5.166.1 10-Jun-2019  christos Sync with HEAD
 1.5.164.1 20-Oct-2018  pgoyette Sync with head
 1.3 13-Apr-2002  tsutsui Add some ioctl() definitions to eject floppy.
 1.2 23-Dec-1999  tsubai branches: 1.2.6; 1.2.10; 1.2.14;
* 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.2.14.1 17-Apr-2002  nathanw Catch up to -current.
 1.2.10.1 23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.2.6.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.2.6.1 23-Dec-1999  bouyer file apcall.h was added on branch thorpej_scsipi on 2000-11-20 20:17:23 +0000
 1.1 30-Mar-2000  soren branches: 1.1.6;
Add asm.h like other ports.
 1.1.6.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.1.6.1 30-Mar-2000  bouyer file asm.h was added on branch thorpej_scsipi on 2000-11-20 20:17:23 +0000
 1.9 09-May-2003  tsutsui - Define and use struct hb_attach_args rather than struct confargs
for hb devices.
- Move declarations for hb functions and macros to dev/hbvar.h.
- Define and use hb_badaddr() macro for hb devices.
- Declare news3400_badaddr() in machine/cpu.h rather than machine/autoconf.h.
- Remove unused stuff from machine/autoconf.h.
 1.8 22-Mar-2003  simonb Fix a grammatical nit.
 1.7 09-Oct-2002  jdolecek make ca_name of struct confargs const
 1.6 17-Dec-1999  tsubai branches: 1.6.8; 1.6.12;
Add interrupt level locator and use it instead of hard-coding.
 1.5 17-Dec-1999  tsubai Implement hb_intr_establish().
 1.4 17-Oct-1999  tsubai branches: 1.4.2;
Rearrange splxxx (from pmax). Closes PR 8445.
 1.3 06-Oct-1998  thorpej branches: 1.3.12;
configure() prototype is in <sys/device.h>
 1.2 05-Jun-1998  tsubai Add support for NWB-231A 4-port RS-232C card.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3.12.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.4.2.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.6.12.1 18-Oct-2002  nathanw Catch up to -current.
 1.6.8.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.4 11-Dec-2005  christos merge ktrace-lwp.
 1.3 06-Feb-2005  tsutsui 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.2 24-Mar-2004  drochner branches: 1.2.8; 1.2.10;
remove license clauses 3 and 4 from my cpoyright notices
 1.1 18-Dec-1999  tsubai branches: 1.1.2; 1.1.8; 1.1.32;
Introduce bootinfo.
 1.1.32.4 06-Feb-2005  skrll Sync with HEAD.
 1.1.32.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.1.32.2 18-Sep-2004  skrll Sync with HEAD.
 1.1.32.1 03-Aug-2004  skrll Sync with HEAD
 1.1.8.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.1.8.1 18-Dec-1999  bouyer file bootinfo.h was added on branch thorpej_scsipi on 2000-11-20 20:17:24 +0000
 1.1.2.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.2.10.1 12-Feb-2005  yamt sync with head.
 1.2.8.1 29-Apr-2005  kent sync with -current
 1.3 12-Aug-2009  matt Nuke a.out support for MIPS.
 1.2 04-Sep-2001  simonb branches: 1.2.6; 1.2.128; 1.2.142;
Remove comment duplicated in <mips/bsd-aout.h>.
 1.1 18-Feb-1998  tsubai branches: 1.1.28;
Initial import of NetBSD/news.
 1.1.28.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.2.142.1 24-Oct-2010  jym Sync with HEAD
 1.2.128.1 19-Aug-2009  yamt sync with head.
 1.2.6.2 04-Sep-2001  simonb Remove comment duplicated in <mips/bsd-aout.h>.
 1.2.6.1 04-Sep-2001  simonb file bsd-aout.h was added on branch nathanw_sa on 2001-09-04 07:36:12 +0000
 1.1 15-Jan-1999  bouyer Move the bswap functions from libutil to libc (this bups the
minor of libc and the major of libutil). For little-endian architectures
merge the bnswap() assembly versions with nto* and hton* using symbols
aliasing. Use symbol renaming for the bswap function in this case to avoid
namespace pollution.
Declare bswap* in machine/bswap.h, not machine/endian.h. For little-endian
machines, common code for inline macros go in machine/byte_swap.h
Sync libkern with libc.
Adjust #include in kernel sources for machine/bswap.h.
 1.23 23-Jan-2021  christos Remove cargo-culted '#if 0' code that was designed to produce a
compile-time error if any of the bus_space_*_8 functions was used,
but was documented that it produces a link-time error.
 1.22 02-Apr-2020  msaitoh branches: 1.22.4;
s/impliment/implement/ in comment.
 1.21 23-Sep-2019  skrll Provide PRIxBUSADDR, PRIxBUSSIZE, PRIuBUSSIZE, and PRIxBSH for all arches
to follow arm and (generic) mips.

Reviewed by christos.
 1.20 12-Feb-2012  matt branches: 1.20.48;
Change old-style function defintions to C89 prototypes.

Approved by releng.
 1.19 28-Apr-2008  martin branches: 1.19.34; 1.19.38;
Remove clause 3 and 4 from TNF licenses
 1.18 04-Mar-2007  christos branches: 1.18.40; 1.18.42; 1.18.44;
Kill caddr_t; there will be some MI fallout, but it will be fixed shortly.
 1.17 21-Feb-2007  mrg add a pair of new bus_dma(9) functions:
int _bus_dmatag_subregion(bus_dma_tag_t tag,
bus_addr_t min_addr,
bus_addr_t max_addr,
bus_dma_tag_t *newtag,
int flags)
void _bus_dmatag_destroy(bus_dma_tag_t tag)

that allow a (normally broken/limited) device to restrict the bus address
range it can talk to. this is used by bce(4) to limit DMA addresses to
1GB range, the maximum the chip can address.

all this is from Yorick Hardy <yhardy@uj.ac.za> with input from several
people on tech-kern.

XXX: bus_dma(9) needs an update still.
 1.16 26-May-2006  tsutsui branches: 1.16.12;
Tweak bus_space_barrier(9) macro to appease
"left-hand operand of comma expression has no effect"
warnings by gcc4.
 1.15 01-Mar-2006  yamt branches: 1.15.2; 1.15.8;
merge yamt-uio_vmspace branch.

- use vmspace rather than proc or lwp where appropriate.
the latter is more natural to specify an address space.
(and less likely to be abused for random purposes.)
- fix a swdmover race.
 1.14 16-Feb-2006  perry Change "inline" back to "__inline" in .h files -- C99 is still too
new, and some apps compile things in C89 mode. C89 keywords stay.

As per core@.
 1.13 24-Dec-2005  perry branches: 1.13.2; 1.13.4; 1.13.6;
Remove leading __ from __(const|inline|signed|volatile) -- it is obsolete.
 1.12 11-Dec-2005  christos merge ktrace-lwp.
 1.11 09-Mar-2005  matt branches: 1.11.4;
Add a dm_maxsegsz public member to bus_dmamap_t. This allows a user of the API
to select the maximum segment size for each bus_dmamap_load (up to the maxsegsz
supplied to bus_dmamap_create). dm_maxsegsz is reset to the value supplied to
bus_dmamap_create when the dmamap is unloaded.
 1.10 06-Feb-2005  tsutsui one more u_intNN_t -> uintNN_t
 1.9 06-Feb-2005  tsutsui 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.8 15-Jun-2003  fvdl branches: 1.8.2; 1.8.10; 1.8.12;
Handle 64bit DMA addresses on PCI for platforms that can (currently only
enabled on amd64). Add a dmat64 field to various PCI attach structures,
and pass it down where needed. Implement a simple new function called
pci_dma64_available(pa) to test if 64bit DMA addresses may be used.
This returns 1 iff _PCI_HAVE_DMA64 is defined in <machine/pci_machdep.h>,
and there is more than 4G of memory.
 1.7 28-Jan-2003  kent Introduce BUS_DMA_NOCACHE, and bus_dmamem_map() of i386 supports it.
 1.6 17-Mar-2002  simonb Make sure that private DMA flags don't overlap with standard DMA flags;
start these at 0x10000 to leave room for an increase in the latter.
 1.5 14-Nov-2001  thorpej branches: 1.5.2;
Merge the thorpej-mips-cache branch onto the trunk. This is an
overhaul of how caches are handled for NetBSD's MIPS ports.
 1.4 19-Jul-2001  thorpej branches: 1.4.4;
Add BUS_DMA_READ and BUS_DMA_WRITE flags, that hint the back-end
at dmamap load time that the mapping will be used for a unidirectional
transfer of the specified direction.
 1.3 07-Mar-2001  thorpej branches: 1.3.2;
Add the BUS_DMA_STREAMING flag.
 1.2 18-Oct-2000  onoe branches: 1.2.2; 1.2.4;
Move APbus dependent unmapped DMA address stuff from bus.c to apbus.c
Support DMA mapping table with NEWSMIPS_DMAMAP_MAPTBL flag for APbus
(MAPTBL is not tested yet).
 1.1 12-Oct-2000  onoe Bus I/O and DMA access macros/routines.
 1.2.4.1 09-Apr-2001  nathanw Catch up with -current.
 1.2.2.3 12-Mar-2001  bouyer Sync with HEAD.
 1.2.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.2.2.1 18-Oct-2000  bouyer file bus.h was added on branch thorpej_scsipi on 2000-11-20 20:17:24 +0000
 1.3.2.3 23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.3.2.2 10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.3.2.1 03-Aug-2001  lukem update to -current
 1.4.4.1 13-Nov-2001  thorpej Make the newsmips port compile with the thorpej-mips-cache branch.
 1.5.2.2 01-Apr-2002  nathanw Catch up to -current.
(CVS: It's not just a program. It's an adventure!)
 1.5.2.1 14-Nov-2001  nathanw file bus.h was added on branch nathanw_sa on 2002-04-01 07:41:42 +0000
 1.8.12.2 19-Mar-2005  yamt sync with head. xen and whitespace. xen part is not finished.
 1.8.12.1 12-Feb-2005  yamt sync with head.
 1.8.10.1 29-Apr-2005  kent sync with -current
 1.8.2.2 01-Apr-2005  skrll Sync with HEAD.
 1.8.2.1 06-Feb-2005  skrll Sync with HEAD.
 1.11.4.3 03-Sep-2007  yamt sync with head.
 1.11.4.2 26-Feb-2007  yamt sync with head.
 1.11.4.1 21-Jun-2006  yamt sync with head.
 1.13.6.2 01-Jun-2006  kardel Sync with head.
 1.13.6.1 22-Apr-2006  simonb Sync with head.
 1.13.4.1 09-Sep-2006  rpaulo sync with head
 1.13.2.2 18-Feb-2006  yamt _dm_proc -> _dm_vmspace.
 1.13.2.1 18-Feb-2006  yamt sync with head.
 1.15.8.1 19-Jun-2006  chap Sync with head.
 1.15.2.1 26-Jun-2006  yamt sync with head.
 1.16.12.2 12-Mar-2007  rmind Sync with HEAD.
 1.16.12.1 27-Feb-2007  yamt - sync with head.
- move sched_changepri back to kern_synch.c as it doesn't know PPQ anymore.
 1.18.44.1 16-May-2008  yamt sync with head.
 1.18.42.1 18-May-2008  yamt sync with head.
 1.18.40.1 02-Jun-2008  mjf Sync with HEAD.
 1.19.38.1 18-Feb-2012  mrg merge to -current.
 1.19.34.1 17-Apr-2012  yamt sync with head
 1.20.48.2 13-Apr-2020  martin Mostly merge changes from HEAD upto 20200411
 1.20.48.1 08-Apr-2020  martin Merge changes from current as of 20200406
 1.22.4.1 03-Apr-2021  thorpej Sync with HEAD.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 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 27-Feb-2002  christos branches: 1.6.8;
- define other DEV_ constants that the local port uses.
- delete cdev_decl(mm) since <sys/conf.h> does it.
 1.5 13-Nov-2000  tsubai branches: 1.5.4; 1.5.8;
Switch to wscons.
 1.4 15-Feb-1999  hubertf branches: 1.4.8;
RCS ID police
 1.3 13-Nov-1998  oster Updating of bdev's and cdev's to support RAIDframe.
 1.2 10-Oct-1998  thorpej Add scsibus entry points to the cdevsw[].
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.4.8.1 22-Nov-2000  bouyer Sync with HEAD.
 1.5.8.2 17-Sep-2002  nathanw Catch up to -current.
 1.5.8.1 28-Feb-2002  nathanw Catch up to -current.
 1.5.4.2 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.4.1 16-Mar-2002  jdolecek Catch up with -current.
 1.6.8.1 19-May-2002  gehenna Remove port-dependent conf.h.
 1.17 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.16 09-May-2003  tsutsui branches: 1.16.192; 1.16.194;
- Define and use struct hb_attach_args rather than struct confargs
for hb devices.
- Move declarations for hb functions and macros to dev/hbvar.h.
- Define and use hb_badaddr() macro for hb devices.
- Declare news3400_badaddr() in machine/cpu.h rather than machine/autoconf.h.
- Remove unused stuff from machine/autoconf.h.
 1.15 26-Apr-2003  tsutsui - Declare common functions in cpu.h
- Rename some machine dependent functions for consistency.
- Remove register declarations.
- Some KNF.
 1.14 20-Sep-2001  tsutsui branches: 1.14.4;
bootloader requires systype values so change
#ifdef _KERNEL -> #if defined(_KERNEL) || defined(_STANDALONE)
 1.13 16-Sep-2001  tsutsui Wrap some declarations with #ifdef _KERNEL and #ifndef _LOCORE .
 1.12 04-Sep-2001  simonb branches: 1.12.2;
May as well include <mips/cpuregs.h> in <mips/cpu.h> once rather than
in every MIPS port's <machine/cpu.h>.
 1.11 04-Sep-2001  simonb Centralise struct cpu_info declaration and related info to <mips/cpu.h>.
 1.10 30-May-2001  mrg branches: 1.10.2;
use _KERNEL_OPT
 1.9 30-May-2000  tsubai branches: 1.9.4;
Add cpu_number().
 1.8 26-May-2000  thorpej branches: 1.8.2;
First sweep at scheduler state cleanup. Collect MI scheduler
state into global and per-CPU scheduler state:

- Global state: sched_qs (run queues), sched_whichqs (bitmap
of non-empty run queues), sched_slpque (sleep queues).
NOTE: These may collectively move into a struct schedstate
at some point in the future.

- Per-CPU state, struct schedstate_percpu: spc_runtime
(time process on this CPU started running), spc_flags
(replaces struct proc's p_schedflags), and
spc_curpriority (usrpri of processes on this CPU).

- Every platform must now supply a struct cpu_info and
a curcpu() macro. Simplify existing cpu_info declarations
where appropriate.

- All references to per-CPU scheduler state now made through
curcpu(). NOTE: this will likely be adjusted in the future
after further changes to struct proc are made.

Tested on i386 and Alpha. Changes are mostly mechanical, but apologies
in advance if it doesn't compile on a particular platform.
 1.7 14-Apr-2000  tsubai Adapt cpu_intr change.
 1.6 24-Mar-2000  soren Revert previous.
 1.5 24-Mar-2000  soren Move sysctl definitions from arch/mips to arch/foo.
 1.4 22-Dec-1999  tsubai First cut of news5000 support.
Mostly from SHIMIZU Ryo <dejiko@di.gi.charat.org>.
 1.3 16-Jan-1999  nisimura branches: 1.3.8;
- Add two macros to deal with a recent change in mips/trap.c.
 1.2 26-Mar-1998  tsubai Add MIPS_INT_MASK_FPU definition and remove unnecessary code.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3.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.8.2.1 22-Jun-2000  minoura Sync w/ netbsd-1-5-base.
 1.9.4.1 21-Jun-2001  nathanw Catch up to -current.
 1.10.2.2 10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.10.2.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.12.2.1 01-Oct-2001  fvdl Catch up with -current.
 1.14.4.2 20-Sep-2001  tsutsui bootloader requires systype values so change
#ifdef _KERNEL -> #if defined(_KERNEL) || defined(_STANDALONE)
 1.14.4.1 20-Sep-2001  tsutsui file cpu.h was added on branch nathanw_sa on 2001-09-20 12:29:49 +0000
 1.16.194.1 10-Jun-2019  christos Sync with HEAD
 1.16.192.1 20-Oct-2018  pgoyette Sync with head
 1.1 05-Feb-2003  nakayama Replace machine/rnd.h with more appropriate name to share it
with cycle counter based microtime in kern/kern_microtime.c.
 1.4 09-Jul-2011  matt Default to DB_ELF_SYMBOLS and DB_ELFSIZE 32
 1.3 04-Sep-2001  simonb branches: 1.3.6;
Standardise the format of MIPS' <machine/db_machdep.h>.
 1.2 26-Mar-1999  tsubai branches: 1.2.22;
Define DB_ELF_SYMBOLS to compile.
(currently /boot doesn't preserve symbols.)
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.22.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.3.6.2 04-Sep-2001  simonb Standardise the format of MIPS' <machine/db_machdep.h>.
 1.3.6.1 04-Sep-2001  simonb file db_machdep.h was added on branch nathanw_sa on 2001-09-04 07:43:31 +0000
 1.2 30-Aug-2011  bouyer Add getlabelusesmbr(), as proposed in
http://mail-index.netbsd.org/tech-userlevel/2011/08/25/msg005404.html
This is used by disk tools such as disklabel(8) to dynamically decide is
the undelyling platform uses a disklabel-in-mbr-partition or not
(instead of using a compile-time list of ports).
getlabelusesmbr() reads the sysctl kern.labelusesmbr, takes its value from the
machdep #define LABELUSESMBR.
For evbmips, make LABELUSESMBR 1 if the platform uses pmon
as bootloader, and 0 (the previous value) otherwise.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2 08-Mar-1999  tsubai Use mips/ecoff_machdep.h.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2 09-Nov-1999  kleink Per discussion on tech-toolchain, remove MIPS-specific <machine/elf.h> header;
all the information is available from <sys/exec_elf.h>.
 1.1 18-Feb-1998  tsubai branches: 1.1.14; 1.1.16; 1.1.20;
Initial import of NetBSD/news.
 1.1.20.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.1.16.1 15-Nov-1999  fvdl Sync with -current
 1.1.14.1 20-Nov-2000  bouyer Remove files that are no longer on the trunck
 1.3 14-Dec-2009  matt Merge from matt-nb5-mips64
Merge mips-specific arch files.
 1.2 25-Oct-1999  kleink branches: 1.2.136; 1.2.154;
Update to match new SVR4-style definition names in <sys/exec_elf.h>.
 1.1 18-Feb-1998  tsubai branches: 1.1.14; 1.1.16; 1.1.18;
Initial import of NetBSD/news.
 1.1.18.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.1.16.1 15-Nov-1999  fvdl Sync with -current
 1.1.14.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.2.154.1 22-Aug-2009  matt Move ELF{32,64}_MACHDEP_ENDIANNESS to <mips/elf_machdep.h>
 1.2.136.1 11-Mar-2010  yamt sync with head
 1.4 17-Mar-2000  mycroft In the `MY THAT'S GROSS' department...
Eliminate the recursive include of machine/endian.h from sys/endian.h.
 1.3 16-Mar-2000  mycroft Foolish consistency. Mainly, always use underscores and sys/endian.h.
 1.2 24-Jan-1999  mycroft branches: 1.2.8;
Format consistency.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.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.1 17-Mar-2000  mycroft branches: 1.1.6;
In the `MY THAT'S GROSS' department...
Eliminate the recursive include of machine/endian.h from sys/endian.h.
 1.1.6.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.1.6.1 17-Mar-2000  bouyer file endian_machdep.h was added on branch thorpej_scsipi on 2000-11-20 20:17:25 +0000
 1.1 21-Dec-2015  christos branches: 1.1.2; 1.1.18;
Add mips fenv.h (From FreeBSD)
 1.1.18.2 03-Dec-2017  jdolecek update from HEAD
 1.1.18.1 21-Dec-2015  jdolecek file fenv.h was added on branch tls-maxphys on 2017-12-03 11:36:33 +0000
 1.1.2.2 27-Dec-2015  skrll Sync with HEAD (as of 26th Dec)
 1.1.2.1 21-Dec-2015  skrll file fenv.h was added on branch nick-nhusb on 2015-12-27 12:09:39 +0000
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3 13-Nov-2000  tsubai No longer used.
 1.2 15-Feb-1999  hubertf branches: 1.2.8;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.8.1 22-Nov-2000  bouyer Sync with HEAD.
 1.2 30-Aug-1999  mycroft A foolish consistency.
 1.1 29-Aug-1999  mycroft Add ieee.h.
 1.3 04-Sep-2001  simonb branches: 1.3.6;
Clean up.
 1.2 15-Feb-1999  hubertf branches: 1.2.22;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.22.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.3.6.2 04-Sep-2001  simonb Clean up.
 1.3.6.1 04-Sep-2001  simonb file ieeefp.h was added on branch nathanw_sa on 2001-09-04 06:26:20 +0000
 1.1 14-Apr-2001  kleink branches: 1.1.2; 1.1.4; 1.1.12;
Add definitions of C99 integer constant macros.
 1.1.12.2 14-Apr-2001  kleink Add definitions of C99 integer constant macros.
 1.1.12.1 14-Apr-2001  kleink file int_const.h was added on branch nathanw_sa on 2001-04-14 22:38:41 +0000
 1.1.4.1 21-Jun-2001  nathanw Catch up to -current.
 1.1.2.2 21-Apr-2001  bouyer Sync with HEAD
 1.1.2.1 14-Apr-2001  bouyer file int_const.h was added on branch thorpej_scsipi on 2001-04-21 17:54:22 +0000
 1.1 15-Apr-2001  kleink branches: 1.1.2; 1.1.4; 1.1.12;
Add definitions of C99 integer format conversion macros.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.2 15-Apr-2001  kleink Add definitions of C99 integer format conversion macros.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.1 15-Apr-2001  kleink file int_fmtio.h was added on branch nathanw_sa on 2001-04-15 17:13:15 +0000
 1.1.4.1 21-Jun-2001  nathanw Catch up to -current.
 1.1.2.2 21-Apr-2001  bouyer Sync with HEAD
 1.1.2.1 15-Apr-2001  bouyer file int_fmtio.h was added on branch thorpej_scsipi on 2001-04-21 17:54:22 +0000
 1.1 15-Apr-2001  kleink branches: 1.1.2; 1.1.4; 1.1.12;
Add definitions of C99 specified-width integer type limits.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.2 15-Apr-2001  kleink Add definitions of C99 specified-width integer type limits.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.1 15-Apr-2001  kleink file int_limits.h was added on branch nathanw_sa on 2001-04-15 15:29:10 +0000
 1.1.4.1 21-Jun-2001  nathanw Catch up to -current.
 1.1.2.2 21-Apr-2001  bouyer Sync with HEAD
 1.1.2.1 15-Apr-2001  bouyer file int_limits.h was added on branch thorpej_scsipi on 2001-04-21 17:54:22 +0000
 1.1 14-Apr-2001  kleink branches: 1.1.2; 1.1.4; 1.1.12;
Add definitions of C99 minimum-width and greatest-width integer types.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.2 14-Apr-2001  kleink Add definitions of C99 minimum-width and greatest-width integer types.
XXX Fastest minimum-width integer types haven't been decided upon yet.
 1.1.12.1 14-Apr-2001  kleink file int_mwgwtypes.h was added on branch nathanw_sa on 2001-04-14 12:19:59 +0000
 1.1.4.1 21-Jun-2001  nathanw Catch up to -current.
 1.1.2.2 21-Apr-2001  bouyer Sync with HEAD
 1.1.2.1 14-Apr-2001  bouyer file int_mwgwtypes.h was added on branch thorpej_scsipi on 2001-04-21 17:54:22 +0000
 1.1 26-Jun-2000  kleink branches: 1.1.2;
Add <machine/int_types.h>, which provides namespace-pure definitions
of exact-width integer types.
 1.1.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.1.2.1 26-Jun-2000  bouyer file int_types.h was added on branch thorpej_scsipi on 2000-11-20 20:17:25 +0000
 1.27 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.26 21-Jul-2016  christos branches: 1.26.14; 1.26.16;
Don't include <mips/locore.h> in <machine/intr.h>, introduces circular
dependencies; instead include it in the 4 driver files that need it,
and reorder it in machdep.c
 1.25 20-Feb-2011  matt branches: 1.25.14; 1.25.32; 1.25.36;
Merge forward matt-nb5-mips64
Adapt to new interrupt/spl framework
 1.24 10-Apr-2009  tsutsui branches: 1.24.4; 1.24.6; 1.24.8;
Include <sys/evcnt.h> instead of <sys/device.h> for struct evcnt
to avoid recursive dependency.
 1.23 28-Apr-2008  martin branches: 1.23.8; 1.23.14; 1.23.18;
Remove clause 3 and 4 from TNF licenses
 1.22 03-Dec-2007  ad branches: 1.22.14; 1.22.16; 1.22.18;
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.21 17-Oct-2007  garbled branches: 1.21.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.20 17-Jun-2007  tsutsui branches: 1.20.8; 1.20.10;
Move declaretions of _spl*() and _{clr,set}softintr() functions
(which are in mips/locore.S) into <mips/locore.h>
from various MD files.
 1.19 16-Feb-2007  ad branches: 1.19.6; 1.19.8; 1.19.14;
Remove spllowersoftclock() and CLKF_BASEPRI(), and always dispatch callouts
via a soft interrupt. In the near future, softclock will be run from process
context.
 1.18 21-Dec-2006  yamt merge yamt-splraiseipl branch.

- finish implementing splraiseipl (and makeiplcookie).
http://mail-index.NetBSD.org/tech-kern/2006/07/01/0000.html
- complete workqueue(9) and fix its ipl problem, which is reported
to cause audio skipping.
- fix netbt (at least compilation problems) for some ports.
- fix PR/33218.
 1.17 11-Dec-2005  christos branches: 1.17.20; 1.17.22;
merge ktrace-lwp.
 1.16 06-Feb-2005  tsutsui branches: 1.16.6;
Change u_int -> uint32_t, u_char,char -> uint8_t where appropriate.
 1.15 06-Feb-2005  tsutsui 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.14 25-Oct-2003  tsutsui branches: 1.14.8; 1.14.10;
Switch to use MI mk48txx(4) and todr(9) for MK48T02 todclocks on newsmips.
 1.13 25-May-2003  tsutsui branches: 1.13.2;
Add MI softintr(9) support with common mips/softintr.c.
 1.12 10-May-2003  tsutsui - Prepare common structures for interrupt handler and share them between
Hyper-bus and AP-bus.
- Use LIST rather than static array for interrupt dispatcher.
 1.11 13-Apr-2001  thorpej branches: 1.11.8;
Remove the use of splimp() from the NetBSD kernel. splnet()
and only splnet() is allowed for the protection of data structures
used by network devices.
 1.10 14-Jan-2001  thorpej branches: 1.10.2;
Make sure everybody has an splvm() and equate it with splimp() (splimp()
is the historical name for this interrupt level, and the historical name
is going to go away in the near future).
 1.9 22-Aug-2000  thorpej Add spllock(). See spl(9) for details.
 1.8 21-Aug-2000  thorpej Make sure we provide splsched() as described in spl(9).
 1.7 14-Apr-2000  tsubai Adapt cpu_intr change.
 1.6 31-Dec-1999  tsubai Add zs softint definition. (I forgot to commit this...)
 1.5 22-Dec-1999  tsubai First cut of news5000 support.
Mostly from SHIMIZU Ryo <dejiko@di.gi.charat.org>.
 1.4 17-Oct-1999  tsubai branches: 1.4.2;
Rearrange splxxx (from pmax). Closes PR 8445.
 1.3 05-Aug-1999  thorpej branches: 1.3.2;
Change the semantics of splsoftclock() to be like other spl*() functions,
that is priority is rasied. Add a new spllowersoftclock() to provide the
atomic drop-to-softclock semantics that the old splsoftclock() provided,
and update calls accordingly.

This fixes a problem with using the "rnd" pseudo-device from within
interrupt context to extract random data (e.g. from within the softnet
interrupt) where doing so would incorrectly unblock interrupts (causing
all sorts of lossage).

XXX 4 platforms do not have priority-raising capability: newsmips, sparc,
XXX sparc64, and VAX. This platforms still have this bug until their
XXX spl*() functions are fixed.
 1.2 26-Aug-1998  tsubai Add MD DELAY and spl routines to fit Nisimura's change.
 1.1 08-Jun-1998  tsubai Introduce newsmips_intr_t for intrcnt[].
 1.3.2.1 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.4.2.3 21-Apr-2001  bouyer Sync with HEAD
 1.4.2.2 18-Jan-2001  bouyer Sync with head (for UBC+NFS fixes, mostly).
 1.4.2.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.10.2.1 21-Jun-2001  nathanw Catch up to -current.
 1.11.8.2 13-Apr-2001  thorpej Remove the use of splimp() from the NetBSD kernel. splnet()
and only splnet() is allowed for the protection of data structures
used by network devices.
 1.11.8.1 13-Apr-2001  thorpej file intr.h was added on branch nathanw_sa on 2001-04-13 23:30:03 +0000
 1.13.2.4 06-Feb-2005  skrll Sync with HEAD.
 1.13.2.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.13.2.2 18-Sep-2004  skrll Sync with HEAD.
 1.13.2.1 03-Aug-2004  skrll Sync with HEAD
 1.14.10.1 12-Feb-2005  yamt sync with head.
 1.14.8.1 29-Apr-2005  kent sync with -current
 1.16.6.4 07-Dec-2007  yamt sync with head
 1.16.6.3 03-Sep-2007  yamt sync with head.
 1.16.6.2 26-Feb-2007  yamt sync with head.
 1.16.6.1 30-Dec-2006  yamt sync with head.
 1.17.22.2 22-Sep-2006  yamt fix softintr for following ports. (hopefully)
hpcmips
evbmips
algor
arc
ews4800mips
newsmips
 1.17.22.1 21-Sep-2006  yamt - implement splraiseipl for algor, arc, ews4800mips, hpcmips, and newsmips.
- tweak evbmips version to match with others.
XXX i think these ought to be merged.
 1.17.20.1 12-Jan-2007  ad Sync with head.
 1.19.14.1 26-Jun-2007  garbled Sync with HEAD.
 1.19.8.1 11-Jul-2007  mjf Sync with head.
 1.19.6.2 03-Dec-2007  ad Sync with HEAD.
 1.19.6.1 15-Jul-2007  ad Sync with head.
 1.20.10.2 09-Jan-2008  matt sync with HEAD
 1.20.10.1 06-Nov-2007  matt sync with HEAD
 1.20.8.1 09-Dec-2007  jmcneill Sync with HEAD.
 1.21.2.1 08-Dec-2007  mjf Sync with HEAD.
 1.22.18.2 04-May-2009  yamt sync with head.
 1.22.18.1 16-May-2008  yamt sync with head.
 1.22.16.1 18-May-2008  yamt sync with head.
 1.22.14.1 02-Jun-2008  mjf Sync with HEAD.
 1.23.18.1 29-Dec-2010  matt Adapt to the new interrupt framework.
Use mips_set_wbflush instead of playing preprocessor games.
 1.23.14.1 13-May-2009  jym Sync with HEAD.

Commit is split, to avoid a "too many arguments" protocol error.
 1.23.8.1 28-Apr-2009  skrll Sync with HEAD.
 1.24.8.1 05-Mar-2011  bouyer Sync with HEAD
 1.24.6.1 06-Jun-2011  jruoho Sync with HEAD.
 1.24.4.1 05-Mar-2011  rmind sync with head
 1.25.36.1 26-Jul-2016  pgoyette Sync with HEAD
 1.25.32.1 05-Oct-2016  skrll Sync with HEAD
 1.25.14.1 03-Dec-2017  jdolecek update from HEAD
 1.26.16.1 10-Jun-2019  christos Sync with HEAD
 1.26.14.1 20-Oct-2018  pgoyette Sync with head
 1.1 19-Feb-1998  thorpej Use the generic NetBSD/mips crash dump code.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3 13-Nov-2000  tsubai No longer used.
 1.2 15-Feb-1999  hubertf branches: 1.2.8;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.8.1 22-Nov-2000  bouyer Sync with HEAD.
 1.2 31-Aug-2001  simonb branches: 1.2.6;
G/C the unused kernel-only CLK_TCK #define.

XXX: does include/time.h still need <machine/limits.h>?
 1.1 18-Feb-1998  tsubai branches: 1.1.28;
Initial import of NetBSD/news.
 1.1.28.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.2.6.2 31-Aug-2001  simonb G/C the unused kernel-only CLK_TCK #define.

XXX: does include/time.h still need <machine/limits.h>?
 1.2.6.1 31-Aug-2001  simonb file limits.h was added on branch nathanw_sa on 2001-08-31 03:46:04 +0000
 1.5 06-Aug-2014  joerg Consistently define WARN in a way that passes format string checks, i.e.
always uses the same number of arguments as given in the format string.
 1.4 28-Apr-2008  martin branches: 1.4.44; 1.4.60;
Remove clause 3 and 4 from TNF licenses
 1.3 25-Jan-2006  christos branches: 1.3.72; 1.3.74; 1.3.76;
free -> dealloc
unsigned -> size_t for alloc/dealloc
 1.2 31-Oct-2001  thorpej branches: 1.2.2; 1.2.34; 1.2.46;
Split elf32 vs. elf64 handling in loadfile(), including support for
each separately and explicitly. BOOT_ELF is now BOOT_ELF32 and
BOOT_ELF64, and ELFSIZE should no longer be defined in loadfile_machdep.h.
 1.1 08-Jul-1999  tsubai branches: 1.1.2; 1.1.18; 1.1.20;
Forgot to add this...
 1.1.20.1 12-Nov-2001  thorpej Sync the thorpej-mips-cache branch with -current.
 1.1.18.1 10-Jan-2002  thorpej Sync kqueue branch with -current.
 1.1.2.2 02-Aug-1999  thorpej Update from trunk.
 1.1.2.1 08-Jul-1999  thorpej file loadfile_machdep.h was added on branch chs-ubc2 on 1999-08-02 19:58:23 +0000
 1.2.46.1 01-Feb-2006  yamt sync with head.
 1.2.34.1 21-Jun-2006  yamt sync with head.
 1.2.2.2 31-Oct-2001  thorpej Split elf32 vs. elf64 handling in loadfile(), including support for
each separately and explicitly. BOOT_ELF is now BOOT_ELF32 and
BOOT_ELF64, and ELFSIZE should no longer be defined in loadfile_machdep.h.
 1.2.2.1 31-Oct-2001  thorpej file loadfile_machdep.h was added on branch nathanw_sa on 2001-10-31 17:20:48 +0000
 1.3.76.1 16-May-2008  yamt sync with head.
 1.3.74.1 18-May-2008  yamt sync with head.
 1.3.72.1 02-Jun-2008  mjf Sync with HEAD.
 1.4.60.1 10-Aug-2014  tls Rebase.
 1.4.44.1 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.2 31-Aug-2001  simonb branches: 1.2.6;
Remove an unneeded comment; ``sync'' with other "just include <mips/foo.h>"
files.
 1.1 29-Apr-2000  thorpej branches: 1.1.6; 1.1.10;
Require that each each MACHINE/MACHINE_ARCH supply a lock.h. This file
contains the values __SIMPLELOCK_LOCKED and __SIMPLELOCK_UNLOCKED, which
replace the old SIMPLELOCK_LOCKED and SIMPLELOCK_UNLOCKED. These files
are also required to supply inline functions __cpu_simple_lock(),
__cpu_simple_lock_try(), and __cpu_simple_unlock() if locking is to be
supported on that platform (i.e. if MULTIPROCESSOR is defined in the
_KERNEL case). Change these functions to take an int * (&alp->lock_data)
rather than the struct simplelock * itself.

These changes make it possible for userland to use the locking primitives
by including <machine/lock.h>.
 1.1.10.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.1.6.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.1.6.1 29-Apr-2000  bouyer file lock.h was added on branch thorpej_scsipi on 2000-11-20 20:17:25 +0000
 1.2.6.2 31-Aug-2001  simonb Remove an unneeded comment; ``sync'' with other "just include <mips/foo.h>"
files.
 1.2.6.1 31-Aug-2001  simonb file lock.h was added on branch nathanw_sa on 2001-08-31 03:53:24 +0000
 1.2 05-Jun-2002  simonb Simplify include files that just include <mips/locore.h>.
 1.1 18-Feb-1998  tsubai branches: 1.1.28; 1.1.32; 1.1.40;
Initial import of NetBSD/news.
 1.1.40.1 15-Jul-2002  gehenna catch up with -current.
 1.1.32.1 20-Jun-2002  nathanw Catch up to -current.
 1.1.28.1 23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.1 30-Nov-2024  christos branches: 1.1.4;
Create a new header lwp_private.h to contain _lwp_getprivate_fast,
_lwp_gettcb_fast, _lwp_settcb and remove them from mcontext.h, so that:
1. we don't need special hacks to hide them
2. we can include <lwp.h> where needed to get the necessary prototypes
without redefining them locally.
 1.1.4.2 02-Aug-2025  perseant Sync with HEAD
 1.1.4.1 30-Nov-2024  perseant file lwp_private.h was added on branch perseant-exfatfs on 2025-08-02 05:55:58 +0000
 1.4 11-Dec-2005  christos merge ktrace-lwp.
 1.3 07-Aug-2003  agc Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.
 1.2 15-Feb-1999  hubertf branches: 1.2.42;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.42.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.2.42.2 18-Sep-2004  skrll Sync with HEAD.
 1.2.42.1 03-Aug-2004  skrll Sync with HEAD
 1.1 23-Dec-1999  kleink branches: 1.1.6;
C99: Define a NAN macro in <math.h> which evaulates to a constant expression of
a single-precision quiet NaN; only to be defined on platforms that do support
this value.
 1.1.6.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.1.6.1 23-Dec-1999  bouyer file math.h was added on branch thorpej_scsipi on 2000-11-20 20:17:25 +0000
 1.2 18-Jan-2003  thorpej Merge the nathanw_sa branch.
 1.1 17-Nov-2001  wdk branches: 1.1.2;
file mcontext.h was initially added on branch nathanw_sa.
 1.1.2.1 17-Nov-2001  wdk mcontext support for MIPS based ports.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3 13-Nov-2000  tsubai No longer used.
 1.2 15-Feb-1999  hubertf branches: 1.2.8;
RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.8.1 22-Nov-2000  bouyer Sync with HEAD.
 1.2 09-Feb-2007  ad branches: 1.2.4;
Merge newlock2 to head.
 1.1 22-Dec-2006  ad branches: 1.1.2;
file mutex.h was initially added on branch newlock2.
 1.1.2.1 22-Dec-2006  ad Pull in CPU specific stubs.
 1.2.4.2 26-Feb-2007  yamt sync with head.
 1.2.4.1 09-Feb-2007  yamt file mutex.h was added on branch yamt-lazymbuf on 2007-02-26 09:07:40 +0000
 1.22 07-Jan-2019  jdolecek move DEV_BSIZE, DEV_BSHIFT out of MD param.h, they are same on all ports

also move BLKDEV_IOSIZE, MAXPHYS, but allow override since some ports
have different value (powerpc uses NBPG for BLKDEV_IOSIZE, sun2/sun3
have lower MAXPHYS)
 1.21 18-Mar-2011  tsutsui branches: 1.21.54; 1.21.56;
- include <mips/mips_param.h> after MACHINE is defined
- remove redundant comment
 1.20 06-Mar-2011  he Now that MACHINE is defined in user-land in either
mips/include/mips_param.h or powerpc/include/param.h, stop
trying to re-define it in the port-specific param.h files
when _KERNEL isn't defined.
 1.19 08-Feb-2011  rmind Remove clause 3 (UCB advertising clause) from the University of Utah
copyright. Confirmed by Mike Hibler, mike at cs.utah.edu - thanks!
Also, merge UCB and Utah copyright texts back into one, as they
originally were.

Extra verification by snj@.
 1.18 14-Dec-2009  matt branches: 1.18.4; 1.18.6; 1.18.8;
Merge from matt-nb5-mips64
Merge mips-specific arch files.
 1.17 13-Aug-2009  matt Move MID_MACHINE to <mips/mips_param.h> and use local values so we don't
need to include exec_aout.h
 1.16 17-Oct-2007  garbled branches: 1.16.20; 1.16.38;
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.15 17-Jul-2007  he branches: 1.15.10;
Patterned after sgimips, move include of <machine/intr.h> to only be done
when _KERNEL is defined and _LOCORE isn't. Fixes build problem in the
extent regression test.
 1.14 26-Sep-2006  tsutsui branches: 1.14.8; 1.14.16;
Protect from multiple inclusion.
 1.13 27-Aug-2006  tsutsui branches: 1.13.2; 1.13.4;
Replace DELAY(9) macro with inline version which uses an asm statement
otherwise gcc4 will omit it completely on optimization.

XXX: some other mips ports have the same problem.
 1.12 11-Dec-2005  christos branches: 1.12.4; 1.12.8;
merge ktrace-lwp.
 1.11 06-Feb-2005  tsutsui branches: 1.11.6;
- remove __P()
- use do{}while(0) and remove register decl for DELAY() macro
 1.10 07-Aug-2003  agc branches: 1.10.8; 1.10.10;
Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.
 1.9 26-Feb-2002  simonb branches: 1.9.16;
Purge CLSIZE, CLSIZELOG2 and MCLOFSET.
Be consistant in the way that MSIZE, MCLSHIFT, MCLBYTES and NMBCLUSTERS
are defined.
Remove old VM constants from cesfic port.
Bump MSIZE to 256 on mipsco (the only one that wasn't already 256).
 1.8 30-May-2001  mrg branches: 1.8.2; 1.8.8;
use _KERNEL_OPT
 1.7 30-Jun-2000  itojun branches: 1.7.2;
raise MSIZE from 128 to 256.
- for sizeof(void *) == 8 arch, this is mandatory. MHLEN is too small
already (less than 80) and there are chances for unwanted packet loss due
to m_pullup restriction.
- for other cases, the change should avoid allocating clusters in most cases
(even when you have IPv4 IPsec tunnel, or IPv6 with moderate amount of
extension header)

portmasters: if your arch chokes with the change (high memory usage or
whatever), please backout the change for your arch.
 1.6 04-Dec-1999  ragge branches: 1.6.4;
CL* discarding.
 1.5 09-Feb-1999  tv branches: 1.5.8; 1.5.14;
Split the "mips" MACHINE_ARCH for 1.4. newsmips is "mipseb"; pmax is
"mipsel".
 1.4 26-Aug-1998  tsubai Add MD DELAY and spl routines to fit Nisimura's change.
 1.3 29-Apr-1998  thorpej Pull in opt_gateway.h as appropriate.
 1.2 04-Mar-1998  thorpej Rename NetBSD/news to NetBSD/newsmips.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.5.14.2 27-Dec-1999  wrstuden Pull up to last week's -current.
 1.5.14.1 21-Dec-1999  wrstuden Initial commit of recent changes to make DEV_BSIZE go away.

Runs on i386, needs work on other arch's. Main kernel routines should be
fine, but a number of the stand programs need help.

cd, fd, ccd, wd, and sd have been updated. sd has been tested with non-512
byte block devices. vnd, raidframe, and lfs need work.

Non 2**n block support is automatic for LKM's and conditional for kernels
on "options NON_PO2_BLOCKS".
 1.5.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.6.4.1 23-Jul-2000  itojun pullup from main trunc (approved by releng-1-5)

raise MSIZE from 128 to 256.
- for sizeof(void *) == 8 arch, this is mandatory. MHLEN is too small
already (less than 80) and there are chances for unwanted packet loss due
to m_pullup restriction.
- for other cases, the change should avoid allocating clusters in most cases
(even when you have IPv4 IPsec tunnel, or IPv6 with moderate amount of
extension header)

portmasters: if your arch chokes with the change (high memory usage or
whatever), please backout the change for your arch.

1.1 -> 1.2 syssrc/sys/arch/amigappc/include/param.h
1.13 -> 1.14 syssrc/sys/arch/arc/include/param.h
1.1 -> 1.2 syssrc/sys/arch/arm26/include/param.h
1.17 -> 1.18 syssrc/sys/arch/arm32/include/param.h
1.6 -> 1.7 syssrc/sys/arch/bebox/include/param.h
1.4 -> 1.5 syssrc/sys/arch/cobalt/include/param.h
1.4 -> 1.5 syssrc/sys/arch/evbsh3/include/param.h
1.2 -> 1.3 syssrc/sys/arch/hpcmips/include/param.h
1.40 -> 1.41 syssrc/sys/arch/i386/include/param.h
1.7 -> 1.8 syssrc/sys/arch/m68k/include/param.h
1.9 -> 1.10 syssrc/sys/arch/macppc/include/param.h
1.4 -> 1.5 syssrc/sys/arch/mmeye/include/param.h
1.6 -> 1.7 syssrc/sys/arch/newsmips/include/param.h
1.7 -> 1.8 syssrc/sys/arch/ofppc/include/param.h
1.23 -> 1.24 syssrc/sys/arch/pc532/include/param.h
1.32 -> 1.33 syssrc/sys/arch/pmax/include/param.h
1.7 -> 1.8 syssrc/sys/arch/powerpc/include/param.h
1.1 -> 1.2 syssrc/sys/arch/prep/include/param.h
1.1 -> 1.2 syssrc/sys/arch/sgimips/include/param.h
1.3 -> 1.4 syssrc/sys/arch/sh3/include/param.h
1.44 -> 1.45 syssrc/sys/arch/sparc/include/param.h
1.21 -> 1.22 syssrc/sys/arch/sparc64/include/param.h
1.43 -> 1.44 syssrc/sys/arch/vax/include/param.h
 1.7.2.1 21-Jun-2001  nathanw Catch up to -current.
 1.8.8.2 28-Feb-2002  nathanw Catch up to -current.
 1.8.8.1 30-May-2001  nathanw file param.h was added on branch nathanw_sa on 2002-02-28 04:11:16 +0000
 1.8.2.1 16-Mar-2002  jdolecek Catch up with -current.
 1.9.16.4 06-Feb-2005  skrll Sync with HEAD.
 1.9.16.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.9.16.2 18-Sep-2004  skrll Sync with HEAD.
 1.9.16.1 03-Aug-2004  skrll Sync with HEAD
 1.10.10.1 12-Feb-2005  yamt sync with head.
 1.10.8.1 29-Apr-2005  kent sync with -current
 1.11.6.2 03-Sep-2007  yamt sync with head.
 1.11.6.1 30-Dec-2006  yamt sync with head.
 1.12.8.1 03-Sep-2006  yamt sync with head.
 1.12.4.1 09-Sep-2006  rpaulo sync with head
 1.13.4.1 22-Oct-2006  yamt sync with head
 1.13.2.1 18-Nov-2006  ad Sync with head.
 1.14.16.1 03-Oct-2007  garbled Sync with HEAD
 1.14.8.1 20-Aug-2007  ad Sync with HEAD.
 1.15.10.1 06-Nov-2007  matt sync with HEAD
 1.16.38.1 22-Aug-2009  matt Move MACHINE_ARCH definition to <mips/mips_param.h>
Move mbuf related defines to <mips/mips_param.h>
 1.16.20.2 11-Mar-2010  yamt sync with head
 1.16.20.1 19-Aug-2009  yamt sync with head.
 1.18.8.1 17-Feb-2011  bouyer Sync with HEAD
 1.18.6.1 06-Jun-2011  jruoho Sync with HEAD.
 1.18.4.2 21-Apr-2011  rmind sync with head
 1.18.4.1 05-Mar-2011  rmind sync with head
 1.21.56.1 10-Jun-2019  christos Sync with HEAD
 1.21.54.1 18-Jan-2019  pgoyette Synch with HEAD
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2 13-Sep-2000  nisimura Nuke unused obscure #define's.
 1.1 18-Feb-1998  tsubai branches: 1.1.14;
Initial import of NetBSD/news.
 1.1.14.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.2 12-Jul-2018  maxv Remove the kernel PMC code. Sent yesterday on tech-kern@.

This change:

* Removes "options PERFCTRS", the associated includes, and the associated
ifdefs. In doing so, it removes several XXXSMPs in the MI code, which is
good.

* Removes the PMC code of ARM XSCALE.

* Removes all the pmc.h files. They were all empty, except for ARM XSCALE.

* Reorders the x86 PMC code not to rely on the legacy pmc.h file. The
definitions are put in sysarch.h.

* Removes the kern/sys_pmc.c file, and along with it, the sys_pmc_control
and sys_pmc_get_info syscalls. They are marked as OBSOL in kern,
netbsd32 and rump.

* Removes the pmc_evid_t and pmc_ctr_t types.

* Removes all the associated man pages. The sets are marked as obsolete.
 1.1 07-Aug-2002  briggs branches: 1.1.2; 1.1.4; 1.1.6; 1.1.202; 1.1.204;
Implement pmc(9) -- An interface to hardware performance monitoring
counters. These counters do not exist on all CPUs, but where they
do exist, can be used for counting events such as dcache misses that
would otherwise be difficult or impossible to instrument by code
inspection or hardware simulation.

pmc(9) is meant to be a general interface. Initially, the Intel XScale
counters are the only ones supported.
 1.1.204.1 10-Jun-2019  christos Sync with HEAD
 1.1.202.1 28-Jul-2018  pgoyette Sync with HEAD
 1.1.6.2 06-Sep-2002  jdolecek sync kqueue branch with HEAD
 1.1.6.1 07-Aug-2002  jdolecek file pmc.h was added on branch kqueue on 2002-09-06 08:38:18 +0000
 1.1.4.2 31-Aug-2002  gehenna catch up with -current.
 1.1.4.1 07-Aug-2002  gehenna file pmc.h was added on branch gehenna-devsw on 2002-08-31 13:45:31 +0000
 1.1.2.2 13-Aug-2002  nathanw Catch up to -current.
 1.1.2.1 07-Aug-2002  nathanw file pmc.h was added on branch nathanw_sa on 2002-08-13 02:18:36 +0000
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3 30-Mar-1999  soda regdef.h is back
 1.2 13-Mar-1999  drochner g/c regdef.h
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3 09-Sep-2001  simonb branches: 1.3.4;
Clean up and standardise across MIPS ports.
 1.2 04-Mar-1998  thorpej branches: 1.2.26; 1.2.28;
Rename NetBSD/news to NetBSD/newsmips.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.28.1 13-Sep-2001  thorpej Update the kqueue branch to HEAD.
 1.2.26.1 01-Oct-2001  fvdl Catch up with -current.
 1.3.4.2 09-Sep-2001  simonb Clean up and standardise across MIPS ports.
 1.3.4.1 09-Sep-2001  simonb file reloc.h was added on branch nathanw_sa on 2001-09-09 04:20:28 +0000
 1.2 05-Feb-2003  nakayama Replace machine/rnd.h with more appropriate name to share it
with cycle counter based microtime in kern/kern_microtime.c.
 1.1 06-Jun-2000  soren branches: 1.1.4; 1.1.6;
Add rnd(4) glue for the MIPS3 cycle counter.
 1.1.6.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.1.6.1 06-Jun-2000  bouyer file rnd.h was added on branch thorpej_scsipi on 2000-11-20 20:17:26 +0000
 1.1.4.2 22-Jun-2000  minoura Sync w/ netbsd-1-5-base.
 1.1.4.1 06-Jun-2000  minoura file rnd.h was added on branch minoura-xpg4dl on 2000-06-22 17:01:56 +0000
 1.3 13-Apr-2002  tsutsui Add some ioctl() definitions to eject floppy.
 1.2 13-Apr-2002  tsutsui Rename halt() -> rom_halt(), and declare it in romcall.h.
 1.1 08-Jul-1999  tsubai branches: 1.1.2; 1.1.18; 1.1.22;
Define ROM monitor interfaces.
 1.1.22.1 17-Apr-2002  nathanw Catch up to -current.
 1.1.18.1 23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.1.2.2 02-Aug-1999  thorpej Update from trunk.
 1.1.2.1 08-Jul-1999  thorpej file romcall.h was added on branch chs-ubc2 on 1999-08-02 19:58:23 +0000
 1.2 09-Feb-2007  ad branches: 1.2.4;
Merge newlock2 to head.
 1.1 22-Dec-2006  ad branches: 1.1.2;
file rwlock.h was initially added on branch newlock2.
 1.1.2.1 22-Dec-2006  ad Pull in CPU specific stubs.
 1.2.4.2 26-Feb-2007  yamt sync with head.
 1.2.4.1 09-Feb-2007  yamt file rwlock.h was added on branch yamt-lazymbuf on 2007-02-26 09:07:40 +0000
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 23-Jul-2014  alnsn branches: 1.1.2; 1.1.6;
Rename sljitarch.h to sljit_machdep.h.
 1.1.6.2 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.1.6.1 23-Jul-2014  tls file sljit_machdep.h was added on branch tls-maxphys on 2014-08-20 00:03:16 +0000
 1.1.2.2 10-Aug-2014  tls Rebase.
 1.1.2.1 23-Jul-2014  tls file sljit_machdep.h was added on branch tls-earlyentropy on 2014-08-10 06:54:04 +0000
 1.2 23-Jul-2014  alnsn Rename sljitarch.h to sljit_machdep.h.
 1.1 25-Nov-2012  alnsn branches: 1.1.2; 1.1.6; 1.1.14;
Add sljitarch.h to all mips machines.
 1.1.14.1 10-Aug-2014  tls Rebase.
 1.1.6.3 20-Aug-2014  tls Rebase to HEAD as of a few days ago.
 1.1.6.2 25-Feb-2013  tls resync with head
 1.1.6.1 25-Nov-2012  tls file sljitarch.h was added on branch tls-maxphys on 2013-02-25 00:28:52 +0000
 1.1.2.2 16-Jan-2013  yamt sync with (a bit old) head
 1.1.2.1 25-Nov-2012  yamt file sljitarch.h was added on branch yamt-pagecache on 2013-01-16 05:33:01 +0000
 1.3 17-Jul-2011  joerg Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
 1.2 22-Jan-1999  mycroft Use mips/stdarg.h.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.13 01-Apr-2021  simonb Define __HAVE_LEGACY_INTRCNT to indicate this port uses legacy intrcnt
interrupt accounting.
 1.12 20-Jan-2008  joerg branches: 1.12.110; 1.12.112;
Now that __HAVE_TIMECOUNTER and __HAVE_GENERIC_TODR are invariants,
remove the conditionals and the code associated with the undef case.
 1.11 17-Oct-2007  garbled branches: 1.11.2; 1.11.8;
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.10 14-Jul-2007  ad branches: 1.10.10;
Generic soft interrupts are mandatory.
 1.9 13-Sep-2006  tsutsui branches: 1.9.10; 1.9.18;
Switch newsmips to timecounters. From gdamore@ on port-newsmips
with one tweak by me, and regressions passed on NWS-5000.
 1.8 04-Sep-2006  tsutsui branches: 1.8.2;
Switch newsmips to MI todr.
 1.7 25-May-2003  tsutsui branches: 1.7.18; 1.7.32; 1.7.36;
Remove __BROKEN_CONFIG_UNIT_USAGE.
It seems fixed long ago.
 1.6 25-May-2003  tsutsui Add MI softintr(9) support with common mips/softintr.c.
 1.5 05-Aug-2002  simonb Use a __HAVE_BOOTINFO_H define to check for bootinfo support instead of
speading port names in arch-dependant code.
 1.4 05-Mar-2002  simonb branches: 1.4.6;
Provide a L2 cache configuration function.
 1.3 28-Feb-2002  simonb Use "#define<tab>".
 1.2 05-Feb-2000  cgd branches: 1.2.8; 1.2.12;
add __BROKEN_CONFIG_UNIT_USAGE #define, becuase these ports do very
wrong things with device configuration data "cf_unit" information.
 1.1 18-Feb-1998  tsubai branches: 1.1.14;
Initial import of NetBSD/news.
 1.1.14.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.2.12.2 13-Aug-2002  nathanw Catch up to -current.
 1.2.12.1 01-Apr-2002  nathanw Catch up to -current.
(CVS: It's not just a program. It's an adventure!)
 1.2.8.2 06-Sep-2002  jdolecek sync kqueue branch with HEAD
 1.2.8.1 16-Mar-2002  jdolecek Catch up with -current.
 1.4.6.1 31-Aug-2002  gehenna catch up with -current.
 1.7.36.1 14-Sep-2006  yamt sync with head.
 1.7.32.1 09-Sep-2006  rpaulo sync with head
 1.7.18.3 21-Jan-2008  yamt sync with head
 1.7.18.2 03-Sep-2007  yamt sync with head.
 1.7.18.1 30-Dec-2006  yamt sync with head.
 1.8.2.1 18-Nov-2006  ad Sync with head.
 1.9.18.1 03-Oct-2007  garbled Sync with HEAD
 1.9.10.1 15-Jul-2007  ad Sync with head.
 1.10.10.2 23-Mar-2008  matt sync with HEAD
 1.10.10.1 06-Nov-2007  matt sync with HEAD
 1.11.8.1 23-Jan-2008  bouyer Sync with HEAD.
 1.11.2.1 18-Feb-2008  mjf Sync with HEAD.
 1.12.112.1 03-Apr-2021  thorpej Sync with HEAD.
 1.12.110.1 03-Apr-2021  thorpej Sync with HEAD.
 1.3 17-Feb-1999  tsubai Use mips/varargs.h.
 1.2 15-Feb-1999  hubertf RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.4 17-Jul-2011  joerg Retire varargs.h support. Move machine/stdarg.h logic into MI
sys/stdarg.h and expect compiler to provide proper builtins, defaulting
to the GCC interface. lint still has a special fallback.
Reduce abuse of _BSD_VA_LIST_ by defining __va_list by default and
derive va_list as required by standards.
 1.3 17-Feb-1999  tsubai Use mips/varargs.h.
 1.2 15-Feb-1999  hubertf RCS ID police
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.5 14-Dec-2009  matt Merge from matt-nb5-mips64
Merge mips-specific arch files.
 1.4 01-Dec-2000  tsutsui branches: 1.4.130; 1.4.148;
Remove unused pcbb() macro.
 1.3 08-Jul-1998  thorpej branches: 1.3.10; 1.3.14;
Define one page free list, and put all pages on it.
 1.2 25-Feb-1998  thorpej NEWS has one physical memory segment.
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.3.14.1 08-Dec-2000  bouyer Sync with HEAD.
 1.3.10.1 06-Aug-1999  chs take an initial guess at UBC parameters.
 1.4.148.1 11-Dec-2009  matt Use the default set of VM_FREELISTs in <mips/vmparam.h> but allow them to
be overridden (for pmax).
 1.4.130.1 11-Mar-2010  yamt sync with head
 1.2 11-Dec-2005  christos merge ktrace-lwp.
 1.1 08-May-2004  kleink branches: 1.1.2;
Factor out W{CHAR,INT}_{MAX,MIN} into their own header file.
 1.1.2.4 21-Sep-2004  skrll Fix the sync with head I botched.
 1.1.2.3 18-Sep-2004  skrll Sync with HEAD.
 1.1.2.2 03-Aug-2004  skrll Sync with HEAD
 1.1.2.1 08-May-2004  skrll file wchar_limits.h was added on branch ktrace-lwp on 2004-08-03 10:38:29 +0000
 1.2 11-Dec-2005  christos branches: 1.2.18;
merge ktrace-lwp.
 1.1 05-Nov-2005  tsutsui branches: 1.1.2;
Add empty <machine/wired_map.h> for the MI mips/wired_map.c.
 1.1.2.2 10-Nov-2005  skrll Sync with HEAD. Here we go again...
 1.1.2.1 05-Nov-2005  skrll file wired_map.h was added on branch ktrace-lwp on 2005-11-10 13:57:57 +0000
 1.2.18.2 21-Jun-2006  yamt sync with head.
 1.2.18.1 11-Dec-2005  yamt file wired_map.h was added on branch yamt-lazymbuf on 2006-06-21 14:54:11 +0000
 1.3 07-Sep-2015  dholland Final bit of PR 41200: headers that declare ioctls should include sys/ioccom.h.
This covers most if not all of the MD headers.

XXX: a lot of the ioctl definitions in some of these files are cutpasted.
 1.2 11-Dec-2005  christos branches: 1.2.122; 1.2.142;
merge ktrace-lwp.
 1.1 01-Aug-2004  uch branches: 1.1.2;
add NEWSMIPS_WSDISPLAYIO_GINFO ioctl to get frame buffer stride.
 1.1.2.4 21-Sep-2004  skrll Fix the sync with head I botched.
 1.1.2.3 18-Sep-2004  skrll Sync with HEAD.
 1.1.2.2 03-Aug-2004  skrll Sync with HEAD
 1.1.2.1 01-Aug-2004  skrll file wsconsio.h was added on branch ktrace-lwp on 2004-08-03 10:38:29 +0000
 1.2.142.1 22-Sep-2015  skrll Sync with HEAD
 1.2.122.1 03-Dec-2017  jdolecek update from HEAD
 1.12 28-Jul-2012  matt Fix -fno-common fallout.
 1.11 26-Jun-2010  tsutsui branches: 1.11.8;
Um, fix botch in previous.
 1.10 29-Mar-2008  tsutsui branches: 1.10.4; 1.10.24; 1.10.26;
Split softc and device_t for zsc(4) and its children.

XXX we should restructure MI APIs and make it really machine independent.
 1.9 07-Nov-2007  ad branches: 1.9.14;
Merge tty changes from the vmlocking branch.
 1.8 11-Dec-2005  christos branches: 1.8.30; 1.8.48; 1.8.50; 1.8.54; 1.8.56;
merge ktrace-lwp.
 1.7 06-Feb-2005  tsutsui branches: 1.7.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.6 07-Aug-2003  agc branches: 1.6.8; 1.6.10;
Move UCB-licensed code from 4-clause to 3-clause licence.

Patches provided by Joel Baker in PR 22364, verified by myself.
 1.5 25-May-2003  tsutsui branches: 1.5.2;
Add MI softintr(9) support with common mips/softintr.c.
 1.4 26-Apr-2003  tsutsui - Move some common declarations into z8530var.h.
- Fix struct consdev properly.
- Remove register declarations.
- some more KNF.
 1.3 03-Dec-2000  matt Make this stuff compile with -wstrict-prototpes -wmissing-prototypes.
More use of prototypes inside includes should be done.
 1.2 01-Jun-1998  tsubai branches: 1.2.14;
Change "extern var;" --> "extern int var;" and so on. (for egcs -Wall)
 1.1 18-Feb-1998  tsubai Initial import of NetBSD/news.
 1.2.14.1 08-Dec-2000  bouyer Sync with HEAD.
 1.5.2.4 06-Feb-2005  skrll Sync with HEAD.
 1.5.2.3 21-Sep-2004  skrll Fix the sync with head I botched.
 1.5.2.2 18-Sep-2004  skrll Sync with HEAD.
 1.5.2.1 03-Aug-2004  skrll Sync with HEAD
 1.6.10.1 12-Feb-2005  yamt sync with head.
 1.6.8.1 29-Apr-2005  kent sync with -current
 1.7.6.1 15-Nov-2007  yamt sync with head.
 1.8.56.1 19-Nov-2007  mjf Sync with HEAD.
 1.8.54.1 13-Nov-2007  bouyer Sync with HEAD
 1.8.50.1 08-Nov-2007  matt sync with -HEAD
 1.8.48.1 11-Nov-2007  joerg Sync with HEAD.
 1.8.30.2 03-Dec-2007  ad Sync with HEAD.
 1.8.30.1 03-Dec-2007  ad Sync with HEAD.
 1.9.14.1 03-Apr-2008  mjf Sync with HEAD.
 1.10.26.1 03-Jul-2010  rmind sync with head
 1.10.24.1 17-Aug-2010  uebayasi Sync with HEAD.
 1.10.4.1 11-Aug-2010  yamt sync with head.
 1.11.8.1 30-Oct-2012  yamt sync with head

RSS XML Feed