Commit Graph

251 Commits

Author SHA1 Message Date
bjh21 a9e02c7638 Correctly calculate fault addresses for instructions like:
ldr	rX, [rY, rZ, ror #16]
and even:
	ldr	rX, [rY, rZ, rrx]
Why anyone would want such an instruction is beyond me, but it's nice not to
panic if they do.  Also this makes regress/sys/arch/arm/abort-fixup pass.
2006-10-14 20:39:21 +00:00
bjh21 2121e75b3f When forking a new LWP, if a new user stack pointer is provided, use it.
Necessary to make regress/lib/libc/clone pass.
2006-10-14 17:51:37 +00:00
bjh21 ecd6759513 Expose __PROG26 to assembly language so we can use it to decide whether
R14 is vulnerable.
2006-10-08 12:22:35 +00:00
bjh21 c3d7e34641 hardsplx() is declared in <machine/intr.h>, so there's no need to declare it
here.
2006-10-07 21:12:00 +00:00
bjh21 0e30542fee Make setsoftnet() into a macro, which seems to be the usual approach on systems
with generic soft interrupts.
2006-10-07 20:58:00 +00:00
bjh21 0ddc4aa582 Make splsched() and splstatclock() into aliases for splhigh(), since
practically no hardware interrupts can occur above splstatclock().
This also makes splsched() faster, which is good since it's called an awful
lot.
2006-10-07 20:51:47 +00:00
bjh21 6f89e70357 When we catch a branch through zero, push a stack frame so that it's possible
to get a stack backtrace through the error.
2006-10-07 13:36:31 +00:00
chs 33c1fd1917 add support for O_DIRECT (I/O directly to application memory,
bypassing any kernel caching for file data).
2006-10-05 14:48:32 +00:00
bjh21 1bef3c4ceb Use top-down VM on acorn26 and increase the maximum data size to take
advantage of this.  I can run GCC on my A540 now.
2006-10-05 00:25:50 +00:00
bjh21 578a81db96 Timecounter support for acorn26, using IOC timer 0 and a bit of trickery. 2006-10-04 23:40:00 +00:00
bjh21 14d2868d44 The IOC datasheet makes it clear that the period of an IOC counter is
(latch + 1) cycles.  Take this into account when programming the latches.
2006-10-04 20:29:51 +00:00
bjh21 742da1ffcd Add RCSID(). 2006-10-04 20:14:44 +00:00
bjh21 d98bf2904c Fast write_region_2, which is just the fast read_region_2 with different
inner loops.
2006-10-03 23:15:18 +00:00
bjh21 9dc368e353 Clean up read_region_2 code to use fast version under more circumstances, and
to always use it aligned on a 4-word boundary.  The setup code feels like
it could be sleeker, but I can't currently see how.
2006-10-03 22:27:02 +00:00
chs e8295642bd remove MALLOC_NOINLINE, it doesn't do anything anymore. 2006-10-02 03:28:29 +00:00
bjh21 6a2268f94f Faster bus_space_read_region_2(), using LDM and STM to process 16 bytes at a
time where possible.  This almost doubles the speed of reading through the
sec(4) in my A540.
2006-10-01 22:47:18 +00:00
bjh21 5375dc7f10 New driver, sec(4), for the Acorn SCSI Expansion Card. Unlike asc(4), this
driver uses the board's DMA system, uses the machine-independent WD33C93
driver, works on NetBSD/acorn26, and doesn't share a name with six other
machine-dependent SCSI drivers.  Not tested on acorn32, but it seems to
work tolerably well on my A540.
2006-10-01 12:39:35 +00:00
bjh21 e9030bd381 Move over to using the standard ARM bus_space implementation on acorn26.
This is more flexible than the old acorn26 bus_space, which means that single
read/write operations are slower, but multi and region operations have the
potential to be faster, and particularly insane podules might be supportable.
In theory the acorn32 mainbus and podulebus code ought to be shareable, but
acorn26 needs the extra overhead of saving R14_svc on some operations so
I've made my own version for now.  Also the acorn32 bus_spaces are a mess.
2006-09-30 16:30:10 +00:00
bjh21 213f273e6a Calls to bus_space_barrier() on acorn26 were very few and using constants that
were two generations obsolete.  Since they do nothing anyway, remove them
rather than trying to update them.
2006-09-30 15:14:21 +00:00
bjh21 3143e7d6c3 ANSIfy, un-__P, light KNF. 2006-09-28 23:54:14 +00:00
bjh21 557f409231 No need to do silly asm() dances to get R14_svc saved now -- the compiler
does it for us everywhere.
2006-09-28 23:25:01 +00:00
bjh21 8e80f0df78 Don't specify -fomit-frame-pointer -mno-apcs-frame, since that breaks kernel
page faults.
2006-09-28 23:23:22 +00:00
bjh21 87e6985bed Add -mapcs-frame -fno-omit-frame-pointer to acorn26 kernel builds. This
is necessary to ensure that GCC saves R14_svc on entry to every function,
and thus that page faults within the kernel are safe (since they corrupt
R14_svc).  I think this used to be the default, but it's not any more.
2006-09-28 22:10:53 +00:00
bjh21 826ff5f060 Make db_validate_address() work, even when called from within an interrupt
handler.  This should make debugging prefetch aborts slightly simpler.
2006-09-27 21:21:09 +00:00
bjh21 5858e7aa70 Arrange that catching an unexpected data abort in the kernel causes a trap
into DDB where possible, even if it happens in an interrupt handler.
2006-09-24 23:38:59 +00:00
bjh21 83d7ac871e Turn address exceptions into SIGSEGV rather than SIGBUS, since they're really
just attempts to access unmapped (and incidentally unmappable) memory,
rather than anything special.
2006-09-24 21:42:06 +00:00
bjh21 7841bf68c0 uvm_fault has been sensible about when to return ENOMEM for some time now,
so it's reasonable for us to kill processes when we get it returned,
rather than sleeping.  Do that.
2006-09-24 20:54:14 +00:00
bjh21 51b05a4131 Use MI inittodr() and friends. 2006-09-03 11:51:29 +00:00
bjh21 1323fd42da This file isn't used any more. 2006-08-31 23:16:28 +00:00
bjh21 44ef93a9be Be more careful with registers in LDR[T] so that GAS doesn't warn us about
constructs that aren't allowed in ARMv3.
2006-08-28 15:15:50 +00:00
bjh21 d5930df82e unifdef -U __APCS_26__: we've been using APCS-32 for years. 2006-08-28 14:31:18 +00:00
bjh21 3612709d56 unifdef __APCS26__: we've been using APCS-32 for years. 2006-08-28 14:26:34 +00:00
christos e0df1e4c51 PR/34283: Gene ENonymous: Add IPFILTER_LOOKUP to the default kernel options
Also remove CCITT,NS,NIP
2006-08-26 20:26:43 +00:00
tsutsui 6ff205ce76 Remove obsolete #options VERIFIED_EXEC, found by grep(1). 2006-08-26 07:59:21 +00:00
christos b300b74469 Disable SYSTRACE by default on all kernels (discussed with core) 2006-08-12 15:29:52 +00:00
drochner 84f50d1b92 don't install <machine/db_machdep.h>, this is kernel only 2006-07-26 19:54:56 +00:00
bjh21 cf7ce97e4b Silly error: xos_cli() should call XOS_CLI, not OS_CLI. 2006-07-20 23:35:20 +00:00
bjh21 5bdcc8987d -mshort-load-words has been removed in GCC 4. It was only an optimisation,
so just stop using it.
2006-07-20 10:53:12 +00:00
ad 2b79369c7e - Hold a reference to the process credentials in each struct lwp.
- Update the reference on syscall and user trap if p_cred has changed.
- Collect accounting flags in the LWP, and collate on LWP exit.
2006-07-19 21:11:37 +00:00
liamjfoy aeee5deab9 Add CARP to GENERIC kernel configs. CARP is not enabled by default.
ok: christos
2006-06-28 15:19:27 +00:00
drochner a3464e1d27 use the "i2cbus" interface attribute rather than putting a string name
into the i2cbus attach args
2006-06-26 18:21:38 +00:00
skrll a9f4c28a3d Fix a bunch of cast lvalues. 2006-05-10 06:24:02 +00:00
jmmv 7a51d4dddc Add an extra cookie to the ioctl and mmap wsdisplay accessops that points
to the screen on which they are being called.  The driver cannot guess
this by itself but it is needed to implement, at least, the getwschar and
putwschar functions in the correct place.  There are no functional changes
yet.

Tested on i386 (vga, vga_raster, machfb, vesafb), macppc and sparc64.
Suggested and reviewed by macallan@.
2006-04-12 19:38:22 +00:00
he 7d6535cfe2 Since this port has its own db_interface.c, we need to declare ddb_regs
here as well, after it moved out of db_machdep.h.
2006-04-06 17:29:49 +00:00
thorpej 2be6494fc9 Use device_cfdata(). 2006-03-29 04:16:44 +00:00
pavel dc1372c547 Add stf to all kernel configs which have INET6 and gif, except the INSTALL
ones and those for specific machines of developers. PR 32304.

OK'ed by rpaulo.

N.B. stf is a cloning device, so it still must be enabled by
"ifconfig stf0 create".
2006-03-28 20:58:39 +00:00
he 450ce68a74 Transform to new signature for uvm_fault() by dropping the third arg.
Discussed with drochner.
2006-03-16 15:10:06 +00:00
thorpej be8b235384 Clean up fallout proc_is_traced_p() change:
- proc_is_traced_p() -> trace_is_enabled(), to match trace_enter() and
  trace_exit().
- trace_is_enabled() becomes a real function.
- Remove unnecessary include files from various files that used to care
  about KTRACE and SYSTRACE, but do no more.
2006-03-07 03:32:04 +00:00
thorpej 458b3e43f7 Use device_parent(). 2006-02-23 05:37:46 +00:00
perry fbae48b901 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@.
2006-02-16 20:17:12 +00:00