kernel: add other needed map_buffers instances
authorAlan Cox <alan@linux.intel.com>
Sat, 6 Oct 2018 21:15:27 +0000 (22:15 +0100)
committerAlan Cox <alan@linux.intel.com>
Sat, 6 Oct 2018 21:15:27 +0000 (22:15 +0100)
As we add it to more stuff it may be more generally needed. For the moment
get the cases that matter

Kernel/cpu-z180/z180.s
Kernel/platform-genie-eg64/trs80-bank.s
Kernel/platform-pcw8256/pcw8256.s
Kernel/platform-rc2014-tiny/rc2014.s
Kernel/platform-sbcv2/sbcv2.s
Kernel/platform-ubee/ubee.s
Kernel/platform-z280rc/z280rc.s

index 52ad772..790bb65 100644 (file)
@@ -28,6 +28,7 @@
         .globl _switchin
         .globl _platform_switchout
         .globl _dofork
+       .globl map_buffers
         .globl map_kernel
         .globl map_process_always
         .globl map_kernel_di
@@ -773,6 +774,7 @@ switchinfail:
         call outstring
         jp _platform_monitor
 
+map_buffers:
 map_kernel_di:
 map_kernel: ; map the kernel into the low 60K, leaves common memory unchanged
         push af
index a788d93..4edbf40 100644 (file)
@@ -9,6 +9,7 @@
        .globl map_kernel
        .globl map_kernel_di
        .globl map_kernel_restore
+       .globl map_buffers
        .globl map_process
        .globl map_process_di
        .globl map_process_always
@@ -76,6 +77,7 @@ init_hardware:
 ;      mark the low 16K R/O to protect it from user but then need to
 ;      flip r/w on syscall and irq entry/exit.. FIXME.
 ;
+map_buffers:
 map_kernel:
 map_kernel_di:
 map_kernel_restore:
index 16cd75a..f13418f 100644 (file)
@@ -8,6 +8,7 @@
             .globl init_early
             .globl init_hardware
             .globl _program_vectors
+           .globl map_buffers
            .globl map_kernel
            .globl map_process
            .globl map_process_always
@@ -171,11 +172,13 @@ _program_vectors:
 ;
 ;      map_kernel              -       map in the kernel, trashes nothing
 ;      map_process_always      -       map in the current process, ditto
+;      map_buffers             -       map in the kernel + buffers, ditto
 ;      map_process             -       map the pages pointed to by hl, eats
 ;                                      a, hl
 ;
 kmap:      .db 0x80, 0x81, 0x82, 0x83
 
+map_buffers:
 map_kernel:
 map_kernel_di:
            push af
index 75063b0..6e327c9 100644 (file)
@@ -326,9 +326,11 @@ map_process_always_di:
 
 ;=========================================================================
 ; map_kernel - map kernel pages
+; map_buffers - map kernel and buffers (no difference for us)
 ; Inputs: none
 ; Outputs: none; all registers preserved
 ;=========================================================================
+map_buffers:
 map_kernel:
 map_kernel_di:
        push af
index b92cd94..2b9b4da 100644 (file)
@@ -12,6 +12,7 @@
             .globl init_hardware
             .globl interrupt_handler
             .globl _program_vectors
+           .globl map_buffers
            .globl map_kernel
            .globl map_kernel_di
            .globl map_process
@@ -208,6 +209,9 @@ _program_vectors:
 ;      are definitely off. In our case it's not useful information so both
 ;      symbols end up at the same code.
 ;
+map_buffers:
+          ; for us no difference. We could potentially use a low 32K bank
+          ; for buffers but it's not clear it would gain us much value
 map_kernel_di:
 map_kernel:
            push af
index 8fb0bab..e19541d 100644 (file)
@@ -9,6 +9,7 @@
             .globl init_hardware
             .globl interrupt_handler
             .globl _program_vectors
+           .globl map_buffers
            .globl map_kernel
            .globl map_kernel_di
            .globl map_process
@@ -364,7 +365,10 @@ _program_vectors:
 ;
 ;      The top 32K bank holds kernel code and pieces of common memory
 ;      The lower 32K is switched between the various user banks.
+;      We don't have a separate 32K for buffers as memory is too precious
+;      on must Microbees
 ;
+map_buffers:
 map_kernel:
 map_kernel_di:
            push af
index 52ba729..d483aef 100644 (file)
@@ -11,6 +11,7 @@
             .globl init_hardware
             .globl interrupt_handler
             .globl _program_vectors
+           .globl map_buffers
            .globl map_kernel
            .globl map_kernel_di
            .globl map_process
@@ -242,8 +243,12 @@ _program_vectors:
 ;      We map the low 64K 1:1 in kernel mode, keep the top 8K fixed and
 ;      map the others by 'bank' for user mode. We don't actually use the
 ;      hardware user mode yet. It's all just a bodge to get us up and
-;      running
+;      running.
 ;
+;      Some day we probably want the buffers outside of the main map, at
+;      least until we do split I/D somehow.
+;
+map_buffers:
 map_kernel:
 map_kernel_di:
            push af