Commit Graph

183775 Commits

Author SHA1 Message Date
drochner
d70cb77245 fix undefined result of stat(), found by clang static analyzer 2009-09-15 19:38:15 +00:00
dyoung
fe01097755 Simplify activation routines: do not call mii_activate(), it is a
no-op.  Do not block interrupts, if_deactivate() will take care of
that for us.
2009-09-15 19:29:17 +00:00
dyoung
b8695aecbf Simplify activation routines: don't call mii_activate(), it's a
no-op.  Don't block interrupts, if_deactivate() does it.
Compile-tested, only.
2009-09-15 19:20:29 +00:00
dyoung
662dfba47d To ease a future device_t/softc split, se device_private() instead
of casting device_t to softc.
2009-09-15 18:37:02 +00:00
dyoung
7cd3e7cb51 unifdef -D__NetBSD__ -U__FreeBSD__.
No functional change intended.
2009-09-15 18:32:00 +00:00
degroote
1c91cfd4c4 Mention pfsync(4) import 2009-09-15 10:42:40 +00:00
he
ad8225c04b Move the addition of pfsync.c from Makefile.inc to Makefile,
so that this part doesn't get included in install media versions
of ifconfig, as per comments on source-changes@ from Izumi Tsutsui.
Also re-instate the use of ${.CURDIR} when setting up the include path.
2009-09-15 09:22:07 +00:00
haad
a6ae7c3f3a Revert my last wrong change this will need more work. 2009-09-15 02:04:12 +00:00
haad
7166baaa71 On i386 use 32bit version of atomic_add_op because 64 doesn't work on
i486 userland.
2009-09-15 01:48:41 +00:00
jnemeth
5fe591a2c9 bump date for previous 2009-09-15 01:20:42 +00:00
jnemeth
b313b03dff mention the new modules.tgz set 2009-09-15 01:12:38 +00:00
apb
1e2ed7f3ca Fix some errors in the way scripts with "KEYWORD: interactive"
are handled.  There was an inverted test, and "set $_args"
had the wrong scope (in several nearly-identical blocks of code).
2009-09-14 22:30:30 +00:00
reinoud
c1a508d11c Rework simplistic UBC flushing. Recent changes to genfs made the old flush
system generate heaps of odd allocations since the end of write request was
overwritten by the start of the second resulting in another relocation.

Also added a full flush of the file on a VOP_CLOSE(). This automatically
flushes file tails to disc.
2009-09-14 21:10:44 +00:00
pooka
70d95ce59f fix markup 2009-09-14 20:54:34 +00:00
apb
50a2fd2471 Make the documentation match reality. If no explicit kernel name is
provided, kvm_open() and kvm_openfiles() will try _PATH_KSYMS first,
then either the path from sysctl machdep.booted_kernel (if that's
available) or _PATH_UNIX (if the sysctl is not available).
2009-09-14 19:34:12 +00:00
apb
8a61809cf3 Move the code that tries to open _PATH_KSYMS first into a common path,
so that it is used both for the /dev/mem case and the core dump case.

Output from savecore(8) before:
    savecore - - - (null): kvm_openfiles: /netbsd: No such file or directory
and after:
    savecore - - - no core dump
2009-09-14 19:29:20 +00:00
apb
a83419cd12 Check whether a core dump exists before trying to save it. This should
prevent /etc/rc from thinking that /etc/rc.d/savecore failed.
2009-09-14 17:34:56 +00:00
skrll
52749c1bca Rely on the new and "just as awful as the old" hack in the battle of rump
vs link sets.
2009-09-14 17:24:20 +00:00
apb
4b22dcf467 Add a note saying that new tests should use ATF. 2009-09-14 17:15:32 +00:00
he
1a0a5901b1 Print an explicit 64-bit type with %PRIu64, not with %llu, so that
this builds on our LP64 ports as well.
2009-09-14 15:18:15 +00:00
he
4cf3355067 Change from using ${.CURDIR} to ${NETBSDSRCDIR} because this file
may be included by different parts of the source tree, in particular
deep down in the distrib/ tree, where ../.. isn't sufficient to "climb"
up to the top of the tree.  Fixes the build at least for our arc port.
2009-09-14 15:12:21 +00:00
pooka
b7f6f78fc9 Remove stale comment about super user. no functional change 2009-09-14 14:37:52 +00:00
he
c88a33f1f2 We need to install disklabel_rdb.h here as well, so that the
toolized disklabel for amiga (at least) can be allowed to build.
2009-09-14 13:44:05 +00:00
tsutsui
16c0f8385d Use device_private(), proper types or variables for device_t and softc.
(not yet split though)

No crash on gxemul emulating hpcmips mobilepro.
2009-09-14 13:41:15 +00:00
rmind
d1e070a421 Add COMPAT_50 for MALTA. 2009-09-14 12:52:20 +00:00
tsutsui
5770fb4ee0 u_intNN_t -> uintNN_t 2009-09-14 12:49:33 +00:00
pooka
84e795ea60 Set fspec to canon_dev instead of dev. 2009-09-14 12:43:46 +00:00
wiz
f08a1819c1 Punctuation nits. 2009-09-14 12:37:08 +00:00
apb
70472a4826 Add the ability for file systems mounted via mount_critical_filesystems()
in rc.subr to be marked as optional.  This means that it's not an
error if the file system is not mentioned in /etc/fstab.  It is
still an error if something else goes wrong.

Change the defaults for these two variables in /etc/defaults/rc.conf:
critical_filesystems_local="OPTIONAL:/var"
critical_filesystems_remote="OPTIONAL:/usr"
2009-09-14 12:05:12 +00:00
tsutsui
7cbddbd446 Replace shutdownhook_establish(9) with pmf_device_register1(9).
Tested on D-Link DL-4000.
2009-09-14 12:02:48 +00:00
jmcneill
1ea984dc79 Don't commit the selected VBE mode until the loader is past the point of
no return; need to stick in text mode as long as possible since libsa does
not include a rasops library. While here, add the 'vesa' command to pxeboot
to mirror biosboot behaviour.
2009-09-14 11:56:27 +00:00
degroote
33e10c238e Improve the pfsync(4) man page
hostname.if(5) is ifconfig.if(5) on NetBSD
Don't speak about enc, as we don't support it at the moment
Make clear that we don't support ipsec protection of pfsync traffic (as long we
doesn't support enc, or similar thing)

Catched by wiz@
2009-09-14 11:45:01 +00:00
tsutsui
cbc3734a99 Enable options IPKDB. 2009-09-14 11:38:29 +00:00
tsutsui
f52132ce21 Make this compile. From elad@. 2009-09-14 11:37:36 +00:00
wiz
f41e8ac844 <>& -> \*[Lt]\*[Gt]\*[Am]
Bump date for pfsync(4) link.
2009-09-14 11:17:49 +00:00
wiz
f8b0915e76 Fix Dd argument. 2009-09-14 11:17:42 +00:00
jmcneill
1b3357e5de Don't treat timeouts or the return key as an invalid choice; spotted by
Andreas Gustafsson.
2009-09-14 10:42:42 +00:00
degroote
2d48ac808c Import pfsync support from OpenBSD 4.2
Pfsync interface exposes change in the pf(4) over a pseudo-interface, and can
be used to synchronise different pf.

This work was part of my 2009 GSoC

No objection on tech-net@
2009-09-14 10:36:48 +00:00
pooka
03266a3f98 Be more naughty and don't even include <machine/cpu_counter.h> for
rump builds.  Hopefully fixes the alpha build failure he@ pointed
out to me.
(yes __HAVE_CPU_COUNTER involves a trickery)
2009-09-14 09:26:28 +00:00
mhitch
e851d39acd Add support for booting off a couple of common RAID adapters found on
several models of alpha systems: mlx [Mylex DAC060] and iop [I2O].
Addresses PR #25829.
2009-09-14 02:46:29 +00:00
mhitch
a25d763f88 Add the I2O iop controller, as used in the ES40 and ES45. 2009-09-14 02:28:22 +00:00
mhitch
3ebe8c5833 Switch the amiga to the common m68k/m68k/pmap_motorola.c (Finally!!). 2009-09-14 02:23:05 +00:00
mhitch
bd24936ebd Not understanding what vax_mfpr_get_counter() was doing, my fix for
backwards time was incorrect, and actually disabled the use of mfpr for
timecounters.  The intent was to emulate a 32 bit counter using the
hardclock_ticks from the clock interrupt and the contents of the
Interval Counter register.  The problem with that was when the ICR
wrapped, but the clock interrupt was blocked resulted in an incorrect
count.  Work around this by keeping track of the previous ICR value
and hardclock_ticks to ensure the 32 bit counter doesn't go backwards.
Also, the ICR runs from -10000 to -1, so adjust the value when reading it.
Now mfpr works quit nicely on my 4000/90.
2009-09-14 02:19:15 +00:00
jmcneill
df6bdc8be4 If the menuformat is not letter, do not allow letter keys to be aliases
for number keys. snj@ often overshoots the spacebar in a panic and
accidentally hits 'b' instead, which makes the loader boot item '2'.
Can't fix snj@, so fix the boot loader instead.
2009-09-13 23:53:36 +00:00
pooka
48b3a6f7a3 binutils 2.19 has changed the old behaviour of defining __start_SECTNAME
for orphaned sections to using PROVIDE.  What this means is that
unless a rump component internally references that symbol, it will
not be included in the component shared library, and hence cannot
be referenced when the component is loaded.  Add a workaround which
works both with 2.16 and 2.19: force a reference to the __start
symbol internally and hence retain it in the resulting library.
2009-09-13 22:51:41 +00:00
jmcneill
891bf245b9 Make the 'dev' command print out a list of known boot devices based on
information from the BIOS in addition to the currently selected default
partition. Handy when you don't know where to boot from. Here's a demo:

  type "?" or "help" for help.
  > dev
  disk hd0 size 3815 MB
    hd0a(4.2BSD) hd0b(swap)
  disk cd0
    cd0a(unknown)
  default hd0a
  >
2009-09-13 22:45:27 +00:00
wiz
86dbe4a721 Recognize bsdiff(1) files.
Patch already sent upstream.
2009-09-13 22:16:45 +00:00
dyoung
9e037d8311 Experimental support for fragmentation and RTS/CTS.
Delete unused atw_voodoo and constants.

Export Tx/Rx statistics with evcnt(9).

Correct the Short Inter-Frame Space (SIFS) that we write to ADM8211's
registers; I do not recall if that corrected the SIFS that I observed
"on the air."  Use the constant IEEE80211_DUR_DS_EIFS to configure
the ADM8211's EIFS, instead of writing the same "magic" number,
0x64, that my reference driver wrote.

Do not clear OACTIVE in atw_init(), because atw_stop() cleared it
previously by calling atw_txdrain().

Use the net80211 short-preamble flag and instead of ATW_SHPREAMBLE.

Add an ADM8211 workaround from the reference driver, atw_workaround1(),
but don't compile it right now.

In at_intr(), don't stop processing the interrupt status after
restarting the receive ring, but process Tx interrupt status.  If
a packet's Tx lifetime is exceeded, reinitialize the device to get
packets moving again.  If the Tx FIFO underflows, restart the
transmitter, not the receiver!

Avoid losing synchronization with the Rx ring by replicating one
of Charles Hannum's fixes to rtw(4) here: receiving a management
packet may, as a side-effect, reset the Rx ring, so refer to the
softc's Rx ring pointer, sc_rxptr, every time through the loop in
atw_rxintr(), instead of refering to a pointer on the stack, i.

Re-synchronize DMA after reading the OWN bit on an Rx/Tx descriptor.
XXX This needs more work.

Reset sc_tx_timer as Tx descriptors are reclaimed from the device.

Shorten staircases in atw_watchdog().

Remove from softc an unused member, sc_intr_ack.
2009-09-13 22:07:34 +00:00
pgoyette
ca6d65ecdd Use PRIu64 for printf'ing stuff. Fixes build breakage on part-amd64
introduced in rev 1.64 (and reverts a partial fix provided in rev 1.65)
2009-09-13 21:46:23 +00:00
dyoung
da6660904b Delete whitespace at ends of lines. No functional change intended. 2009-09-13 21:24:58 +00:00