Change the way options are parsed on the `#!'-line of a shell-script. Instead
of having the kernel parse that line and add an entry to the argument list for
each 'separate word' it finds, have it add only one entry which holds all
the words found on that line. The old behavior is useful in some situations,
but it does not match the way any other operating system will parse that line.
This has been discussed in the thread "Bug in #! processing - One More Time"
on the freebsd-arch mailing list (starting back on Feb 24, 2005). The first
few messages in that thread provide the background in much detail.
Robert Watson [Sat, 28 May 2005 14:34:41 +0000 (14:34 +0000)]
Explicitly acquire Giant around the ntp_gettime() and assert it in the
sysctl path. While this code is close to MPSAFE, it may require some
additional locking. Mark ntp_gettime1() as GIANT_REQUIRED for now.
Robert Watson [Sat, 28 May 2005 13:23:42 +0000 (13:23 +0000)]
Mark the following compatability system calls as MCOMPAT or MCOMPAT4 based
on the their simply wrapping MPSAFE implementations of existing MPSAFE
system calls:
Note that ogetdirentries() is not marked MPSAFE because it does not share
the MPSAFE implementation used for getdirentries(), and requires separate
locking to be implemented.
Bjoern A. Zeeb [Sat, 28 May 2005 13:15:44 +0000 (13:15 +0000)]
Fix use of uninitialized variable len in ngd_send.
Note: len gets intialized to 0 for sap == NULL case only to
make compiler on amd64 happy. This has nothing todo with the
former uninitialized use of len in sap != NULL case.
Robert Watson [Sat, 28 May 2005 12:58:54 +0000 (12:58 +0000)]
Acquire Giant explicitly in fhopen(), fhstat(), and kern_fhstatfs(),
so that we can start to eliminate the presence of non-MPSAFE system
call entries in syscalls.master.
Maksim Yevmenkin [Sat, 28 May 2005 00:48:42 +0000 (00:48 +0000)]
Move AVM USB Bluetooth-Adapter BlueFritz! from "broken" devices list
(where I incorrectly put it initially) to "ignored" devices list (where
it should be). Pointy hat goes to me.
John Baldwin [Fri, 27 May 2005 19:31:00 +0000 (19:31 +0000)]
- Add support to the loader for multiple consoles.
- Teach the i386 and pc98 loaders to honor multiple console requests from
their respective boot2 binaries so that the same console(s) are used in
both boot2 and the loader.
- Since the kernel doesn't support multiple consoles, whichever console is
listed first is treated as the "primary" console and is passed to the
kernel in the boot_howto flags.
PR: kern/66425
Submitted by: Gavin Atkinson gavin at ury dot york dot ac dot uk
MFC after: 1 week
Robert Watson [Fri, 27 May 2005 17:52:56 +0000 (17:52 +0000)]
dd a '-n' option to ministat, which causes it to display only summary
statistics, not graph and statistical test output. Useful for automated
processing.
Robert Watson [Fri, 27 May 2005 17:16:43 +0000 (17:16 +0000)]
In the current world order, each socket has two mutexes: a mutex
that protects socket and receive socket buffer state, and a second
mutex to protect send socket buffer state. In some places, the
mutex shared between the socket and receive socket buffer will be
acquired twice, once by each layer, resulting in some
inconsistency, but providing the abstraction benefit of being able
to more easily separate the two mutexes in the future if desired.
When transitioning a socket to the SS_ISDISCONNECTING or
SS_ISDISCONNECTED states, grab the socket/receive socket buffer lock
once rather than grabbing it as the socket lock, modifying socket
state, then grabbing a second time as the receive lock in order to
modify the socket buffer state to indicate no further data can be
read. This change is believed to close a race between the change in
socket state and the change in socket buffer state, which for a
remotely initiated close on a UNIX domain socket, resulted in
soreceive() returning ENOTCONN rather than an EOF condition.
A similar race still exists in the case of send, however, and is
harder to fix as the socket and send socket buffer mutexes are not
the same, and we would like to avoid holding combinations of socket
mutexes over sb_upcall until we've finished clarifying the locking
protocol for upcalls.
This change has the side affect of reducing the number of mutex
operations to initiate disconnect or perform disconnect on a
socket by two.
David Xu [Fri, 27 May 2005 15:57:27 +0000 (15:57 +0000)]
Remove thread_upcall_check, it was used to avoid race bug in earlier
day's sleep queue code, today the bug no longer exists.
please see 04/25/2004 freebsd-threads@ mailing list archive.
Robert Watson [Fri, 27 May 2005 12:25:42 +0000 (12:25 +0000)]
Back out ipx.h:1.18, which introduced a Linux API compatibility field in
the ipx_net data structure. Doing so introduced a stronger alignment
requirement for the address structure, which in turn propagated into
other dependent data structures, which turns out not to be suported by
the available IPX source code. As a result, a number of user space
applications, such as IPX routing components, failed to operate
correctly.
RELENG_5_3 candidate?
PRs: 74059, 80266
Pointy hat to: bms
Fix by: bde
Tested by: Keith White <Keith dot White at site dot uottawa dot ca>
MFC after: 1 week
Suffering: great
Fix long (and long long) to long double, unsigned to long double and unsigned
long (and unsigned long long) to long double conversions.
- Add a parameter that specifies the position of the sign bit to the _QP_TTOQ
macro, previously it always looked at bit 31. Pass a negative number to
disable sign inspection for unsigned types. This fixes _Qp_xtoq(),
_Qp_uitoq() and _Qp_uxtoq().
- In the functions __fpu_itof() and __fpu_xtof(), look at the sign bit to
decide whether we're doing a conversion from an unsigned type. If so, don't
negate the mantissa if the integer exceeds the biggest signed number.
Maxime Henrion [Fri, 27 May 2005 00:05:16 +0000 (00:05 +0000)]
Use clnt_create_timed() instead of clnt_create(). The former has an
additional argument that allows us to specify a timeout, like we do for
the subsequent clnt_call() calls.
Submitted by: Jeremie Le Hen <jeremie@le-hen.org>
MFC after: 3 weeks
Tony Ackerman [Thu, 26 May 2005 23:32:02 +0000 (23:32 +0000)]
Changes to update driver with latest Intel driver version 2.1.7
- Changed from using explicit devices id to using descriptive labels.
- Added support for 82573 and 82546 Quad adapters.
- Corrected support for 82547EI and 82541ER (mac_type was not assigned)
- Removed #ifdef DBG_STATS and extraneous code.
if_em_hw.c/if_em_hw.h
- Added support for 82573 and 82546 Quad adapters.
- Brought forward Intel's most current mac and phy changes.
Eivind Eklund [Thu, 26 May 2005 23:01:30 +0000 (23:01 +0000)]
Baby, we are not in Kansas anymore. Nor are we in 1996 or FreeBSD 2.1.
Note that these papers are mostly quite old, and add a pointer to
more recent docs.
Olivier Houchard [Thu, 26 May 2005 15:01:13 +0000 (15:01 +0000)]
Don't call vm_page_dirty() in pmap_nuke_pv(), it's not the place to do so, and
it leads to funny things, such as pmap_remove_all() marking the page as dirty.
Gleb Smirnoff [Thu, 26 May 2005 06:50:00 +0000 (06:50 +0000)]
Plug mbuf leak, that I have introduced in 1.85. Also restore important comment
from if_ethersubr.c:1.178. While here adjust formatting, to make code more
readable.
Looking just at Makefiles was slightly too narrow to catch all
"inofficial" declarations of maintainership. Grep all plain files,
and insert the actual command the list was generated with, so
future updates avoid that pitfall.
Removed sheldonh@ who just released his maintainership of ntp/doc
after I informed him of this effort.
Sheldon Hearn [Wed, 25 May 2005 16:30:43 +0000 (16:30 +0000)]
Release maintainership. More ambitious minds have plans for the ntp
docs. Last I heard, Harlan Stenn was considering using FreeBSD's
pages as a starting point for the ISC NTP distribution's own pages.
If that happens, everyone wins and these can go away, to be replaced
by imported versions in contrib/ntp.
Hartmut Brandt [Wed, 25 May 2005 16:06:14 +0000 (16:06 +0000)]
Under certain conditions the condition parser would go one past end of
the string. Until now this caused no harm, because the buffer code used
to tack two NULs onto buffers. With the new, soon to come, parsing code
this isn't the case anymore in all cases, so fix this.
Marcel Moolenaar [Wed, 25 May 2005 07:25:12 +0000 (07:25 +0000)]
For ISA DMA maps, the chipsets scatter/gather feature is used. As
such, the segments pointer in the DMA tag will always be NULL. In
bus_dmamap_load(), temporarily point the segments pointer in the
DMA tag to a local variable so that we don't dereference a NULL
pointer. Reset the segments pointer to NULL after calling the
callback function with it.
John-Mark Gurney [Tue, 24 May 2005 23:42:50 +0000 (23:42 +0000)]
make stat return an zero'd struct, and be a FIFO again... This is only
to fix libc_r since it requires stat to close fd's, and so commented in
the code...
If sysctlbyname fails for kernel related reasons, tag the errno
string to the end of the error message. I think we used errx()
there when we really wanted an err().