Commit Graph

116 Commits

Author SHA1 Message Date
matt
caeec93030 Add BUSDMA_COUNTERS option 2013-02-14 07:26:23 +00:00
matt
d71cca3bb3 Disable bzero_page_vfp and bcopy_page_vfp since it really isn't any faster
than memcpy.
2013-01-28 06:14:45 +00:00
matt
18feae1b06 Add code to use VFP(or Neon) instructions to zero or copy a page via
pmap_zero_page and pmap_copy_page.  (Not hooked into vfp_init yet).
Requires FPU_VFP
2012-12-10 04:58:54 +00:00
matt
cb72f6574f ARMFPE hasn't compiled since NetBSD 4. Remove it.
Complete support for FPU_VFP.
fpregs now contains vfpreg.
XXX vfpreg only has space for 16 64-bit FP registers though VFPv3 and later
have 32 64-bit FP registers.
2012-12-05 19:05:45 +00:00
matt
60064e74d2 Add a PMAP_NEEDS_ALLOC_POOLPAGE / PMAP_ALLOC_POOLPAGE hook so systems can
allocate pool pages from a specific VM freelist.
2012-10-17 18:52:15 +00:00
matt
1504726d21 add _ARM32_NEED_BUS_DMA_BOUNCE to opt_arm_bus_space.h (It's not really a
bus_space option but it's close enough).
2012-09-18 05:09:47 +00:00
matt
2ea337846d Add core locator to mainbus. Add support for attaching multiple CPUs 2012-08-29 23:16:35 +00:00
matt
33f1e7498b Rename ARM options PROCESS_ID_IS_CUR{CPU,LWP} to TPIDRPRW_IS_CUR{CPU,LWP}
since TPIDRPRW is the cp15 register name.
Initialize it early in start along with CI_ARM_CPUID.
Remove other initializations.
We alays have ci_curlwp.
Enable TIPRPRW_IS_CURCPU in std.beagle.
[tested on a beaglboard (cortex-a8)]
2012-08-29 07:14:03 +00:00
matt
c58ada7b56 Rework VFP support to use PCU.
Add emulation of instruction which save/restore the VFP FPSCR.
Add a sysarch hook to VFP FPSCR manipulation.

[The emulation will be used by libc to store/fetch exception modes and
rounding mode on a per-thread basis.]
2012-08-12 05:05:47 +00:00
matt
9fae3660d0 COMPAT_NETBSD32 support for ARM. Which is strange since ARM is already
32-bits.  But the newer ARM ABI AAPCS changes the alignment of 64-bit
fields so structures need to copied in and out to deal with the alignment
change.  This is a kludge but makes debugging of AAPCS support much easier.
2012-08-03 07:59:22 +00:00
skrll
734571d26b Add support for the ARM1176JZS 2012-07-21 12:19:15 +00:00
matt
a08758835a Add intrbase locator to mainbus. 2012-07-14 07:57:26 +00:00
matt
15c59d8b13 Begin support for Cortex A5, A7, A15 and expand A8 and A9 definitions.
Instead of testing all possible CPUids for a cortex, we know what range
a cortex will be so mask out the insignificant parts and do a single test.
2012-07-13 05:23:29 +00:00
kiyohara
7b1d08098e Require arm3_cache_flush for ARM2/ARM250. 2011-12-11 03:30:23 +00:00
rmind
e225b7bd09 Welcome to 5.99.53! Merge rmind-uvmplock branch:
- Reorganize locking in UVM and provide extra serialisation for pmap(9).
  New lock order: [vmpage-owner-lock] -> pmap-lock.

- Simplify locking in some pmap(9) modules by removing P->V locking.

- Use lock object on vmobjlock (and thus vnode_t::v_interlock) to share
  the locks amongst UVM objects where necessary (tmpfs, layerfs, unionfs).

- Rewrite and optimise x86 TLB shootdown code, make it simpler and cleaner.
  Add TLBSTATS option for x86 to collect statistics about TLB shootdowns.

- Unify /dev/mem et al in MI code and provide required locking (removes
  kernel-lock on some ports).  Also, avoid cache-aliasing issues.

Thanks to Andrew Doran and Joerg Sonnenberger, as their initial patches
formed the core changes of this branch.
2011-06-12 03:35:36 +00:00
bsh
d5f7715c70 Preliminary ARM11 MPCore support.
I have confirmed this commit doesn't affect existing evbarm kernels by
comparing binaries.
2011-03-10 07:47:14 +00:00
kiyohara
4f2a5779d9 Add support Marvell Sheeva Core and SoC. (Orion/Kirkwood)
Discovery Innovation not yet.
2010-10-02 05:37:58 +00:00
matt
30ce2039ad Cleanup the armv7 changes. Add ARM_ARCH_7. Use CPU_CORTEX instead of
CPU_CORTEXA8 everywhere since there more types of Cortex than just the A8.
CPU_CORTEXA8 still exists but causes CPU_CORTEX to be defined.
Add CPU_CORTEXA9 as well.  Use .arch armv7a to get us the isb/dsb
instructions.

Test booted to root device prompt on a Beagleboard.
All ARM kernels successfully test built.
2010-06-19 19:44:57 +00:00
jmcneill
5ddffda4bf PR port-arm/43299: Support added for igepv2/cortexa8/omap3530
Apply patch from PR, with build fixes. ok skrll, matt
2010-06-16 22:06:53 +00:00
uebayasi
fe705f1018 Add write-through cache work-around for ARM11 as well as ARM9/ARM10. Analyzed
& tested on i.MX35 with help from Tsubai Masanari.
2009-12-27 05:14:56 +00:00
bjh21
e9aeb0583d Adapt the arm32 fusu implementation for use on PROG26 configurations
and use it on acorn26.
2009-01-18 16:42:09 +00:00
bjh21
e5754b08fd Move arch/arm/arm32/fusu.S to arch/arm/arm/fusu.S in preparation for making
it usable on acorn26 as well.
2009-01-18 15:43:20 +00:00
ad
92ce8c6a3d Make the emulations, exec formats, coredump, NFS, and the NFS server
into modules. By and large this commit:

- shuffles header files and ifdefs
- splits code out where necessary to be modular
- adds module glue for each of the components
- adds/replaces hooks for things that can be installed at runtime
2008-11-19 18:35:57 +00:00
matt
c9a118aa75 Add FA526 support (compile tested only) 2008-10-14 16:01:22 +00:00
matt
7dfcaf179b Add CPU_CORTEXA8 2008-08-27 11:18:40 +00:00
matt
825088eda6 Merge kernel changes in matt-armv6 to HEAD. 2008-04-27 18:58:43 +00:00
rearnsha
b45167b608 VFP support. 2008-03-15 10:16:43 +00:00
chris
bb382cd142 Add arm version of cpu_in_cksum. Based on previous in_cksum4 code.
In fact it's mostly the same code, with a different stub on it.

On a cats the regress/sys/net/in_cksum tests show that it takes around
50-60% of the time the C version takes.  In some cases it takes as low as
20%.
2008-01-26 02:06:04 +00:00
joerg
6e869e402d Refactor in_cksum/in4_cksum/in6_cksum implementations:
- All three functions are included in the kernel by default.
  They call a backend function cpu_in_cksum after possibly
  computing the checksum of the pseudo header.
- cpu_in_cksum is the core to implement the one-complement sum.
  The default implementation is moderate fast on most platforms
  and provides a 32bit accumulator with 16bit addends for L32 platforms
  and a 64bit accumulator with 32bit addends for L64 platforms.
  It handles edge cases like very large mbuf chains (could happen with
  native IPv6 in the future) and provides a good base for new native
  implementations.
- Modify i386 and amd64 assembly to use the new interface.

This disables the MD implementations on !x86 until the conversion is
done. For Alpha, the portable version is faster.
2008-01-25 21:12:10 +00:00
ad
0805a9416a Add MODULAR option. Include kernel linker stuff if MODULAR. 2008-01-06 18:03:58 +00:00
garbled
d974db0ada Merge the ppcoea-renovation branch to HEAD.
This branch was a major cleanup and rototill of many of the various OEA
cpu based PPC ports that focused on sharing as much code as possible
between the various ports to eliminate near-identical copies of files in
every tree.  Additionally there is a new PIC system that unifies the
interface to interrupt code for all different OEA ppc arches.  The work
for this branch was done by a variety of people, too long to list here.

TODO:
bebox still needs work to complete the transition to -renovation.
ofppc still needs a bunch of work, which I will be looking at.
ev64260 still needs to be renovated
amigappc was not attempted.

NOTES:
pmppc was removed as an arch, and moved to a evbppc target.
2007-10-17 19:52:51 +00:00
tsutsui
6a8a584d1a Remove leftover netns stuff. 2007-07-07 05:13:14 +00:00
yamt
f03010953f merge yamt-idlelwp branch. asked by core@. some ports still needs work.
from doc/BRANCHES:

	idle lwp, and some changes depending on it.

	1. separate context switching and thread scheduling.
	   (cf. gmcgarry_ctxsw)
	2. implement idle lwp.
	3. clean up related MD/MI interfaces.
	4. make scheduler(s) modular.
2007-05-17 14:51:11 +00:00
thorpej
165d4e6d83 Rewrite the ARM mutex implementation to be of the simple-mutex variety.
Because pre-v6 ARM lacks support for an atomic compare-and-swap, we
implement _lock_cas() as a restartable atomic squence that is checked
in the IRQ handler right before AST processing.  (This is safe because,
for all practical purposes, there are no SMP pre-v6 ARM systems.)

This can serve as a model for other non-MP platforms that lack the
necessary atomic operations for mutexes (SuperH, for example).

Upshots of this change:
- kmutex_t is now down to 8 bytes on ARM; about as good as we can get.
- ARM2 systems don't have to trap and emulate SWP or SWPB for mutexes.

The acorn26 port is not updated by this commit to do the LOCK_CAS_CHECK.
That is left as an exercise for the port maintainer.

Reviewed and tested by Matt Thomas.
2007-03-09 19:21:57 +00:00
christos
87f8f1a9a7 Scott Allan in http://mail-index.netbsd.org/port-arm/2006/07/31/0000.html
Patch to add support for ARM9E
2007-01-06 00:50:54 +00:00
christos
95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
christos
afffbeb330 split compat_16 functions to their own file and make this compile again. 2005-09-13 22:07:47 +00:00
bsh
c61364bf3e The first step to support Intel PXA270.
kernel config option CPU_XSCALE_PXA2X0 is now obsoleted by
CPU_XSCALE_PXA250 and CPU_XSCALE_PXA270.  If both of them are defined,
CPU is determined run-time.
2005-07-04 00:42:36 +00:00
rearnsha
80a3b6d023 Very basic support for the ARM1136.
This code takes no advantage of any 'new' features provided by
architecture 6 devices (such as physically tagged caches or new
MMU features), and basically runs the chip in a 'legacy v5' mode.
2005-06-03 15:55:55 +00:00
bsh
16cf047697 add an option to force ARM9 dcache to write-through mode. 2004-04-03 04:34:40 +00:00
scw
aee833c0ee Add "options ARM32_DISABLE_ALIGNMENT_FAULTS" to forcibly disable
alignment fault checking if necessary.

This option gets the acorn32 port working again.

XXX: Richard Earnshaw suggested enabling alignment faults for
XXX: userland only on acorn32. Need to investigate this.
2003-11-05 12:53:15 +00:00
scw
1fdc9cd5a1 Add a defflag for __BUS_SPACE_HAS_STREAM_METHODS, and add the
appropriate glue in bus.h, contingent on the option being defined.

This allows stream methods to be available on a port-by-port basis.
2003-10-23 15:03:24 +00:00
scw
877b3cbe5e Hand-optimised in_cksum/in4_cksum for ARM and XSCALE.
Contributed by Wasabi Systems, with input from Chris Gilbert,
Richard Earnshaw and David Laight.
2003-09-11 18:54:31 +00:00
rearnsha
b805fdb7fa Add build-system support for ARM10. 2003-09-06 09:48:47 +00:00
ichiro
00eb02e3da support IXP425 Intel Network Processor
running on BigEndian
2003-05-23 00:57:23 +00:00
thorpej
55073c92c1 Move the new pmap from arm32/pmap_new.c to arm32/pmap.c, fully replacing
the old.
2003-05-21 18:07:07 +00:00
thorpej
38d274c953 ARM32_PMAP_NEEDS_PTE_SYNC no longer exists. 2003-05-03 00:47:42 +00:00
briggs
a2f6e1f09a Add arm32 machine-specific remote kgdb support. Largely
from PR port-arm/15530 by bsh@, but with some updates from
me, including a fresh arm32/kgdb_machdep.c--ported from pc532.
2003-04-28 01:54:49 +00:00
thorpej
215580f2da Defflag XSCALE_CACHE_READ_WRITE_ALLOCATE and XSCALE_NO_COALESCE_WRITES. 2003-04-21 05:36:14 +00:00
scw
41a1932e58 Add the generic arm32 bits of the new pmap, contributed by Wasabi Systems.
Some features of the new pmap are:

 - It allows L1 descriptor tables to be shared efficiently between
   multiple processes. A typical "maxusers 32" kernel, where NPROC is set
   to 532, requires 35 L1s. A "maxusers 2" kernel runs quite happily
   with just 4 L1s. This completely solves the problem of running out
   of contiguous physical memory for allocating new L1s at runtime on a
   busy system.

 - Much improved cache/TLB management "smarts". This change ripples
   out to encompass the low-level context switch code, which is also
   much smarter about when to flush the cache/TLB, and when not to.

 - Faster allocation of L2 page tables and associated metadata thanks,
   in part, to the pool_cache enhancements recently contributed to
   NetBSD by Wasabi Systems.

 - Faster VM space teardown due to accurate referenced tracking of L2
   page tables.

 - Better/faster cache-alias tracking.

The new pmap is enabled by adding options ARM32_PMAP_NEW to the kernel
config file, and making the necessary changes to the port-specific
initarm() function. Several ports have already been converted and will
be committed shortly.
2003-04-18 11:08:24 +00:00