History log of /openbsd-current/sys/arch/mips64/conf/files.mips64
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 1.31 20-Jul-2021 visa

Remove unneeded __sync_* library functions from the kernel.

These library functions were added as stopgaps because GCC 4.2.1
lacks the corresponding __sync_* builtins on mips64. However,
the builtins are now provided by Clang.


# 1.30 01-May-2021 visa

Retire OpenBSD/sgi.

OK deraadt@


Revision tags: OPENBSD_6_3_BASE OPENBSD_6_4_BASE OPENBSD_6_5_BASE OPENBSD_6_6_BASE OPENBSD_6_7_BASE OPENBSD_6_8_BASE OPENBSD_6_9_BASE
# 1.29 25-Jan-2018 mpi

Move common mutex implementations to a MI place.

Archs not yet converted can to the jump by defining __USE_MI_MUTEX.

ok visa@


# 1.28 21-Oct-2017 visa

Use MI mplock on mips64.

OK mpi@


Revision tags: OPENBSD_6_2_BASE
# 1.27 21-May-2017 visa

Enable radeondrm(4) on loongson to get accelerated graphics
with the RS780E chipset.

OK kettenis@, jsg@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE OPENBSD_6_1_BASE
# 1.26 09-Sep-2015 visa

The mplock implementations on MP-enabled mips64 platforms, octeon and
sgi, are identical. Put one implementation in mips64 and drop the
platform-specific copies, to remove duplicated code.

ok miod@


# 1.25 15-Aug-2015 miod

Some bits for Loongson 3A support.


Revision tags: OPENBSD_5_8_BASE
# 1.24 17-Jul-2015 tedu

remove obsolete INET kernel option


# 1.23 08-Jul-2015 dlg

unify the mutex implementations on all the mips64 platforms.

this basically copies the sgi implementation to mips64 and removes
it from the rest. this way they get an optimised UP mutex implementation
and correct asserts on all platforms.

ok miod@ jmatthew@


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE
# 1.22 22-Mar-2014 miod

Second draft of my attempt to workaround the infamous R4000 end-of-page errata,
affecting R4000 processors revision 2.x and below (found on most R4000 Indigo
and a few R4000 Indy).

Since this errata gets triggered by TLB misses when the code flow crosses a
page boundary, this code attempts to identify code pages prone to trigger the
errata, and force the next page to be mapped for at least as long as the
current pc lies in the troublesome page, by creating wiring extra TLB entries.
These entries get recycled in a lazy-but-aggressive-enough way, either because
of context switches, or because of further tlb exceptions reaching trap().

The errata workaround code is only compiled on R4000-capable kernels (i.e.
sgi GENERIC-IP22 and nothing else), and only enabled on affected processors
(i.e. not on R4000 revision 3, or on R4400).

There is still room for improvemnt in unlucky cases, but in this simple enough
incarnation, this allows my R4000 2.2 Indigo to finally reliably boot multiuser,
even though both /sbin/init and /bin/sh contain code pages which can trigger
the errata.


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 29-Sep-2012 miod

Basic R8000 processor support. R8000 processors require MMU-specific code,
exception-specific code, clock-specific code, and L1 cache-specific code. L2
cache is per-design, of which only two exist: SGI Power Indigo2 (IP26) and SGI
Power Challenge (IP21) and are not covered by this commit.

R8000 processors also are 64-bit only processors with 64-bit coprocessor 0
registers, and lack so-called ``compatibility'' memory spaces allowing 32-bit
code to run with sign-extended addresses and registers.

The intrusive changes are covered by #ifdef CPU_R8000 stanzas. However,
trap() is split into a high-level wrapper and a new function, itsa(),
responsible for the actual trap servicing (which name couldn't be helped
because I'm an incorrigible punster). While an R8000 exception may cause
(via trap() ) multiple exceptions to be serviced, non-R8000 processors will
always service one exception in trap(), but they are nevertheless affected
by this code split.


Revision tags: OPENBSD_5_2_BASE
# 1.20 23-Jun-2012 miod

Replace R5000 and R10000 family assembly cache routines with C equivalents,
which will be easier to maintain on the long run. Be sure to rm cache_r*.d in
your kernel compile directories after updating.


# 1.19 27-May-2012 miod

Replace Loongson2F assembly cache routines with equivalent C code. This will
make future maintainance easier.


# 1.18 28-Mar-2012 miod

Work in progress support for the SGI Indigo, Indigo 2 and Indy systems
(IP20, IP22, IP24) in 64-bit mode, adapated from NetBSD. Currently limited
to headless operation, input and video drivers will get ported soon.

Should work on all R4000, R4440 and R5000 based systems. L2 cache on R5000SC
Indy not supported yet (coming soon), R4600 not supported yet either (coming
soon as well).

Tested to boot multiuser on: Indigo2 R4000SC, Indy R4000PC, Indy R4000SC,
Indy R5000SC, Indigo2 R4400SC. There are still glitches in the Ethernet driver
which are being looked at.

Expansion support is limited to the GIO E++ board; GIO boards with PCI-GIO
bridges not ported yet due to the lack of hardware, and this kind of driver
does not port blindly.

Most of this work comes from NetBSD, polishing and integration work, as well
as putting as many ``R4x00 in 64-bit mode'' erratas as necessary, by yours
truly.

More work is coming, as well as trying to get some easy way to boot install
kernels (as older PROM can only boot ECOFF binaries, which won't do for the
kernel).


Revision tags: OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE
# 1.17 24-Oct-2010 miod

Move build_trampoline() and setregs() to a common location for all mips ports.


# 1.16 21-Sep-2010 miod

Replace the old floating point completion code with a C interface to the
MI softfloat code, implementing all MIPS IV specified floating point
operations.
Tested on R5000, R10000, R14000 and Loongson2F.


# 1.15 20-Sep-2010 syuu

cache operations for octeon. ok miod@


Revision tags: OPENBSD_4_7_BASE OPENBSD_4_8_BASE
# 1.14 12-Dec-2009 miod

Introduce various CPU_### options to enable cpu-specific code or workarounds;
be sure to rerun config(8) on your kernel configuration files.


# 1.13 25-Nov-2009 syuu

IP30 IPI implementation.
Also few xheart modification for SMP.
ok miod@


# 1.12 06-Aug-2009 miod

Work in progress support for Loongson2E/2F processors; need option CPU_LOONGSON2
in the kernel to be brought in, due to invasive differences in tlb operation.
Comes with a separate cache operations file due to the cache being R5k-style
with R10k-style way number encoding.


Revision tags: OPENBSD_4_6_BASE
# 1.11 13-Jun-2009 miod

Enumerate all available nodes for hardware on IP27/IP35 systems; works to some
extent, but isp(4) on other nodes do not work correctly yet.


# 1.10 20-Mar-2009 miod

Switch sgi to __HAVE_GENERIC_SOFT_INTERRUPTS.


Revision tags: OPENBSD_4_2_BASE OPENBSD_4_3_BASE OPENBSD_4_4_BASE OPENBSD_4_5_BASE
# 1.9 21-Jun-2007 miod

Extent sgi bus_dma to cope with different views of memory: non-contiguous
for the cpu, contiguous from different bases for devices. This allows
memory above 256MB to be used with bus_dma (and we had really been lucky
with the first few large-memory builds).
Information about memory accesses taken from Linux.


# 1.8 18-Jun-2007 deraadt

this is the sgi disksubr, not some mythical "all mips64 architectures can use it" balony


Revision tags: OPENBSD_3_8_BASE OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE
# 1.7 14-Jul-2005 uwe

More netccitt and netns removals; OK henning, brad, mickey


# 1.6 02-May-2005 deraadt

obvious typo, designed to break the tree, brad, hmm?


# 1.5 01-May-2005 brad

To allow for MD override of in4_cksum()...

ok deraadt@


Revision tags: OPENBSD_3_7_BASE
# 1.4 08-Oct-2004 grange

disksubr.c should depend on disk.

ok pefo@ miod@


# 1.3 20-Sep-2004 pefo

Add support for R10K cpu class


Revision tags: OPENBSD_3_6_BASE
# 1.2 09-Aug-2004 pefo

Big cleanup. Removed some unused obsolete stuff and fixed copyrights
on some files. Arcbios support is now in, thus detects memorysize and cpu
clock frequency.


# 1.1 06-Aug-2004 pefo

initial mips64


# 1.30 01-May-2021 visa

Retire OpenBSD/sgi.

OK deraadt@


Revision tags: OPENBSD_6_3_BASE OPENBSD_6_4_BASE OPENBSD_6_5_BASE OPENBSD_6_6_BASE OPENBSD_6_7_BASE OPENBSD_6_8_BASE OPENBSD_6_9_BASE
# 1.29 25-Jan-2018 mpi

Move common mutex implementations to a MI place.

Archs not yet converted can to the jump by defining __USE_MI_MUTEX.

ok visa@


# 1.28 21-Oct-2017 visa

Use MI mplock on mips64.

OK mpi@


Revision tags: OPENBSD_6_2_BASE
# 1.27 21-May-2017 visa

Enable radeondrm(4) on loongson to get accelerated graphics
with the RS780E chipset.

OK kettenis@, jsg@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE OPENBSD_6_1_BASE
# 1.26 09-Sep-2015 visa

The mplock implementations on MP-enabled mips64 platforms, octeon and
sgi, are identical. Put one implementation in mips64 and drop the
platform-specific copies, to remove duplicated code.

ok miod@


# 1.25 15-Aug-2015 miod

Some bits for Loongson 3A support.


Revision tags: OPENBSD_5_8_BASE
# 1.24 17-Jul-2015 tedu

remove obsolete INET kernel option


# 1.23 08-Jul-2015 dlg

unify the mutex implementations on all the mips64 platforms.

this basically copies the sgi implementation to mips64 and removes
it from the rest. this way they get an optimised UP mutex implementation
and correct asserts on all platforms.

ok miod@ jmatthew@


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE
# 1.22 22-Mar-2014 miod

Second draft of my attempt to workaround the infamous R4000 end-of-page errata,
affecting R4000 processors revision 2.x and below (found on most R4000 Indigo
and a few R4000 Indy).

Since this errata gets triggered by TLB misses when the code flow crosses a
page boundary, this code attempts to identify code pages prone to trigger the
errata, and force the next page to be mapped for at least as long as the
current pc lies in the troublesome page, by creating wiring extra TLB entries.
These entries get recycled in a lazy-but-aggressive-enough way, either because
of context switches, or because of further tlb exceptions reaching trap().

The errata workaround code is only compiled on R4000-capable kernels (i.e.
sgi GENERIC-IP22 and nothing else), and only enabled on affected processors
(i.e. not on R4000 revision 3, or on R4400).

There is still room for improvemnt in unlucky cases, but in this simple enough
incarnation, this allows my R4000 2.2 Indigo to finally reliably boot multiuser,
even though both /sbin/init and /bin/sh contain code pages which can trigger
the errata.


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 29-Sep-2012 miod

Basic R8000 processor support. R8000 processors require MMU-specific code,
exception-specific code, clock-specific code, and L1 cache-specific code. L2
cache is per-design, of which only two exist: SGI Power Indigo2 (IP26) and SGI
Power Challenge (IP21) and are not covered by this commit.

R8000 processors also are 64-bit only processors with 64-bit coprocessor 0
registers, and lack so-called ``compatibility'' memory spaces allowing 32-bit
code to run with sign-extended addresses and registers.

The intrusive changes are covered by #ifdef CPU_R8000 stanzas. However,
trap() is split into a high-level wrapper and a new function, itsa(),
responsible for the actual trap servicing (which name couldn't be helped
because I'm an incorrigible punster). While an R8000 exception may cause
(via trap() ) multiple exceptions to be serviced, non-R8000 processors will
always service one exception in trap(), but they are nevertheless affected
by this code split.


Revision tags: OPENBSD_5_2_BASE
# 1.20 23-Jun-2012 miod

Replace R5000 and R10000 family assembly cache routines with C equivalents,
which will be easier to maintain on the long run. Be sure to rm cache_r*.d in
your kernel compile directories after updating.


# 1.19 27-May-2012 miod

Replace Loongson2F assembly cache routines with equivalent C code. This will
make future maintainance easier.


# 1.18 28-Mar-2012 miod

Work in progress support for the SGI Indigo, Indigo 2 and Indy systems
(IP20, IP22, IP24) in 64-bit mode, adapated from NetBSD. Currently limited
to headless operation, input and video drivers will get ported soon.

Should work on all R4000, R4440 and R5000 based systems. L2 cache on R5000SC
Indy not supported yet (coming soon), R4600 not supported yet either (coming
soon as well).

Tested to boot multiuser on: Indigo2 R4000SC, Indy R4000PC, Indy R4000SC,
Indy R5000SC, Indigo2 R4400SC. There are still glitches in the Ethernet driver
which are being looked at.

Expansion support is limited to the GIO E++ board; GIO boards with PCI-GIO
bridges not ported yet due to the lack of hardware, and this kind of driver
does not port blindly.

Most of this work comes from NetBSD, polishing and integration work, as well
as putting as many ``R4x00 in 64-bit mode'' erratas as necessary, by yours
truly.

More work is coming, as well as trying to get some easy way to boot install
kernels (as older PROM can only boot ECOFF binaries, which won't do for the
kernel).


Revision tags: OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE
# 1.17 24-Oct-2010 miod

Move build_trampoline() and setregs() to a common location for all mips ports.


# 1.16 21-Sep-2010 miod

Replace the old floating point completion code with a C interface to the
MI softfloat code, implementing all MIPS IV specified floating point
operations.
Tested on R5000, R10000, R14000 and Loongson2F.


# 1.15 20-Sep-2010 syuu

cache operations for octeon. ok miod@


Revision tags: OPENBSD_4_7_BASE OPENBSD_4_8_BASE
# 1.14 12-Dec-2009 miod

Introduce various CPU_### options to enable cpu-specific code or workarounds;
be sure to rerun config(8) on your kernel configuration files.


# 1.13 25-Nov-2009 syuu

IP30 IPI implementation.
Also few xheart modification for SMP.
ok miod@


# 1.12 06-Aug-2009 miod

Work in progress support for Loongson2E/2F processors; need option CPU_LOONGSON2
in the kernel to be brought in, due to invasive differences in tlb operation.
Comes with a separate cache operations file due to the cache being R5k-style
with R10k-style way number encoding.


Revision tags: OPENBSD_4_6_BASE
# 1.11 13-Jun-2009 miod

Enumerate all available nodes for hardware on IP27/IP35 systems; works to some
extent, but isp(4) on other nodes do not work correctly yet.


# 1.10 20-Mar-2009 miod

Switch sgi to __HAVE_GENERIC_SOFT_INTERRUPTS.


Revision tags: OPENBSD_4_2_BASE OPENBSD_4_3_BASE OPENBSD_4_4_BASE OPENBSD_4_5_BASE
# 1.9 21-Jun-2007 miod

Extent sgi bus_dma to cope with different views of memory: non-contiguous
for the cpu, contiguous from different bases for devices. This allows
memory above 256MB to be used with bus_dma (and we had really been lucky
with the first few large-memory builds).
Information about memory accesses taken from Linux.


# 1.8 18-Jun-2007 deraadt

this is the sgi disksubr, not some mythical "all mips64 architectures can use it" balony


Revision tags: OPENBSD_3_8_BASE OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE
# 1.7 14-Jul-2005 uwe

More netccitt and netns removals; OK henning, brad, mickey


# 1.6 02-May-2005 deraadt

obvious typo, designed to break the tree, brad, hmm?


# 1.5 01-May-2005 brad

To allow for MD override of in4_cksum()...

ok deraadt@


Revision tags: OPENBSD_3_7_BASE
# 1.4 08-Oct-2004 grange

disksubr.c should depend on disk.

ok pefo@ miod@


# 1.3 20-Sep-2004 pefo

Add support for R10K cpu class


Revision tags: OPENBSD_3_6_BASE
# 1.2 09-Aug-2004 pefo

Big cleanup. Removed some unused obsolete stuff and fixed copyrights
on some files. Arcbios support is now in, thus detects memorysize and cpu
clock frequency.


# 1.1 06-Aug-2004 pefo

initial mips64


# 1.29 25-Jan-2018 mpi

Move common mutex implementations to a MI place.

Archs not yet converted can to the jump by defining __USE_MI_MUTEX.

ok visa@


# 1.28 21-Oct-2017 visa

Use MI mplock on mips64.

OK mpi@


Revision tags: OPENBSD_6_2_BASE
# 1.27 21-May-2017 visa

Enable radeondrm(4) on loongson to get accelerated graphics
with the RS780E chipset.

OK kettenis@, jsg@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE OPENBSD_6_1_BASE
# 1.26 09-Sep-2015 visa

The mplock implementations on MP-enabled mips64 platforms, octeon and
sgi, are identical. Put one implementation in mips64 and drop the
platform-specific copies, to remove duplicated code.

ok miod@


# 1.25 15-Aug-2015 miod

Some bits for Loongson 3A support.


Revision tags: OPENBSD_5_8_BASE
# 1.24 17-Jul-2015 tedu

remove obsolete INET kernel option


# 1.23 08-Jul-2015 dlg

unify the mutex implementations on all the mips64 platforms.

this basically copies the sgi implementation to mips64 and removes
it from the rest. this way they get an optimised UP mutex implementation
and correct asserts on all platforms.

ok miod@ jmatthew@


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE
# 1.22 22-Mar-2014 miod

Second draft of my attempt to workaround the infamous R4000 end-of-page errata,
affecting R4000 processors revision 2.x and below (found on most R4000 Indigo
and a few R4000 Indy).

Since this errata gets triggered by TLB misses when the code flow crosses a
page boundary, this code attempts to identify code pages prone to trigger the
errata, and force the next page to be mapped for at least as long as the
current pc lies in the troublesome page, by creating wiring extra TLB entries.
These entries get recycled in a lazy-but-aggressive-enough way, either because
of context switches, or because of further tlb exceptions reaching trap().

The errata workaround code is only compiled on R4000-capable kernels (i.e.
sgi GENERIC-IP22 and nothing else), and only enabled on affected processors
(i.e. not on R4000 revision 3, or on R4400).

There is still room for improvemnt in unlucky cases, but in this simple enough
incarnation, this allows my R4000 2.2 Indigo to finally reliably boot multiuser,
even though both /sbin/init and /bin/sh contain code pages which can trigger
the errata.


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 29-Sep-2012 miod

Basic R8000 processor support. R8000 processors require MMU-specific code,
exception-specific code, clock-specific code, and L1 cache-specific code. L2
cache is per-design, of which only two exist: SGI Power Indigo2 (IP26) and SGI
Power Challenge (IP21) and are not covered by this commit.

R8000 processors also are 64-bit only processors with 64-bit coprocessor 0
registers, and lack so-called ``compatibility'' memory spaces allowing 32-bit
code to run with sign-extended addresses and registers.

The intrusive changes are covered by #ifdef CPU_R8000 stanzas. However,
trap() is split into a high-level wrapper and a new function, itsa(),
responsible for the actual trap servicing (which name couldn't be helped
because I'm an incorrigible punster). While an R8000 exception may cause
(via trap() ) multiple exceptions to be serviced, non-R8000 processors will
always service one exception in trap(), but they are nevertheless affected
by this code split.


Revision tags: OPENBSD_5_2_BASE
# 1.20 23-Jun-2012 miod

Replace R5000 and R10000 family assembly cache routines with C equivalents,
which will be easier to maintain on the long run. Be sure to rm cache_r*.d in
your kernel compile directories after updating.


# 1.19 27-May-2012 miod

Replace Loongson2F assembly cache routines with equivalent C code. This will
make future maintainance easier.


# 1.18 28-Mar-2012 miod

Work in progress support for the SGI Indigo, Indigo 2 and Indy systems
(IP20, IP22, IP24) in 64-bit mode, adapated from NetBSD. Currently limited
to headless operation, input and video drivers will get ported soon.

Should work on all R4000, R4440 and R5000 based systems. L2 cache on R5000SC
Indy not supported yet (coming soon), R4600 not supported yet either (coming
soon as well).

Tested to boot multiuser on: Indigo2 R4000SC, Indy R4000PC, Indy R4000SC,
Indy R5000SC, Indigo2 R4400SC. There are still glitches in the Ethernet driver
which are being looked at.

Expansion support is limited to the GIO E++ board; GIO boards with PCI-GIO
bridges not ported yet due to the lack of hardware, and this kind of driver
does not port blindly.

Most of this work comes from NetBSD, polishing and integration work, as well
as putting as many ``R4x00 in 64-bit mode'' erratas as necessary, by yours
truly.

More work is coming, as well as trying to get some easy way to boot install
kernels (as older PROM can only boot ECOFF binaries, which won't do for the
kernel).


Revision tags: OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE
# 1.17 24-Oct-2010 miod

Move build_trampoline() and setregs() to a common location for all mips ports.


# 1.16 21-Sep-2010 miod

Replace the old floating point completion code with a C interface to the
MI softfloat code, implementing all MIPS IV specified floating point
operations.
Tested on R5000, R10000, R14000 and Loongson2F.


# 1.15 20-Sep-2010 syuu

cache operations for octeon. ok miod@


Revision tags: OPENBSD_4_7_BASE OPENBSD_4_8_BASE
# 1.14 12-Dec-2009 miod

Introduce various CPU_### options to enable cpu-specific code or workarounds;
be sure to rerun config(8) on your kernel configuration files.


# 1.13 25-Nov-2009 syuu

IP30 IPI implementation.
Also few xheart modification for SMP.
ok miod@


# 1.12 06-Aug-2009 miod

Work in progress support for Loongson2E/2F processors; need option CPU_LOONGSON2
in the kernel to be brought in, due to invasive differences in tlb operation.
Comes with a separate cache operations file due to the cache being R5k-style
with R10k-style way number encoding.


Revision tags: OPENBSD_4_6_BASE
# 1.11 13-Jun-2009 miod

Enumerate all available nodes for hardware on IP27/IP35 systems; works to some
extent, but isp(4) on other nodes do not work correctly yet.


# 1.10 20-Mar-2009 miod

Switch sgi to __HAVE_GENERIC_SOFT_INTERRUPTS.


Revision tags: OPENBSD_4_2_BASE OPENBSD_4_3_BASE OPENBSD_4_4_BASE OPENBSD_4_5_BASE
# 1.9 21-Jun-2007 miod

Extent sgi bus_dma to cope with different views of memory: non-contiguous
for the cpu, contiguous from different bases for devices. This allows
memory above 256MB to be used with bus_dma (and we had really been lucky
with the first few large-memory builds).
Information about memory accesses taken from Linux.


# 1.8 18-Jun-2007 deraadt

this is the sgi disksubr, not some mythical "all mips64 architectures can use it" balony


Revision tags: OPENBSD_3_8_BASE OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE
# 1.7 14-Jul-2005 uwe

More netccitt and netns removals; OK henning, brad, mickey


# 1.6 02-May-2005 deraadt

obvious typo, designed to break the tree, brad, hmm?


# 1.5 01-May-2005 brad

To allow for MD override of in4_cksum()...

ok deraadt@


Revision tags: OPENBSD_3_7_BASE
# 1.4 08-Oct-2004 grange

disksubr.c should depend on disk.

ok pefo@ miod@


# 1.3 20-Sep-2004 pefo

Add support for R10K cpu class


Revision tags: OPENBSD_3_6_BASE
# 1.2 09-Aug-2004 pefo

Big cleanup. Removed some unused obsolete stuff and fixed copyrights
on some files. Arcbios support is now in, thus detects memorysize and cpu
clock frequency.


# 1.1 06-Aug-2004 pefo

initial mips64


# 1.28 21-Oct-2017 visa

Use MI mplock on mips64.

OK mpi@


Revision tags: OPENBSD_6_2_BASE
# 1.27 21-May-2017 visa

Enable radeondrm(4) on loongson to get accelerated graphics
with the RS780E chipset.

OK kettenis@, jsg@


Revision tags: OPENBSD_5_9_BASE OPENBSD_6_0_BASE OPENBSD_6_1_BASE
# 1.26 09-Sep-2015 visa

The mplock implementations on MP-enabled mips64 platforms, octeon and
sgi, are identical. Put one implementation in mips64 and drop the
platform-specific copies, to remove duplicated code.

ok miod@


# 1.25 15-Aug-2015 miod

Some bits for Loongson 3A support.


Revision tags: OPENBSD_5_8_BASE
# 1.24 17-Jul-2015 tedu

remove obsolete INET kernel option


# 1.23 08-Jul-2015 dlg

unify the mutex implementations on all the mips64 platforms.

this basically copies the sgi implementation to mips64 and removes
it from the rest. this way they get an optimised UP mutex implementation
and correct asserts on all platforms.

ok miod@ jmatthew@


Revision tags: OPENBSD_5_6_BASE OPENBSD_5_7_BASE
# 1.22 22-Mar-2014 miod

Second draft of my attempt to workaround the infamous R4000 end-of-page errata,
affecting R4000 processors revision 2.x and below (found on most R4000 Indigo
and a few R4000 Indy).

Since this errata gets triggered by TLB misses when the code flow crosses a
page boundary, this code attempts to identify code pages prone to trigger the
errata, and force the next page to be mapped for at least as long as the
current pc lies in the troublesome page, by creating wiring extra TLB entries.
These entries get recycled in a lazy-but-aggressive-enough way, either because
of context switches, or because of further tlb exceptions reaching trap().

The errata workaround code is only compiled on R4000-capable kernels (i.e.
sgi GENERIC-IP22 and nothing else), and only enabled on affected processors
(i.e. not on R4000 revision 3, or on R4400).

There is still room for improvemnt in unlucky cases, but in this simple enough
incarnation, this allows my R4000 2.2 Indigo to finally reliably boot multiuser,
even though both /sbin/init and /bin/sh contain code pages which can trigger
the errata.


Revision tags: OPENBSD_5_3_BASE OPENBSD_5_4_BASE OPENBSD_5_5_BASE
# 1.21 29-Sep-2012 miod

Basic R8000 processor support. R8000 processors require MMU-specific code,
exception-specific code, clock-specific code, and L1 cache-specific code. L2
cache is per-design, of which only two exist: SGI Power Indigo2 (IP26) and SGI
Power Challenge (IP21) and are not covered by this commit.

R8000 processors also are 64-bit only processors with 64-bit coprocessor 0
registers, and lack so-called ``compatibility'' memory spaces allowing 32-bit
code to run with sign-extended addresses and registers.

The intrusive changes are covered by #ifdef CPU_R8000 stanzas. However,
trap() is split into a high-level wrapper and a new function, itsa(),
responsible for the actual trap servicing (which name couldn't be helped
because I'm an incorrigible punster). While an R8000 exception may cause
(via trap() ) multiple exceptions to be serviced, non-R8000 processors will
always service one exception in trap(), but they are nevertheless affected
by this code split.


Revision tags: OPENBSD_5_2_BASE
# 1.20 23-Jun-2012 miod

Replace R5000 and R10000 family assembly cache routines with C equivalents,
which will be easier to maintain on the long run. Be sure to rm cache_r*.d in
your kernel compile directories after updating.


# 1.19 27-May-2012 miod

Replace Loongson2F assembly cache routines with equivalent C code. This will
make future maintainance easier.


# 1.18 28-Mar-2012 miod

Work in progress support for the SGI Indigo, Indigo 2 and Indy systems
(IP20, IP22, IP24) in 64-bit mode, adapated from NetBSD. Currently limited
to headless operation, input and video drivers will get ported soon.

Should work on all R4000, R4440 and R5000 based systems. L2 cache on R5000SC
Indy not supported yet (coming soon), R4600 not supported yet either (coming
soon as well).

Tested to boot multiuser on: Indigo2 R4000SC, Indy R4000PC, Indy R4000SC,
Indy R5000SC, Indigo2 R4400SC. There are still glitches in the Ethernet driver
which are being looked at.

Expansion support is limited to the GIO E++ board; GIO boards with PCI-GIO
bridges not ported yet due to the lack of hardware, and this kind of driver
does not port blindly.

Most of this work comes from NetBSD, polishing and integration work, as well
as putting as many ``R4x00 in 64-bit mode'' erratas as necessary, by yours
truly.

More work is coming, as well as trying to get some easy way to boot install
kernels (as older PROM can only boot ECOFF binaries, which won't do for the
kernel).


Revision tags: OPENBSD_4_9_BASE OPENBSD_5_0_BASE OPENBSD_5_1_BASE
# 1.17 24-Oct-2010 miod

Move build_trampoline() and setregs() to a common location for all mips ports.


# 1.16 21-Sep-2010 miod

Replace the old floating point completion code with a C interface to the
MI softfloat code, implementing all MIPS IV specified floating point
operations.
Tested on R5000, R10000, R14000 and Loongson2F.


# 1.15 20-Sep-2010 syuu

cache operations for octeon. ok miod@


Revision tags: OPENBSD_4_7_BASE OPENBSD_4_8_BASE
# 1.14 12-Dec-2009 miod

Introduce various CPU_### options to enable cpu-specific code or workarounds;
be sure to rerun config(8) on your kernel configuration files.


# 1.13 25-Nov-2009 syuu

IP30 IPI implementation.
Also few xheart modification for SMP.
ok miod@


# 1.12 06-Aug-2009 miod

Work in progress support for Loongson2E/2F processors; need option CPU_LOONGSON2
in the kernel to be brought in, due to invasive differences in tlb operation.
Comes with a separate cache operations file due to the cache being R5k-style
with R10k-style way number encoding.


Revision tags: OPENBSD_4_6_BASE
# 1.11 13-Jun-2009 miod

Enumerate all available nodes for hardware on IP27/IP35 systems; works to some
extent, but isp(4) on other nodes do not work correctly yet.


# 1.10 20-Mar-2009 miod

Switch sgi to __HAVE_GENERIC_SOFT_INTERRUPTS.


Revision tags: OPENBSD_4_2_BASE OPENBSD_4_3_BASE OPENBSD_4_4_BASE OPENBSD_4_5_BASE
# 1.9 21-Jun-2007 miod

Extent sgi bus_dma to cope with different views of memory: non-contiguous
for the cpu, contiguous from different bases for devices. This allows
memory above 256MB to be used with bus_dma (and we had really been lucky
with the first few large-memory builds).
Information about memory accesses taken from Linux.


# 1.8 18-Jun-2007 deraadt

this is the sgi disksubr, not some mythical "all mips64 architectures can use it" balony


Revision tags: OPENBSD_3_8_BASE OPENBSD_3_9_BASE OPENBSD_4_0_BASE OPENBSD_4_1_BASE
# 1.7 14-Jul-2005 uwe

More netccitt and netns removals; OK henning, brad, mickey


# 1.6 02-May-2005 deraadt

obvious typo, designed to break the tree, brad, hmm?


# 1.5 01-May-2005 brad

To allow for MD override of in4_cksum()...

ok deraadt@


Revision tags: OPENBSD_3_7_BASE
# 1.4 08-Oct-2004 grange

disksubr.c should depend on disk.

ok pefo@ miod@


# 1.3 20-Sep-2004 pefo

Add support for R10K cpu class


Revision tags: OPENBSD_3_6_BASE
# 1.2 09-Aug-2004 pefo

Big cleanup. Removed some unused obsolete stuff and fixed copyrights
on some files. Arcbios support is now in, thus detects memorysize and cpu
clock frequency.


# 1.1 06-Aug-2004 pefo

initial mips64