Commit Graph

267 Commits

Author SHA1 Message Date
cognet
43586d701a Instead of using sysarch() to store-retrieve the tp, add a magic address,
ARM_TP_ADDRESS, where the tp will be stored. On CPUs that support it, a cache
line will be allocated and locked for this address, so that it will never go
to RAM. On CPUs that does not, a page is allocated for it (it will be a bit
slower, and is wrong for SMP, but should be fine for UP).
The tp is still stored in the mdthread struct, and at each context switch,
ARM_TP_ADDRESS gets updated.

Suggested by:   davidxu
2005-02-26 18:59:01 +00:00
cognet
ea8a18c379 Add the field in the md part of the struct thread required by ARM_[GET|SET]_TP. 2005-02-26 00:02:14 +00:00
cognet
3aab487108 Implement two new sysarch for arm, ARM_GET_TP and ARM_SET_TP, to work around
the lack of tls on arm.
2005-02-25 22:56:16 +00:00
cognet
5b6d27e25b Make sure casuptr() reset pcb->pcb_onfault when returning. 2005-02-25 22:54:56 +00:00
cognet
e3c78fa692 MFp4: get the code that set the pc correctly to work, remove a few IQ31244
specific mappings from locore.S, re-organize iq31244_machdep.c to work with
the new locore.S

Spotted out by:	jmg
2005-02-20 21:34:59 +00:00
cognet
2b4c5432b2 Removing the #endif as well sounds like a good idea. 2005-02-20 01:26:01 +00:00
cognet
66e4db6966 In cpufunc_control, uncomment the code responsible for returning the old
state of the control register.
2005-02-20 01:24:46 +00:00
ru
6cc6926066 Use a common multi-inclusion protection, and add such a
protection to alpha/include/exec.h.
2005-02-19 21:16:48 +00:00
cognet
eebf9afbba Support high vectors for arm9.
Obtained from:	NetBSD
2005-02-18 17:29:12 +00:00
cognet
19a07769b7 Define NIRQ to 64 for CPU_ARM9, because Cirrus Logic EP93XX cores provides
64 irqs.
This should be re-thought later.
2005-02-13 18:26:31 +00:00
cognet
60d70ae863 Remove unused prototype. 2005-02-13 18:20:39 +00:00
cognet
e8d555022d Remove redondant includes. 2005-02-13 18:05:36 +00:00
cognet
8466ce70d6 Don't prototype pmap_kenter(). 2005-02-13 17:18:20 +00:00
jmg
e9d4e6750b move pmap.h after vm.h include... some of the headers from pmap.h depend
upon vm.h
2005-02-09 00:10:17 +00:00
njl
2958530007 Finish the job of sorting all includes and fix the build by including
malloc.h before proc.h on sparc64.  Noticed by das@

Compiled on:	alpha, amd64, i386, pc98, sparc64
2005-02-06 01:55:08 +00:00
njl
cd2bcf063b Sort includes a little so that bus.h comes before cpu.h (for device_t). 2005-02-04 06:58:09 +00:00
njl
54a88fdbee Add an implementation of cpu_est_clockrate(9). This function estimates the
current clock frequency for the given CPU id in units of Hz.
2005-02-04 05:32:56 +00:00
njl
2579b2e0bf Sort functions. 2005-02-01 06:36:27 +00:00
cognet
5638709391 Make sure we can boot both with and without MMU enabled. 2005-01-23 22:08:31 +00:00
cognet
fe5f83713c Define bus_dmamap_load_buffer before bus_dmamap_load to make gcc happy. 2005-01-23 22:07:33 +00:00
cognet
37230f7c69 Fix compile for !KTR. 2005-01-23 21:39:23 +00:00
cognet
28e246b289 Remove references to non-existing symbols DO_corb and got_mmu.
While I'm there, remove dead code.
2005-01-20 22:23:26 +00:00
cognet
2a66290389 Fix compile for __ARMEB__. 2005-01-19 16:22:20 +00:00
cognet
5608e326b2 MFpowerpc: Work around the problem of returning a 32 bits value from
__syscall() on a 32 bits big-endian arch.

Spotted out by:	grehan
2005-01-19 00:37:03 +00:00
cognet
ab7ed627f8 Start to support the big endian case as well. 2005-01-18 15:51:50 +00:00
cognet
5dcea2459e Add a new sysctl, hw.sevenseg.freq, to control the update frequency. 2005-01-16 13:18:52 +00:00
cognet
3f738b3942 Erm, don't forget to store the mbuf in the dmamap in bus_dmamap_load_mbuf_sg(),
so that bus_dmamap_sync() knows what to invalidate. This makes em(4) work again.
While I'm there, remove the unused "first" variable.
2005-01-16 13:15:16 +00:00
cognet
7c9c98e639 Add support for KTR_BUSDMA. 2005-01-15 19:42:28 +00:00
cognet
897fdcefd3 Add the prototype for bus_dmamap_load_mbuf_sg().
Spotted out by:	scottl
2005-01-15 19:31:08 +00:00
cognet
072c519386 MFi386: add bus_dmamap_load_mbuf_sg(). 2005-01-15 19:07:23 +00:00
cognet
5435311167 Add the 7 seg display. 2005-01-15 18:55:40 +00:00
cognet
6365349c89 Add support for the IQ31244 7 seg display.
Obtained from:	NetBSD
2005-01-15 18:55:22 +00:00
cognet
4955cf8c26 Start the license statement with /*- 2005-01-15 18:38:10 +00:00
cognet
4251591c3f Use device_set_desc(). 2005-01-15 16:57:00 +00:00
cognet
f34de841db Add the i80321 watchdog. 2005-01-15 16:56:22 +00:00
cognet
d96d350b95 Add a driver for the i80321 watchdog.
Obtained from:		NetBSD
2005-01-15 16:54:35 +00:00
cognet
14d3ee495d Add support for ptrace() and gdb breakpoints. 2005-01-10 22:43:16 +00:00
cognet
83fcc96139 Don't assume pmap_update() will cpwait for us, pmap_update will disappear soon. 2005-01-10 22:41:08 +00:00
imp
77267e277f Start all license statements with /*- 2005-01-05 21:58:49 +00:00
alc
a618275b13 Modify pmap_enter_quick() so that it expects the page queues to be locked
on entry and it assumes the responsibility for releasing the page queues
lock if it must sleep.

Remove a bogus comment from pmap_enter_quick().

Using the first change, modify vm_map_pmap_enter() so that the page queues
lock is acquired and released once, rather than each time that a page
is mapped.
2004-12-23 20:16:11 +00:00
cognet
a90b1e3656 - The IQ80321 has a jumper which changes the PCI device id from 4 to 8 for the
GigE controller, so handle this.
- Use the outbound window 0 if the PCI mem requested is in its range, instead
of inconditionally use the outbound window 1.
This should be enough to get FreeBSD/arm to work on the IQ80321 board as well.

Reported and tested by: Jia-Shiun Li <jiashiun at gmail dot com>
2004-12-21 11:36:09 +00:00
cognet
b231943e0e Update the StrongArm port to match the current code.
- Implement arm_mask_irqs and arm_unmask_irqs
- Provide the available physical address range after pmap_bootstrap allocated
things, instead or before, or bad things happen.
2004-12-18 17:58:49 +00:00
cognet
5b61dc111e Make sure gcc doesn't generate something such as swp r3, r4, [r3] for __swp,
as it has unpredictable results.
2004-12-18 17:43:01 +00:00
alc
ede2fb9751 In the common case, pmap_enter_quick() completes without sleeping.
In such cases, the busying of the page and the unlocking of the
containing object by vm_map_pmap_enter() and vm_fault_prefault() is
unnecessary overhead.  To eliminate this overhead, this change
modifies pmap_enter_quick() so that it expects the object to be locked
on entry and it assumes the responsibility for busying the page and
unlocking the object if it must sleep.  Note: alpha, amd64, i386 and
ia64 are the only implementations optimized by this change; arm,
powerpc, and sparc64 still conservatively busy the page and unlock the
object within every pmap_enter_quick() call.

Additionally, this change is the first case where we synchronize
access to the page's PG_BUSY flag and busy field using the containing
object's lock rather than the global page queues lock.  (Modifications
to the page's PG_BUSY flag and busy field have asserted both locks for
several weeks, enabling an incremental transition.)
2004-12-15 19:55:05 +00:00
cognet
7ce4a54e10 Enable interrupts once the active ones have been masked. 2004-12-14 18:57:21 +00:00
cognet
c372644159 Update the sp after popping the regs.
This is a good candidate for the golden pointy hat awards.
2004-12-14 18:45:05 +00:00
cognet
8e56111fcd Save a few more cycles in cpu_switch() and cpu_throw(). 2004-12-12 19:21:58 +00:00
cognet
f047a2aa01 Fix style. 2004-12-11 23:56:03 +00:00
cognet
3c819126da Add entries to trace syscalls with KTR. 2004-12-11 23:54:03 +00:00
cognet
975196bf45 Fix compilation with INVARIANTS. 2004-12-11 14:46:52 +00:00