summaryrefslogtreecommitdiff
path: root/sys/arch/luna88k
AgeCommit message (Collapse)Author
2014-07-01Replace the assembly 88100 FPU imprecise exception code (mostly triggered byMiod Vallat
denormal results) with C code using softfloat to correctly round the inexact results in the best possible way according to the current rounding mode. No functional change intended, and this assembly code was surprisingly almost non-buggy, as opposed to the precise exception code replaced a few weeks ago; still an improvement as this replaces 900 lines of arcane assembly with 90 lines of understandable C code.
2014-06-18Update comment; there seems to be no PC-9801 extension board slot onKenji Aoyama
'original' LUNA-88K.
2014-06-09Replace the unmaintainable assembler code responsible for 88100 precise FPUMiod Vallat
fault handling with a C wrapper around the softfloat code, as already done for 88110 kernels. As a bonus, attempting to read or write FPU control registers but fcr62 and fcr63 in userland will now correctly signal an illegal instruction, instead of leaving the destination register unchanged and pretending nothing bad happened. Be sure to rm m88100_fp.d in your kernel compile directory after updating your tree.
2014-06-07Modify to ANSI-style function declarations. No binary change.Kenji Aoyama
2014-06-03Fix sentinel style.Kenji Aoyama
ok miod@
2014-06-03Better comment for `faulty address'.Kenji Aoyama
2014-05-31Revert previous diff setting cold to 1 on shutdown because it breaks machineMartin Pieuchot
with softraid(4) disks. softraid(4) is the last real consumer of the doshutdownhooks(9) API and it is not trivial to convert its hook to a DVACT_POWERDOWN handler since the latter does not allow to sleep.
2014-05-30Set cold to 1 before executing the DVACT_POWERDOWN handlers when halting orMartin Pieuchot
rebooting a machine, like it is done in the hibernate case. At least some USB host controller drivers rely on this to busy way instead of sleeping. Avoid a panic on macppc with an uhci(4) cardbus plugged in. ok deraadt@, uebayashi@
2014-05-17Change the return value of interrupt handler to 0 when nothing isKenji Aoyama
processed on this driver. "This is correct" miod@
2014-05-08Format string fixes for m88k; remove -Wno-format from the m88k kernels.Miod Vallat
2014-05-08The pcexmem(4) and pcexio(4) should be attached on LUNA-88K2 only.Kenji Aoyama
Actually, there seems to be no PC-9801 extension board slot on 'original' LUNA-88K. ok miod@
2014-04-22Unify the model name to LUNA-88K{,2}, that is considered theKenji Aoyama
`official' name. ok jmc@ miod@
2014-04-16Add generic driver for "NEC PC-9801(*) extension board slot" onKenji Aoyama
LUNA-88K. LUNA-88K{,2} has one or two slot(s) that can attach the extension board designed for PC-9801. This driver provides dedicated mmap(2) and capability for waiting specified interrupt on that slot so that we can use the extension board from userland program. (*)PC-9801 is a Japanese popular personal computer, mainly used in 1980-90's. (see http://en.wikipedia.org/wiki/NEC_PC-9801) ok miod@, and man pages jmc@
2014-04-12Delete unused variable.Kenji Aoyama
2014-03-29It's been a quarter century: we can assume volatile is present with that name.Philip Guenther
ok dlg@ mpi@ deraadt@
2014-03-13get rid of the assumption that the head of the alldevs list is theDavid Gwynne
"mainbus" device. this breaks when mpath is enabled because it attaches before mainbus and therefore takes the head position. have autoconf provide device_mainbus() which looks up mainbus_cd, and use that instead. discussed with deraadt who just wants mpath stuff to move forward despite there being many ways to shine this particular turd.
2014-02-23Try and load /etc/random.seed before attempting to load the kernel.Miod Vallat
Bump version.
2014-01-30Add missing 'stand' directory in order to work 'make build' and 'makeKenji Aoyama
install' properly. ok miod@
2014-01-29Add rnddata[] placeholders to make boot block build again, same asKenji Aoyama
other platforms. ok miod@
2014-01-26Attempt to make user changes of keyboard layout a bit more `sticky' on wsmuxMiod Vallat
kernels: - keyboard drivers will now tell wskbd if the keyboard layout they ask for is a default value, or a value they are 100% sure of (either because your kernel has a XXXKBD_LAYOUT option, or because the driver can tell the keyboard layout, e.g. by the country code on USB keyboards which provide it, such as Sun's) - when attaching a keyboard with a non-default layout, the layout will become the default layout of the mux for new keyboard attachments if the mux doesn't have a layout set already. - when changing the keyboard layout of a particular keyboard with an ioctl (i.e. using kbd(8) or wsconsctl(8)), the layout will become the default layout of the mux for new keyboard attachments. ok mpi@
2014-01-19Initialize ci_randseed better using arc4random() + a trick. Remove theTheo de Raadt
libkern srandom() API since it is not suitable for this use. ok kettenis miod
2014-01-15Add WSDISPLAYIO_SETGFXMODE ioctl on LUNA's frame buffer.Kenji Aoyama
This ioctl changes `pseudo' frame buffer depth, in order to use color wscons and monochrome X server both. Also need to some luna88k-specific initialization in xenocara/driver/xf86-video-wsfb/src/wsfb_driver.c.
2014-01-06typoMiod Vallat
2014-01-03KNF, update comments, and delete LUNA(m68k) specific DIPSW comments.Kenji Aoyama
No functional change.
2014-01-02Add primary support for LUNA-88K 4bpp/8bpp frame buffer.Kenji Aoyama
This brings color support on LUNA's wscons. And, with the help of recent development version of 'mlterm-fb' (frame buffer version of ports/x11/mlterm), graphic images can be displayed in 16/256 colors on the screen. Thanks to arakiken, the original developer of mlterm! This diff is based on NetBSD/luna68k work: http://mail-index.netbsd.org/source-changes/2013/12/28/msg050266.html Need more work to coexist with the monochrome X.Org server. "go ahead!" miod@
2013-12-30Correct initialization of Bt458, used in LUNA's 8bpp frame buffer.Kenji Aoyama
According to the manual, the address register does not automatically increment when we access to the control registers. Also we disable overlay planes, because we do not use them. This diff should be one of preliminaries for upcoming colored wscons on luna88k. ok miod@
2013-12-25Add missing IPL_MPSAFE, as same as mvme88k.Kenji Aoyama
ok miod@
2013-12-08reflect reality, mark as NOOBJMarc Espie
"sure" deraadt@
2013-11-16Re-organize luna88k rasops om_{copy,erase}{cols,rows} by using oneKenji Aoyama
generic function, based on hp300/dev/diofb_mono.c. This also fixes `screen is not updated when delete a character if it is on the middle of a 32-bit word of the frame buffer' problem. "Go for it!" miod@
2013-11-16Allow initial device mappings (from pmap_table) to be backed up by BATC.Miod Vallat
Use this on luna88k to map the bitmap planes of the frame buffer used by the driver. 10% speedup under X.
2013-11-16Allow ddb to be entered from the keyboard, if glass console and ddb.console=1,Miod Vallat
with ctrl-alt/zenmen-esc. Tested on three different keyboard models (compact black, JIS, and full-sized) by aoyama@ and me.
2013-11-13Do not map frame buffer resources the kernel doesn't use; only keep theMiod Vallat
lowest bitmap plane, and a page per plane to be able to probe the frame buffer depth. Saves an insignificant amount of kernel memory (about 4KB), still worth doing. ok aoyama@
2013-11-12We always make symlinks to 'machine' and 'm88k' to compile.Kenji Aoyama
ok miod@
2013-11-12Fix the bootloader random hang-up while counting down on LUNA-88K2.Kenji Aoyama
The same logic is also applied to luna88k/dev/timekeeper.c. suggested and ok miod@
2013-11-05Replace direct references to p_size, p_offset and d_secperunit withKenneth R Westerback
DL_[GET|SET]PSIZE(), DL_[GET|SET]POFFSET(), DL_[GET|SET]DSIZE() in order to get|set correct value that includes the high bits of the value.
2013-11-03Even saner kernel layout, so that .rodata can be batc mapped by a read-onlyMiod Vallat
dbatc. Add batc mapping support for 88110 systems as well.
2013-11-02Use a linker script to align .data to a BATC boundary as well, so that noMiod Vallat
DBATC may span over parts of .rodata.
2013-11-02Create the initial page tables in the area between the end of the firmwareMiod Vallat
data area and the kernel image, whenever possible. On 88100/88200 systems, use BATC mappings to map the kernel text (and the kernel data for non-MULTIPROCESSOR kernels). 88110 to follow soon.
2013-11-02Link m88k kernels on a BATC boundary.Miod Vallat
2013-11-02Reserve a page at the beginning of the kernel text to use for the trap vectors,Miod Vallat
and switch to it, on all processors, after autoconf is over. First step towards being able to unmap the low memory and have address 0 non-accessible in the kernel.
2013-11-02No need to cast constants or simple variables to (daddr_t). UseKenneth R Westerback
(u_int64_t) instead of (daddr_t) when casting a variable in an expression passed to DL_SETDSIZE(). Change a variable counting open files from daddr_t to int64_t. ok deraadt@ with the tweak to fix that pesky expression.
2013-11-01Better report of the system type, to match the OMRON spelling; aoyama@Miod Vallat
2013-10-30Fix native builds of the luna88k boot block. Install it into /usr/mdec.Miod Vallat
2013-10-30Reduce gap at the end of .text from a page to 0x10 bytes. The ELF->a.outMiod Vallat
conversion done in objcopy loses if an alignment smaller than this is requested (and this is probably my {fault,bug}, somewhere in binutils). Shrinks the boot blocks a bit.
2013-10-30Bring getline() - a.k.a libsa gets() with a prompt prefix - in par with libsaMiod Vallat
gets(), featurewise; this means support for ^u to clear the input. Requested by aoyama@
2013-10-30No longer build luna88k kernels as a.out binaries, now that we have a nativeMiod Vallat
bootloader for ELF kernels.
2013-10-29Get boot device and partition from NVRAM. Boot filename still defaults toMiod Vallat
"bsd", since the PROM boot_filename has to point to the bootloader itself (I store mine as /vmunix).
2013-10-29More cleanups:Miod Vallat
- accept empty controller and partition numbers, as well as empty filenames, and use defaults (0, 0 and "bsd") instead of complaining the boot path is invalid. - do not attempt to detect and report devices at boot, using a small list of possible devices (only scsi id #6 and #5, come on!). Instead, parse the user-supplied boot string to figure out which controller and device to talk to. (still no SCSI LUN support, though). Because of the last change, SCSI unit numbers ought to match the PROM numbering now (10 * controller + 6 - device id). Crank version to 0.2.
2013-10-29More cleanup and unused code or data removal.Miod Vallat
Constify the bitmap font. Bound check sd() numbers instead of accessing an array out of bounds (noticed by aoyama@). Use the same SCSI select timeout as the kernel does (250ms instead of 2ms).
2013-10-28This is the cleaned up version I had intended to commit.Miod Vallat