Home | History | Annotate | Download | only in include
History log of /src/sys/arch/next68k/include/bus_space.h
RevisionDateAuthorComments
 1.23  11-Feb-2023  tsutsui Handle NeXT Turbo VRAM regions properly.

Info from Andreas Grabher on port-next68k@:
https://mail-index.netbsd.org/port-next68k/2023/02/06/msg000052.html

Also refactor bus_space_map(9) and fix (unused) bus_space_mmap(9).
 1.22  03-Feb-2023  tsutsui Use proper C99 int types.
 1.21  03-Feb-2023  tsutsui Misc KNF and cosmetics.
 1.20  27-Jan-2023  tsutsui next68k: Specify proper constraints for bus_space_read region and multi ops.

These functions write the read data into memory at a specified pointer,
but without the "memory" constraint gcc could optimize out these ops
if the memory is allocated on local stack.

With this fix nextkbd(4) works again.

Should be pulled up to netbsd-10 and netbsd-9.
 1.19  23-Jan-2021  christos branches: 1.19.18;
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.18  02-Apr-2020  msaitoh branches: 1.18.4;
s/impliment/implement/ in comment.
 1.17  23-Sep-2019  skrll Provide PRIxBUSADDR, PRIxBUSSIZE, PRIuBUSSIZE, and PRIxBSH for all arches
to follow arm and (generic) mips.

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

Approved by releng.
 1.15  28-Apr-2008  martin branches: 1.15.34; 1.15.38;
Remove clause 3 and 4 from TNF licenses
 1.14  16-Feb-2006  perry branches: 1.14.68; 1.14.70; 1.14.72;
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  19-Jan-2005  chs branches: 1.11.8;
de-__P, remove register, ansify.
 1.10  01-Oct-2003  mycroft branches: 1.10.8;
Some small cleanup -- make the base,limit values vaddr_t, not char*.
Also add some code that attempts to deal with C16_VIDEO interrupts, though it
does not seem to make my color slabs work again.
 1.9  11-Sep-2002  mycroft branches: 1.9.6;
Comprehensive patches from Christian Limpach:
* Fix problems with the DMA and SCSI drivers.
* Make turbo machines sort of work.
Additional fixes from me:
* Determine if we're a turbo at boot time, by looking at the ROM machine type.
* Set the display size correctly (1120 pixels wide, but padded to 1152 only on
non-turbo machines).
Caveats:
* SCSI doesn't work on the turbo (or at least it blows chunks with no devices
attached).
* Media selection doesn't work on the turbo (the BMAP stuff doesn't exist on
turbo machines).
* The boot block is prone to timing out.
 1.8  11-Jun-2002  deberg bus_space_mmap(), same as atari port. untested, as it is unused.
 1.7  12-May-2001  chs branches: 1.7.2; 1.7.8; 1.7.16;
switch next68k to ELF. highlight include:
add "%" prefix to register names in assembly code.
change assembly functions to return pointer values in %a0 instead of %d0.
C symbols no longer prepend an underscore, adjust assembly code for this.
32-bit values are now 32-bit aligned instead of 16-bit aligned,
adjust structure packing and padding to override this where necessary.
make EXEC_ELF std, make EXEC_AOUT and COMPAT_AOUT_M68K optional.
use the MI loadfile() instead of several home-grown versions.
 1.6  29-Sep-2000  deberg branches: 1.6.2;
add support for 12-bit color displays, from Timm Wetzel w/ changes by
me. closes 10741.
 1.5  10-Apr-1999  drochner branches: 1.5.2; 1.5.12;
add BUS_SPACE_ALIGNED_POINTER() definitions for completeness
 1.4  24-Mar-1999  dbj branches: 1.4.4;
Applied patches from Matt Debergalis <deberg@mit.edu>.
These patches include:
Added framebuffer mapping for color framebuffer to support color wscons
which is coming soon.
Renamed wskbdmap_mfii[ch] to wskbdmap_next[ch]
Changed video to be white on black instead of black on white.
Now handles and discards mouse interrupts.
Video and keyboard is now working on mono machines.
 1.3  02-Jan-1999  dbj Applied supplied patches from pr port-next68k/6709
add bus_space support for mono framebuffer
 1.2  05-Jul-1998  dbj Started the esp scsi driver.
Fixed bus_space_handle_t in nextdma device.
Fixed scsi interrupt define.
 1.1  09-Jun-1998  dbj branches: 1.1.1;
Initial revision
 1.1.1.1  09-Jun-1998  dbj Initial import of NetBSD/next68k.
 1.4.4.1  21-Jun-1999  thorpej Sync w/ -current.
 1.5.12.1  06-Oct-2000  deberg pullup 1.6, approved by thorpej

add support for 12-bit color displays, from Timm Wetzel w/ changes by
me. closes 10741.
 1.5.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.2.1  21-Jun-2001  nathanw Catch up to -current.
 1.7.16.1  15-Jul-2002  gehenna catch up with -current.
 1.7.8.3  17-Sep-2002  nathanw Catch up to -current.
 1.7.8.2  20-Jun-2002  nathanw Catch up to -current.
 1.7.8.1  12-May-2001  nathanw file bus_space.h was added on branch nathanw_sa on 2002-06-20 03:40:22 +0000
 1.7.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.7.2.1  23-Jun-2002  jdolecek catch up with -current on kqueue branch
 1.9.6.4  24-Jan-2005  skrll Sync with HEAD.
 1.9.6.3  21-Sep-2004  skrll Fix the sync with head I botched.
 1.9.6.2  18-Sep-2004  skrll Sync with HEAD.
 1.9.6.1  03-Aug-2004  skrll Sync with HEAD
 1.10.8.1  29-Apr-2005  kent sync with -current
 1.11.8.1  21-Jun-2006  yamt 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.1  18-Feb-2006  yamt sync with head.
 1.14.72.1  16-May-2008  yamt sync with head.
 1.14.70.1  18-May-2008  yamt sync with head.
 1.14.68.1  02-Jun-2008  mjf Sync with HEAD.
 1.15.38.1  18-Feb-2012  mrg merge to -current.
 1.15.34.1  17-Apr-2012  yamt sync with head
 1.16.52.2  15-Feb-2023  martin Pull up following revision(s) (requested by tsutsui in ticket #1598):

sys/arch/next68k/next68k/nextrom.h: revision 1.13
sys/arch/next68k/dev/nextdisplayvar.h: revision 1.6
sys/arch/next68k/dev/intiovar.h: revision 1.8
sys/arch/next68k/dev/nextcons.c: revision 1.12
sys/arch/next68k/next68k/locore.s: revision 1.69
sys/arch/next68k/dev/nextcons.c: revision 1.13
sys/arch/next68k/dev/nextcons.c: revision 1.14
sys/arch/next68k/include/bus_space.h: revision 1.18
sys/arch/next68k/dev/nextdisplay.c: revision 1.30
sys/arch/next68k/include/bus_space.h: revision 1.19
sys/arch/next68k/stand/boot/boot.c: revision 1.13
sys/arch/next68k/next68k/nextrom.c: revision 1.28
sys/arch/next68k/next68k/nextrom.c: revision 1.29
sys/arch/next68k/next68k/pmap_bootstrap.c: revision 1.46
sys/arch/next68k/next68k/pmap_bootstrap.c: revision 1.47
sys/arch/next68k/include/cpu.h: revision 1.52
sys/arch/next68k/dev/intio.c: revision 1.17 (patch)
sys/arch/next68k/dev/intio.c: revision 1.18 (patch)
sys/arch/next68k/dev/intio.c: revision 1.19 (patch)
sys/arch/next68k/next68k/locore.s: revision 1.72
sys/arch/next68k/stand/boot/version: revision 1.6
sys/arch/next68k/include/bus_space.h: revision 1.21
sys/arch/next68k/include/bus_space.h: revision 1.22
sys/arch/next68k/dev/nextdisplay.c: revision 1.26
sys/arch/next68k/include/bus_space.h: revision 1.23
sys/arch/next68k/dev/nextdisplay.c: revision 1.27
sys/arch/next68k/dev/nextdisplay.c: revision 1.28
sys/arch/next68k/dev/nextdisplay.c: revision 1.29

s/impliment/implement/ in comment.

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.

Misc KNF and cosmetics.

Use proper C99 int types.

Remove trailing spaces and TABs.

Handle NeXT Turbo VRAM regions properly.
Info from Andreas Grabher on port-next68k@:
https://mail-index.netbsd.org/port-next68k/2023/02/06/msg000052.html

Also refactor bus_space_map(9) and fix (unused) bus_space_mmap(9).

Add and check machine type NeXT_CUBE_TURBO (type 8).
Info from Andreas Grabher on port-next68k@.

NeXT Turbo Color doesn't have NEXT_P_C16_CMD_REG.
Info from Andreas Grabher on port-next68k@.

Bump version again to denote NeXT_CUBE_TURBO support.
 1.16.52.1  01-Feb-2023  martin Pull up following revision(s) (requested by tsutsui in ticket #1581):

sys/arch/next68k/next68k/machdep.c: revision 1.117
sys/arch/next68k/dev/esp.c: revision 1.65
sys/arch/next68k/include/cpu.h: revision 1.51
sys/arch/next68k/include/bus_space.h: revision 1.20
sys/arch/next68k/next68k/clock.c: revision 1.13

next68k: Fix delay_divisor value for proper delay(9) on 68040.

next68k: Specify proper constraints for bus_space_read region and multi ops.

These functions write the read data into memory at a specified pointer,
but without the "memory" constraint gcc could optimize out these ops
if the memory is allocated on local stack.

With this fix nextkbd(4) works again.
Should be pulled up to netbsd-10 and netbsd-9.

next68k: Fix silent stall of next68k esp(4) SCSI.

next68k esp(4) driver requires nextdma(4) interrupts at ipl 6
during ncr53c9x_intr() for esp(4) at ipl 3. It worked on netbsd-5
and prior, but on netbsd-5 splbio() was changed from ipl 3 to 6
for SMP support and on netbsd-6 ncr53c9x driver was changed to
use mutex(9) instead of simple_lock(9), so nextdma interrupts
were no longer raised during ncr53c9x interrupt handler.

For now, just call mutex_exit(9) and mutex_enter(9) during
waiting nextdma(4) interrupts in MD esp_dma_intr() handler.

This could be wrong and the interrupt handler for nextdma should
be reorganized, but it just works.

Should be pulled up to netbsd-10 and netbsd-9.
 1.16.48.2  13-Apr-2020  martin Mostly merge changes from HEAD upto 20200411
 1.16.48.1  08-Apr-2020  martin Merge changes from current as of 20200406
 1.18.4.1  03-Apr-2021  thorpej Sync with HEAD.
 1.19.18.2  15-Feb-2023  martin Pull up following revision(s) (requested by tsutsui in ticket #88):

sys/arch/next68k/next68k/nextrom.h: revision 1.13
sys/arch/next68k/dev/nextdisplayvar.h: revision 1.6
sys/arch/next68k/dev/intiovar.h: revision 1.8
sys/arch/next68k/dev/nextcons.c: revision 1.12
sys/arch/next68k/next68k/locore.s: revision 1.69
sys/arch/next68k/dev/nextcons.c: revision 1.13
sys/arch/next68k/dev/nextcons.c: revision 1.14
sys/arch/next68k/dev/nextdisplay.c: revision 1.30
sys/arch/next68k/stand/boot/boot.c: revision 1.13
sys/arch/next68k/next68k/nextrom.c: revision 1.28
sys/arch/next68k/next68k/nextrom.c: revision 1.29
sys/arch/next68k/next68k/pmap_bootstrap.c: revision 1.46
sys/arch/next68k/next68k/pmap_bootstrap.c: revision 1.47
sys/arch/next68k/include/cpu.h: revision 1.52
sys/arch/next68k/dev/intio.c: revision 1.17
sys/arch/next68k/dev/intio.c: revision 1.18
sys/arch/next68k/dev/intio.c: revision 1.19
sys/arch/next68k/next68k/locore.s: revision 1.72
sys/arch/next68k/stand/boot/version: revision 1.6
sys/arch/next68k/include/bus_space.h: revision 1.21
sys/arch/next68k/include/bus_space.h: revision 1.22
sys/arch/next68k/dev/nextdisplay.c: revision 1.26
sys/arch/next68k/include/bus_space.h: revision 1.23
sys/arch/next68k/dev/nextdisplay.c: revision 1.27
sys/arch/next68k/dev/nextdisplay.c: revision 1.28
sys/arch/next68k/dev/nextdisplay.c: revision 1.29

Misc KNF and cosmetics.

Use proper C99 int types.

Remove trailing spaces and TABs.

Handle NeXT Turbo VRAM regions properly.
Info from Andreas Grabher on port-next68k@:
https://mail-index.netbsd.org/port-next68k/2023/02/06/msg000052.html

Also refactor bus_space_map(9) and fix (unused) bus_space_mmap(9).

Add and check machine type NeXT_CUBE_TURBO (type 8).
Info from Andreas Grabher on port-next68k@.

NeXT Turbo Color doesn't have NEXT_P_C16_CMD_REG.
Info from Andreas Grabher on port-next68k@.

Bump version again to denote NeXT_CUBE_TURBO support.
 1.19.18.1  01-Feb-2023  martin Pull up following revision(s) (requested by tsutsui in ticket #63):

sys/arch/next68k/next68k/machdep.c: revision 1.117
sys/arch/next68k/dev/esp.c: revision 1.65
sys/arch/next68k/include/cpu.h: revision 1.51
sys/arch/next68k/include/bus_space.h: revision 1.20
sys/arch/next68k/next68k/clock.c: revision 1.13

next68k: Fix delay_divisor value for proper delay(9) on 68040.

next68k: Specify proper constraints for bus_space_read region and multi ops.

These functions write the read data into memory at a specified pointer,
but without the "memory" constraint gcc could optimize out these ops
if the memory is allocated on local stack.

With this fix nextkbd(4) works again.
Should be pulled up to netbsd-10 and netbsd-9.

next68k: Fix silent stall of next68k esp(4) SCSI.

next68k esp(4) driver requires nextdma(4) interrupts at ipl 6
during ncr53c9x_intr() for esp(4) at ipl 3. It worked on netbsd-5
and prior, but on netbsd-5 splbio() was changed from ipl 3 to 6
for SMP support and on netbsd-6 ncr53c9x driver was changed to
use mutex(9) instead of simple_lock(9), so nextdma interrupts
were no longer raised during ncr53c9x interrupt handler.

For now, just call mutex_exit(9) and mutex_enter(9) during
waiting nextdma(4) interrupts in MD esp_dma_intr() handler.

This could be wrong and the interrupt handler for nextdma should
be reorganized, but it just works.

Should be pulled up to netbsd-10 and netbsd-9.

RSS XML Feed