Commit Graph

7 Commits

Author SHA1 Message Date
Travis Geiselbrecht
b433d4582d [arch][m68k] careful of PC relative addressing on 68000 and 68010
These cpus only support a simple 16 bit offset from PC, so cannot use it
in start.S to compute a large offset. This is okay, because the code
that needs it is only for cpus with an MMU, which these dont have.
2025-09-22 21:52:48 -07:00
Travis Geiselbrecht
6c7e6a1796 [arch][m68k] start to enable the VM on m68k
-Wire up the make plumbing for setting the kernel vm bits
-Implement stubbed out arch_mmu routines.
-Set up a high mapping in start.S that should be compatible with the mmu
code.
2025-09-22 21:52:48 -07:00
Travis Geiselbrecht
7e11c3bf78 [arch][m68k] save up to 4 arguments passed to LK
Pass the first 4 words on the stack that may have been passed from
firmware or bootloader to LK on to lk_main.
2024-02-11 00:38:52 -08:00
Travis Geiselbrecht
49644a2c39 [platform][rosco-m68k] Add port to the Rosco M68k board
Port to the really neat 68010 based board at https://rosco-m68k.com/

Port Features:
-10Mhz 68010
-1MB ram
-Dual UART + timer implemented as a 68c681 chip
-timer running at 1Khz, UART A for console
-interrupt driven RX support

Some amount of extending of the 68k exceptinon code was needed to
support the autovectored irqs that the 68681 uart uses. Added build
system support for 68010.
2022-04-12 00:25:12 -07:00
Travis Geiselbrecht
cc21c06eb6 [platform][m68k-virt] parse the BOOTINFO structure qemu uses to pass info
Pull out the memory size of the system and use it to initialize the
novm.
2022-02-11 00:37:51 -08:00
Travis Geiselbrecht
4b508cecc9 [arch][m68k] use a jsr in the initial start routine to main
It's non ideal, since there's no relaxation done in the linker so we
have to assume the branch target is > 16 bits away and do what the
compiler usually does and emit a full 32bit jsr.
2021-06-11 21:34:34 -07:00
Travis Geiselbrecht
12fee4b59a [arch][m68k] initial port to m68k
Uses the QEMU virt machine for 68k defined in qemu 6.0+.
Basic support that boots, prints to the console, takes input from
console, and context switches.

TODO: interrupt support, timer support.
2021-06-06 19:38:45 -07:00