Commit Graph

2276 Commits

Author SHA1 Message Date
thorpej
8526824bce Fix the LOADADDR() macro. 2001-11-02 23:43:13 +00:00
thorpej
428018d519 The a.out header is at the beginning of the .text segment in
ZMAGIC images, so use the correct constant (KERNEL_TEXT_BASE)
to find it.
2001-11-02 21:19:10 +00:00
thorpej
b563250dbb Couple of changes:
- Set MARK_START to where we expect to be loading the kernel (0xf0100000).
- The ARM OpenFirmare bindings document describes how the client
  program is loaded: OFW allocates and maps 6MB of memory at load-base
  (0xf0000000), loads the client program, and then unmaps the memory from
  the end of the client program to the end of the allocated region.  Then
  transfers control to the client program.  We must emulate this behavior
  to load the kernel: allocate 5MB at 0xf0100000 (where we expect to load
  the kernel), load the kernel, then unmap the area after the kernel.

We can now load DHCP and load the kernel via NFS before getting the
dreaded Data Abort.
2001-11-02 20:24:37 +00:00
thorpej
f0be361fce Make this build again with ALLOC_TRACE, and enable freeall(). 2001-11-02 19:58:52 +00:00
thorpej
da9b5f3614 loadfile() support for the Shark. 2001-11-02 01:27:41 +00:00
thorpej
4cbfdf4a51 Correct a kernel name. 2001-11-01 22:55:25 +00:00
thorpej
13d619a803 Check in of work-in-progress ofwboot for the Shark. Starts, does a
DHCP, attempts to load kernel, gets a Data Abort.
2001-11-01 22:50:18 +00:00
matt
3a74f9105b root finds ofbus, not ofroot (just like the shark/dnard) 2001-10-29 17:32:57 +00:00
matt
40296b7cc8 Use Lirqhandler (same bug/fix as in the footbridge_irq.S) 2001-10-29 17:30:26 +00:00
jmc
6d536163de Change defaults for kernel compiles. Default all to USETOOLS?=no and have
the etc Makefile override that by putting USETOOLS into $.MAKEOVERRIDES
This way the default for kernel compiles is still to use the installed
toolchain instead of depending on $TOOLDIR. $TOOLDIR can be used by
simply adding USETOOLS=yes to the command line as usual.

Adjust each ports template to set the default no setting and also pull in
bsd.own.mk if they weren't already to ensure they'll build correctly
with the new toolchain setup.
2001-10-26 06:45:33 +00:00
thorpej
ba217c4196 Set MACHINE_ARCH explicitly in Makefiles for which it is constant.
Also, since config(8) now explcitly sets MACHINE, there is no need
to do it here in the Makefile.
2001-10-23 19:26:41 +00:00
thorpej
a2bf3bc31b Pull in <bsd.own.mk> to get the correct toolchain definitions for
the USE_NEW_TOOLCHAIN case.
2001-10-23 17:32:35 +00:00
phil
ff3d710817 Sharks run coda just fine. Get it here so it is easy to recompile
a kernel with coda support.
2001-10-19 00:12:24 +00:00
reinoud
e8a24b6100 Forgot these ones... and make notice of the move. 2001-10-17 23:58:34 +00:00
reinoud
9bb6db7a85 Major step in creation of arch/acorn32 : remove acorn RiscPC compatibles
and RC7500 from the old arch/arm32 that is gonna be deleted in its whole
soon.

IMPORTANT for RC7500 ... this also removes all RC7500 support .... its a
big pitty but was virtually unsupported allready for a few years and noone
had one... if someone wants to make RC7500 or decendants support undo this
removal and start from here.
2001-10-17 23:53:29 +00:00
thorpej
16d926c4b8 Use ISACF_IRQ_DEFAULT rather than IRQUNK. 2001-10-06 03:04:01 +00:00
augustss
1339e88a86 Add a new optional method, dev_ioctl, to the audio hardware driver interface.
It is called when an unrecognized ioctl() is performed on a device,
thus allowing ioctl()s that frob the hardware driver (like loading
microcode).
2001-10-03 00:04:47 +00:00
rearnsha
a5480e24b4 Hmm, on a.out platforms we have
size_t == unsigned int
on elf platforms we have
	size_t == unsigned long int

So use %ld when printing and cast md->md_size to long.
2001-09-24 17:00:52 +00:00
wiz
4c99916337 va_{start,end} audit:
Make sure that each va_start has one and only one matching va_end,
especially in error cases.
If the va_list is used multiple times, do multiple va_starts/va_ends.
If a function gets va_list as argument, don't let it use va_end (since
it's the callers responsibility).

Improved by comments from enami and christos -- thanks!

Heimdal/krb4/KAME changes already fed back, rest to follow.

Inspired by, but not not based on, OpenBSD.
2001-09-24 13:22:25 +00:00
reinoud
8b8ec21061 Make the NE1000/NE2000 clone podulebus driver a bit more verbose over the
chipset found on the card.
2001-09-19 22:40:17 +00:00
reinoud
72854dc39d Finally make the RiscPC boot ELF kernels for real !! ... it now loads a.out
kernels as also ELF ones. Also cleaned up the code a bit and removed a
bunch of errors in the ELF loading code... no wonder it didn't work ! ... I
tried to squeeze about 8000 bytes in one 4096 byte page resulting in a
corrupted bss.
2001-09-18 23:23:22 +00:00
wiz
9fa0b17629 Give initiali[sz]e all the "i"s it deserves. 2001-09-18 18:15:49 +00:00
wiz
456dff6cb8 Spell 'occurred' with two 'r's. 2001-09-16 16:34:23 +00:00
chris
0e7661f023 Update pmap_update to now take the updated pmap as an argument.
This will allow improvements to the pmaps so that they can more easily defer expensive operations, eg tlb/cache flush, til the last possible moment.

Currently this is a no-op on most platforms, so they should see no difference.

Reviewed by Jason.
2001-09-10 21:19:08 +00:00
reinoud
7bace466ad Initial commitment of the bus_space_mmap() functions as proposed by Jason R
Thorpe as an extension to the bus_space(9) API.

Only the mainbus has a working mmap... iomd, podulebus and isa dont have
one yet. Its trivial to add the iomd and isa's memory part but am a bit
hessistant to add it without knowing its implications by heart.

Podulebus might be implemented in 32 bits EASI but otherwise its not really
transparent since there is AFAIK no function to explicitly read one byte or
so .. or is this implemented in a higher level ?

ARM26 and arch/arm32/dnard (Shark) kernels compile and RiscPC and Shark
kernels are tested and function OK.

Implications of other ARM systems like hpcarm and ebarm are propably
minimal or solved trivially.
2001-09-10 02:20:19 +00:00
reinoud
180a40eb5b A long int for kernel sizes is a bit overdone for an arm32 ... make it
compile again by changing the format string to use ints.
2001-09-09 15:15:14 +00:00
matt
7ce6450eac Add a merged <pcb.h> for arm26/arm32. 2001-09-03 19:20:27 +00:00
matt
cc353c4912 Sync hpcarm & arm32 conf.c (this entails shifting the i4b major numbers
up by one on arm32 and and adding notdef entries on hpcarm).
2001-09-03 01:33:38 +00:00
atatat
5f25c01eff Comment out bridge pseudo devices from ports that don't
__HAVE_GENERIC_SOFT_INTERRUPTS.  bridge(4) doesn't compile there.
2001-09-01 23:08:40 +00:00
atatat
97c67a9bae Add bridge pseudo devices to GENERIC configs 2001-09-01 21:52:23 +00:00
rearnsha
46f383bde2 Adjust printf format string for size_t change. 2001-08-30 17:16:02 +00:00
reinoud
d7964c6e78 Initial commit for Xserver support for the wscons interface; it isn't fully
functional yet since the keyboard changes are not committed yet but it
should compile and work independently.

Initial support for mouse and screen takeovers / screen hardware scroll
reset is done.
2001-08-21 14:48:54 +00:00
wiz
c52d355d71 "wierd" is weird. 2001-08-20 12:20:01 +00:00
matt
7cab3778d5 Make EXEC_ELF32 support std now, 2001-08-19 05:51:09 +00:00
rearnsha
d47e5736c8 ANSIfy function declarations and prototypes. Tidy up include files.
Minor reformatting.
2001-08-15 22:28:15 +00:00
rearnsha
0d9806035b Include sys/types.h, sys/callout.h and machine/intr.h. Don't include
sys/disklabel.h or sys/dkstat.h.
2001-08-15 20:27:46 +00:00
rearnsha
5bc2f13417 Don't need machine/io.h or machine/irqhandler.h either. 2001-08-15 20:08:46 +00:00
rearnsha
34ab61ef21 Don't include podulebus.h. Do include machine/bus.h. 2001-08-15 20:05:08 +00:00
rearnsha
ff2b83c782 New bus-independent DMA framework. Adjust asc.c for new interface
but not (yet) make use of new framework.
2001-08-14 22:58:17 +00:00
chris
191de4d242 Checking a whole host of pmap changes:
Improved locking (not that we actually use it on a uniprocessor, but one day :)
Removed unneeded splvm's
tweaked pmap_clean_page code to only flush the cache if the page is mapped in the current pmap  (based on diff from richard E)
Adopted pv entry allocation mechanism from i386.
Laid framework for returning ptp's when we've finished with them rather than holding onto them till the process exits.
ptp's are now allocated with a uvm object for the pmap, means that we can walk a list to free them off in pmap_release, until they get freed off by pmap_remove.

Also implemented a page zeroing function when the processor is idling.  Note that hpcarm may wish to disable this.

I believe this code to be stable, if anyone has any problems please shout up.
2001-08-11 13:20:19 +00:00
jdolecek
74954dadf9 use unsigned variable types as appropriate 2001-08-05 18:07:51 +00:00
matt
ced3859405 print time_t as signed long. 2001-08-05 05:22:10 +00:00
chris
9f04d8d670 A couple of tidy ups to pmap:
pmap_t -> struct pmap * in pmap.c and pmap.h
kernel_pmap -> pmap_kernel() everywhere.

Compiled and booted on riscpc and cats.
2001-07-28 18:12:43 +00:00
chris
17ecd4e41a Update Makefile.arm32 for the newly moved locore.S and genassym.cf 2001-07-28 15:50:40 +00:00
chris
4a126d9937 finish moving common arm32 bits out into arm/arm32. 2001-07-28 15:08:10 +00:00
chris
27f96e8440 Move the generic arm32 files into arm/arm32 from arm32/arm32, tested kernel builds on cats and riscpc. 2001-07-28 13:28:03 +00:00
chris
338f184d45 Fixup stray interrupt handler's return address. 2001-07-28 12:28:56 +00:00
chris
0481f078a0 bzero -> memset 2001-07-28 11:17:15 +00:00
wiz
035b63a542 auxilliary -> auxiliary 2001-07-26 22:53:13 +00:00
wiz
a9356936b4 seperate -> separate 2001-07-22 13:33:58 +00:00
wiz
1bc6d2cee9 Fix typo (`information' has an 'r'). 2001-07-19 16:13:00 +00:00
matt
24a2b394aa Make <sysarch.h> valid for all arm platforms. Adjust/remove port-specific
includes as required.
2001-07-14 00:23:09 +00:00
reinoud
0d6f7550d9 A new setup for the fastboot file... a lot more clear. 2001-07-12 15:55:42 +00:00
chris
242cb56ca5 Fixup vidc files, VIDC_FREF is now vidc_fref. 2001-07-10 22:09:04 +00:00
bjh21
3eec98b7e8 Gratuitously print out the IOMD version at boot, since there's a register
for it.
2001-07-10 21:31:59 +00:00
bjh21
ea353a48e1 Purge CPU_ARM7500. Thanks to Reinoud's work, it's no longer needed. 2001-07-10 20:43:57 +00:00
bjh21
9c93fee83f Remove spurious inclusions of opt_cputypes.h. 2001-07-10 20:10:48 +00:00
bjh21
d715053902 As far as I can tell "options IOMD" is never referenced, so remove it.
Anything that needs to know if we're building for an IOMD machine can check
NIOMD.
2001-07-10 00:52:29 +00:00
bjh21
55a4aace27 Use NIOMD to determine if we're on an IOMD system, rather than
RISCPC || CPU_ARM7500.  I think this removes that last substantive use
of CPU_ARM7500 in the kernel (hooray!).
2001-07-10 00:41:12 +00:00
bjh21
cf9453aeae iomd is marked "needs-flag", and this file is conditional on iomd, so
NIOMD == 1 whenever this file is included.  Don't bother asserting it.
2001-07-10 00:36:10 +00:00
bjh21
838c7e36a1 Remove a confused (probably outdated) comment. 2001-07-10 00:09:44 +00:00
bjh21
469339d93c Clean up some cruft left behind (but AFAIK never used) from poduleirqhandler(). 2001-07-10 00:04:30 +00:00
bjh21
368f9c15c1 Remove another spurious #ifdef CPU_ARM7500. 2001-07-09 23:35:58 +00:00
reinoud
8ca7d6ec9c Initial commit for merging A7000/NC with the RISCPC in order to get _one_
bootable GENERAL kernel for the 3 machines.

This is done by integrating the ARM7500 in a better way. In various places
the IOMD ID is checked and action is taken at runtime compared to
compiletime.

The small piece of assembler that is changed now uses the flag
`arm7500_ioc_found' that is set up by iomd.c at startup. When this chip
isnt found at startup it will skip reading the ARM7500 extended IRQ
registers and wont clear them either.

The next step will be getting the mode-definition files to the bootloader.
Currently they are compiled in.
2001-07-09 21:46:19 +00:00
wiz
cc0b68092e Correct various misspellings of 'transfer' and inflected forms. 2001-07-08 18:06:42 +00:00
abs
01b024cd5b Standardise TCP_COMPAT_42 as commented out, grouped with other COMPAT options,
and with the comment '4.2BSD TCP/IP bug compat. Not recommended'
Add commented out 'TCP_DEBUG # Record last TCP_NDEBUG packets with SO_DEBUG'
(All hail amiga and atari which make some attempt to automate the
multiplicity of config files...)
2001-07-08 16:32:12 +00:00
bjh21
260f6ffe33 Remove the old Ether3 and EtherB drivers, since the new ones seem to work fine. 2001-07-08 15:41:55 +00:00
rearnsha
471acbf74f Fix a couple of minor merge botches from the new scsipi merge.
More minor formatting tidyups.
2001-07-08 14:50:05 +00:00
toshii
4866f1a22b Fix typo. s/extention/extension/ 2001-07-05 08:38:24 +00:00
bjh21
3452c0d0a3 Add PowerROM support to asc(4), csa(4), csc(4) and ptsc(4). Not tested much,
I'm afraid.
2001-07-04 17:54:18 +00:00
bjh21
b8a09ee766 Add dummy "podloader" functions on arm32, and move their declarations to the MI
header file.  This should allow MI drivers to use the podloader functions,
though obviously they'll have to be able to cope if podulebus_initloader()
fails.
2001-07-04 13:58:04 +00:00
bjh21
0be64cc691 Move "podulebus" and "podloader" declarations up into files.podulebus. 2001-07-04 13:49:24 +00:00
bjh21
67ace1b581 Gratuitously make podulebusprint() more standard. It now says:
ea0 at podulebus0 slot 2: address 00:02:07:dd:ee:16, 16-bit, SEEQ 8005
eb0 at podulebus0 [ netslot 0 ]: address 00:00:a4:54:42:cb, 16-bit, SEEQ 80C04

Netslots will be dealt with later (I didn't like the idea of just printing
"slot 8").
2001-07-04 13:38:36 +00:00
bjh21
204fa6d2ef The only use of poduleirqhandler() was commented out, so remove it to
avoid confusion.
2001-07-03 20:47:23 +00:00
bjh21
659b8ab115 Separate out netslot-specific code into its own file, so that one day we can
make it optional.
2001-07-02 23:18:34 +00:00
bjh21
2e95360b2f Add dtide and hcide, since they should work on arm32. 2001-06-30 15:09:38 +00:00
darcy
ce0ec1e208 Add System V semaphore resource limits to each GENERIC file that has an
option for System V semaphores.  It appears that there are no overrides
in the code and each file has the following added.

 options    SYSVSEM     # System V semaphores
+#options   SEMMNI=10   # number of semaphore identifiers
+#options   SEMMNS=60   # number of semaphores in system
+#options   SEMUME=10   # max number of undo entries per process
+#options   SEMMNU=30   # number of undo structures in system
 options    SYSVSHM     # System V shared memory

If anyone thinks that this is incorrect for any of these files, please
correct it.

Note - the i386 port was not forgotten.  It was done separately.
2001-06-30 11:00:31 +00:00
chris
e2d29421a9 Add checks (make non DIAGNOSTIC) to make sure that we never call uvm_fault from an interrupt. 2001-06-26 22:09:19 +00:00
bjh21
c92dc14f82 It looks like cninit() is necessary on Risc PCs using the old console
drivers.  At least, putting it back in stops my Risc PC crashing at startup.
2001-06-23 16:47:41 +00:00
chris
ca2e4c7c43 remove another reference to ebsa285 missed in the last change 2001-06-20 22:20:42 +00:00
chris
7383fda9e0 Remove defopt EBSA285.
Move the files from footbridge that are cats specific.
Remove EBSA285 kernel as people should be able to use the generic cats kernel for EBSA285 systems.
2001-06-20 22:14:32 +00:00
wiz
ac951736bc response', not responce' 2001-06-19 13:45:52 +00:00
wiz
3f9984fc90 existent', not existant' 2001-06-19 13:42:07 +00:00
wiz
f3f6c5b675 accessible' only has one a'. 2001-06-19 12:52:20 +00:00
bjh21
cb36bacea5 Merge arm32/dev/bus_space_notimpl.S and hpcarm/hpcarm/bus_space_notimpl.S
into arm/arm/bus_space_notimpl.S.  They were identical anyway.

This file has no excuse for being in assembler, but I'll leave that for another
day.
2001-06-18 22:26:15 +00:00
bjh21
80c5d7ab99 Move <arm/arm32/bus.h> to <arm/bus.h>, since it looks like it's going to be
necessary on arm26 as well.
2001-06-18 21:37:32 +00:00
bjh21
743e0579d1 Remove "defopt FOOTBRIDGE" -- it's in files.footbridge now. 2001-06-18 20:49:14 +00:00
wiz
c03a48d64f withough -> without 2001-06-13 10:45:57 +00:00
wiz
0a600be867 receive, not recieve 2001-06-12 15:17:10 +00:00
wiz
2a8c778f1b retrieve, not retreive 2001-06-12 14:59:27 +00:00
chris
ed72dec945 Remove locore dependancy on opt_netwinder and use the netwinder define from the command line. 2001-06-11 22:08:42 +00:00
rearnsha
bf3fad1043 Split consinit functionality out of machdep.c into platform-specific
files.  G/c include files for machdep.c

Only include dev/cninit.c in ofw-based kernels.
2001-06-11 11:56:57 +00:00
chris
4c30449347 Remove the old kernel config files for cats, also remove isa_cats_machdep, as
it now lives in cats/isa/isa_machdep.c
2001-06-09 10:35:55 +00:00
chris
af8ce95972 Move the footbridge dir out of arm32 into arm. 2001-06-09 10:29:11 +00:00
bjh21
bfddba9825 Separate podule and netslot cases in poduleread() into separate functions,
with the correct one referenced by a pointer in the podule structure.  This is
in aid of eventually making the netslot and podulebus code a little more
separate from one another.
2001-06-08 22:38:07 +00:00
simonb
e5bd00e48d For ports that wire up pciide in compatibility mode, have
them define __HAVE_PCIIDE_MACHDEP_COMPAT_INTR_ESTABLISH
in pci_machdep.h and pciide_map_compat_intr() only calls
pciide_machdep_compat_intr_establish() if that preprocessor
define exists.

Ports that don't need to do this no longer need to supply a
dummy function.
2001-06-08 04:48:54 +00:00
chris
4e6f32c9d7 Fix the broken stray irq handling for footbridge, this needs to be
propegated to other arm32 irq handlers, until there's a common core part
for doing irq handling.

Untested as I've no cards that generate stray irq's.
2001-06-07 21:47:36 +00:00
thorpej
5523a584c5 HZ -> hz 2001-06-05 05:12:18 +00:00
bjh21
6a32761143 Now that cpu_dataabt_fixup() can fail, print slightly more useful information
(address and disassembly of the instruction that aborted) when it does so.
2001-06-02 22:48:40 +00:00
chs
821ec03ed9 replace vm_map{,_entry}_t with struct vm_map{,_entry} *. 2001-06-02 18:09:08 +00:00