rpaulo [Tue, 29 Dec 2009 19:47:34 +0000 (19:47 +0000)]
iwn(4) update. Notable changes:
* new firmware
* untested support for 1000 and 6000 series
* bgscan support
* remove unnecessary RXON changes
* allow setting of country/regdomain by enforcing channel flags read
from the EEPROM
* suspend/resume fixes
* RF kill switch fixes
* LED adjustments
* several bus_dma*() related fixes
* addressed some LORs
* many other bug fixes
Submitted by: Bernhard Schmidt <bschmidt at techwires.net>
Obtained from: Brandon Gooch <jamesbrandongooch at gmail dot com> (LED
related changes), Benjamin Kaduk <kaduk at mit dot edu>
(LOR fixes), OpenBSD
marius [Tue, 29 Dec 2009 14:03:38 +0000 (14:03 +0000)]
- Prefer i and j over i and n for temporary integer variables.
- Wrap/shorten too long lines.
- Remove a redundant variable and an unnecessary cast in schizo(4).
jhb [Tue, 29 Dec 2009 13:35:18 +0000 (13:35 +0000)]
Change vlan interfaces to cope more usefully with the parent interface being
renamed. Previously the vlan interfaces would lose their configuration as if
the parent interface had been physically removed. Now vlan interfaces ignore
rename events.
- Add a new ifnet flag (IFF_RENAMING) that is set while an ifnet is being
renamed. This flag can be checked in ifnet departure/arrival event
handlers to treat rename events differently.
- Change the ifnet departure event handler in the if_vlan(4) driver to
ignore departure events due to a trunk interface being renamed.
ed [Tue, 29 Dec 2009 10:28:20 +0000 (10:28 +0000)]
Make rpc.ruserd work with utmpx/libulog.
Because strings are now null-terminated, I've decided to just use an
array of utmpx structures, instead of the separated strings. This means
we just copy the entire utmpx structure and point to the strings within
the structures directly.
kientzle [Tue, 29 Dec 2009 06:34:23 +0000 (06:34 +0000)]
Essentially eliminate problems with false hardlinks in POSIX cpio
archives by generating synthetic ino values and mapping values
from disk into the new values.
kientzle [Tue, 29 Dec 2009 06:06:20 +0000 (06:06 +0000)]
If we're linking against liblzma, allow the decompressor to use up to
1<<30 bytes of memory, which is required for some streams.
Also, try to make the taster more discriminating about raw lzma streams.
The detection here is still really weak, though; please use xz instead
of lzma.
kientzle [Tue, 29 Dec 2009 05:47:46 +0000 (05:47 +0000)]
Style and portability fixes for pax writer. Mostly very routine, except for:
* Use ino64 where appropriate
* Don't pass atime or nsec to ustar formatter
kientzle [Tue, 29 Dec 2009 05:44:39 +0000 (05:44 +0000)]
Style fixes to tar reader:
For portability, prefer int64_t to off_t.
Improve numeric overflow handling when parsing.
Fix some variable types.
Eliminate some unused results.
kientzle [Tue, 29 Dec 2009 05:41:57 +0000 (05:41 +0000)]
Various style fixes to the 'newc' cpio writer:
* Warn about truncation of ino
* Use a macro to hide the somewhat obscure pad-to-multiple-of-4 calculation
* Eliminate some unused variables
kientzle [Tue, 29 Dec 2009 05:35:40 +0000 (05:35 +0000)]
Various fixes when creating objects on disk:
* Write xattrs last instead of first (required on platforms that use
system xattrs for security attributes)
* Better handling of chdir() failures
* Don't bother trying to shorten files via seek()/write()
* Fix build on systems that lack link()/symlink()/mknod()
* Prefer futimens()/utimensat() when they're present
kientzle [Tue, 29 Dec 2009 05:28:28 +0000 (05:28 +0000)]
Various style and portability fixes, including:
* Enforce option interface can only be used before the archive is opened
* Correctly handle large skips on platforms with 32-bit off_t
* Use int64_t instead of off_t
antoine [Mon, 28 Dec 2009 22:56:30 +0000 (22:56 +0000)]
(S)LIST_HEAD_INITIALIZER takes a (S)LIST_HEAD as an argument.
Fix some wrong usages.
Note: this does not affect generated binaries as this argument is not used.
bz [Mon, 28 Dec 2009 21:14:18 +0000 (21:14 +0000)]
Make the compiler happy after r201125:
- + remove two unnecessary initializations in ip_output;
+ + remove one unnecessary initializations in ip_output;
ed [Mon, 28 Dec 2009 20:54:34 +0000 (20:54 +0000)]
Migrate finger(1) away from <utmp.h>.
Unfortunately it also uses lastlog, which means we must resort to local
extensions of the utmpx-interface. Because the user name and TTY name
are now nul-terminated, there is no need to copy around strings as
often.
mav [Mon, 28 Dec 2009 20:08:01 +0000 (20:08 +0000)]
Add BIO_DELETE support to ada(4):
- For SSDs use TRIM feature of DATA SET MANAGEMENT command, as defined by
ACS-2 specification working draft.
- For CompactFlash use CFA ERASE command, same as ad(4) does.
With this patch, `newfs -E /dev/ada1` was able to restore write speed of
my heavily weared OCZ Vertex SSD (firmware 1.4) up to the initial level
for the most part of it's capacity. Previous 1.3 firmware, even reportiong
TRIM capabilty bit set, was not working, reporting ABORT error for every
DSM command.
I have no idea whether it is normal, but for some reason it takes 200ms
to handle any TRIM command on this drive, that was making delete extremely
slow. But TRIM command is able to accept long list of LBAs and the length of
that list seems doesn't affect it's execution time. Implemented request
clusting algorithm allowed me to rise delete rate up to reasonable numbers,
when many parallel DELETE requests running.
gibbs [Mon, 28 Dec 2009 18:59:13 +0000 (18:59 +0000)]
Correct alignment and boundary constraints in blkfront's bus dma tag. The
blkif interface in Xen requires all I/O to be 512 byte aligned with each
segment bounded by a 4k page.
Note: This submission only documents the proper contraints for blkif I/O.
The alignment code in busdma does not yet handle alignment constraints
correctly in all cases.
delphij [Mon, 28 Dec 2009 17:57:37 +0000 (17:57 +0000)]
Make umount(8) WARNS=6 clean:
- Cast delimiter width to integer [1]
- Solve name conflicts against system header
- Constify parameters to avoid qualifier conflict
kib [Mon, 28 Dec 2009 15:35:39 +0000 (15:35 +0000)]
Add a knob to allow reclaim of the directory vnodes that are source of
the namecache records. The reclamation is not enabled by default because
for typical workload it would make namecache unusable, but large nested
directory tree easily puts any process that accesses filesystem into 1
second wait for vlru.
Reported by: yar (long time ago)
MFC after: 3 days
luigi [Mon, 28 Dec 2009 14:48:32 +0000 (14:48 +0000)]
introduce a local variable rte acting as a cache of ro->ro_rt
within ip_output, achieving (in random order of importance):
- a reduction of the number of 'r's in the source code;
- improved legibility;
- a reduction of 64 bytes in the .text
luigi [Mon, 28 Dec 2009 14:09:46 +0000 (14:09 +0000)]
+ remove an unused #define print_ip;
+ remove two unnecessary initializations in ip_output;
+ localize 'len';
+ introduce a temporary variable n to count the number of fragments,
the compiler seems unable to identify a common subexpression
(written 3 times, used twice);
+ document some assumptions on ip_len and ip_hl
luigi [Mon, 28 Dec 2009 10:47:04 +0000 (10:47 +0000)]
bring in several cleanups tested in ipfw3-head branch, namely:
r201011
- move most of ng_ipfw.h into ip_fw_private.h, as this code is
ipfw-specific. This removes a dependency on ng_ipfw.h from some files.
- move many equivalent definitions of direction (IN, OUT) for
reinjected packets into ip_fw_private.h
- document the structure of the packet tags used for dummynet
and netgraph;
r201049
- merge some common code to attach/detach hooks into
a single function.
r201055
- remove some duplicated code in ip_fw_pfil. The input
and output processing uses almost exactly the same code so
there is no need to use two separate hooks.
ip_fw_pfil.o goes from 2096 to 1382 bytes of .text
r201057 (see the svn log for full details)
- macros to make the conversion of ip_len and ip_off
between host and network format more explicit
r201113 (the remaining parts)
- readability fixes -- put braces around some large for() blocks,
localize variables so the compiler does not think they are uninitialized,
do not insist on precise allocation size if we have more than we need.
r201119
- when doing a lookup, keys must be in big endian format because
this is what the radix code expects (this fixes a bug in the
recently-introduced 'lookup' option)
kientzle [Mon, 28 Dec 2009 02:20:23 +0000 (02:20 +0000)]
Portability: terminate abnormally via abort() instead of segfault,
watch the return value from write(), and avoid signed arithmetic on
unsigned values.