Commit Graph

167790 Commits

Author SHA1 Message Date
skrll
06c967f126 Modernise NetBSD/alpha gdb - taken from gdb-current.
Add support for siginfo trampolines as well as sigcontext.
2008-03-13 18:18:15 +00:00
drochner
86d10efebd if "ddb_vgapost" is called but its data structures were not initialized,
print a message, suggested by joerg
(the message might be invisible if the console is in X mode)
2008-03-13 17:40:24 +00:00
taca
3a86ada98a Reflect change of PMF_FN_ARGS. 2008-03-13 16:29:48 +00:00
christos
749de7f2a4 Since _file is a short, check that the fd fits in it, otherwise bail with
EMFILE. We treat _file as an unsigned short to double our range, with a
special case for -1 (closed). Make a note of what we should do about stdio
if we ever bump libc. We could change _file in the future compatibly to an
int by putting it in the extension space but for now we don't bother.
2008-03-13 15:40:00 +00:00
pooka
546bf50253 Cache referenced rootvp in struct ukfs. Makes it possible to run
pre/postcall wrapper around the exported namei, since postcall no
longer needs to execute VFS_ROOT (which is a bad thing to do while
potentially holding on to a locked vnode, mmkay).
2008-03-13 14:24:30 +00:00
wiz
08186da791 Fix download-vulnerability-list's -c option. From Jim Bernard in PR 38231. 2008-03-13 08:38:24 +00:00
bjs
c5051ae798 Don't include i810 hack if DRM_NO_AGP is defined, as it results in
an undefined symbol (agp_i810_borrow) at kernel link time.
2008-03-13 05:35:43 +00:00
drochner
3678498d59 -add a function to vga_post which can be called from DDB to get a
usable VGA console ("call ddb_vgapost")
-allow to switch from/to screens occupied by an X server if the graphics
 device is console and in polling mode (ie DDB)
This together allows to get a DDB session on a VGA console if the
system crashed while X11 was running.
As long as the protocol to tell X servers about virtual screen switches
is as primitive as it is, it is unsafe to restart an X session afterwards.
So this is basically for crash analysis.
2008-03-12 23:26:18 +00:00
pooka
e8401439ac Implement all ukfs interfaces (except getdents, that's a bit more
tricky) with the help of rump system calls instead of calling namei
by themselves.  Trust me when I say it was non-trivial to get the
namei calls right.
2008-03-12 21:37:15 +00:00
dyoung
edb53ad207 Use device_t and accessors. 2008-03-12 18:26:58 +00:00
dyoung
84f6ead420 Make some cosmetic changes:
Use fewer 'error = ...; break;' statements and more 'return
        ...;'

        Make the SIOCSIFFLAGS case more clear by using a switch
        statement instead of an if-else if-else chain.

        Shorten a staircase, and remove two unnecessary curly
        braces.
2008-03-12 18:22:24 +00:00
dyoung
0f6e74fc64 epic_stop: clear IFF_RUNNING before disabling. 2008-03-12 18:15:31 +00:00
dyoung
47d2258078 sonic_stop: clear IFF_RUNNING before disabling. 2008-03-12 18:13:15 +00:00
phx
f04ba7d138 Make console drivers support PCI_IOC_CFGREAD/WRITE ioctls. This is useful for
XFree86, which can alternatively find the graphics card through /dev/ttyE0.
Approved by macallan.
2008-03-12 18:11:38 +00:00
dyoung
332191ede5 sf_stop: clear IFF_RUNNING before disabling. 2008-03-12 18:09:56 +00:00
dyoung
7bbfa300c6 Do not use sc_invalid, it is no more. 2008-03-12 18:08:43 +00:00
dyoung
3df2b2feb5 Use device_t and its accessors throughout. Use aprint_*_dev().
Improve PMF-ability.

        Add a 'flags' argument to suspend/resume handlers and
        callers such as pmf_system_suspend().

        Define a flag, PMF_F_SELF, which indicates to PMF that a
        device is suspending/resuming itself.  Add helper routines,
        pmf_device_suspend_self(dev) and pmf_device_resume_self(dev),
        that call pmf_device_suspend(dev, PMF_F_SELF) and
        pmf_device_resume(dev, PMF_F_SELF), respectively.  Use
        PMF_F_SELF to suspend/resume self in ath(4), audio(4),
        rtw(4), and sip(4).

        In ath(4) and in rtw(4), replace the icky sc_enable/sc_disable
        callbacks, provided by the bus front-end, with
        self-suspension/resumption.  Also, clean up the bus
        front-ends.  Make sure that the interrupt handler is
        disestablished during suspension.  Get rid of driver-private
        flags (e.g., RTW_F_ENABLED, ath_softc->sc_invalid); use
        device_is_active()/device_has_power() calls, instead.

        In the network-class suspend handler, call if_stop(, 0)
        instead of if_stop(, 1), because the latter is superfluous
        (bus- and driver-suspension hooks will 'disable' the NIC),
        and it may cause recursion.

        In the network-class resume handler, prevent infinite
        recursion through if_init() by getting out early if we are
        self-suspending (PMF_F_SELF).

rtw(4) improvements:

        Destroy rtw(4) callouts when we detach it.  Make rtw at
        pci detachable.  Print some more information with the "rx
        frame too long" warning.

Remove activate() methods:

        Get rid of rtw_activate() and ath_activate().  The device
        activate() methods are not good for much these days.

Make ath at cardbus resume with crypto functions intact:

        Introduce a boolean device property, "pmf-powerdown".  If
        pmf-powerdown is present and false, it indicates that a
        bus back-end should not remove power from a device.

        Honor this property in cardbus_child_suspend().

        Set this property to 'false' in ath_attach(), since removing
        power from an ath at cardbus seems to lobotomize the WPA
        crypto engine.  XXX Should the pmf-powerdown property
        propagate toward the root of the device tree?

Miscellaneous ath(4) changes:

        Warn if ath(4) tries to write crypto keys to suspended
        hardware.

        Reduce differences between FreeBSD and NetBSD in ath(4)
        multicast filter setup.

        Make ath_printrxbuf() print an rx descriptor's status &
        key index, to help debug crypto errors.

        Shorten a staircase in ath_ioctl().  Don't check for
        ieee80211_ioctl() return code ERESTART, it never happens.
2008-03-12 18:02:21 +00:00
dyoung
15bb494e45 In smap_stop(), clear IFF_RUNNING before disabling the device. 2008-03-12 17:23:13 +00:00
dyoung
f71d8b8379 Cosmetic: use device_t and accessors. Change to ANSI-style
prototypes.  Delete some dead code.
2008-03-12 16:11:23 +00:00
dyoung
677859c28a Print the TPPoll register when the Tx DMA engine doesn't shut down
in the time we allow.
2008-03-12 15:47:49 +00:00
tsutsui
21497ab14b Sync with MI NE2000 changes:
> Split device_t and softc for the NE2000 Ethernet chip and all its variants
> and attachments.  Use device_t accessors, correct types, and ANSIfy when
> appropriate.
2008-03-12 15:07:48 +00:00
pooka
b590aae6d8 Support chdir. This is useful for example when testing and not
wanting to stress namei() so much as test individual ops.
XXX: it should be implemented per calling thread, not per fs.
2008-03-12 14:49:19 +00:00
cube
cf80f73d17 Split device_t and softc for the NE2000 Ethernet chip and all its variants
and attachments.  Use device_t accessors, correct types, and ANSIfy when
appropriate.
2008-03-12 14:31:11 +00:00
pooka
8ca4306537 Support multiple file systems within one process with ukfs by using
a "chroot" for each file system.
2008-03-12 11:17:33 +00:00
ad
7b0b5fdc9d +2008 for the copyright 2008-03-12 11:05:01 +00:00
ad
2dc7c918f0 A test for the lwpctl preemption counter. 2008-03-12 11:02:21 +00:00
ad
727b89a296 Add a preemption counter to lwpctl_t, to allow user threads to detect that
they have been preempted.
2008-03-12 11:00:43 +00:00
mrg
3db9261484 don't need <sys/tty.h> here. 2008-03-12 05:57:28 +00:00
lukem
471f389be3 Add -I${LIBRUMPDIR} to fix objdir builds. 2008-03-12 05:11:51 +00:00
joerg
d134e844b3 libform and libmenu need libcurses. 2008-03-12 00:21:29 +00:00
dyoung
d347ff7717 Prepare for PMF self-suspension: in the if_stop() methods, clear
IFF_UP and IFF_RUNNING before running the 'disable' step, instead
of after.  Soon I will handle the 'disable' step by calling into
PMF, which may call if_stop(, 0).  Ordinarily, that is harmless.
This change lets the if_stop() routines exit early when they find
on entry that IFF_RUNNING is not set.
2008-03-11 23:58:06 +00:00
dyoung
25cf32ee3d Use device_t and accessors. 2008-03-11 23:19:03 +00:00
joerg
cb41266e10 Depends on libcurses. 2008-03-11 23:06:04 +00:00
pooka
3f429ae81b Compile rump_syscalls, use them in a few places. 2008-03-11 22:57:26 +00:00
pooka
a5d0e14cb0 regen this too, not that it changes except for rcsid 2008-03-11 22:55:35 +00:00
pooka
5a2a7c7039 gen 2008-03-11 22:53:54 +00:00
pooka
de0571f1e7 regen 2008-03-11 22:52:37 +00:00
pooka
5354d1092b Add locations for rump_syscalls.[hc] files 2008-03-11 22:51:51 +00:00
pooka
f2976c3905 Generate syscalls entry points which can be called directly without
going through a syscall trap.  These are currently useful for rumps.
As all the standard syscalls are not compiled into librump, mark
relevant ones with RUMP in syscalls.master.  To do e.g. a mkdir
"system call" from a rump, one would call

  rump_sys_mkdir("/dir", mode, &eval);

where the last value represents something to store errno into.
2008-03-11 22:50:10 +00:00
joerg
aa717955e2 Use CPUID2EXTFAMILY and CPUID2EXTMODEL. 2008-03-11 22:43:08 +00:00
dyoung
7f0a735df6 Use device_t and accessors. 2008-03-11 22:26:14 +00:00
dyoung
78a6c4d71a pci_disable_retry() is now a no-op, so don't call it any more. 2008-03-11 20:55:32 +00:00
dyoung
db4f43a7cd pci_disable_retry() is now a no-op, so don't call it any more. 2008-03-11 20:45:04 +00:00
matt
9b9164cc52 on MP systems, whenever we change a PTE, make to sync the data cache so that
other processors can see the change.
2008-03-11 20:44:01 +00:00
dyoung
0dddb5735e Finish the job: pci_disable_retry() is now a no-op, so don't call
it any more.
2008-03-11 20:41:35 +00:00
pooka
ab7b2e9a1b missed this 2008-03-11 20:40:58 +00:00
dyoung
5f07fde2c9 pci_disable_retry() is now a no-op, so don't call it any more. 2008-03-11 20:40:51 +00:00
joerg
e1032da53f Don't skip ioctls with a digit in the name.
Add a number of conflicting entries.
Add some entries from the IPv6 stack where the used structure is not
exported to userland.
2008-03-11 20:39:57 +00:00
dyoung
e33cbf5cfc pci_disable_retry() is now a no-op, so don't call it any more. 2008-03-11 20:39:24 +00:00
tonnerre
974efd2037 Dutifully add myself to the list 2008-03-11 19:19:14 +00:00