Commit Graph

62 Commits

Author SHA1 Message Date
tv e58532a4bf No-op commit to force update to a non-"-kk" revision. 2001-01-18 17:47:58 +00:00
fvdl c7f1462f3e Add machdep file for procfs. Currently only used for linux-style
/proc/cpuinfo (only active when procfs is mounted with -o linux).
For ports other than the i386 this currently produces an empty
string.
2001-01-17 00:07:18 +00:00
thorpej d74e432ed3 Make softclock a generic soft interrupt of the API is available,
adding the requisite void * argument to softclock().
2001-01-15 20:19:50 +00:00
thorpej d85a75f583 Make sure everybody has an splvm() and equate it with splimp() (splimp()
is the historical name for this interrupt level, and the historical name
is going to go away in the near future).
2001-01-14 02:00:37 +00:00
bouyer c71f40d166 Add pseudo-device vlan 2000-12-19 10:42:02 +00:00
matt 825cb46de5 Revert back to a machinearch (really cputype) of mips. Put ENDIAN back. 2000-12-03 07:05:21 +00:00
matt 866f93d61f Change arch from mips to mipsel/mipseb as appropriate. Nuke the ENDIAN
makeoption.  Key off MACHINE_ARCH for adding -EB/-EL to CFLAGS/AFLAGS/LD/
LINKFLAGS.
2000-12-03 05:30:31 +00:00
matt a0a88e0a71 Use shared Makefile.mips 2000-12-03 04:51:26 +00:00
matt bd338a518c Deal with -Wstrict-prototypes -Wmissing-prototypes 2000-12-03 04:51:04 +00:00
soren 38a44e0d8f Consistently use pmap_steal_memory() to allocate USPACE. 2000-11-27 05:57:25 +00:00
chs c62d17a551 rationalize the use of b_flags for geteblk() buffers.
rather than assigning to the whole field, set or clear individual flags,
which implies that the B_BUSY and B_INVAL flags will remain set.
this allows us to make the assertion in brelse() that B_BUSY is set,
which is the purpose of all this.
2000-11-20 08:24:08 +00:00
itojun 0c84fad435 more rnd(4). 2000-10-04 22:26:49 +00:00
wdk 6b207c8f05 Add netbsd.ecoff to list of files to cleanup. Forgot in previous commit. 2000-10-03 10:09:12 +00:00
wdk ff5d9dc3a7 Change default kernel format from ECOFF to ELF now we can boot ELF using
libsa based bootstraps.   This is now the prefered format.

ECOFF format kernel renamed to netbsd.ecoff - still required for network
booting.
2000-10-03 09:46:39 +00:00
wdk e705396abb Switch to MI md_root.c 2000-10-03 09:38:20 +00:00
abs 2824f4906d Ensure all INSTALL* kernels have two ptys, and a note explaining why:
pseudo-device  pty             2       # pseudo-terminals (Sysinst needs two)
(Some installers may not be using sysinst, in which case this just reduces
the number of ptys from 16 that are not used to 2 that are not used)
For i386 conf files, no change other than comments.
2000-10-02 18:43:34 +00:00
wdk 2bc18c0ead Add parenthesis to TICKS_TO_USECS macro avoiding side-effects.
Fixes glitch where microtime goes backward.   KNF rules!
2000-10-02 07:58:26 +00:00
wdk d7ff540d90 Boot to multiuser by default. 2000-10-02 07:57:29 +00:00
wdk 68e8ad5120 Fixup missing entries in chrtoblktbl 2000-10-02 07:56:31 +00:00
wdk 77c68f1f9c downsized kernels for installation & recovery 2000-10-02 07:54:34 +00:00
wdk caccbc2e21 Add kernel support for memory disks 2000-09-29 12:43:14 +00:00
wdk ceb69697cd Backout previous commit.
loadfile_machdep.h doesn't belong in /usr/include/machine

Pointed out by Simon Burge
2000-09-27 02:06:08 +00:00
wdk bbec09cae1 Add stand directory to build process 2000-09-26 11:45:06 +00:00
wdk 7378a103a0 Much needed installboot utility. Manual page to follow.
Builds and installs from stand directories, but untested from higher
level makefiles.
2000-09-26 10:00:19 +00:00
wdk 50e120c13f Parse boot string intelligently to extract the boot device options.
This permits boot from any SCSI ID
2000-09-26 09:48:35 +00:00
wdk 7495cd76b1 Since we don't have a lseek function in the PROM firmware standalone libs
we have to poke the data structures directly to force the offset we need.

The open() function returns with the address of the IO control block in
register t0 so we take a copy of it for our brute-force lseek function.

This should be reasonably portable since the firmware writers closely
follow UNIX semantics and the open stubs should recompile and use the
same registers.   May break on the rebadged clones -- buyer beware.

The alternative is to use dummy reads to go forwards and reopen followed
by dummy reads to go backwards.  It takes around 60 seconds to boot
using this method if we use a clean filesystem.

Tested with firmware versions 5.40 and 5.43
2000-09-26 09:32:25 +00:00
wdk 9b4e50f624 Second stage bootstrap:
-  Rename from boot.mipsco -> boot to be consistant with other ports
  -  use ELF format
2000-09-26 09:11:04 +00:00
wdk 1eec339f4b First stage bootstrap is stored on boot sectors in ECOFF format. Ensure
entire file fits within the imposed limit.
2000-09-26 09:06:50 +00:00
jdolecek b1f94e26ab don't specify number of ptys if >= 16 (current default initial number)
pty comments: normalize and g/c what is no longer relevant
2000-09-24 15:59:26 +00:00
jdolecek 49c105ffdb add new macro BOOT_FLAG() (defined in <sys/boot_flag.h>) - this
maps standard boot flags to corresponding RB_* values
use BOOT_FLAG() in port's MD code as appropriate

as discussed on tech-kern, add new boot flags -v, -q for booting
verbosely or quietly, and corresponding AB_VERBOSE/AB_QUIET
boot flags; also add FreeBSD-compatible bootverbose macro and
NetBSD-specific bootquiet macro

for hpcmips, use new bootverbose instead of it's own hpcmips_verbose

Tested on i386, and to limited extend (compile of affected files) also for
mvme68k, hp300, luna68k, sun3.
2000-09-24 12:32:31 +00:00
wdk d471ac652d Forgot to commit this file with the 2 stage bootstrap 2000-09-19 07:50:50 +00:00
wdk 513cc0ca27 Linker script for building first stage bootstrap. Due to bugs/limitations
in the MIPS prom loader we have to be very careful how the sections are
ordered and the number of sections defined.   For this reason the standard
linker scripts cannot be used.

The exact rules don't appear to be documented and a little experimentation
is required.
2000-09-18 11:48:29 +00:00
wdk a3ec172607 Initial commit of a 2 stage bootloader for NetBSD/mipsco. Based on pmax
and alpha ports.

Uses PROM standalone I/O functions but due to the lack of a lseek function
it currently only works with version 5.40 of the firmware.  A more portable
solution is being worked on.

installboot utility requires several changes in order to correctly install
the bootstrap code - there is a "volume directory" which contains a list
of filenames, start sectors and length.  We need to add a "boot" entry of
the correct length starting at block 2.  The boot file has to be ecoff
which means we waste another 0.5k

Normally the Mips filesystem has a ~500k partition for this purpose but it
should be possible to squeeze it all into the first 7k "BSD Style" (1k is
required for 2 different copies of the partition table)

Only the bootxx_ffs first stage bootstrap has been tested via bootp() which
loads the second stage off disk and then boots the kernel.
2000-09-18 11:40:46 +00:00
wdk 74fa574688 * Add INET6 and IPSEC support.
* Enable vnd driver for creating a working miniroot.
2000-09-16 09:35:38 +00:00
wdk 0b445f157e Add missing align argument to uvm_map() which was missed by thorpej during
original commit.
2000-09-16 09:18:01 +00:00
wdk da962aaad5 Add support for bootinfo structure to be passed from 2nd stage bootstrap.
Pass symbol table information to DDB if available.
2000-09-16 08:34:26 +00:00
wdk 780256a327 Prototype prom_ioctl 2000-09-16 08:27:58 +00:00
wdk b57fe26ada Write a NetBSD disklabel to 2nd sector while retaining the Mips volume
header in the ist sector.   We now use the NetBSD label in preference
to the Mips Volume header.
2000-09-16 08:27:16 +00:00
nisimura c65b8a8ceb Nuke unused obscure #define's. 2000-09-13 05:23:37 +00:00
nisimura a101bca4b8 Needs to have machine/asm.h for userland applications. 2000-09-11 03:25:40 +00:00
nisimura eafab3fe6b RB_DFLTROOT is obsolute and G/C'ed from main trunk at late Jul of 2000. 2000-09-10 06:26:51 +00:00
wdk b38096892a Microtime calculation was seriously incorrect when HZ != 100
Give rest of clock interrupt code a revamp.  Because we are using an external
cycle counter we can now handle loosing several hundred interrupts without
the time slipping.
2000-09-06 07:52:47 +00:00
wdk f0f97fa466 * Add extra tests to ensure NetBSD disklabel is not corrupted
* For MIPS RISC/os based diskl labels create partition 8 which is used
  by sash (and where bootstrap code hides).

* If existing MIPS RISC/os label is present update disk parameter information
2000-09-04 22:35:26 +00:00
wdk 3e329a2925 * Use bus_space_write_multi_2 for priming the DMA FIFO as suggested by cgd
*  Correctly handle transfer pad operation

*  Remove check for DMA fifo flush during DMA chaining - after considerable
   thought this is not required
2000-09-04 22:28:53 +00:00
wdk 7980486e61 Add #define's for PROM entry point addresses which will be needed by any
replacement bootstrap routines
2000-09-04 22:23:34 +00:00
wdk 801b97faf2 Add wbflush() to bus_space_{write_multi,write_region,set_region,copy_region}
functions
2000-09-04 22:18:58 +00:00
wdk 35871e7996 Report memory sizes using format_bytes(9) kernel function 2000-08-29 12:12:59 +00:00
wdk 149a5fc5f2 Engage the clutch before changing gears.
If the machine uses a Z85230 ESCC device with deep buffers, we observe
output glitches when printing the zstty{0,1} probe lines when the device
is reset & reprogrammed during startup.

There is no easy 'hook' in the MI Z8530 driver, so we wait for output
buffer to drain before changing the baud rate generator prescaler value.
2000-08-29 11:25:08 +00:00
wdk 5656bdea79 Don't trust the realtime clock if the data is before 1988. This is
consistant with other ports.

Prevent uninitialized time from being written back to the RTC (1-Jan-1970)
if the machine is halted from the root device name prompt
(bootflags & RB_ASKNAME)
2000-08-29 10:34:13 +00:00
wdk aaa3f11967 Fix an obscure bug with dump corrupting files during raw reads.
If the DMA chaning interrupt couldn't be serviced immediately (higher spl
level when kernel doing something else) a few microseconds later the NCR
controller will fill its FIFO and also interrupt the CPU.

The SCSI interrupt sees the terminal count has been reached, calls
asc_dma_intr to finish the job off.   The FIFO cannot be flushed because
the block count hasn't been setup for the last dma segment (DMA chaining
still wasn't serviced).

Since the NCR 53c94 FIFO is only 16 bytes in size, any short DMA in this
size combined with the machine 'doing something else' causes the problem
to occur.

Servicing the DMA chaining interrupt before the NCR SCSI interrupt solves
this problem.

Add tests to ensure the DMA FIFO has been flushed correctly at the end of
each DMA operation just to be on the safe side.
2000-08-29 08:24:06 +00:00