Commit Graph

34325 Commits

Author SHA1 Message Date
lukem 4bb41ae2f2 Rework how KERNOBJDIR functions; now it's always determined with
cd ${KERNSRCDIR}/${KERNARCHDIR}/compile && ${PRINTOBJDIR}
This is far simpler than the previous system, and more robust with
objdirs built via BSDOBJDIR.

The previous method of finding KERNOBJDIR when using BSDOBJDIR by
referencing _SRC_TOP_OBJ_ from another directory was extremely
fragile due to the depth first tree walk by <bsd.subdir.mk>, and
the caching of _SRC_TOP_OBJ_ (with MAKEOVERRIDES) which would be
empty on the *first* pass to create fresh objdirs.

This change requires adding sys/arch/*/compile/Makefile to create
the objdir in that directory, and descending into arch/*/compile
from arch/*/Makefile.  Remove the now-unnecessary .keep_me files
whilst here.

Per lengthy discussion with Andrew Brown.
2003-01-06 17:40:18 +00:00
reinoud 3630c2d8c4 Remove loadfile_machdep.h from being installed 2003-01-06 17:00:12 +00:00
mrg 675149a358 - md_fpumid = -1 => md_fpu = NULL, in some #ifdef FPU_DEBUG code
- only call KERNEL_PROC_UNLOCK() if we called KERNEL_PROC_LOCK() originally.
2003-01-06 14:16:10 +00:00
wiz c053751628 compatibility, not compatiblity. 2003-01-06 13:26:24 +00:00
wiz 4824190751 transmission, not transmition. 2003-01-06 13:17:01 +00:00
wiz c6f1277bfa synchronous, not syncronous. 2003-01-06 13:10:25 +00:00
wiz 7e681f7063 interrupt with two rs. 2003-01-06 13:04:54 +00:00
pk 67998a8646 Move schedintr() to clock.c and initialise schedhz in initclocks(), so
these are available to all timer implementations.
2003-01-06 12:50:43 +00:00
wiz 45ad5c9584 successful with only one l. 2003-01-06 12:46:05 +00:00
wiz 5e442fbbdd specified, not specifed. 2003-01-06 12:38:47 +00:00
wiz 5a91827c81 through, not throught. 2003-01-06 12:29:48 +00:00
pk 9a9c991837 Fix SP tlb_flush_{ctx,all} macros. 2003-01-06 12:10:46 +00:00
wiz 9a3f5034cf No more opms on i386. 2003-01-06 11:31:39 +00:00
rafal b892fa21e2 There's no cache_r5k.h yet, so don't try to include it. 2003-01-06 06:25:32 +00:00
rafal 0098f248ba PCI fixup code for the O2. Tested with a range of 32 and 64-bit network
cards, but not much else.  Seems to work fairly well, though.
2003-01-06 06:21:11 +00:00
rafal c21021e6fb Improve the interrupt code somewhat by having callers of xxx_intr_establish
pass in an interrupt handle (which is currently to the CRIME interrupt the
device is attached to) so the interrupt handlers know which device was the
one looking for attention.

While here, fix up PCI interrupt routing for both the on-board devices and
the PCI slots -- even though there is only one PCI slot in the chasis, the
hardware can accomodate up to three and provides an interrupt mapping for
all the PCI interrupt pins for both the internal SCSI & PCI slot and the
two "extra" slots.
2003-01-06 06:19:40 +00:00
rafal b0e9963d23 Don't shift the pending interrupt bitmask passed to crime_intr() so it can
associate pending interrupts with the proper sources.  Add some comments to
the vestigal ip32_intr_establish() on what it really *should* do.
2003-01-06 05:59:34 +00:00
rafal 1e74cf4267 Postpone DDB/KGDB init until we know the machine type, so the debugger can
be attached to the right place, twiddle the right watchdog registers, etc.
2003-01-06 05:56:00 +00:00
reinoud 340ca7145e We have version 3.02 now : just a small fix for bootkernel name guessing. 2003-01-06 02:54:03 +00:00
sommerfeld 52b083a154 Add symbolic names for MSR's used by SYSENTER/EXIT.
(I was experimenting a while back, might as well commit this one file..)
2003-01-05 22:47:13 +00:00
christos a731ae7dc4 add ACPIVERBOSE [commented out] 2003-01-05 22:31:13 +00:00
jmcneill 65c6c82f48 Document all known ACPI devices and options (disabled by default). 2003-01-05 21:44:32 +00:00
pk 9df7616ed3 Combine the various sun4m/sun4d TLB flush routines into a hand-coded
assembler version.
2003-01-05 19:38:42 +00:00
pk c0142e4ded Print the cpu number in many pmapdebug-controlled debug traces. 2003-01-05 19:31:12 +00:00
pk 113229a2cb trap(T_FPE): reset the `p_md.md_fpu' when preempting the FPU. 2003-01-05 19:26:17 +00:00
briggs 6e51b83bf3 Add mlx. Pointed out by Daniel Eggert in PR 18487. 2003-01-05 19:21:44 +00:00
takemura cfbbdd3ae0 Fixed threshold value for Vrc4173 PIU. 2003-01-05 08:41:54 +00:00
thorpej 1106d42424 On the IBM 4xx, don't enter DDB on user mode traps. Fixes
port-powerpc/19662.

Some minor cleanup while here.
2003-01-04 23:46:11 +00:00
tsutsui 0d588a6b61 Add options MIIVERBOSE. 2003-01-04 21:09:31 +00:00
pk 3e2e9af6c9 Grab the kernel lock on interrupts at level IPL_CLOCK and lower. 2003-01-04 19:25:36 +00:00
pk 5e73320f0f Re-arrange the fields in struct cpu_info such that the most heavily used ones
are together, to reduce cache stomping.
2003-01-04 18:54:45 +00:00
thorpej 4f162f46b9 Make this compile without DDB. 2003-01-04 18:14:48 +00:00
thorpej 296dfde575 Remove KERNFS silliness. 2003-01-04 18:14:22 +00:00
thorpej c72ac1fcf2 Don't fail the kernel build if dbsym fails. 2003-01-04 18:13:51 +00:00
tsutsui c1acc622c0 Check chip type first in mbe_g2_detect() to reduce unexpected device access
in mbe_g2_match() when the device does not exist.
2003-01-04 18:10:18 +00:00
thorpej 62a4b10f83 Make this compile without DDB. 2003-01-04 18:04:43 +00:00
mrg a8699889af use "booted_device" when calling setroot(), so that raidframe autoconfigured
root works...  now with a "/boot" partition holding /ofwboot & /netbsd i can
have a raidframe root without hard coding root at in my kernel.
2003-01-04 17:00:27 +00:00
pk f6fc3bd5fc new cpu_switch: SMP: even if we pick up the same process after idling, we
must reset its context as the process might have run on another cpu in
between and had its context changed, e.g. by exec(2).
2003-01-04 11:09:18 +00:00
mrg 277fb5e18a remove a now bogus comment from xcall() 2003-01-03 16:27:23 +00:00
mrg 68da24bd3d - remove some dead debug code
- don't cross call the smp_tlb_flush*() routines on SUN4D, just ensure
that there is only one concurrent flush happening.
2003-01-03 16:24:50 +00:00
mrg fb1500c7e1 remove dead extern fpproc/foundfpu declarations. 2003-01-03 16:21:05 +00:00
mrg 5b23b7800a FPU save is handled in xcall() now. 2003-01-03 16:20:21 +00:00
pk 444faacaac xcall(): consult the `cpuset' argument for posting the cross calls. 2003-01-03 15:49:11 +00:00
pk 0a78c9e13a Define a few XCALL? shorthand macros to avoid clutter. 2003-01-03 15:44:55 +00:00
lukem a250e57c96 Install release files under "${RELEASEDIR}/${MACHINE}/..." instead of
"${RELEASEDIR}/...".

${RELEASEDIR} is never cleaned , and ${RELEASEDIR}/${MACHINE} is only
cleaned if UPDATE is not defined.
2003-01-03 15:34:30 +00:00
pk ff451161e2 Finish FPU context switching on SMP systems. 2003-01-03 15:12:02 +00:00
martin 87a073002c Make the *_stream_* methods always use the *_real accessors.
Define __BUS_SPACE_HAS_STREAM_METHODS.
2003-01-03 13:23:39 +00:00
mrg 7bd617d237 part one of bus_space(9) fixes to enable bus spaces to override the
bus_space_{read,write}_[1248]() functions, which will allow 16-bit
PCMCIA support to work without additional hacks in MI drivers.
this option is not enabled yet.
2003-01-03 11:57:45 +00:00
rafal 3021da226f Cosmetic fix -- move __HAVE_MIPS_MACHDEP_CACHE_CONFIG to "MIPS specific
options" section.
2003-01-03 10:30:00 +00:00
pk 947028ed94 reverse mailbox physical address check: now warn if it's not I/O space. 2003-01-03 09:22:11 +00:00
pk 3f5be1863e srmmu cache flush: use to the CPU context parameter; this is now required. 2003-01-03 09:19:03 +00:00
rafal 0cff9e28dc Checkpoint of O2 work by Chris Sekiya and myself. This is the sgimips bit;
still needs some arch/mips support code before it will fully work.
2003-01-03 09:09:21 +00:00
rafal b983746705 Also remove `options MIPS3_5200' since nothing uses it ATM. 2003-01-03 08:18:20 +00:00
rafal 2d6f1ac150 The Tigon driver is known to have issues on BE systems, so remove it (I got
the card probed & attached, but had to hack the driver source to even get
it that far and it had issues after that which made me punt on it).
2003-01-03 08:14:44 +00:00
rafal f2c485b280 Move console setup after we've determined machine type so the console init
code can guess where to find a console depending on machine type.
2003-01-03 06:26:06 +00:00
rafal fe84d50d7e Mark the CRIME/MACE register twiddling done after autoconfig with an XXX so
it gets cleaned out when the interrupt registration code is capable of doing
the interrupt mask setup itself.
2003-01-03 06:24:18 +00:00
takemura 285679b875 Added new ioctl command, WSMOUSEIO_GETID to tell touch panel identifier
for tpctl(8).
2003-01-03 04:36:26 +00:00
thorpej 81c6d35e2b Remove obsolete MACHINE_ARCH -> arm32 2003-01-03 02:40:57 +00:00
thorpej c2e9de7319 Don't define -D${MACHINE} in Makefile.arm. Instead, let platforms
that care define it themselves.  Note that evbarm NO LONGER defines
-D${MACHINE}.
2003-01-03 02:34:48 +00:00
thorpej bc45f5ceeb Split board-specific Makefile fragments into their own files. 2003-01-03 02:16:26 +00:00
thorpej e5afd96a97 Use the common linker script for all evbarm platforms. 2003-01-03 02:02:11 +00:00
thorpej b179f9cf73 Use the generic irq_dispatch.S 2003-01-03 00:55:59 +00:00
thorpej 6620220d46 Use the generic irq_dispatch.S 2003-01-03 00:41:19 +00:00
thorpej 074858daeb Fiddle with current_intr_depth in assembly code again. Because we
have just pushed a frame, we can make some assumptions that the
compiler cannot as easily make, and can thus do it slightly more
efficiently.
2003-01-03 00:38:16 +00:00
thorpej 6c9c7f3b21 Garbage-collect prev_intr_depth; nothing uses it. 2003-01-02 23:54:39 +00:00
thorpej b33e60be39 Clean up evbarm interrupt support a little:
* Define an ARM_INTR_IMPL option, which specifies a header file
  describing the interrupt implementation for the platform.  Use
  this instead of the list of EVBARM_BOARDTYPE checks.
* Make the s3c2xx0 interrupt dispatch code a bit more generic, and move
  it to a generic location so that other platforms can use it.

This eliminates all uses of the EVBARM_BOARDTYPE stuff, so delete it.
2003-01-02 23:37:53 +00:00
briggs 147ab60754 Enable a few more bus_space functions.
If a region is outside the regular obio space in obio_bs_map(), create
mappings for it.
2003-01-02 23:04:08 +00:00
thorpej 9f57359336 Don't need to explicitly include <arm/s3c2xx0/s3c2xx0_intr.h>. 2003-01-02 22:30:04 +00:00
pooka fb4bf2a901 * tweak CRIME and MACE interrupt masks for IP32 and add some verbosity
* recognize ahc scsi as a boot device

once again thanks to Chris Sekiya
2003-01-02 15:08:18 +00:00
tron 050140988d Add commented out entry for acpi(4). 2003-01-02 12:36:51 +00:00
mrg c79ff46cb6 don't try to setup MXCC registers on non-primary CPU's on systems without
SMP support.
2003-01-02 09:42:09 +00:00
reinoud c065f11230 Oeps... forgot the versions file 2003-01-02 01:05:35 +00:00
augustss 6bf498b3c2 A little more debug. 2003-01-01 21:00:42 +00:00
augustss f2a72b5110 Make sure DDB is set up correctly when we have SYMTAB_SPACE. 2003-01-01 16:18:49 +00:00
augustss 256784b520 Set up proper symbol table space. 2003-01-01 16:18:03 +00:00
pk 9dd42c6155 SMP: lock kernel for soft interrupts < IPL_SCHED as well. 2003-01-01 16:17:10 +00:00
augustss a89cd41b68 Add NEED_SYMTAB to run dbsym. 2003-01-01 16:14:36 +00:00
pk 3607bd7dca pmap_alloc_cpu: use flags from boot cpu for now, as the passed cpu_info
structure has not been fully setup yet.
2003-01-01 15:56:11 +00:00
pk 16305a65cb prom mailbox map: look for the property `mailbox-virtual' first. 2003-01-01 15:51:00 +00:00
mrg 79037114d8 this file is really no longer used 2003-01-01 08:41:17 +00:00
mrg 2fff4ee989 fix a comment. 2003-01-01 08:24:48 +00:00
mrg 62a9b2484d this is no longer used. 2003-01-01 07:45:41 +00:00
mrg aa9a4f85dd enable sab & sabtty 2003-01-01 07:45:21 +00:00
mrg d06249b555 KNF. 2003-01-01 06:33:29 +00:00
thorpej 98b0e9af47 Use aprint_normal() for cfprint routines. 2003-01-01 02:31:13 +00:00
thorpej 9c1214153c Use aprint_normal() for cfprint routines. 2003-01-01 02:20:47 +00:00
thorpej dca15fc8c2 Use aprint_normal() for cfprint routines. 2003-01-01 02:10:08 +00:00
thorpej 95fa2e148a Use aprint_normal() for cfprint routines. 2003-01-01 01:57:51 +00:00
thorpej dbb0f0ebed Use aprint_normal() for cfprint routines. 2003-01-01 01:47:30 +00:00
thorpej 72a2c87923 Use aprint_normal() for cfprint routines. 2003-01-01 01:34:45 +00:00
thorpej 1132348b98 Use aprint_normal() for cfprint routines. 2003-01-01 01:24:19 +00:00
thorpej 359ed65495 Use aprint_normal() for cfprint routines. 2003-01-01 00:46:13 +00:00
thorpej 1eab093085 * Use a device node for each DMA channel.
* Use aprint_normal() for cfprint routines.
2003-01-01 00:45:00 +00:00
thorpej 21fbbf679c Define a base for each DMA channel. 2003-01-01 00:44:34 +00:00
thorpej 7ca7bdb37c Use aprint_normal() for cfprint routines. 2003-01-01 00:39:19 +00:00
thorpej 41a403fb33 Use aprint_normal() for cfprint() routines. 2003-01-01 00:35:30 +00:00
thorpej a7f53c4d06 Use aprint_normal() for cfprint routines. 2003-01-01 00:34:05 +00:00
thorpej aec1389b37 Use aprint_normal for cfprint routines. 2003-01-01 00:32:04 +00:00
thorpej 5001cdaf1f Use aprint_normal() for cfprint routines. 2003-01-01 00:25:01 +00:00
thorpej 703e7687a9 Use aprint_normal() in cfprint routines. 2003-01-01 00:16:46 +00:00
thorpej 0ad39e91ea Fix sysmon entry. 2002-12-31 22:43:38 +00:00
pk 2aac3c7c89 Slight optimisation in proc_trampoline(). 2002-12-31 17:07:36 +00:00
pk 1df04e663f Make the schedintr() code common for all timers. 2002-12-31 16:45:52 +00:00
pk 7b7269ba42 New version of cpu_switch/switchexit, mostly to simplify SMP support. It's
currently conditional on ALT_SWITCH_CODE (defaults to `on' if MULTIPROCESSOR
is defined) until more testing rounds are completed.
2002-12-31 16:17:12 +00:00
pk 3d8def4865 Use a soft interrupt scheme to schedule schedclock(), so we can make
splsched() less than splhigh().
2002-12-31 15:57:26 +00:00
pk 67e16e38a4 Define IPL_SCHED at level 11 and make splsched() use it. 2002-12-31 15:51:18 +00:00
pk d358537b64 Pass the CPU context to all TLB flush routines. Because of this (and the
fact that cache flushes are also passed the context number), most
"long-term" context switches can be eliminated from the SRMMU versions
of the pmap functions.
2002-12-31 15:23:29 +00:00
pk 83dae8a821 * map the PROM CPU mailbox if available.
* map MXCC error/status registers if available.
* add MXCC-specific module error interrupt handler.
* use high priority interrupt level in mp_pause_cpus()
2002-12-31 15:10:28 +00:00
pk 2b59d26892 Add offset for `cpuinfo.ci_tt'. 2002-12-31 15:05:48 +00:00
pk c3bb05ff5b * Add level argument to raise_ipi()
* Add diagnostic field members to cpu_info.
2002-12-31 15:04:49 +00:00
pk 5c671fd10d nmi_sun4m: run handler at splhigh() 2002-12-31 14:34:54 +00:00
pk 43b86d0b59 rwindow debug code: display the current cpu number. 2002-12-31 13:17:23 +00:00
pk a1e9e5cae8 Add some more definitions: SRMMU and MXCC reset register. 2002-12-31 12:01:27 +00:00
shin 031dbfcca0 add PCI bus access device. 2002-12-31 06:54:13 +00:00
explorer 4b995bb9a4 fix for my sony laptop, which doesn't quite follow spec 2002-12-30 21:55:05 +00:00
reinoud 006384eaed In the case there is just one SIMM and one memory bank from the SIMM things
got wrong when no VRAM was there.

Placing the video DRAM in front of the kernel is OK when its 1Mb since the
kernel wants to be on a Mb boundary. Placing the video DRAM in the last
SIMM bank at the front is also OK unless there is just one SIMM and just one
bank; then it got in the way again!

Solution is to put the DRAM at the end of the SIMM instead of the beginning!
This however can result in the non 16 kb alignment of the top of physical
RAM where the temporary L1 page tables are situated. If its not 16 kb aligned
then move the L1 page table address down and down until it is 16 kb aligned.
This memory will be reused later on anyway.

What to do when we really support changing screensizes... see it as a max?
or use a different sceme alltogether? It might not even be a bootloader
problem then allthough its memory is not showing up in the DRAM/VRAM
block counts wich needs to be fixed one day.
2002-12-30 15:54:46 +00:00
reinoud 2f6fe363fa Since we dont support switching screenmodes (yet) we might as well claim
just enough for the screenmemory to be in instead of the maximum of 1Mb.
Small machines like my 8Mb NC get a 700 kb back and thats really noticeable.
2002-12-30 03:30:16 +00:00
reinoud 3e5225eafa If we don't have VRAM then at least account the screensize correctly :) it goes
pretty wierd if it is set wrongly.
2002-12-30 02:19:20 +00:00
reinoud 33ae7765a1 If we nick memory from the DRAM for video then please account it correctly! 2002-12-30 02:05:12 +00:00
reinoud f223d87792 Typo and comments 2002-12-29 22:41:08 +00:00
ad d4ed18b479 Block tty interrupts in getc()/putc(). 2002-12-29 20:12:19 +00:00
ad 17fa1f0778 - X pads bitmap rows to a word boundary.
- Handle WSDISPLAYIO_GCURMAX.
2002-12-29 20:01:17 +00:00
kristerw 9d1bcdf947 Use "__asm" instead of "asm" to pacify lint. 2002-12-29 14:41:29 +00:00
kristerw d320ba3418 Use "__asm __volatile" instead of "asm volatile" to pacify lint. 2002-12-29 14:40:35 +00:00
kristerw 069c964473 Do not try to return a value from void functions. 2002-12-29 14:38:11 +00:00
tsutsui 7bc5ebdb72 Wrap DELAY() macro with do { } while (/*CONSTCOND*/ 0). 2002-12-29 14:09:37 +00:00
uwe a391e8bea6 Add sh7709 INTEVT2 codes for IRQs, PINTs, IRDA and ADC. 2002-12-29 02:47:07 +00:00
reinoud 24dac6bf26 The unique machine ID is used in some networking stuff to generate a
unique-ish number, so better add it again!
2002-12-29 00:30:40 +00:00
reinoud bf5fbfa164 Update the NetBSD part for the bootloader change. Mostly the changes in
bootconfig.h needs reflection
2002-12-29 00:02:20 +00:00
reinoud 46dbb0f225 Initial commit of the 3rd generation of bootloaders for the Acorn32
platform. It features far better support for newer architectures and is
fully rewritten in C and compile-able under NetBSD.

Since it shares code with `boot26' for Acorn26 merging the common parts is
likely to be next on the list.
2002-12-28 23:57:36 +00:00
leo d2a5a7fd71 Regen. 2002-12-28 22:13:22 +00:00
leo e946acdd50 Since 1.6 we have 3 images (not 2!):
- 1Mb on HD floppy's
  - 1.44Mb on HD floppy's
  - 1.44Mb on a DD floppy
2002-12-28 22:11:30 +00:00
reinoud 779842e0f8 Remove spurious declaration of bootconfig structure since that is already
done in bootconfig.h
2002-12-28 20:40:21 +00:00
sommerfeld 20d271e712 TODO list, paraphrasing Jason Thorpe 2002-12-28 20:12:24 +00:00
kristerw 2ae40935fb The correct way to decorate objects with attributes is to use __attribute__
instead of the synonyms understood by gcc.
2002-12-28 20:11:57 +00:00
christos f69bc61a87 remove redundant declaration 2002-12-28 20:06:07 +00:00
jmcneill 8eb0fffdfc Add an npx at acpi(4) attachment 2002-12-28 17:51:16 +00:00
matt 13e7cd4f3f Use i386_isa_chipset explicitly. 2002-12-28 17:36:59 +00:00
jmcneill df719d72e4 NACPCA -> NACPI, so isa_dmainit gets called if we have ACPI support too. 2002-12-28 17:31:25 +00:00
matt 6b5d7a7b6c Remember the isa_chipset_tag_t and supply to isa_intr_establish.
(thereby removing a XXX in the code).
2002-12-28 17:13:39 +00:00
matt 51ec27c813 Move the call to isa_dmainit to mainbus_attach from pnpbios_attach since
ACPI needs to have that done for the exact same reasons as ACPI.
2002-12-28 17:11:50 +00:00
tsutsui e60823f9f2 Fix typo in comment. 2002-12-28 16:52:02 +00:00
tsutsui 46cc633768 Oops, fix typo in the previous. 2002-12-28 16:44:43 +00:00
pooka bca1052dab on second thought... make this also compile 2002-12-28 16:44:36 +00:00
pooka 00ddd0deec add timer calibration
from Chris Sekiya
2002-12-28 16:40:48 +00:00
tsutsui da446ea2da Change device names in struct pica_dev to match ones used by ARC BIOS.
All of these parameters should be obtained from ARC BIOS, and we will
switch to the way in future. As per discussion with soda.
2002-12-28 16:25:38 +00:00
jmcneill c8111254a1 Pass ISA chipset information through to ACPI devices, to allow for porting
of pnpbios(4) glue to acpi(4).
2002-12-28 06:14:07 +00:00
reinoud ca70f10e3b Add the loadfile_machdep.h as needed for native bootloaders 2002-12-28 02:42:13 +00:00
mrg 122353da40 rename CPU_READY() to CPU_NOTREADY() seeing that's what it checks. 2002-12-28 02:35:56 +00:00
mrg 7d51aacb32 update the vme bus_space_tag_t to reality. 2002-12-28 01:33:00 +00:00