summaryrefslogtreecommitdiff
path: root/sys/arch
AgeCommit message (Collapse)Author
2014-12-01Remove an unused gdt structure definition.Mike Larkin
2014-12-01Remove an old and superfluous comment, and fix some KNF style issues inMike Larkin
some other comments.
2014-11-30SPARC T4 and later have a pause instruction to voluntarily pause a virtualMark Kettenis
processor in order to give other strands a chance to run. Use it in __mp_lock_spin_hook() to avoid wasting CPU cycles if we're waiting for the kernel or scheduler locks. This is instruction is patched in, just like we already do for the sleep instruction on SPARC64 VI processors. We look at the hwcap-list property of the cpu nodes in the machine description to decide whether the pause instruction is available.
2014-11-30Unbreak zzz/ZZZ resume - ensure NX is re-enabled on resume (if enabled).Mike Larkin
Also transformed some complicated code that was setting EFER into something much simpler. Tested on a variety of real machines, emulators/VMs, MP, UP, zzz, ZZZ, NX on, NX off ... ok deraadt@
2014-11-30Mask out EFER_LMA when restoring saved EFER on zzz/ZZZ resume as it's aMike Larkin
read only bit. Also fix some comments describing EFER bits that were obviously wrong. ok deraadt@
2014-11-30rxr ioctl handling.Brad Smith
2014-11-27Missing comparison caused NX to always be enabled during boot, even on CPUsMike Larkin
that may have had it disabled in BIOS. ok deraadt@
2014-11-26Introduce softraid boot support to sparc64 ofwboot.Stefan Sperling
sparc64 machines should now be able to boot from softraid raid1 and crypto. Tested on sun blade100, sunfire v240, and sun t1000 ldom guests. Lots of encouragement from deraadt@
2014-11-26Add a new ELF segment .openbsd.bootdata to the sparc64 kernel.Stefan Sperling
This can be used to pass boot parameters to the kernel which can't be passed safely via the Open Firmware interface, such as softraid volume IDs and keys. The kernel already reads the arguments if available but ofwboot won't provide them until further changes are committed there. With support from deraadt, kettenis and matthew. ok deraadt@
2014-11-26Add softraid support to sparc64 first-level boot blocks.Stefan Sperling
Written with use of the forth by jedi jsing@ For now this only supports 'a' RAID partitions, no other partition letters.
2014-11-26Add softraid boot support code files ported by me to sparc64 from amd64.Stefan Sperling
Not hooked to the build yet. ok kettenis@
2014-11-26Copy some Open Firmware interface functions from the kernel to ofwboot.Stefan Sperling
Will be needed soon. ok kettenis@
2014-11-26Hook ofwbootfd to the build.Stefan Sperling
2014-11-26Add a separate ofwboot build for the sparc64 floppies.Stefan Sperling
2014-11-25A few reliability fixes:Miod Vallat
- protect pv lists with splvm. - try to return as soon as possible from pmap_rmproc(). - correctly maintain wired pages statistics. - invoke pmap_remove_pcb() at splsched to avoid racing the scheduler.
2014-11-25Brag about what OS we are running on the LCD panel, if there is one.Miod Vallat
2014-11-25Speed up page zeroing by using a loop of dcbz/dcbzl instead of bzero().Martin Pieuchot
While here, use the direct map for pmap_copy_page() and remove the now unused stolen page addresses. No objection from the usual suspects, "it works, commit" deraadt@
2014-11-25disable qla. there is a boot-time raceTheo de Raadt
2014-11-24Actually, the previous change didn't quite work on the SPARC T5-2. But ifMark Kettenis
we change the order of the xxx_setvalidand xxx_setstate hypervisor calls things actually work.
2014-11-24Add missing pci_msiq_setstate and pci_msi_setstate calls. Makes MSI workMark Kettenis
on the SPARC T5-2. Make error messages a bit more consistent while there.
2014-11-24Do not attempt to dereference NULL pointers when encountering an empty SCSIMiod Vallat
bus on a dual-scsi controller abstraction, while walking the KL component tree.
2014-11-24The hypervisor on a SPARC T5-2 needs stricter alignment of the MSI messageMark Kettenis
queue.
2014-11-24If we use the vintr cookie to point at the interrupt handler struct, weMark Kettenis
shouldn't link it into the table.
2014-11-24Use the pointer to "struct intrhand" as the vintr cookie.Mark Kettenis
2014-11-24On sun4v, interpret the first data word of a device interrupt message as aMark Kettenis
pointer to "struct intrhand" if it is larger than MAXINTNUM. To be used with the cookie based "vintr" scheme.
2014-11-24use the correct capitalization for Realtek.Brad Smith
2014-11-23enable xhci(4) in ramdisksJonathan Gray
ok deraadt@
2014-11-23Make sure the direction bit is cleared on entry to the kernel by syscallPhilip Guenther
or interrupt, as specified by the ABIs. Our current gcc doesn't assume this bit of the ABI, but future compilers may and some ASM can be simplified by assuming it. in snaps for a bit
2014-11-22the per-cpu storage page does not need to be executable in thisTheo de Raadt
fashion. Anyways, we don't do MP here yet, so #ifdef it all away. with miod
2014-11-22Be more careful draining the error register and reenabling traps in the sun4mMiod Vallat
NMI handler; apparently ROSS modules depend upon this to behave correctly. From NetBSD
2014-11-22Driver for the ECC memory controller found on some sun4m (ss20), so thatMiod Vallat
recoverable memory errors no longer panic the kernel. From NetBSD but the manual page.
2014-11-22Previous diff changed the location of the ACPI S3/S4 trampoline, which hasMike Larkin
a common #defined location for both i386 and amd64. This diff fixes i386 to match. Also fix a tab/space issue in amd64 hibernate_var.h discussed with deraadt
2014-11-22{ on seperate line at start of function or I go crazyTheo de Raadt
2014-11-22Do not use PROT_MASK as a non-maskTheo de Raadt
2014-11-22Split the MP trampoline into two pages, one for code and one for data/stackMike Larkin
and then protect the code page as RX and the data/stack page as RW (NX). ok deraadt@
2014-11-22Switch to using MI installboot, after a conversation with stsp. He willTheo de Raadt
need this soon. install tested by jsg
2014-11-22spell PROT_EXEC correctlyTheo de Raadt
2014-11-22mop up a barely started project... getting in the way of grepping the tree!Theo de Raadt
2014-11-21We can map 'fuse ROM' area with read only.Kenji Aoyama
2014-11-21remove unused #defines and labels.Mike Larkin
ok deraadt, guenther
2014-11-21Since we enable NX in locore now, no need to do it again later in theMike Larkin
bootstrap sequence ok deraadt@
2014-11-21Add NX (if available) to the mid-level page tables (PDE, etc).Mike Larkin
ok deraadt@
2014-11-20Fix comment.Kenji Aoyama
2014-11-20When removing the identity mapping in low memory used during bootstrap,Mike Larkin
there is no reason to keep the NX bit around on null PTEs (PTEs that have been removed).
2014-11-20Don't attempt to clear/disable %tick_cmpr. This register is no longer presentMark Kettenis
on newer sun4v implementations (possibly SPARC T3 and later, definitely not there on SPARC T5) and it should not be necessary on older systems. Tested by dlg@
2014-11-20Disentagle bcopy/memcpy/memmove.Theo de Raadt
The situation was: memcpy swaps registers and drops into bcopy, which does the overlap check, before getting around to business. But memcpy is not supposed to handle overlapped arguments special, so we don't need all this complex register swapping and tests up front -- when memcpy is the most common operation. Refactor all these upside downupside down. Survived multiple make builds, so probably good, and faster. ok dlg
2014-11-20Move previous PTE permission fixup code into locore, and fixup some moreMike Larkin
ranges while we're there. ok deraadt@, tested by many and in snaps
2014-11-20Revert the previous changes that enabled various PTE permissions fixupsMike Larkin
in pmap.c - equivalent code will shortly be committed to locore.S that accomplishes the same thing. ok deraadt@
2014-11-19Only keep {recv,send}udp() in the pxe-specific code, the remainder of whatMiod Vallat
used to be local net.c (renamed to pxe_udp.c) can now be obtained from libsa's net.c rather than being duplicated. No functional change.
2014-11-19Remove some unused i386 pmap functions. Also fix two typos in commentsMike Larkin
while I had the hood open. ok deraadt@, mpi@