csjp [Tue, 24 Jan 2006 04:05:47 +0000 (04:05 +0000)]
MFC revision 1.28
date: 2006/01/15 20:30:13; author: csjp; state: Exp; lines: +5 -0
Validate that the supplied file is not empty before trying mmap(2) it
and access the pages associated with it.
marius [Mon, 23 Jan 2006 16:32:29 +0000 (16:32 +0000)]
Revert the hack introduced in rev. 1.6.2.1, a fix/workaround for the
underlying problem was committed in sys/sparc64/pci/psycho.c 1.55 and
MFC'ed to RELENG_6 in 1.53.2.1.
Sync psycho(4) with HEAD expect for the UPA_RANGE_* -> OFW_PCI_RANGE_*
and PCI_CS_* -> OFW_PCI_CS_* changes in order to mainly obtain the
following changes:
- Add a workaround for the incorrect interrupt map entry for the EBus
bridge on E250 machines. [1]
- Register an interrupt handler for the spare hardware interrupt which
according to OpenSolaris is used as the over-temperature interrupt in
systems with Psycho bridges.
Use <sys/ktr.h> directly in .S files instead of exporting the
KTR_* class macros via genassym.c. Together with sys/sys/ktr.h 1.34
(MFC'ed in 1.32.2.2) this has the desired side-effect of providing a
default value for KTR_COMPILE. Thus this fixes warnings from -Wundef
regarding KTR_COMPILE not being defined for .S files.
marius [Mon, 23 Jan 2006 14:56:33 +0000 (14:56 +0000)]
MFC: 1.34
Extend the scope of #ifndef LOCORE to also cover the prototype of
ktr_tracepoint() and the macros using it. This allows this header
to be included in .S files for obtaining the KTR_* class macros
directly and providing a default value for KTR_COMPILE in case it's
not specified in the kernel config file including defining it to 0
when not using 'options KTR' at all.
marius [Mon, 23 Jan 2006 14:45:24 +0000 (14:45 +0000)]
MFC: 1.3
- The inline asm in this file uses output operands before all input
operands are consumed so use the appropriate constraint modifier.
Before this change GCC used one register for both an input and an
unrelated output operand of in_addword(), causing the input to be
overwritten before it was consumed and thus breaking in_addword().
For in_cksum_hdr() and in_pseudo() this change is more or less
cosmetic.
- Fix a misspelling in a nearby comment.
marius [Mon, 23 Jan 2006 14:33:53 +0000 (14:33 +0000)]
MFC: 1.26
In moduledir_readhints() cast the value returned by sizeof() to ssize_t
when checking whether it's greater than a struct stat st_size in order
to also catch the case when st_size is -1. Previously this check didn't
trigger on sparc64 when st_size is -1 (as it's the case for a file on
a bzipfs, TFTP server etc.), causing the content of the linker hints
file to be copied to memory referenced by a null-pointer.
yar [Sun, 22 Jan 2006 19:22:53 +0000 (19:22 +0000)]
MFC rev. 1.9, 1.10:
Use a callback to set up a vlan interface so that "vlan"
and "vlandev" commands can be specified in any order.
This makes the code more compact and clear as well.
dds [Sun, 22 Jan 2006 13:52:10 +0000 (13:52 +0000)]
MFC: Return EINVAL if the tv_usec part of the utimes(2) arguments
contains incorrect fractional second values (outside the range
0-999999).
Prior to this change users could create files with values outside
that range. Moreover, on 32-bit machines tv_usec offsets larger than
4.3s would result in an unnormalized AND wrong timestamp value,
due to overflow.
yar [Sat, 21 Jan 2006 22:09:32 +0000 (22:09 +0000)]
MFC r1.12 -- back out r1.7.2.2.
As rse@ agreed, "status" should stay in $extra_commands
if an rc.d script doesn't use $command and default methods
associated with it. This is true since rc.subr r1.42.
With r1.42 merged to rc.subr on RELENG_6 (thanks Doug!),
it's right time to re-add "status" to $extra_commands in
this script.
glebius [Sat, 21 Jan 2006 10:09:18 +0000 (10:09 +0000)]
MFC 1.18:
When sending export datagram from interrupt thread, use NG_QUEUE
in flags. When sending export datagram from expiry thread, then
use default zero flags. This removes unpleasant contention of the
interrupt thread on mutexes (usually ng_ksocket's socket buffer
mutex).
glebius [Sat, 21 Jan 2006 10:07:25 +0000 (10:07 +0000)]
MFC 1.58:
Do not force queueing on peer hooks. This was important only for
5.0-CURRENT. And it looks like this didn't work before Julian's
revamp of netgraph queue code.
glebius [Sat, 21 Jan 2006 10:00:51 +0000 (10:00 +0000)]
MFC 1.65:
Provide additional macros for sending netgraph items, which allow
to use non-default flags for netgraph functions. Implement current
macros via new ones.
cperciva [Sat, 21 Jan 2006 09:59:07 +0000 (09:59 +0000)]
MFC rev. 1.3:
Add a warning pointing out that incomplete ports trees are not
supported and that users of REFUSE directives should update their
entire ports tree before asking for help on the mailing lists.
mux [Fri, 20 Jan 2006 22:55:45 +0000 (22:55 +0000)]
MFC ugraphire_rdesc.h r1.3, uhid.c r1.80, usbdevs r1.245:
Add support for the Wacom Graphire 3 4x5. Like the Graphire 3, it has a
broken report descriptor. While I'm here, make all the other report
descriptors const to match the newly added one.
mux [Fri, 20 Jan 2006 22:47:49 +0000 (22:47 +0000)]
MFC uhid.c r1.79, usb.h r1.40, uxb360gp_rdesc.h r1.1:
Add support for Xbox 360 gamepads. They are HID-capable devices, but
lack a report descriptor and don't use the standard interface class.
This patch works around these deficiencies so that the uhid(4) driver
can recognize and use those broken devices.
ceri [Fri, 20 Jan 2006 13:00:32 +0000 (13:00 +0000)]
MFC revisions 1.36 and 1.37:
r1.36:
Correct obsolete chown syntax.
r1.37:
If sysinstall was used to configure an anonymous FTP area, it
was possible for information to be copied from the group file to
the group file in the FTP area. This patch based on a patch
from Zak Johnson <zakj at nox dot cx>.
ariff [Fri, 20 Jan 2006 03:55:58 +0000 (03:55 +0000)]
MFC:
- Workaround for sb16 behave poorly when running at 45000 hz while
vchan is enabled.
Ruthless vchan speed workaround against the dreaded sb16 / sb16x.
It appear that nothing else using this weird 45k / 49k speed upper
limit.
- Raise VCHAN_DEFAULT_SPEED from 44100 to 48000.
glebius [Thu, 19 Jan 2006 13:36:26 +0000 (13:36 +0000)]
Sync driver with HEAD merging all revisions from 1.96 to 1.115. The most
markable changes are:
o Suspend/resume methods.
o Link state detection fixes.
o Utilization of jumbo allocator and extended RX descriptors.
o busdma(9) cleanup and support for big-endian architectures.
o Improved checksum offloading support.
o Reduced number of PCI register writes in bge_start().
o Counting RX/TX errors as input/output interface errors.
ariff [Wed, 18 Jan 2006 01:05:34 +0000 (01:05 +0000)]
MFC:
- Locking fixes. Release lock while chn_intr().
- Mark MPSAFE since most of the locking procedures already implemented.
- Turn on inverted external amplifier sense flag for selected boards.
pjd [Tue, 17 Jan 2006 10:19:37 +0000 (10:19 +0000)]
MFC: sys/kern/kern_malloc.c 1.150
In realloc(9), determine size of the original block based on
UMA_SLAB_MALLOC flag.
In some circumstances (I observed it when I was doing a lot of reallocs)
UMA_SLAB_MALLOC can be set even if us_keg != NULL.
If this is the case we have wonderful, silent data corruption, because less
data is copied to the newly allocated region than should be.
dougb [Tue, 17 Jan 2006 06:45:05 +0000 (06:45 +0000)]
MFC ntpd 1.12 and ntpdate 1.14 - use of REQUIRE rather than BEFORE,
MFC ntpd 1.12 - REQUIRE devfs to help users with serial GPS interfaces
MFC ntpdate 1.15 - REQUIRE named
flz [Mon, 16 Jan 2006 19:51:41 +0000 (19:51 +0000)]
MFC:
Add -K option to pkg_add and pkg_info.
This option saves packages to PKGDIR (if defined or current directory by default)
as they are downloaded.
Silent a warning when -n is used and package has a +DISPLAY file.