Commit Graph

850 Commits

Author SHA1 Message Date
thorpej cd0e28f1e7 Use L2_S_CACHE_MASK in places where we revoke cacheability. 2002-04-10 15:44:23 +00:00
thorpej 668547d841 pmap_kenter_pa(): Obey the "prot" argument, rather than simply making
all mappings r/w (!!).
2002-04-10 04:40:58 +00:00
thorpej 6e52cbf89e In pmap_copy_page_xscale(), put the source page in the mini-data
cache, as well.  The mini-data cache is 2-way, so src and dst won't
clobber each other, and the smallness of the cache doesn't matter,
since we access each page once sequentially.

While we still have to do the initial clean of the source page, this
saves another 4K of main D$ pollution, and also means we don't have
to do 2 cache passes after the copy is complete (i.e. we can skip the
invalidation of the source page in the main cache, since it's no longer
there).
2002-04-10 01:30:42 +00:00
thorpej 2092e78cec Add separate pmap_{zero,copy}_page() functions for generic ARM
vs. XScale.  Use the mini-data cache for the destination on XScale,
thus saving tossing out 4K of possible-useful data from the main
data cache each time.

This significantly improves every test in lmbench.
2002-04-10 00:45:43 +00:00
thorpej da162bee90 * Move the code that cleans the XScale mini-data cache into its
own function.
* Add a new function which sets up the mini-data cache clean area
  properly.
2002-04-09 23:44:00 +00:00
thorpej 1b20a04772 * Split pte_cache_mode into pte_l1_s_cache_mode, pte_l2_l_cache_mode,
and pte_l2_s_cache_mode.  The cache-meaningful bits are different
  for these descriptor types on some processor models.
* Add pte_*_cache_mask, corresponding to each above, which has a mask
  of the cache-meangful bits, and define those for generic and XScale
  MMU classes.  Note, the L2_S_CACHE_MASK_xscale definition requires
  use of the Extended Small Page L2 descriptor (the "X" bit overlaps
  with AP bits otherwise).
2002-04-09 22:37:00 +00:00
thorpej de29118bc5 Use the "Extended Small Page" L2 descriptor type on XScale (note
this means that there are no 1K sub-pages on XScale, but we don't
use them anyway).
2002-04-09 21:23:16 +00:00
thorpej 917afc7038 Remove the implementation-defined bits from L1_S_PROTO_xscale and
L1_C_PROTO_xscale; while they are supposed to be set to 1 on generic
ARM MMUs (according to the SA-110 and ARM920T manuals), they are listed
as "should be zero" in the i80200 manual.
2002-04-09 21:11:31 +00:00
thorpej c535f4ffc4 Define 2 classes of ARM MMUs:
1. Generic (compatible with ARM6)
1. XScale (can be used as generic, but also has certainly nifty extensions).

Define abstract PTE bit defintions for each MMU class.  If only one MMU
class is configured into the kernel (based on CPU_* options), then we
get the constants for that MMU class.  Otherwise we indirect through
varaibles set up via set_cpufuncs().

XXX The XScale bits are currently the same as the generic bits.  Baby steps.
2002-04-09 21:00:42 +00:00
thorpej 7b422802f6 L2_TYPE_S -> L2_S_PROTO 2002-04-09 19:44:22 +00:00
thorpej aee5994fce Use abstract names for the protection and PTE type bits in
L1 and L2 descriptors.  This will allow us to support different
PTE layouts that enable the use of extensions on different
processor models.
2002-04-09 19:37:14 +00:00
thorpej 4d78508c9d Back-out rev 1.75 (pmap_extract() rewrite), and fix the (minor)
bug that revision intended to fix properly.
2002-04-05 22:17:41 +00:00
thorpej 991426d348 * Rewrite the 32-bit ARM pte.h based on the ARM architecture manual.
Significant cleanup, here, including better PTE bit names.
* Add XScale PTE extensions (ECC enable, write-allocate cache mode).
* Mechanical changes everywhere else to update for new pte.h.  While
  doing this, two bugs (as a result of typos) were fixed in

	arm/arm32/bus_dma.c
	evbarm/integrator/int_bus_dma.c
2002-04-05 16:58:01 +00:00
thorpej 388879eeaf Use pte_cache_mode instead of PT_CACHEABLE. 2002-04-05 03:42:39 +00:00
thorpej 22e72c8da2 Don't need to mask w/ PG_FRAME. 2002-04-04 16:56:36 +00:00
skrll c0e4084210 Fix compile problem when DDB not defined. 2002-04-04 12:39:55 +00:00
thorpej ce482eca0a Eliminate a mask against PD_MASK. 2002-04-04 05:42:29 +00:00
thorpej 60b63aec95 There is no need to mask VAs and PAs w/ PG_FRAME to clear
the lower bits; UVM provides us page-aligned addresses for
everything.  For the paranoid, we'll leave KDASSERT()'s in
that check for this if the kernel is built with DEBUG.

Low-hanging fruit that shaves some cycles.
2002-04-04 04:43:20 +00:00
thorpej e539ef03aa Rename flags that are really part of the pv_entry/mdpage into
pmap.h and give them more descriptive names and better comments:
* PT_M  -> PVF_MOD (page is modified)
* PT_H  -> PVF_REF (page is referenced)
* PT_W  -> PVF_WIRED (mapping is wired)
* PT_Wr -> PVF_WRITE (mapping is writable)
* PT_NC -> PVF_NC (mapping is non-cacheable; multiple mappings)
2002-04-04 04:25:44 +00:00
thorpej 263270d684 Catch a couple more vector page mapping manipulations. 2002-04-04 02:06:46 +00:00
reinoud c85015ee71 Also provide differential coordinate updates... pitty it can't be choosen
or specified in wscons itself. The absolute coordinates are broadcasted
_after_ the relative so a program that takes both won't get confused.
2002-04-04 01:03:23 +00:00
thorpej 20b1bb2655 Clean up handling of the vector page on 32-bit ARM systems:
* Don't refer to VA 0, instead refer to a new variable: vector_page
* Delete the old zero_page_*() functions, replacing them with a new
  one: vector_page_setprot().
* When manipulating vector page mappings in user pmaps, only do so if
  the vector page is below KERNEL_BASE (if it's above KERNEL_BASE, the
  vector page is mapped by the kernel pmap).
* Add a new function, arm32_vector_init(), which takes the virtual
  address of the vector page (which MUST be valid when the function
  is called) and a bitmask of vectors the kernel is going to take
  over, and performs all vector page initialization, including setting
  the V bit in the CPU Control register ("relocate vectors to high
  address"), if necessary.
2002-04-03 23:33:26 +00:00
thorpej d36a56b03a Define the two possible addresses for the ARM vector page. 2002-04-03 22:12:52 +00:00
thorpej d8ab0d1e84 Remove unused extern decls. 2002-04-03 21:06:21 +00:00
thorpej 6d66c469bf Add a comment summarizing the post-ARM3 CP15 registers. 2002-04-03 19:57:48 +00:00
thorpej 7739f7410a Always provide kernel_text. 2002-04-03 17:30:50 +00:00
reinoud 9fc5cf5824 Fix the mmap'ing of the screen memory. The way it was implemented
completely sucked... I wonder how it was even working (....)

Thanks to Jason for pointing out the problem.
2002-04-03 16:03:50 +00:00
reinoud 943880cea2 Rototil and fix the pmap_extract function. It wouldn't even return data
when the part being quiried was mapped with a section (!) giving weird
results and had become a mess of goto's.

Complete rewrite and cleaned up the `goto'-jungle entirely ... ripped all
goto's. The resulting code is much better to read and might even have a
small performance gain.
2002-04-03 15:59:58 +00:00
reinoud d6a3919c2c In analogy to L2_LPAGE_SIZE add L2_SPAGE_SIZE .... 2002-04-03 00:46:53 +00:00
lukem d213d804f7 Rename MEMORY_DISK_SIZE (formerly MINIROOTSIZE) to MEMORY_DISK_ROOT_SIZE,
which was suggested by Izumi Tsutsui <tsutsui@ceres.dti.ne.jp> as
being more consistent with what it's controlling...
2002-04-02 05:30:34 +00:00
reinoud d1f811363a Only include the vidc_machdep.h file when we're compiling the kernel 2002-03-30 17:10:31 +00:00
thorpej 243dc1d498 Rename the ARM sysarch calls from arm32* -> arm* 2002-03-30 06:23:39 +00:00
thorpej 863afc5d41 Fix a printf format. 2002-03-29 00:48:58 +00:00
thorpej 6ce299c3d3 Use write-back caching on the Verde. 2002-03-28 16:47:49 +00:00
thorpej 70fbd8fba7 Fix soft interrupts. 2002-03-28 03:19:31 +00:00
thorpej 0b109cd060 iwin_base_lo is a BAR value; make sure to mask off the non-address
bits when using it.
2002-03-27 23:17:03 +00:00
thorpej f536211623 Basic support for the Intel i80321 I/O Processor (Xscale core).
Note: This is a snapshot of work-in-progress; there are still some
bugs to be shaken out.
2002-03-27 21:45:47 +00:00
thorpej c915b880c5 The 80321 manual lies; it does have a CPU ID distinct from the 80200.
Add that CPU ID, and add a case for it.
2002-03-27 01:34:47 +00:00
thorpej 41f47f03e7 Restructure a few things in order to support other XScale core
I/O processors:
* The i80200 and the i80321 have the same CPU ID, so split the
  CPU_XSCALE option into CPU_XSCALE_80200 and CPU_XSCALE_80321
  options, and don't let them both be defined at the same time.
  XXX May want to revisit this in the future.
* Split some registers common between the i80200 and i80321 into
  <arm/xscale/xscalereg.h>.
* Rename a few existing functions.
2002-03-26 19:29:44 +00:00
thorpej 3964313f67 Fix reporting of the kernel virtual address space range to UVM. 2002-03-25 22:11:12 +00:00
thorpej a2a309d02a * Some cleanup.
* Delete the call to pmap_copy() in pmap.h
2002-03-25 19:53:38 +00:00
thorpej b17e7a03c2 Clean up pmap_map_ptes() and pmap_unmap_ptes() a little, and add
a debug assertion that curproc is never NULL if mapping a non-current
pmap.
2002-03-25 17:50:12 +00:00
thorpej a2d8f71d01 The target page of pmap_zero_page(), pmap_pageidlezero(), and
pmap_copy_page() will never have any mappings.  Therefore, it
is unnecessary to do a cache clean for that page.

Add assertions in #ifdef DEBUG that assert this invariant.

This shaves some cycles off the frequently-called pmap_zero_page()
and pmap_copy_page() (no need to look up the dst page's vm_page
structure, and one less function call to clean the page).
2002-03-25 17:33:26 +00:00
thorpej 75cb2c6554 * Clean up some comments/whitespace.
* Don't construct a fake trap frame and pass it to main(); that hasn't
  been needed for some time.
* panic if main() returns.
2002-03-25 16:58:18 +00:00
thorpej a61914be93 Garbage-collect fetchuserword(); nothing uses it any more. 2002-03-25 16:32:55 +00:00
thorpej dbe6d8291b * Fix use of pmap_curmaxkvaddr.
* Use the PTP hint in the pmap.
2002-03-25 04:51:19 +00:00
thorpej 8500c97458 Move some private pmap data structures into pmap.c 2002-03-25 03:00:28 +00:00
thorpej c93e4f6940 Tidy a few things up. 2002-03-25 02:51:32 +00:00
thorpej a9cba12f54 Correct the comment describing the layout of the VM space. In
particular, don't describe a recursive PTE mapping, since the ARM
port doesn't (and can't) use one.
2002-03-25 02:44:07 +00:00
thorpej da2944b10e In the Prefetch Abort handler, just do the uvm_fault() dance
directly, rather than doing a data access to fetch the page,
which meant we had to take another fault (!!).
2002-03-25 01:53:36 +00:00
thorpej a4652c81cf Only check for SA110 bugs on SA110 CPUs with step <= K. 2002-03-24 22:03:23 +00:00
thorpej ea553e2681 Cache the cpu type and cpu revision in cpu_info. 2002-03-24 22:02:58 +00:00
thorpej 186c0135d6 Garbage-collect pmap_pte() (and good riddance!) 2002-03-24 21:32:18 +00:00
thorpej ea95b58d21 * Only check for SA110 rev K bug if we're on an SA110 (XXX should also
check stepping).
* In said check, don't use pmap_pte().
* Garbage-collect some useless debug code.
2002-03-24 21:27:57 +00:00
chris 03345d6008 remove pointless pg = NULL in else part of if (pg != NULL) 2002-03-24 21:10:25 +00:00
thorpej bf3ea66d5c pmap_enter(): Use pmap_map_ptes() correctly. 2002-03-24 20:48:59 +00:00
thorpej 1ffa188c0a Remove exported pmap_pte() prototype. 2002-03-24 18:36:52 +00:00
thorpej 5ffc15a083 Use vtopte() instead of pmap_pte(). 2002-03-24 18:12:54 +00:00
chris 434f6391ea Update pmap_copy_page to only map in the src readonly and only invalidate it after the copy, no need for it to flush the wb. 2002-03-24 18:05:45 +00:00
bjh21 650f7e5c99 arm26 -> acorn26 changes. 2002-03-24 16:10:11 +00:00
bjh21 99ba40c188 arm26->acorn26 transition. 2002-03-24 15:49:38 +00:00
bjh21 ebfcb75fe5 Add ARM610 cache information. Not yet tested because booting on ARM610s seems
to be broken at present.
2002-03-24 15:37:46 +00:00
thorpej a6d59cb039 pmap_allocpagedir(): Don't use pmap_pte(), and simplify a little. 2002-03-24 06:07:00 +00:00
thorpej b812152b34 pmap_handled_emulation(): Fix locking protocol botch.
XXX Should we traverse the PV list and enable all PTEs?
2002-03-24 05:55:31 +00:00
thorpej 6fbfe41621 pmap_handled_emulation(): Use pmap_map_ptes() correctly. 2002-03-24 05:52:10 +00:00
thorpej ec75dcf496 pmap_modified_emulation(): Use pmap_map_ptes() correctly. 2002-03-24 05:39:53 +00:00
thorpej 0aef2cab11 pmap_unwire(): Use pmap_map_ptes() correctly. 2002-03-24 05:28:46 +00:00
thorpej 11df08a743 pmap_clearbit(): Use pmap_map_ptes() correctly. 2002-03-24 05:15:59 +00:00
thorpej eb638f9bc5 Use pmap_is_curpmap() consistently. 2002-03-24 04:56:49 +00:00
thorpej 242f080390 Clean up the PTP allocation functions a bit. 2002-03-24 04:49:16 +00:00
thorpej c34d24ea3c Clean up PTE access macros a bit. 2002-03-24 04:38:33 +00:00
thorpej aa1563948c * arm_byte_to_page() -> arm_btop()
* arm_page_to_byte() -> arm_ptob()
2002-03-24 03:37:18 +00:00
thorpej 48d8c5fdd9 Remove some redundant tests in pmap_enter(). 2002-03-24 03:25:10 +00:00
reinoud 2b488a7d9f Big rototil of the vidcvideo code to cleanup illogical structures and to
incorporate write back support for processors not having a write through
cache.

The current fb_devconfig structure now really holds the device's
configuration and the softc really only holds the attachment information.
This used to be mixed giving rise to weird stuctures and cross references.

The number of vertical syncs before the video memory writeback is triggered
is configurable ... default is to wait for 5 Vsync .. aprox minumum 10
times a second, but more likely in the order of 12,5 times a second. When
printing is in progress no write back is performed... only after the
waiting time. The reasoning behind this is that as long as the screen is
printed too the cache will be purged of dirty data anyway due to the
processing and new screen memory useage.
2002-03-23 21:27:41 +00:00
thorpej 2488d00e5f KERNEL_SPACE_START -> KERNEL_BASE 2002-03-23 19:38:30 +00:00
thorpej e80bfdc1a3 Garbage-collect the "pagehook" stuff. 2002-03-23 19:21:58 +00:00
reinoud 2d2df858f7 Fix up typos. 2002-03-23 18:10:24 +00:00
reinoud fe2473fafd Fix typo. 2002-03-23 17:10:13 +00:00
thorpej 0ba36d6f6f * Rename PROCESS_PAGE_TBLS_BASE -> PTE_BASE
* Rename ALT_PAGE_TBLS_BASE -> APTE_BASE
* Garbage-collect PAGE_TABLE_SPACE_START
2002-03-23 02:22:56 +00:00
reinoud 89400b4aab Allthough this patch doesn't look that much it adds a few things that were
on the port-acorn32's TODO list for quite some time :

- when the serial console is selected, don't exclude the screen
alltogether; currently the keyboard is still not attached but that might be
a configuration problem in the GENERIC console or a failure to explicitly
connect to a wsmux. This needs further investigation.

- create a framework for the display memory writeback on vsync for
StrongARM processors since they don't have a write-trough cache. This is to
solve the lazy screen update that is very evident in single user mode on
these processors; the cache isn't flushed/written back that often and parts
of the screen can thus be resident in the cache but not written out to
memory yet.

- clean up some loose ends in the code.
2002-03-23 02:00:26 +00:00
thorpej b326238b01 Remove redundant #ifdef _KERNEL 2002-03-23 01:56:31 +00:00
reinoud 12d0f60218 If the serial console is asked for then dont forget to define the function
prototype for connecting the serial console....
2002-03-22 13:32:51 +00:00
briggs 14bcbc0e29 Ignore cpu_sleep() if called with anything other than ARM_SLEEP_MODE_IDLE. 2002-03-19 19:41:57 +00:00
briggs 47c8167bc7 Fix typo: ISDNCTL -> NISDNCTL. 2002-03-18 22:46:57 +00:00
bjh21 e637cd6c16 PS_STRINGS -> p->p_psstr 2002-03-18 22:21:25 +00:00
atatat 31144d9976 Convert ioctl code to use EPASSTHROUGH instead of -1 or ENOTTY for
indicating an unhandled "command".  ERESTART is -1, which can lead to
confusion.  ERESTART has been moved to -3 and EPASSTHROUGH has been
placed at -4.  No ioctl code should now return -1 anywhere.  The
ioctl() system call is now properly restartable.
2002-03-17 19:40:26 +00:00
bjh21 a12e90b08f Only put the CPU type into cpu_model, not the state of the control register.
Instead, print the control register state on the next line at startup.
2002-03-16 18:47:51 +00:00
bjh21 dccc5d2c67 Get rid of the #ifdef DEBUG_FAULT_CORRECTION #ifdef mess, and use a
couple of conditionally-defined macros instead.  This makes the
fault-correction code almost readable.
2002-03-16 18:26:00 +00:00
bjh21 da4eca13c2 Kill some unnecessary settings of arm_dcache_align_mask. 2002-03-16 18:11:11 +00:00
bjh21 2d05b7a7b6 For those CPUs which don't have a cache-type register, keep the details
of the cache in a static table.  Note that the table isn't complete --
contributions of cache details for CPUs whose data sheets I haven't got are
welcome.
2002-03-16 18:02:19 +00:00
martin 94881fb123 Rename ISDN devices, per discussion on tech-kern. The network devices
become ippp (ISDN ppp) and irip (ISDN raw IP). The character device now
are called: /dev/isdn (isdnd <-> kernel communication), /dev/isdnctl (dialing
and other control), /dev/isdntrc* (tracing), /dev/isdnbchan* (raw B channel
access, i.e. for user land PPP) and /dev/isdntel* (telephone devices, i.e.
for answering machines).
2002-03-16 16:55:51 +00:00
bjh21 57eb77d59f Add CPU ID for the ARM1022ES.
Also add a CPU class for ARM10E processors in general.
2002-03-16 14:41:15 +00:00
reinoud 5fd6dd1b2b Clean up cpufunc.c so you can really use it for debugging ... the
dependency on DEBUG_PMAP was useless anyway since the PMAP_DEBUG was
printing soooo much garbage cpufunc's debugging stuff was lost anyway.
2002-03-16 03:38:28 +00:00
reinoud aefe920476 Serious bug fix: a userland program could panic the kernel when it tried to
issue an instruction that caused the late abort handler to be called for
wich the kernel had no support build in for.

It now only panics when it happends in kernel but otherwise signals the
process a SEGV signal.
2002-03-15 22:19:49 +00:00
reinoud 1a19ddabcd Some cosmetic changes.... 2002-03-15 13:33:19 +00:00
ad b89e39b91a Reorganise the wsfont stuff slightly so that multiple display adapters
with different bit/byte order requirements can co-exist happily.
2002-03-13 15:05:13 +00:00
rjs 415c021881 Map the reset controller registers. 2002-03-13 00:02:41 +00:00
rjs 54204051f6 Add bus space handle for SA11x0 reset controller. 2002-03-12 23:57:35 +00:00
reinoud b91c20709e When ARMFPE wasn't enabled the `usearmfpe' flag was statically initialised
but not used resulting in a compiler error. By splitting the declaration
and the initialisation this is solved.

Better would be to not even declare the flag when ARMFPE isnt enabled but
that would just add to the #ifdef jungle.
2002-03-11 11:50:12 +00:00
lukem cd19d52695 * rename MINIROOTSIZE to MEMORY_DISK_SIZE, so that all md(4) options
are now consistently named
* fold opt_mdsize.h into opt_md.h
2002-03-10 19:56:37 +00:00
bjh21 a42e17ae9a __RCSID -> __KERNEL_RCSID 2002-03-10 15:47:43 +00:00
bjh21 3a0f83d390 Re-work the way that FPAs are handled. If ARMFPE isn't configured, don't
even bother probing for an FPA.  If ARMFPE is configured, always use it,
even if there's an FPA (since it provides the FPA support code).  Move all
printfs about FPAs into armfpe_init.c.

This means I can delete the last two elements from struct _cpu, so that the
structure, and the whole of <arm/cpus.h> is redundant and can be deleted.
2002-03-10 15:29:53 +00:00
bjh21 b0f4f4fe56 Add an RCSID while I'm here. 2002-03-10 11:39:58 +00:00
bjh21 9bb7807c7b Remove fpu_model from struct _cpu. Instead, have initialise_arm_fpe()
printf() the FPE version number itself.
2002-03-10 11:32:00 +00:00
bjh21 63231772e8 Add a ci_dev element to struct cpu_info, pointing to the device that
corresponds to the CPU.
2002-03-10 11:06:01 +00:00
bjh21 60219ba2a6 Kill the fpu_flags element from struct _cpu. It was only ever set to 0
anyway.
2002-03-10 00:44:09 +00:00
bjh21 01b68bd7de Clean up inline assembler. Rather than saving R0, copying FPSR to R0,
copying it to the output register and then restoring R0, just copy the
FPSR straight to the output.
2002-03-10 00:09:24 +00:00
bjh21 aeece3b5bd Remove the cpu_model member from struct _cpu, and just use the cpu_model
variable directly.  While we're at it, make cpu_model rather larger.
2002-03-09 23:49:15 +00:00
bjh21 09dd49a342 Remove the cpu_class element from struct _cpu, and make it a local variable
in identify_arm_cpu(), since it's almost unused elsewhere.

Change the detection of bugged StrongARMs to use the cpu ID rather than the
class.  This turns "almost" into "entirely".
2002-03-09 23:24:11 +00:00
bjh21 1c1e3f8439 Replace cpu_id and cpu_ctrl in struct _cpu with ci_cpuid and ci_ctrl in
struct cpu_info.  Also kill the cpuctrl global while we're here, and make
identify_arm_cpu() take a struct cpu_info * as an argument alongside the CPU
number.
2002-03-09 21:30:57 +00:00
bjh21 20917f120c Move arm700bugcount into stuct cpu_info, and attach it in
identify_master_cpu().
2002-03-09 19:11:20 +00:00
thorpej a180cee23b Pool deals fairly well with physical memory shortage, but it doesn't
deal with shortages of the VM maps where the backing pages are mapped
(usually kmem_map).  Try to deal with this:

* Group all information about the backend allocator for a pool in a
  separate structure.  The pool references this structure, rather than
  the individual fields.
* Change the pool_init() API accordingly, and adjust all callers.
* Link all pools using the same backend allocator on a list.
* The backend allocator is responsible for waiting for physical memory
  to become available, but will still fail if it cannot callocate KVA
  space for the pages.  If this happens, carefully drain all pools using
  the same backend allocator, so that some KVA space can be freed.
* Change pool_reclaim() to indicate if it actually succeeded in freeing
  some pages, and use that information to make draining easier and more
  efficient.
* Get rid of PR_URGENT.  There was only one use of it, and it could be
  dealt with by the caller.

From art@openbsd.org.
2002-03-08 20:48:27 +00:00
tsutsui 3c8b0446fe Change type of dumpmag to u_int32_t since it is actually
a 32bit unsigned magic number.
As per discussion on tech-kern, and fixes port-sparc64/11949.
2002-03-06 13:10:18 +00:00
chris 09b5f7b740 Mostly style changes to stop us directly referencing tqh_first, and use TAILQ_FIRST instead. Based on rev 1.130 of the i386 pmap.c. 2002-03-06 10:55:21 +00:00
thorpej 84be4d4719 Fix size/padding of .data. From Nick. 2002-03-05 21:26:11 +00:00
thorpej 5658662324 * Make pmap_is_{modified,referenced}() macros in pmap.h that just
test the attributes in the vm_page_md directly.
* Clean up pmap_clear_{modified,referenced}().
* Delete now-unused pmap_testbit().
2002-03-05 04:48:03 +00:00
thorpej a92da3d4a5 Switch back to using vm_page_md (thanks chuq for finding the bug
in the code that made it unstable before!)
2002-03-05 04:19:59 +00:00
simonb 6f0fb25121 Don't need to declare phys_map - it is declared in <uvm/uvm_extern.h>. 2002-03-04 02:43:22 +00:00
chris 1181e367e0 Implement pmap_growkernel for arm32 based ports.
Note that this has been compiled on some systems, cats, IQ80310, IPAQ, netwinder and shark (note that shark's build is currently broken due to other reasons), but only actually run on cats.
Shark doesn't make use of the functionality as I believe there has to be a correlation between OFW and the kernel tables so that calls into OFW work.
2002-03-03 11:22:58 +00:00
chris a973797a7a Remove ref to VM_MAXKERN_ADDRESS, it's not used in this file 2002-03-02 15:35:05 +00:00
chris 4fa8495ff4 Update the types, pt_entry and pd_entry should be unsigned, and fixed at 32 bits. 2002-03-02 15:30:49 +00:00
simonb 4324f37586 Use "#define<tab>". 2002-02-28 03:17:23 +00:00
christos e8116a8f5b - Use DEV_ constants, instead of documenting the numbers!
- Delete cdev_decl(mm); where appropriate, and other hand-crufting [hi powerpc!]
2002-02-27 01:20:51 +00:00
christos 6b030ee036 - define other DEV_ constants that the local port uses.
- delete cdev_decl(mm) since <sys/conf.h> does it.
2002-02-27 01:19:03 +00:00
simonb d9ab16ba2f Purge CLSIZE, CLSIZELOG2 and MCLOFSET.
Be consistant in the way that MSIZE, MCLSHIFT, MCLBYTES and NMBCLUSTERS
  are defined.
Remove old VM constants from cesfic port.
Bump MSIZE to 256 on mipsco (the only one that wasn't already 256).
2002-02-26 15:13:19 +00:00
briggs c31c5df13c Bumb NMBCLUSTER defaults to 2048 for GATEWAY and 1024 otherwise. These
match current powerpc defaults and are more reasonable for the current era.
2002-02-22 06:41:48 +00:00
thorpej bb84e85802 Change pmap_map_entry() to work like pmap_map_chunk(): take a pointer
to the L1 table and a virtual address, and no pointer to the L2 table.
The L2 table will be looked up by pmap_map_entry(), which will panic
if the there is no L2 table for the requested VA.

NOTE: IT IS EXTREMELY IMPORTANT THAT THE CORRECT VIRTUAL ADDRESS
BE PROVIDED TO pmap_map_entry()!  Notably, the code that mapped
the kernel L2 tables into the kernel PT mapping L2 table were not
passing actual virtual addresses, but rather offsets into the range
mapped by the L2 table.  I have fixed up all of these call sites,
and tested the resulting kernel on both an IQ80310 and a Shark.
Other portmasters should examine their pmap_map_entry() calls if
their new kernels fail.
2002-02-22 04:49:19 +00:00
thorpej 77e3a89912 When reporting there is no VM map for a fault, also report the
faulting address.
2002-02-22 03:24:09 +00:00
thorpej 79738a99e9 Keep track of which kernel PTs are available during bootstrap,
and let pmap_map_chunk() lookup the correct one to use for the
current VA.  Eliminate the "l2table" argument to pmap_map_chunk().

Add a second L2 table for mapping kernel text/data/bss on the
IQ80310 (fixes booting kernels with ramdisks).
2002-02-21 21:58:00 +00:00
thorpej 6d35f61035 In pmap_map_chunk(), if we can't use a section mapping, then
make sure that the L1 slot for the current VA points to an L2
table, and panic if it doesn't.
2002-02-21 06:36:11 +00:00
thorpej 15e0450397 Always pass the L1 table to pmap_map_chunk(). This allows pmap_map_chunk()
to perform some error checking.
2002-02-21 05:25:23 +00:00
thorpej 454e106a48 map_chunk() -> pmap_map_chunk(), and move it to pmap.c 2002-02-21 02:52:19 +00:00
skrll f9d21f3995 Use shell arithmetic as much as possible and reduce the number of times
that awk is used to one.

No functional change.
2002-02-20 21:54:08 +00:00
thorpej 425011f621 map_pagetable() -> pmap_link_l2pt(), and move it to pmap.c 2002-02-20 20:41:15 +00:00
thorpej c44b9117f0 Collapse map_entry{,ro,nc}() into a single pmap_map_entry() that
takes a prot and a "cacheable" indicator.
2002-02-20 02:32:56 +00:00
thorpej 9c31f51c34 Rename map_section() to pmap_map_section(), move it to pmap.c, and give it
an extra argument (prot - specifies protection of the mapping).
2002-02-20 00:10:15 +00:00
wiz 37e458fa45 strategy should have an 'r'. Inspired by similar change in OpenBSD. 2002-02-19 17:09:40 +00:00
simonb 2d8577fb83 Clean up some rampant code duplication wrt ieee number handling:
- Add alignment-safe double and float unions.
 - Use the above for the __infinity and __nan constants on all
   architectures that use the standard ieee754 representation of
   those constants.
 - Add a single copy of various ieee754 math functions (frexp, isinf,
   isnan, ldexp and modf) that had numerous duplicates among the
   arch-specific directories.
 - Use the above functions on all architectures where the generic C
   versions where used.  Architectures that had local assembly
   routines are untouched (for those functions only).
2002-02-19 13:08:12 +00:00
bjh21 ff94cc2ad5 Add prototype for getkey_polled(). 2002-02-18 19:05:35 +00:00
bjh21 d4d3aa6468 Add internal prototype for cmd_mouse().
Also __RCSID() while I'm here.
2002-02-18 18:58:47 +00:00
bjh21 eb821c3860 Add a prototype for qms_console_freeze(). 2002-02-18 18:43:55 +00:00
bjh21 1e6835687e Rename prototype from sysbeep_vidc() to sysbeep() to match definition.
Pull in beepvar.h and vidcaudiovar.h for beep_generate() and
vidcaudio_beep_generate() prototypes.
__RCSID().
2002-02-18 16:23:54 +00:00
bjh21 2712a10c7c Add a prototype for vidcvideo_config_wscons(). 2002-02-18 14:30:20 +00:00
bjh21 761157905a Add prototypes to all declarations of function pointers.
Include <arch/arm/iomd/vidcaudiovar.h> for vidcaudio_beep_generate() prototype.
Add in-core RCSID.
2002-02-18 12:55:47 +00:00
bjh21 a06b71e864 Add a vidcaudiovar.h to contain a prototype for vidcaudio_beep_generate(). 2002-02-18 12:52:09 +00:00
bjh21 2aa99b4f12 Include <arch/arm/iomd/beepvar.h> for beep_generate() prototype.
Include <machine/conf.h> for cdevsw function prototypes.
Correct argument types of beepioctl().
Add in-core RCSID.
2002-02-18 12:36:27 +00:00
bjh21 668fc0d2b7 Add beepvar.h, to hold a prototype for beep_generate(). 2002-02-18 12:34:11 +00:00
bjh21 c1f8e3aa21 Comment out vidcvideo_setbase() (it's unused).
Remove vidcvideo_mmap() (it's redundant).
Add in-core RCSID.
2002-02-18 12:23:24 +00:00
bjh21 1a140d2090 Add prototypes for clockhandler() and statclockhandler(), and adjust their
argument types to match other interrupt handlers.
Also minor KNF (add in-core RCSID).
2002-02-18 12:18:26 +00:00
bjh21 40933bf05e Add prototype for yeartoday(). 2002-02-18 12:03:38 +00:00
bjh21 57a6aecd77 Include <machine/conf.h> for cdevsw function prototypes.
Add internal prototypes for hexdectodec(), dectohexdec() and twodigits().
Correct signature of rtcioctl().
2002-02-18 11:59:16 +00:00
bjh21 b5c13de9bf Pull in <machine/conf.h> to get prototypes for cdevsw functions, and correct
the signature of iicioctl() appropriately.
2002-02-18 11:51:57 +00:00
bjh21 216b4f1c81 Add prototypes for dma_reset(), dma_setup(), dma_isactive(), dma_isintr() and
dma_intr().
2002-02-18 11:41:18 +00:00
bjh21 dbc5effbc8 Change signature of dma_intr() to match other interrupt handlers. 2002-02-18 11:40:42 +00:00
bjh21 ca677d0d06 Add a prototype for linux_syscall(). It should be in a header file, but
other files that refer to it don't know its argument types anyway.
2002-02-17 23:37:18 +00:00
bjh21 e6e848ef6d Our assembler handles FPA instructions fine, so don't use .word for them. 2002-02-17 20:41:02 +00:00
bjh21 cb7a3d0674 ANSIfy, and othe KNF cleanup. 2002-02-17 19:53:44 +00:00
bjh21 561984015b Undo part of rev 1.8: SWP intructions really do both read and write
the referenced address.
2002-02-14 11:59:26 +00:00
chs b744097a5f allow writing to write-only mappings. fixes PR 3493. 2002-02-14 07:08:02 +00:00
briggs b72d845476 Actually set the i80312_softc global. 2002-02-14 02:38:22 +00:00
rjs 9134bf2610 Add Cotulla CPU IDs. 2002-02-14 01:37:20 +00:00
thorpej cd98cbf7fb * For platforms which are already ELF, remove the definition of
MACHINE_ARCH since <arm/param.h> already sets it correctly to "arm".
* For platforms which are not yet ELF, defined MACHINE_ARCH to "arm32"
  if __ELF__ is not defined by the C preprocessor.
* In <arm/param.h>, clarify the rules about when MACHINE and
  MACHINE_ARCH are defined, and to what.  Also, for ELF platforms,
  int the non-_KERNEL case, force both MACHINE and MACHINE_ARCH to "arm",
  rather than allowing platform-specifc code to define either.
2002-02-12 06:58:18 +00:00
reinoud a74d22be50 Add some extra comments for the `booted_kernel' variable. 2002-02-10 13:20:26 +00:00
chris a73dabb4b1 Following the demise of arch/arm32 update cats, and restore the isa files to a more sane location.
Also fix build break on GENERIC cats kernel, seems that conf.h should have been including arm/conf.h.

This completes the removal of arch/arm32.
2002-02-10 12:26:00 +00:00
reinoud 8843d04234 Please only return errno values !!! ... also doing a bit of KNF'ing 2002-02-10 00:53:28 +00:00
chris 2ba81d8c9c Update elf2aout to cope with infile and outfile being the same.
Make the cats a.out kernel be called netbsd.  This means that make install installs the correct kernel
2002-02-09 11:53:58 +00:00
thorpej d17cc4f043 * Move some generic ARM OpenFirmware stuff into arch/arm/ofw (still
more can move, but not yet).
* Garbage-collect some cruft from arch/arm32 in preparation for
  renaming to arch/shark.
2002-02-06 21:30:25 +00:00
thorpej 5113cbfb17 A slightly cleaned up version of chris/nick's elf2aout.sh for ARM
platforms.
2002-02-06 19:54:47 +00:00
thorpej da13cb2fb5 Back out all the vm_page_md changes. They are causing some
mysterious problems (a similar change to the i386 pmap causes
mysterious problems there, as well), and the issue needs to
be investigated more.
2002-02-06 17:41:42 +00:00
thorpej 4611193917 Efficiency tweaks, some made possible by vm_page_md. 2002-02-06 17:32:35 +00:00
thorpej 58eebd58b3 Use vm_page_md rather than pmap_physseg. Saves lots of cycles in
common operations.
2002-02-05 21:14:36 +00:00
thorpej 9485327397 Allow platforms to use an extra level of indirection for FIQs,
enabled by definining __ARM_FIQ_INDIRECT in <machine/types.h>.
This is needed for OpenFirmware systems (like the Shark), where
the OFW vector page is used, and kernel entries merely patched
into it.
2002-02-05 18:26:07 +00:00
reinoud fe0ecbaede At last enable the real time clock again on acorn32 !! thanks a lot to Mike
Pumford for the patches.
2002-02-05 14:36:35 +00:00
chris 4253f3bbfc Set LOOSE_PROTOTYPES to no for cats. This means cats now uses stricter prototype checking. 2002-01-31 09:53:33 +00:00
chris 3ead7271d5 Fix the type of irqmasks (any reason it's even been added as an extern when it's in irqhandler.h with the correct type and array size?) 2002-01-31 09:43:42 +00:00
thorpej 2bc996b0bc New interrupt framework for NetBSD/evbarm, and accompanying new
interrupt code for the IQ80310 board support package.

XXX The Integrator board support package still uses the old-style
arm32 interrupt code, so some compatibility hacks have been added
for it.  When the Integrator uses new-style interrupts, those hacks
can go away.
2002-01-30 03:59:39 +00:00
thorpej 5e0726b647 Set the CPU sleep routine to sa11x0_cpu_sleep() on SA-1100 and SA-1110
processors.
2002-01-30 00:37:18 +00:00
thorpej 50f7f1d785 Add prototype for sa11x0_cpu_sleep(). 2002-01-30 00:36:32 +00:00
thorpej 2c0cb97fa8 Add a sleep routine for the SA-11x0. 2002-01-30 00:25:07 +00:00
thorpej cb51977892 When initializing sf->sf_spl, simply always assume that 0 is
equivalent to spl0().
2002-01-29 23:02:48 +00:00
thorpej 558b6aece0 Move the generic ARM soft interrupt code into a generic place. 2002-01-29 22:54:14 +00:00
rearnsha 45b996e3b2 Fix copying and disclaimer (ARM != Causality). 2002-01-29 15:27:29 +00:00
bjh21 e4b1cbedfc Add revision->stepping maps for the SA-110, SA-1100 and SA-1110.
Those for the SA-1100 and SA-1110 are from Intel's documentation.
The mapping for the SA-110 is from various sources on the net, since Intel
don't seem to document it.

Also, change the layout of the maps to have four steppings per line,
so they aren't quite so unwieldy.
2002-01-27 14:43:47 +00:00
thorpej f59990cae7 * Default dcache_inv_range to xscale_cache_flushD_rng for XScale
cores.
* For i80200 Step-A0 and Step-A1, set dcache_inv_range to
  xscale_cache_purgeD_rng to work around a bug where a D$
  "invalidate by address" doesn't properly clear the dirty
  bits on the cache block (i80200 errata item #25).
2002-01-25 21:33:26 +00:00
thorpej 08342df793 Overhaul bus_dmamap_sync for the ARM:
* Track which process (XXX really, vmspace) owns the mapping.  When
  we sync the map, if the mapping doesn't belong to the kernel or to
  the current process (XXX really, vmspace), then no cache fobbing
  is necessary, since the cache is Wb-Inv'd on context switch (XXX need
  to revisit this when we support FCSE).
* Be smarter about which cache operation we do when sync'ing the map:
  - PREREAD -- Invalidate D$ (XXX right now, we actually do Wb-Inv)
  - PREWRITE -- Write-back D$ (note, we do NOT invalidate here)
  - PREREAD|PREWRITE -- Wb-Inv D$

More work is needed here.  In particular, a version for CPUs
with write-through caches should be provided, to eliminate
the write-back steps (which are noops on such CPUs, but skipping
two branches would be nice).
2002-01-25 20:57:41 +00:00
thorpej 2c23251a7a ANSI'ify function decls. 2002-01-25 19:37:49 +00:00
thorpej 4e990d9ccb Overhaul of the ARM cache code. This is mostly a simplification
pass.  Rather than providing a whole slew of cache operations that
aren't ever used, distill them down to some useful primitives:

	icache_sync_all         Synchronize I-cache
	icache_sync_range       Synchronize I-cache range

	dcache_wbinv_all        Write-back and Invalidate D-cache
	dcache_wbinv_range      Write-back and Invalidate D-cache range
	dcache_inv_range        Invalidate D-cache range
	dcache_wb_range         Write-back D-cache range

	idcache_wbinv_all       Write-back and Invalidate D-cache,
				Invalidate I-cache
	idcache_wbinv_range     Write-back and Invalidate D-cache,
				Invalidate I-cache range

Note: This does not yet include an overhaul of the actual asm files
that implement the primitives.  Instead, we've provided a safe default
for each CPU type, and the individual CPU types can now be optimized
one at a time.
2002-01-25 19:19:22 +00:00
thorpej 8ed8f67cf7 Make the software copy of INTCTL volatile. 2002-01-25 19:05:36 +00:00
thorpej c2004821b2 Use a table to look up stepping names. Add a generic stepping
table ("rev 0", "rev 1", etc.) and an i80200 stepping table that
has the stepping names that appear in the i80200 manuals/errata..
2002-01-24 20:14:19 +00:00
thorpej e05fbea5e8 Shave an instruction off the case where we want to do a CPWAIT and
then return.
2002-01-24 17:53:08 +00:00
thorpej d58e8e800b Update copyright years and author list. 2002-01-24 06:21:27 +00:00
thorpej 68a5455c8b Work around a bug in the XScale core's D-cache. The work-around is to
use 2 adjacent cache-size areas for global cache clean, alternating
between the two of them on each call.  Without this, D-cache blocks
aren't evicted properly, and no one seems to know why.
2002-01-24 06:18:12 +00:00
briggs 2341768d92 Two changes for XScale:
1) Add defparam XSCALE_CCLKCFG to define a parameter for the
	   CCLKCFG register.  Default it to '9' on the IQ80310.
	2) Add a sleep call to the xscale CPU function vector (replacing
	   the nullop) which should drop the CPU into "idle" mode when
	   cpu_switch finds nothing on the run queues.
2002-01-24 04:23:18 +00:00
thorpej bd098d4ca4 Fix a typo (thanks Allen). 2002-01-24 03:58:09 +00:00
thorpej 7c2247336b Clean up the i80312 PMU definitions. 2002-01-24 01:21:44 +00:00
thorpej e33cde5940 Add an IRQ vector to be shared by all i80200 applications. This
consults the interrupt source bits in the i80200 ICU and calls
a board-specific external IRQ dispatcher if an external IRQ is
pending.
2002-01-24 01:12:40 +00:00
thorpej 372342ce22 i80200: Call i80200_intr_init() to initialize the ICU, rather than
doing it ourselves.
2002-01-23 21:03:07 +00:00
thorpej d70b940ca2 Add generic code to manipulate the i80200 ICU. 2002-01-23 21:00:12 +00:00
thorpej 361cbb0a88 Make this usable directly by assembly code. 2002-01-23 20:58:29 +00:00
bjh21 8a3c27fbf7 Add support for the ARM-specific syscalls in ARMLinux. These are invoked
by SWI numbers above 0x9f0000, but we re-map them down to somewhere just
after the end of the usual syscall range, since NetBSD doesn't handle
sparse syscall arrays well.

The only syscall I've actually implemented in this range is cacheflush(),
which was previously being mapped to fork(), causing ... interesting results.
2002-01-23 15:52:58 +00:00
thorpej e594c94727 Some prototype cleanup. 2002-01-20 03:41:47 +00:00
thorpej ce74acf44c XXX Local prototype for syscall(). 2002-01-20 03:39:51 +00:00
chs b263a7eb4d add a new flag PMAP_CACHE_VIVT for the pmap to inform the MI code that
that the cache is virtually-indexed and virtually-tagged (such as on the ARM),
and use this flag in the UBC code to be more friendly to those caches.
2002-01-19 16:55:20 +00:00
thorpej 940aa6cbf5 Add cpwait's after TLB operations. 2002-01-17 23:56:01 +00:00
bjh21 6ad60873c2 More-or-less working signal handling for Linux processes on ARM. 2002-01-17 22:50:38 +00:00
thorpej e422b995b1 Cleanup a little, and teach db_write_text() about section mappings. 2002-01-17 20:47:00 +00:00
bjh21 0598bbd10f Separate out syscall() out into three parts:
swi_handler() does stuff that all SWIs will need, then calls
   curproc->p_emul->e_syscall.
  syscall() handles native NetBSD system calls.
  linux_syscall() handles Linux system calls.
2002-01-17 17:26:03 +00:00
thorpej 79543e3e0b * db_validate_address(): Use pmap_extract().
* db_read_bytes()/db_write_bytes(): Do comparisons against the
  (unsigned) size_t correctly.
2002-01-17 03:52:06 +00:00
thorpej 3609326b93 Teach pmap_extract() about section mappings. 2002-01-17 03:06:21 +00:00
bjh21 b5c6c1df63 Simplify SWI entry: syscall() now extracts the SWI comment field itself. 2002-01-14 23:21:06 +00:00
bjh21 6462506466 Crude first cut at ARMLinux binary compatibility. Successfully runs
"/emul/linux/bin/echo hello, world", dynamically linked.
2002-01-14 23:14:32 +00:00
bjh21 ef2920350e Use symbolic names for SWI number blocks (from <arm/swi.h>). 2002-01-13 15:04:09 +00:00
bjh21 d46952877d Add an <arm/swi.h>, containing symbolic names for SWI ranges. 2002-01-13 15:03:06 +00:00
bjh21 9379550701 Make this actually compile on acorn32. 2002-01-13 14:39:13 +00:00
bjh21 9fe68c4f64 Combined syscall handler for all ARM ports. This is basically the arm32
version, made readable and compatible with arm26.  In addition, this adds
support for NetBSD/arm's newly allocated SWI range.
2002-01-12 20:02:13 +00:00
chris c3abf9a50c Make GENERIC cats kernel boot again. By allocating a 2nd second level page table for the kernel and stack space we can now have to 8MB of kernel and stacks (if the kernel ever gets really bloated might need to add a 3rd!)
Also update the funcs in arm32_machdep.c that create the entries so that on cats they expect the 2 pagetables to be contiguous, note this means that for now cats is special cased in lots of funcs.  I'll tidy this up to something a bit more sane soon, to avoid the multitude of #ifndef cats that I had to sprinkle in.
2002-01-12 13:37:55 +00:00
rjs adde6b76ba Interrupt related defines for SA11x0. 2002-01-09 15:54:19 +00:00
bjh21 33096a0e18 Add a couple of ARM7500 registers I missed last time, and correct a couple
of others to match the names in the data sheet.
2002-01-08 21:00:12 +00:00
rjs 1d49b1abec Establish interrupt handlers before enabling the clocks. 2002-01-08 11:40:56 +00:00
rjs 4bb5c4fa7c Add extra SA1111 register definitions. 2002-01-08 11:36:52 +00:00
rjs cd6d465f6b Add reset controller register definitions. 2002-01-08 11:29:51 +00:00
rjs 1b4e5cf968 Add check for microtime() being called before clock is initialized. 2002-01-08 11:21:02 +00:00
chris 8dd3ca5994 Finish up the changes to get LOOSE_PROTOTYPES working for cats.
Note that this leaves a few inconsistencies (no more than we already had though) eg initarm is now prototyped in arm32/machdep.h, however only cats currently makes use of that header.
2002-01-07 22:58:07 +00:00
bjh21 2b44bd85c5 On arm26, vectors.S needs to be at the start of the kernel text, so that it's
on a page boundary and can be mapped straight into zero page.  This means it
has to be in MD_SFILES on arm26, and not in SFILES.

This probably leaves kernel_text in the wrong place, but it at least leaves the system bootable.
2002-01-07 21:15:50 +00:00
chris e3a3a9f56f Make some of the arm32 files build with LOOSE_PROTOTYPES not set in the makefile. Turned up a few mismatched functions. Note that this isn't all of the arm32 files. Aim will be to get arm32 kernels built with LOOSE_PROTOTYPES not set. 2002-01-05 22:41:46 +00:00
chris 826b7655cf include <arm/conf.h> for prototypes.
Correct args to mmopen and mmclose.
Add RCSID line.
2002-01-05 17:02:22 +00:00
chris b51b9e9e63 Update with radio, cir and irframe. also add block device for ld. Update other tables in file as appropriate. 2002-01-05 00:51:30 +00:00
chris 9b812a6774 Update mem device to bring it into line with a change in version 1.32 of i386/mem.c. Appears that we may move uio twice.
Original i386 log message:
Optimize the case of writing to /dev/zero, and clean up the
surrounding code a bit.  Partly suggested by gwr.

I think this needs to be applied to arm26 as well.
2002-01-05 00:46:33 +00:00
briggs e984bd475c Initialize pba_intrswiz and pba_intrtag before configuring PCI bus. 2002-01-04 22:39:47 +00:00
skrll e25a471c87 Fix typo in comment. 2002-01-01 16:24:33 +00:00
thorpej d2453f69b1 Remove the call to abort(). We don't pull in a prototype for it,
and there's no sane way to do so.
2002-01-01 01:58:01 +00:00
bjh21 00bd2cbdac Merge ast() and userret() between arm32 and arm26. The implementation used
is the arm32 one.
2001-12-21 22:56:16 +00:00
thorpej a6a5d9fa2b Use the correct version of va_arg() for _STANDALONE. 2001-12-20 20:29:09 +00:00
bjh21 a938f3a7ee Remove some outdated comments: arm26 kernels use APCS-32 now, which
means they don't do silly things like restoring IRQ/FIQ disable bits
on function return.
2001-12-20 16:12:10 +00:00
thorpej 014157862c * Share a common vector page between arm26 and arm32.
* Use a common set of exception handlers for all arm32 platforms.
* New FIQ framework based on discussions with Ben Harris, shared
  between arm26 and arm32.
2001-12-20 01:20:21 +00:00
thorpej 631447bb4a Change some #if 0 to #ifdef VERBOSE_INIT_ARM. 2001-12-18 02:52:00 +00:00
bjh21 f2ebadcc6f Ensure that vidc.h gets installed somewhere -- Xarm32vidc needs it to compile. 2001-12-17 15:07:37 +00:00
bjh21 7bc474a92b mod() was unused. g/c it. New code should use abs() anyway. 2001-12-15 22:41:44 +00:00
bjh21 eefdf030c9 Simplify the pixel-clock-rate-setting code, so it always works out the
parameters from first principles rather than using a static table for some
rates.  This makes it work correctly on ARM7500, for which the table was
bogus (ARM7500 has a different refclk from VIDC20).
2001-12-15 22:21:46 +00:00
chris 80e667c6ab Add clockctl device.
Note that someone needs to tidy this up, we've got 92 block devices, which just ain't true.  Also appears we're actually missing some, eg the ld block device.
2001-12-11 00:34:50 +00:00
thorpej 51535d4bf5 Add support for dumping ELF-cormat core files. 2001-12-09 23:05:56 +00:00
atatat b45c51b1fc Roll the rest of the ports over to the new MI kernel build machinery.
Any problems reported by testers have been fixed, and massive
cross-compiling of kernels has shown that any problems that remain
with actually building kernels are not related to this.
2001-12-09 05:00:40 +00:00
chris 3831bfec98 Improve comment on the clockswitching asm code, it doesn't use r0 at all, it just needs it to make valid asm. 2001-12-08 21:30:04 +00:00
chris ce689bde4d Fix the asm macros
The tmpx registers are now outputs, this makes them all unique.
Add the fact that cc is changed by the asm (not believed to be used but rather be correct)
Correctly specify w as an input and output register, I think this was hiding the bug below!
Allow sum to be in a different input and output register.

Correct bug in psuedo header handling for in4_cksum.  Seems that the new macros turned up a latent bug in the psuedo header handling, the code was moving a pointer forward 16 bytes twice, not found before as the ADD16 macro wasn't 100% accurate, as it didn't output w, even though it modified it.
2001-12-08 21:18:50 +00:00
thorpej 72dee19a8c Reset the i80200 ICU and PMU to a pristine state very early. 2001-12-01 23:06:45 +00:00
bjh21 e4dac015cd Don't define get_cachetype() unless it's going to be used. 2001-12-01 14:21:18 +00:00
thorpej 3fd0a58e9d On the i80200, disable ECC in the Bus Controller Unit early on; we
don't really have code to deal with ECC errors yet.
2001-12-01 06:33:40 +00:00
thorpej 5936a89bf5 Add register definitions for the i80200 Interrupt Controller Unit,
Bus Controller Unit, and Performance Monitoring Unit.
2001-12-01 05:46:19 +00:00
thorpej 2b08dcc43b Clarify a comment to state that it is intentional that we attach
only the Secondary PCI bus (it's the only bus which can have a
device space hidden from any PCI host on the Primary bus).

Also, use the bus number from the PPB businfo register seecondary bus
field rather than hard-coding "1".
2001-11-30 19:29:44 +00:00
thorpej e90eccc52c Clarify a comment. 2001-11-30 19:26:03 +00:00