Commit Graph

8860 Commits

Author SHA1 Message Date
sos
85f5504c52 Add the pst (Promise SX6000) driver to GENERIC. 2002-09-27 19:09:21 +00:00
scottl
0d4a968a49 Move the aac driver from MI to MD NOTES. It is a long way from being
64-bit clean.
2002-09-26 18:16:28 +00:00
peter
1a6bc64814 ISMEMSDP(), IS286GDP(), IS386GDP(), ISGDP(), ISSDP() and ISSYSSDP() are
not used anywhere anymore.
2002-09-26 05:07:41 +00:00
markm
6e3bf1cf9c Fix a declaration that is actually supposed to be a macro definition.
Submitted by:	marius@alchemy.franken.de
2002-09-25 13:46:23 +00:00
mini
7a31c08874 Back out last commit. Linux uses the old 4.3BSD sockaddr format. 2002-09-24 07:03:01 +00:00
alfred
ac315391ce use __packed. 2002-09-23 18:54:32 +00:00
jhb
5dc0248605 Now that we only probe host-PCI bridges once, we no longer have to check to
see if we have been probed before by checking for a pciX bus device.
2002-09-23 18:14:31 +00:00
jhb
f05f2dae06 Put verbose printf's in the PCI BIOS interrupt routing code under
if (bootverbose).
2002-09-23 18:13:42 +00:00
jhb
a6b32a877e Update the nexus driver for the addition of the legacy driver:
- nexus no longer has PCI bridges as direct children, so the PCI bus
  ivar is no longer used and is removed.
- Don't attach default EISA, ISA, or MCA busses.  Instead, if we do not
  have an acpi0 device after bus_generic_probe(), add a legacy0 child
  device.
- Remove machine/nexusvar.h.
2002-09-23 16:03:00 +00:00
jhb
f08e07f2b3 Hang apm off of the legacy device instead of the nexus. 2002-09-23 15:56:09 +00:00
jhb
36594f8de5 Change the nexus_pcib driver (eventually to be renamed to legacy_pcib) to
hang off of the legacy driver instead of the nexus.
2002-09-23 15:52:30 +00:00
jhb
3c64027d75 Add a new legacy(4) device driver for use on machines that do not have
ACPI or for when ACPI support is disabled or not present in the kernel.
Basically, the nexus device is now split into two with some parts
(such as adding default ISA, MCA, and EISA busses if they aren't found
as well as support for PCI bus device ivars) being moved to the legacy
driver.
2002-09-23 15:50:06 +00:00
peter
1cb6a2f64f PIC_GOTOFF is OBE. 2002-09-23 07:27:45 +00:00
peter
6fedca521d use __packed, rather than __attribute__((packed)). 2002-09-23 06:50:07 +00:00
mini
e206834961 Don't use compatability syscall wrappers in emulation code.
This is needed for the COMPAT_FREEBSD3 option split.

Reviewed by:	alfred, jake
2002-09-23 06:17:54 +00:00
peter
478da56c11 At great personal risk, add a __packed and __aligned(x) define that
expand to __attribute__((packed)) and __attribute__((aligned(x)))
respectively.  Replace the handful of gcc-ism's that use
__attribute__((aligned(16))) etc around the kernel with __aligned(16).

There are over 400 __attribute__((packed)) to deal with, that can come
later.  I just want to use __packed in new code rather than add more
gcc-ism's.
2002-09-23 05:55:10 +00:00
peter
c853ce6ce7 Delete a whole bunch of compatability defines that we dont use anymore. 2002-09-23 05:04:05 +00:00
mike
fb4d714b00 Be careful not to define GCC-specific optimizations in the non-GCC
case.
2002-09-23 04:32:17 +00:00
peter
e8f9ac26c8 Create inlines for ltr(sel), lldt(sel), lidt(addr) rather than
functions that have one instruction.
2002-09-22 04:45:21 +00:00
mdodd
d0bd1b75a0 - Move the init of %gs and pcb_gs before user_ldt_free().
- Always call load_gs()
- Trim comments.

This addresses some of the issues raised by BDE.
2002-09-22 01:32:48 +00:00
jake
be3bee9396 Moved nfs_diskless setup code from autoconf.c to nfsclient/nfs_diskless.c
so that it is MI.  Allow nfs_mountroot to return an error if the nfs_diskless
struct is not valid, rather than panicing later on.  Call nfs_setup_diskless()
from nfs_mountroot if NFS_ROOT is defined, like bootpc_init().  Removed legacy
root mount support for sparc64, and enabled NFS_ROOT by default.
2002-09-22 00:59:02 +00:00
jake
2b71a04b1e Use the fields in the sysentvec and in the vm map header in place of the
constants VM_MIN_ADDRESS, VM_MAXUSER_ADDRESS, USRSTACK and PS_STRINGS.
This is mainly so that they can be variable even for the native abi, based
on different machine types.  Get stack protections from the sysentvec too.
This makes it trivial to map the stack non-executable for certain abis, on
machines that support it.
2002-09-21 22:07:17 +00:00
markm
03d0f482ba Use a function instead of a non-portable, GCC-specific asm() entry. 2002-09-21 19:03:42 +00:00
markm
6b1c92e89e A good dose of style.9. No functional change. 2002-09-21 19:02:17 +00:00
markm
138978c497 Code tidy-up. ISOfy, turn a macro into an inline for lint(1) (perhaps
this needs to go to cpufunc.h?), de-register.
2002-09-21 18:53:58 +00:00
markm
ac87fc24a6 Use a function instead of embedding non-portable asm() constructs
in C code.
2002-09-21 18:51:19 +00:00
markm
e97f22de41 Sort includes. 2002-09-21 18:30:12 +00:00
markm
fed5dfb239 Provide in inline function for the (GNUC) assembler "hlt" instruction. 2002-09-21 18:26:53 +00:00
markm
e51e2b450a Wrap GCC-specific asm() code in #ifdef __GNUC__ 2002-09-21 18:19:51 +00:00
phk
9012cc741f Fix a 3 year old oversight: Remove the #ifdef/#endif pair now that there
is nothing between them anymore.

Spotted by:	peter.
2002-09-21 07:59:06 +00:00
jhb
8c280ed0fd Axe unused include. 2002-09-20 19:16:41 +00:00
phk
9759856130 We need neither <sys/diskslice.h> nor <sys/disklabel.h> here.
Sponsored by:	DARPA & NAI Labs.
2002-09-20 17:59:09 +00:00
phk
d376fc4110 For reasons now lost in historical fog, the bounds_check_with_label()
function were put in i386/i386/machdep.c from where it has been
cut and pasted to other architectures with only minor corruption.

Disklabel is really a MI format in many ways, at least it certainly
is when you operate on struct disklabel.

Put bounds_check_with_label() back in subr_disklabel.c where it belongs.

Sponsored by:   DARPA & NAI Labs.
2002-09-20 17:51:00 +00:00
jhb
868209c892 fork_trampoline() marks a trap frame.
Submitted by:	bde
2002-09-20 13:58:21 +00:00
jhb
8ba762c99f Use proper type for a variable used as a DDB symbol. 2002-09-20 13:56:11 +00:00
jhb
1deeb25fda Trim includes.
Submitted by:	bde
2002-09-20 13:54:45 +00:00
jhb
a68b84312f Various style fixes, including moving db_print_backtrace() out of the
middle of the watchpoint code.

Submitted by:	bde
2002-09-20 13:53:33 +00:00
mdodd
b2eb3d57ff This patch enables FreeBSD i686 MTRR support on Intel Pentium
4/XEON processors, which are not currently recognized.

Submitted by:	 Christian Zander <zander@minion.de>
2002-09-19 18:53:49 +00:00
jhb
03dc7bc4a4 Implement db_print_backtrace() if DDB is compiled into the kernel. This
MD function is just a wrapper around db_stack_trace_cmd() that prints out
a backtrace of curthread.  Currently, this function is only implemented
on i386 and alpha (and the alpha version isn't quite tested yet, will do
that in a bit).  Other changes:

- For i386, fix a bug in the raw frame address case.  The eip we extract
  from the passed in frame address does not match the frame we received.
  Thus, instead of printing a bogus frame with the wrong eip, go ahead
  and advance frame down to the same frame as the eip we are using.
- For alpha, attempt to add a way of doing a raw trace for alpha.  Instead
  of passing a frame address in 'addr', pass in a pointer to a structure
  containing PC and KSP and use those to start the backtrace.  The alpha
  db_print_backtrace() uses asm to read in the current PC and KSP values
  into such a request.

Tested on:	i386
Requested by:	many
2002-09-19 18:46:29 +00:00
mdodd
862a7a0206 From Christian Zander:
This patch addresses a bug that can cause a GPF in the kernel - if a
process makes use of i386_set_ldt to install a LDT entry, then loads
a corresponding segment descriptor into %gs, forks, and if the child
execs.

In this scenario, setregs executes user_ldt_free and then determines
how to reset the %gs register:

    /* reset %gs as well */
    if (pcb == curpcb)
        load_gs(_udatasel);
    else
        pcb->pcb_gs = _udatasel;

This is insufficient in the fork/exec case, since pcb will be equal
to curpcb when the child execs; load_gs will reset %gs to _udatasel
but it doesn't reset pcb->pcb_gs; upon return from the system call,
cpu_switch_load_gs will thus attempt to restore %gs from pcb->pcb_gs
and trigger a GPF since all LDT entries have already been cleared.

The fix is to always reset pcb->pcb_gs to _udatasel.

Submitted by:	Christian Zander <zander@minion.de>
Reviewed by:	jake
2002-09-19 18:46:25 +00:00
peter
c6d7dcd0d4 Repo copied to <sys/smbus/smb.h> 2002-09-19 04:13:43 +00:00
peter
ef89cffd6d Repo copied to <sys/iicbus/iic.h> 2002-09-19 04:13:29 +00:00
peter
af094d65ba move wl (isa wavelan card, not "wi") to i386-only 2002-09-19 03:10:23 +00:00
peter
8bd0246702 move "profile 2" to i386 2002-09-19 03:04:07 +00:00
peter
2a90117a45 move ncv, nsp, stg to i386-only section (there is no pc98-specific version) 2002-09-19 03:02:42 +00:00
peter
ef7ad90d61 Move dgb to the i386 section 2002-09-19 02:58:41 +00:00
iwasaki
c30c4f6198 Restore status register A of RTC at resume time.
This should fix the 'too many RTC interrupts and statclock seems
broken after resume' problem.

MFC after:	1 week
2002-09-18 07:34:04 +00:00
mike
e35c51c74c Implement C99's va_copy() macro. 2002-09-18 07:33:16 +00:00
phk
241ea7bde8 Add /dev/soekris-errled device to control the Error-LED on Soekris cards/boxes.
# turn LED off
    echo '0' > /dev/soekris-errled

    # turn LED on
    echo '1' > /dev/soekris-errled

    # flash LED (5 hz)
    echo 'f' > /dev/soekris-errled

    # flash LED (4/2 = 2 hz), syntax: "f[1-9]" -> .5 -> 4.5 Hz
    echo 'f4' > /dev/soekris-errled

    # flash digits 1,3 and 7, syntax: "d[1-9]*"
    echo 'd137' > /dev/soekris-errled

Characters not understood are ignored.
2002-09-17 11:47:38 +00:00
sobomax
f4675ef21f Don't reference cpu_fxsr unless CPU_ENABLE_SSE is defined. This fixes kernel
in !CPU_ENABLE_SSE case.
2002-09-17 11:12:10 +00:00