sam [Sat, 22 Jan 2005 20:12:05 +0000 (20:12 +0000)]
o replace out-of-line copy of FCS w/ a flag that indicates the
frame includes FCS (requires applications to be updated, but since
we weren't doing the out-of-line FCS stuff anyway app changes
were needed already)
o add a flag to indicate padding exists between the 802.11 header and
the payload (e.g. for Atheros cards)
o diff reducation against netbsd
pjd [Sat, 22 Jan 2005 19:56:03 +0000 (19:56 +0000)]
- Don't destroy UMA zone on error in mdcreate_malloc(), because we need it
in mddestroy() to properly free already allocated memory.
This fixes a panic when we want to create too big memory backed device
with preallocate memory (-o reserve).
- Remove redundant { }.
delphij [Sat, 22 Jan 2005 19:35:48 +0000 (19:35 +0000)]
Make sure that we don't define INET6 when NO_INET6 is defined.
Without this change, when running netstat with a kernel without
INET6 built in, you will get a complain at the end of "netstat -s"
output.
das [Sat, 22 Jan 2005 06:03:40 +0000 (06:03 +0000)]
Replace the ldexp() implementation in libc with a renamed copy of the
scalbn() implementation from libm. (The two functions are defined to
be identical, but ldexp() lives in libc for backwards compatibility.)
The old ldexp() implementation...
- was more complicated than this one
- set errno instead of raising FP exceptions
- got some corner cases wrong
(e.g. ldexp(1.0, 2000) in round-to-zero mode)
The new implementation lives in libc/gen instead of
libc/$MACHINE_ARCH/gen, since we don't need N copies of a
machine-independent file. The amd64 and i386 platforms
retain their fast and correct MD implementations and
override this one.
wes [Fri, 21 Jan 2005 22:20:25 +0000 (22:20 +0000)]
Add an option to suppress the creation of the .snap directory in
the new filesystem. This is intended for memory and vnode filesystems
that will never be fsck'ed or dumped.
Obtained from: St. Bernard Software RAPID
MFC after: 2 weeks
wes [Fri, 21 Jan 2005 22:13:25 +0000 (22:13 +0000)]
Improved error checking for existence of a .snap directory to
generate snapshots in when -L is requested. If the .snap directory
does not exist, or is not a directory, issue a warning and revert
to the non- live behavior.
imp [Fri, 21 Jan 2005 19:51:23 +0000 (19:51 +0000)]
we don't need the offset in the attr memory to get the ethernet
address, nor do we need the alignment requirements, so eliminate them.
This likely means that we can now collapse some of the entries as we
have no need of them anymore (they match other entries and were there
only to get the right attr memory offset of the enet addr).
bmilekic [Fri, 21 Jan 2005 18:09:17 +0000 (18:09 +0000)]
Bring in MemGuard, a very simple and small replacement allocator
designed to help detect tamper-after-free scenarios, a problem more
and more common and likely with multithreaded kernels where race
conditions are more prevalent.
Currently MemGuard can only take over malloc()/realloc()/free() for
particular (a) malloc type(s) and the code brought in with this
change manually instruments it to take over M_SUBPROC allocations
as an example. If you are planning to use it, for now you must:
1) Put "options DEBUG_MEMGUARD" in your kernel config.
2) Edit src/sys/kern/kern_malloc.c manually, look for
"XXX CHANGEME" and replace the M_SUBPROC comparison with
the appropriate malloc type (this might require additional
but small/simple code modification if, say, the malloc type
is declared out of scope).
3) Build and install your kernel. Tune vm.memguard_divisor
boot-time tunable which is used to scale how much of kmem_map
you want to allott for MemGuard's use. The default is 10,
so kmem_size/10.
ToDo:
1) Bring in a memguard(9) man page.
2) Better instrumentation (e.g., boot-time) of MemGuard taking
over malloc types.
3) Teach UMA about MemGuard to allow MemGuard to override zone
allocations too.
4) Improve MemGuard if necessary.
This work is partly based on some old patches from Ian Dowse.
bms [Fri, 21 Jan 2005 17:11:38 +0000 (17:11 +0000)]
If a device resides in physical slot 0, report it as being on-board as
per PIR specification.
Add the VIA VT82C686 PCI interrupt routing function as a known chipset.
bms [Fri, 21 Jan 2005 16:15:24 +0000 (16:15 +0000)]
Do not treat an invalid PIR table checksum as a fatal error condition, but
do print a warning about it.
Correct a stupid logic error.
Update copyrights. Fix whitespace bug.
imp [Fri, 21 Jan 2005 02:14:40 +0000 (02:14 +0000)]
Rework pccard attachment a little. Now both of my fe based ethernet
cards work. These changes depend on the expanded funce parsing that
just was committed to pccard_cis.c. In NetBSD the ethernet address
was read out of attr memory directly. We rely on the kernel pccard
parser to pulll this information out of what appears to be an obsolete
funce with the information in it.
# I'm still getting the no rx interrupt sometimes with some hub/switches
# for reasons unknown... But usually only one and only when dhclient
# runs.
imp [Fri, 21 Jan 2005 02:11:48 +0000 (02:11 +0000)]
Some older PC Cards have a weird format for FUNCE tuples. They appear
as type 0, rather than the usualy type 4. Assume that this format is
from an old standard and go with it. The Fujitsu FMV-186A and Silicom
Ethernet cards I have both have tuples with this format, and they are
both pretty old cards.
pjd [Thu, 20 Jan 2005 22:14:05 +0000 (22:14 +0000)]
Protect against recursive slices creation in simlar way as it is done
in BSD class, ie. if provider below us uses the same metadata, don't
create slices based on the metadata.
This allows to create slices on geoms with rank != 1 without hacks.
imp [Thu, 20 Jan 2005 20:08:18 +0000 (20:08 +0000)]
Only attach to network functions. This should be a nop since I'm not
aware of any fe based cards that do anything except network (well,
maybe the fujitsu scsi/lan card, but I've only seen two of those on
ebay in the last 3 years).
imp [Thu, 20 Jan 2005 20:03:37 +0000 (20:03 +0000)]
Only match ethernet functions. I've not seen any multifunction cards
(from a PC Card sense), so this should be a nop. The
pseudo-multifunction cards (eg Silicom ones) need a special driver
anyway..
imp [Thu, 20 Jan 2005 19:59:31 +0000 (19:59 +0000)]
Only attach to network functions. I'm not aware of any multifunction
(pccard sense) sn based cards, but this won't hurt. The
pseudo-multifunction cards need a special driver anyway...
dhartmei [Thu, 20 Jan 2005 18:07:35 +0000 (18:07 +0000)]
Use the packet's address family instead of the rule's when selecting a
replacement address for an rdr rule. Some rdr rules have no address family
(when the replacement is a table and no other criterion implies one AF).
In this case, pf would fail to select a replacement address and drop the
packet due to translation failure.
imp [Thu, 20 Jan 2005 17:27:37 +0000 (17:27 +0000)]
Mask off the upper bits of the resource before using it as an index
into a small array. Also, re-save the dev in attach to avoid
depending on side effects of the probe.
bms [Thu, 20 Jan 2005 15:40:50 +0000 (15:40 +0000)]
Add device description for the Dell Remote Access Card (DRAC) III and IV
virtual COM port. This makes the use of the Dell OpenManage tools on FreeBSD
considerably easier, and is based on Chuck Cranor's original patch for 4.6.
Reviewed by: imp
Tested by: dpk at dpk dot net
MFC after: 1 week
marius [Thu, 20 Jan 2005 13:29:31 +0000 (13:29 +0000)]
At least on some U30 there's a spurious duplicate device node of an EBus
bridge in the device tree which lacks the mandatory (also by the OFW PCI
bus binding spec) "reg" property. Change the code to just ignore nodes
missing the "reg" property instead of panicing when encountering such a
node. Also ignore nodes without a "name" property (guaranteed by the OFW
PCI bus binding spec). This brings the behaviour of the MD OFW PCI code
regarding such incomplete nodes in line with the EBus and the SBus code.
ru [Thu, 20 Jan 2005 10:49:03 +0000 (10:49 +0000)]
In crunchgen(1), when calling make(1), don't redirect stderr to stdout,
just rely on the exit status to detect an error. This makes crunchgen(1)
safe to use with certain make(1) debugging flags.
ru [Thu, 20 Jan 2005 10:43:43 +0000 (10:43 +0000)]
Ignoring MAKEFLAGS in rev. 1.15 was a very bad idea. This causes
wrong share/mk files to be used, which can be fatal with upgrades
or downgrades, e.g., when building RELENG_5 on HEAD.
Reported by: glebius
For now, just exclude -P from MAKEFLAGS when running crunchgen(1).
(Note that it will still break when run with certain -d options.)
The real solution is to fix make(1) to not print stuff on stdout
when it's not supposed to, e.g., through the -P and -dX options,
and to fix crunchgen(1) to not redirect stderr to stdout when
running make(1). Once this is implemented, this hack can go.
wes [Thu, 20 Jan 2005 05:43:24 +0000 (05:43 +0000)]
Provide a WITHOUT_MODULES variable that specifies a list of modules
to elide. This is a somewhat more convenient way of specifying in
e.g. make.conf a list of modules you know you will never need.