]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
18 years agoAfter going to some trouble to create a temporary directory in which to run
rwatson [Sun, 11 Sep 2005 17:41:32 +0000 (17:41 +0000)]
After going to some trouble to create a temporary directory in which to run
fifo tests, chdir to it.

18 years agoFix hang at init for MagicMedia 256A[VX] chips. [1]
netchild [Sun, 11 Sep 2005 17:30:27 +0000 (17:30 +0000)]
Fix hang at init for MagicMedia 256A[VX] chips. [1]

In case this causes trouble for some other chipsets add a comment how to
proceed. If we don't get bugreports, this should be removed after a while
(some releases?).

PR: 56617 [1], 29465, 39260, 40574, 68225
Submitted by: Matthew E. Gove <mgove@comcast.net> [1]

18 years agoThe arguments for time2posix() and posix2time() are time_t values, not
stefanf [Sun, 11 Sep 2005 17:09:50 +0000 (17:09 +0000)]
The arguments for time2posix() and posix2time() are time_t values, not
pointers.

18 years agoForward declare z_errmsg with static linkage since it is defined
rodrigc [Sun, 11 Sep 2005 16:13:02 +0000 (16:13 +0000)]
Forward declare z_errmsg with static linkage since it is defined
with static linkage later in the file.  Eliminates GCC 4.0 error.

18 years agoForward declare atalkdomain with static linkage, not extern, since
rodrigc [Sun, 11 Sep 2005 16:04:56 +0000 (16:04 +0000)]
Forward declare atalkdomain with static linkage, not extern, since
it is defined with static linkage later in the file.  Eliminates
GCC 4.0 error.

18 years agoCast bf_sysid to const char * when passing it to strncmp(), because
rodrigc [Sun, 11 Sep 2005 16:02:14 +0000 (16:02 +0000)]
Cast bf_sysid to const char * when passing it to strncmp(), because
strncmp does not take an unsigned char *.  Eliminates warning with GCC 4.0.

18 years agoDo not declare M_NTFSMNT with extern linkage here, since
rodrigc [Sun, 11 Sep 2005 15:57:07 +0000 (15:57 +0000)]
Do not declare M_NTFSMNT with extern linkage here, since
it is defined with static linkage in ntfs_vfsops.c.
Fixes compilation with GCC 4.0.

18 years agoA new version of rev. 1.4: postpone a temporary file creation
maxim [Sun, 11 Sep 2005 14:29:58 +0000 (14:29 +0000)]
A new version of rev. 1.4: postpone a temporary file creation
until we realize if ipfw(4) ever used.

PR: bin/85970
Submitted by: Andre Albsmeier
MFC after: 3 days

18 years agoPower up the external amplifiers additionally to powering up the DAC and ADC.
netchild [Sun, 11 Sep 2005 14:15:05 +0000 (14:15 +0000)]
Power up the external amplifiers additionally to powering up the DAC and ADC.

PR: 47029
Submitted by: Anish Mistry <mistry.7@osu.edu>
Tested by: David Murphy <dm@dmz.ie>

18 years agoAdd some ad_wait_init() calls to fix some problems in some configs (e.g.
netchild [Sun, 11 Sep 2005 13:59:02 +0000 (13:59 +0000)]
Add some ad_wait_init() calls to fix some problems in some configs (e.g.
PC98, CS4231A, "pcm0: play interrupt timeout").

PR: 45682
Submitted by: Watanabe Kazuhiro <CQG00620@nifty.ne.jp>

18 years agoAllow to record non 8bit-mono formats even in half-duplex configurations.
netchild [Sun, 11 Sep 2005 13:49:24 +0000 (13:49 +0000)]
Allow to record non 8bit-mono formats even in half-duplex configurations.

PR: 45679
Submitted by: Watanabe Kazuhiro <CQG00620@nifty.ne.jp>

18 years agoAdd fifo_open, a basic regression test for opening fifos, which tests
rwatson [Sun, 11 Sep 2005 13:03:36 +0000 (13:03 +0000)]
Add fifo_open, a basic regression test for opening fifos, which tests
the blocking and non-blocking forms of open based on the POSIX spec for
now O_NONBLOCK should be handled.

18 years agoFix typo: ${PORTDIR} -> ${PORTSDIR}.
cperciva [Sun, 11 Sep 2005 12:55:07 +0000 (12:55 +0000)]
Fix typo: ${PORTDIR} -> ${PORTSDIR}.

Apologies to everyone who has run portsnap in 7.0-CURRENT since
Tuesday; if there is a file "/.portsnap.INDEX" on your system, you can
delete it (or even better, move it to /usr/ports/.portsnap.INDEX).

Big pointy hat to: cperciva
Reported that things weren't working properly: Aleksander Fafula

18 years agoDo not destroy the queue mutex until the thread is done with it.
phk [Sun, 11 Sep 2005 12:35:32 +0000 (12:35 +0000)]
Do not destroy the queue mutex until the thread is done with it.

18 years agoStop leaking a lock. This used to cause a propagate_priority() page fault
mlaier [Sun, 11 Sep 2005 11:55:39 +0000 (11:55 +0000)]
Stop leaking a lock.  This used to cause a propagate_priority() page fault
when setting syncdev and syncpeer.

Reported by: Dominic Marks

18 years agoFix misdetection of the sound chip on PC98 systems. The submitter doesn't
netchild [Sun, 11 Sep 2005 10:07:12 +0000 (10:07 +0000)]
Fix misdetection of the sound chip on PC98 systems. The submitter doesn't
believe that there are PC98 systems with an OPTi chip.

I don't know enough about this special PC architecture to be sure about
this, so let's find out by letting people with such a system complain in
case this commit breaks the sound system for them. It's easy to revert
then.

PR: 45673
Submitted by: Watanabe Kazuhiro <CQG00620@nifty.ne.jp>

18 years agoFix a bug in volume calculation, this sometimes gives a USB audio device an
netchild [Sun, 11 Sep 2005 09:15:42 +0000 (09:15 +0000)]
Fix a bug in volume calculation, this sometimes gives a USB audio device an
unexpected value (when the volume is high).

Submitted by: Kazuhito HONDA <kazuhito@ph.noda.tus.ac.jp>

18 years agoRelocate witness_levelall(), witness_leveldescendents(), and
truckman [Sun, 11 Sep 2005 07:57:06 +0000 (07:57 +0000)]
Relocate witness_levelall(), witness_leveldescendents(), and
witness_displaydescendants() so that they are protected by
"#ifdef DDB/#endif" to unbreak kernels not using "option DDB".

MFC after: 3 weeks

18 years agoThe kernel-depend target doesn't get any information from "compile-with",
obrien [Sun, 11 Sep 2005 07:33:43 +0000 (07:33 +0000)]
The kernel-depend target doesn't get any information from "compile-with",
so repeat the includes paths for that target.

18 years agoClaim frames corresponding to tl(0|1)_intr and tl0_trap as well. I
marcel [Sun, 11 Sep 2005 06:52:14 +0000 (06:52 +0000)]
Claim frames corresponding to tl(0|1)_intr and tl0_trap as well.  I
think that's the lot, but it's hard to understand the exception code
by mere glancing at it.

MFC after: 1 week

18 years agoUnwind across intrframes as well. While here, better handle bottom of
marcel [Sun, 11 Sep 2005 05:55:24 +0000 (05:55 +0000)]
Unwind across intrframes as well. While here, better handle bottom of
stack by claiming the frame when the IP is 0. It's a bit of a kluge,
but avoids screens full of bogus frames.

MFC after: 1 week

18 years agoUnwind across intrframes as well.
marcel [Sun, 11 Sep 2005 05:36:30 +0000 (05:36 +0000)]
Unwind across intrframes as well.

MFC after: 1 week

18 years agoChange hw.pci.do_powerstate from a boolean to a range. 0 means the
imp [Sun, 11 Sep 2005 04:09:44 +0000 (04:09 +0000)]
Change hw.pci.do_powerstate from a boolean to a range.  0 means the
same as today: do no power management.  1 means be conservative about
what you power down (any device class that has caused problems gets
added here).  2 means be agressive about what gets powered down (any
device class that's fundamental to the system is here).  3 means power
them all down, reguardless.  The default is 1.

The effect in the default system is to add mass storage devices to the
list that we don't power down.  From all the pciconf -l lists that
I've seen for the aac and amr issue, the bad device has been a mass
storage device class.

This is an attempt at a compromise between the very small number of
systems that have extreme issues with powerdown, and the very large
number of systems that gain real benefits from powerdown (I get about
20% more battery life when I attach a minimal set of drivers on my
Sony).  Hopefully it will strike the proper balance.

MFC After: 3 days (before next beta)

18 years agoDon't pollute the entire kernel build with -I$S/contrib/dev/ath and
obrien [Sun, 11 Sep 2005 03:38:18 +0000 (03:38 +0000)]
Don't pollute the entire kernel build with -I$S/contrib/dev/ath and
-I$S/contrib/dev/ath/freebsd.  "ATH_BUILDING_FROM_SOURCE" can be defined to
globally get back -I$S/contrib/dev/ath.

18 years agoAllow one to access the cached values for CMDREG, CACHELNSZ, MINGNT,
imp [Sun, 11 Sep 2005 03:22:03 +0000 (03:22 +0000)]
Allow one to access the cached values for CMDREG, CACHELNSZ, MINGNT,
MAXLAT and LATTIMER.

Improve error message when a bogus RID type is requested for a bar.

18 years agoDon't pollute the entire kernel build with -I$S/contrib/ipfilter.
obrien [Sun, 11 Sep 2005 02:27:34 +0000 (02:27 +0000)]
Don't pollute the entire kernel build with -I$S/contrib/ipfilter.

18 years agoDon't pollute the entire kernel build with -I$S/contrib/pf.
obrien [Sun, 11 Sep 2005 02:04:04 +0000 (02:04 +0000)]
Don't pollute the entire kernel build with -I$S/contrib/pf.

18 years agoDon't pollute the entire kernel build with -I$S/contrib/ngatm.
obrien [Sun, 11 Sep 2005 01:28:05 +0000 (01:28 +0000)]
Don't pollute the entire kernel build with -I$S/contrib/ngatm.

18 years agoDon't pollute the entire kernel build with -I$S/dev/twa.
obrien [Sun, 11 Sep 2005 00:52:05 +0000 (00:52 +0000)]
Don't pollute the entire kernel build with -I$S/dev/twa.

18 years agoUnwind across trap frames. Handles all entry points, except the EPC
marcel [Sun, 11 Sep 2005 00:47:03 +0000 (00:47 +0000)]
Unwind across trap frames. Handles all entry points, except the EPC
syscall. This is an entry from userland anyway.

MFC after: 1 week

18 years agoFor HEAD, install a kernel with debug information if DEBUG is a kernel
obrien [Sun, 11 Sep 2005 00:22:21 +0000 (00:22 +0000)]
For HEAD, install a kernel with debug information if DEBUG is a kernel
config option.  It is too easy to loose the build directory and not have
symbols for kgdb to read.

18 years agoUnwind across trapframes. All kernel entries are handled.
marcel [Sat, 10 Sep 2005 23:11:54 +0000 (23:11 +0000)]
Unwind across trapframes. All kernel entries are handled.

MFC after: 1 week

18 years agoStyle issue: Don't include <wchar.h> where it is not actually needed.
kientzle [Sat, 10 Sep 2005 22:58:06 +0000 (22:58 +0000)]
Style issue:  Don't include <wchar.h> where it is not actually needed.
(wchar_t is defined in stddef.h, and only two files need more than that.)

Portability:  Since the wchar requirements are really quite modest,
it's easy to define basic replacements for wcslen, wcscmp, wcscpy,
etc, for use on systems that lack <wchar.h>.  In particular, this allows
libarchive to be used on older OpenBSD systems.

18 years agoComment out ofw_console 'screen' entry and zs tty entries.
grehan [Sat, 10 Sep 2005 22:46:03 +0000 (22:46 +0000)]
Comment out ofw_console 'screen' entry and zs tty entries.
The OpenFirmware console isn't used on real systems anymore and
I never get to multi-user mode in psim. There are problems with
zs that need to be resolved before these lines can be enabled.

This eliminates disconcerting warnings on boot.

MFC after: 2 days

18 years agoUnwind across trap frames. This adds most of the meat. The sniffer
marcel [Sat, 10 Sep 2005 22:03:09 +0000 (22:03 +0000)]
Unwind across trap frames. This adds most of the meat. The sniffer
just needs to be taught about all the other entry points and the
unwinder needs to be taught about the frame variation between them.

MFC after: 1 week

18 years agoIn ext2_mountfs(), check that the superblock size, SBSIZE,
rodrigc [Sat, 10 Sep 2005 21:30:49 +0000 (21:30 +0000)]
In ext2_mountfs(), check that the superblock size, SBSIZE,
is aligned with the sectorsize value returned by GEOM, before
doing a bread() of the superblock.
This eliminates a panic when trying the following on an empty CD-ROM drive:
mount_ext2fs /dev/acd0 /mnt

Reviewed by: phk

18 years agoAdd fifo_create, a simple regression test for mkfifo(2).
rwatson [Sat, 10 Sep 2005 21:09:26 +0000 (21:09 +0000)]
Add fifo_create, a simple regression test for mkfifo(2).

18 years agoFix boot-time hang/panic on G3 systems when modifying IBAT0 in
grehan [Sat, 10 Sep 2005 21:03:10 +0000 (21:03 +0000)]
Fix boot-time hang/panic on G3 systems when modifying IBAT0 in
pmap_bootstrap by using the sync;isync big hammer to make sure
all prior operations have completed.

Reported by: Nathan Whitehorn <nathan at uchicago edu>
MFC after: 2 days

18 years agoUnwind across trap frames. This adds most of the meat. The sniffer
marcel [Sat, 10 Sep 2005 21:01:36 +0000 (21:01 +0000)]
Unwind across trap frames. This adds most of the meat. The sniffer
just needs to be taught about all the other entry points and the
unwinder needs to be taught about the frame variation between them.

MFC after: 1 week

18 years agoAdd mkfifo(2) to the man page SEE ALSO list for umask(2) -- it's
rwatson [Sat, 10 Sep 2005 20:47:02 +0000 (20:47 +0000)]
Add mkfifo(2) to the man page SEE ALSO list for umask(2) -- it's
mentioned in the description.

MFC after: 2 days

18 years agoUnwind across trap frames. This adds most of the meat. The sniffer
marcel [Sat, 10 Sep 2005 20:12:52 +0000 (20:12 +0000)]
Unwind across trap frames. This adds most of the meat. The sniffer
just needs to be taught about all the other entry points and the
unwinder needs to be taught about the frame variation between them.

MFC after: 1 week

18 years agoAdd a kluge to allow kgdb(1) to inject its own frame sniffer in the
marcel [Sat, 10 Sep 2005 18:25:53 +0000 (18:25 +0000)]
Add a kluge to allow kgdb(1) to inject its own frame sniffer in the
list of frame sniffers so that trapframes can be detected. The kluge
is needed because this version of gdb only supports appending a
sniffer to the list of sniffers and the moment kgdb gets a chance to
add its own frame sniffer, the target's default frame sniffer is
already in the list. Since the default frame sniffer claims any
frame thrown at it, kgdb's frame sniffer never gets to smell (a
process much akin to tasting, but with lesser chance of hurling :-)

This commit adds dummy frame sniffers that never claim a frame and
as such don't fix anything yet. However, we now have frame sniffers
and they are being called, so it's just a matter of adding meat to
the bones and we'll be able to properly unwind across trapframes.

MFC after: 1 week

18 years ago- channel.h
netchild [Sat, 10 Sep 2005 18:10:31 +0000 (18:10 +0000)]
- channel.h
  * New definition CHN_F_HAS_VCHAN.
- channel.c
  * Use CHN_F_HAS_VCHAN to mark channel with vchan capability instead
    of relying on SLIST_EMPTY(&channel->children) == true for better
    clarification and future possible usages of children (like
    'slave' channel).
  * Various fixes, including blocksize / format bps allignment,
    better 24bit seeking (mplayer, others).
  * Improve format chain building, it's now possible to record something
    to a format non-native to the soundcard through various feeder format
    converters or to higher sampling rate. This also gains another feature,
    like doing vchan mixing on non s16le soundcard such as sb8.
- sound.c
  * Increase robustness within various function that handle vchan
    creation / termination (these function need a total rewrite, but
    that would cause other major rewrite within various places too!).
    As far as its robustness can be guaranteed, leave it as is.
  * Optimize channel ordering, prefer *real* hardware playback
    channels over virtual channels. cat /dev/sndstat should look
    better.
  * Increase sndstat verbosity to include bufsoft/bufhard allocation.
- vchan.c
  * Fix LOR 119.
    - http://sources.zabbadoz.net/freebsd/lor.html#119
  * Reorder / increase robustness of vchan_create() / destroy().
    Enforce destroy_dev() during destroy operation, fix possible
    panic / dangling character device.
    - http://lists.freebsd.org/pipermail/freebsd-current/2005-May/050308.html
  * Tolerate a little bit more during mixing process, this should help
    non s16le soundcards.

Note: Recoring in a non-native rate/format may result in overruns. A friendly
      application is wavrec from audio/wavplay. The problem is under
      investigation.

Submitted by: Ariff Abdullah <skywizard@MyBSD.org.my>

18 years agoFix some errors in archive_read_data that caused failures in bsdtar's
kientzle [Sat, 10 Sep 2005 18:05:54 +0000 (18:05 +0000)]
Fix some errors in archive_read_data that caused failures in bsdtar's
pass-through filtering.

Thanks to: Bjoern Koenigönig
PR: bin/82878

18 years agoRelease lock for a while during chn_reset() / pcm_chnalloc() operation
netchild [Sat, 10 Sep 2005 17:51:38 +0000 (17:51 +0000)]
Release lock for a while during chn_reset() / pcm_chnalloc() operation
while malloc()ing, this fixes LOR 129.

See
 - http://lists.freebsd.org/pipermail/freebsd-current/2005-June/051157.html
 - http://lists.freebsd.org/pipermail/freebsd-current/2005-August/054620.html
 - http://sources.zabbadoz.net/freebsd/lor.html#129

Submitted by: Ariff Abdullah <skywizard@MyBSD.org.my>

18 years ago- fake.c
netchild [Sat, 10 Sep 2005 17:47:39 +0000 (17:47 +0000)]
- fake.c
  * Add missing A_LAW / MU_LAW format.
- feeder.c
  * Fix format chain building. Traverse backward instead of forward
    during format chainning.
- feeder_fmt.c
  * Add missing alaw/mulaw converter.
  * Add 16 -> 24/32bit converter.
  * whitespace cleanup.
- sound.h
  * alaw / mulaw are member of AFMT_8BIT.

Submitted by: Ariff Abdullah <skywizard@MyBSD.org.my>

18 years ago- Few buggy codecs (STAC9704, probably others) return inconsistent
netchild [Sat, 10 Sep 2005 17:42:59 +0000 (17:42 +0000)]
- Few buggy codecs (STAC9704, probably others) return inconsistent
  ac97_rdcd() value. Enable aggresive workaround.
- Fix mixer resolution detection for 5/6 bit register, carefully not to
  overflow others.

PR: 84728
Submitted by: Ariff Abdullah <skywizard@MyBSD.org.my>

18 years agoFix panic caused by full duplex operation.
netchild [Sat, 10 Sep 2005 17:33:58 +0000 (17:33 +0000)]
Fix panic caused by full duplex operation.

From the PR:
---snip---
The vibra16X supports full duplex. I traced the Windows driver, and what is
does is that it programs one DMA channel 8-bit, and the other 16-bit. There
might be some kind of auto detection logic here, because it always uses 8-bit
for playback, even if I play 16-bit sound ...
---snip---

PR: 80977
Submitted by: Hans Petter Selasky <hselasky@c2i.net>

18 years agoProtect interface and address lists using the appropriate mutex. These
csjp [Sat, 10 Sep 2005 15:12:24 +0000 (15:12 +0000)]
Protect interface and address lists using the appropriate mutex. These
locks were not aquired because the user buffers were not wired, thus it was
possible that that SYSCTL_OUT could sleep, causing a number of different
problems such as lock ordering issues and dead locks.

-Wire user supplied buffer to ensure SYSCTL_OUT will not sleep.
-Pickup ifnet locks to protect the list.
-Where applicable pickup address locks.
-Pickup radix node head locks.
-Remove splnet stubs
-Remove various comments about locking here, because they are no
 longer needed.

It is the hope that these changes will make sysctl_rtsock MP safe.

MFC after: 3 weeks

18 years agoAdd an MLINK for devname_r().
stefanf [Sat, 10 Sep 2005 14:09:37 +0000 (14:09 +0000)]
Add an MLINK for devname_r().

18 years agoThe header and the man page say that sethostid() returns void, so make the
stefanf [Sat, 10 Sep 2005 13:54:42 +0000 (13:54 +0000)]
The header and the man page say that sethostid() returns void, so make the
definition match.  Include <unistd.h>.

18 years agoFix parameter types of close and get members in DB.
stefanf [Sat, 10 Sep 2005 12:40:51 +0000 (12:40 +0000)]
Fix parameter types of close and get members in DB.

18 years agoElaborate on the behaviour of set -e.
stefanf [Sat, 10 Sep 2005 09:28:39 +0000 (09:28 +0000)]
Elaborate on the behaviour of set -e.

18 years agoRemove a duplicate and fix a typo.
schweikh [Sat, 10 Sep 2005 08:27:07 +0000 (08:27 +0000)]
Remove a duplicate and fix a typo.

18 years agoPass the EV_TESTED flag to evalloop() and evalfor(). This fixes unwanted
stefanf [Sat, 10 Sep 2005 08:25:28 +0000 (08:25 +0000)]
Pass the EV_TESTED flag to evalloop() and evalfor().  This fixes unwanted
termination with set -e if a command fails in a loop body inside a function
with an explicitely tested exit status, eg

f() {
for i in 1 2 3; do
false
done
}
f || true

Briefly reviewed by: cracauer

18 years agoPass the EV_TESTED flag to the left operand of NSEMI nodes. This fixes
stefanf [Sat, 10 Sep 2005 08:19:58 +0000 (08:19 +0000)]
Pass the EV_TESTED flag to the left operand of NSEMI nodes.  This fixes
two cases of unwanted termination with set -e:

* if-commands containing several commands separated by semicolons, eg

if false; false; then [...]

* functions with an explicitely tested exit status that contain a failing
  command which is not the last one, eg

f() {
false
false
}
f || true

PR: 77067, 85267
Briefly reviewed by: cracauer

18 years agoFix copy&paste typo.
pjd [Sat, 10 Sep 2005 07:46:47 +0000 (07:46 +0000)]
Fix copy&paste typo.

MFC after: 3 days

18 years agoDon't forget to initialize crp_etype field.
pjd [Sat, 10 Sep 2005 07:45:10 +0000 (07:45 +0000)]
Don't forget to initialize crp_etype field.

Reported by: Nick Evans <nevans@syphen.net>
MFC after: 3 days

18 years agoIn tcp_ctlinput() do not swap ip->ip_len a second time. It
andre [Sat, 10 Sep 2005 07:43:29 +0000 (07:43 +0000)]
In tcp_ctlinput() do not swap ip->ip_len a second time.  It
has been done in icmp_input() already.

This fixes the ICMP_UNREACH_NEEDFRAG case where no MTU was
proposed in the ICMP reply.

PR: kern/81813
Submitted by: Vitezslav Novy <vita at fio.cz>
MFC after: 3 days

18 years agoEven if there are no valid keys in metadata, but provider is attached
pjd [Sat, 10 Sep 2005 07:43:03 +0000 (07:43 +0000)]
Even if there are no valid keys in metadata, but provider is attached
we can still use setkey subcommand.

MFC after: 3 days
Found by: regression tests

18 years agoExit the shell if a pipeline that is not preceded by ! fails and set -e is
stefanf [Sat, 10 Sep 2005 07:41:36 +0000 (07:41 +0000)]
Exit the shell if a pipeline that is not preceded by ! fails and set -e is
active.  Use a separate flag to avoid adding another condition to the
if-statement at the end of evaltree().

Briefly reviewed by: cracauer

18 years agoMerge db_interface.c and db_trace.c into db_machdep.c.
marcel [Sat, 10 Sep 2005 03:18:51 +0000 (03:18 +0000)]
Merge db_interface.c and db_trace.c into db_machdep.c.

18 years agoMove the prototypes of db_md_set_watchpoint(), db_md_clr_watchpoint()
marcel [Sat, 10 Sep 2005 03:01:25 +0000 (03:01 +0000)]
Move the prototypes of db_md_set_watchpoint(), db_md_clr_watchpoint()
and db_md_list_watchpoints() to ddb/ddb.h.

18 years agoMove the ia32_sigcode structure from ia32_sigtramp.c to ia32_signal.c.
marcel [Sat, 10 Sep 2005 02:12:49 +0000 (02:12 +0000)]
Move the ia32_sigcode structure from ia32_sigtramp.c to ia32_signal.c.
It's a bit excessive to have it in a file of its own.

18 years agoRemove redundant $FreeBSD$
marcel [Sat, 10 Sep 2005 01:13:33 +0000 (01:13 +0000)]
Remove redundant $FreeBSD$

18 years agoMFp4:
imp [Sat, 10 Sep 2005 00:17:55 +0000 (00:17 +0000)]
MFp4:

Reduce the size of ed a little by removing some CIS based entries (others
likely can be removed too):
o The D-Link DFE-670TXD doesn't need its own entry based on strings.
o The Xircom CompactCard appears to be a TDK design, so list it there by ID
  and remove the strings.

Increase the size of ed a little:
o Add support for the Addtron AE-660CT and Addtron AE-660.  This is a very
  generic NE-2000 clone (so generic that its CIS tags say NE-2000 generic
  card!).

18 years agoSplit the export synopsis into two lines as -p cannot be mixed with variable
stefanf [Fri, 9 Sep 2005 21:06:03 +0000 (21:06 +0000)]
Split the export synopsis into two lines as -p cannot be mixed with variable
names.

18 years ago- Provide a reasonable error message for `export -p var'.
stefanf [Fri, 9 Sep 2005 21:03:34 +0000 (21:03 +0000)]
- Provide a reasonable error message for `export -p var'.
- Use argv rather than argptr since getopt() is used here.

18 years agoFix the error message if the mask that is passed to umask -S contains
stefanf [Fri, 9 Sep 2005 19:59:41 +0000 (19:59 +0000)]
Fix the error message if the mask that is passed to umask -S contains
non-digits.

18 years agoChange the High FP lock from a sleep lock to a spin lock. We can
marcel [Fri, 9 Sep 2005 19:18:36 +0000 (19:18 +0000)]
Change the High FP lock from a sleep lock to a spin lock. We can
take the lock from interrupt context, which causes an implicit
lock order reversal. We've been using the lock carefully enough
that making it a spin lock should not be harmful.

18 years agoFix fallout from the previous commit:
yar [Fri, 9 Sep 2005 19:02:03 +0000 (19:02 +0000)]
Fix fallout from the previous commit:
We shouldn't call chmod() if we've just used
fchmod() OK on the same file.

Approved by: kientzle

18 years agoAdded missing builtins; a few other clean-ups.
garys [Fri, 9 Sep 2005 17:02:08 +0000 (17:02 +0000)]
Added missing builtins; a few other clean-ups.

- The first "alias" "Yes" should be "No**".
- Made "builtin echo command" consistent with csh and sh manpages.
- In group of 3 interactive commands, 2 used .Pa instead of .Ic.
- "Name" section now has "builtin" and "built-in" for better apropos.
- Added these builtins: !, %, ., :, @, {, }, local, return

PR:             docs/85065
Approved by:    keramida
MFC after:      3 days

18 years agoBe a little more obvious about the steps to build a kernel.
obrien [Fri, 9 Sep 2005 15:59:17 +0000 (15:59 +0000)]
Be a little more obvious about the steps to build a kernel.

18 years agoExpand a bit the description of the -t option.
keramida [Fri, 9 Sep 2005 11:29:51 +0000 (11:29 +0000)]
Expand a bit the description of the -t option.

Triggered by: Stijn Hoop <stijn@win.tue.nl>
on freebsd-questions

18 years ago- Do not hold route entry lock, when calling arprequest(). One such
glebius [Fri, 9 Sep 2005 10:06:27 +0000 (10:06 +0000)]
- Do not hold route entry lock, when calling arprequest(). One such
  call was introduced by me in 1.139, the other one was present before.
- Do all manipulations with rtentry and la before dropping the lock.
- Copy interface address from route into local variable before dropping
  the lock. Supply this copy as argument to arprequest()

LORs fixed:
http://sources.zabbadoz.net/freebsd/lor/003.html
http://sources.zabbadoz.net/freebsd/lor/037.html
http://sources.zabbadoz.net/freebsd/lor/061.html
http://sources.zabbadoz.net/freebsd/lor/062.html
http://sources.zabbadoz.net/freebsd/lor/064.html
http://sources.zabbadoz.net/freebsd/lor/068.html
http://sources.zabbadoz.net/freebsd/lor/071.html
http://sources.zabbadoz.net/freebsd/lor/074.html
http://sources.zabbadoz.net/freebsd/lor/077.html
http://sources.zabbadoz.net/freebsd/lor/093.html
http://sources.zabbadoz.net/freebsd/lor/135.html
http://sources.zabbadoz.net/freebsd/lor/140.html
http://sources.zabbadoz.net/freebsd/lor/142.html
http://sources.zabbadoz.net/freebsd/lor/145.html
http://sources.zabbadoz.net/freebsd/lor/152.html
http://sources.zabbadoz.net/freebsd/lor/158.html

18 years agoWhen a carp(4) interface is being destroyed and is in a promiscous mode,
glebius [Fri, 9 Sep 2005 08:41:39 +0000 (08:41 +0000)]
When a carp(4) interface is being destroyed and is in a promiscous mode,
first interface is detached from parent and then bpfdetach() is called.
If the interface was the last carp(4) interface attached to parent, then
the mutex on parent is destroyed. When bpfdetach() calls if_setflags()
we panic on destroyed mutex.

To prevent the above scenario, clear pointer to parent, when we detach
ourselves from parent.

18 years agoIntroduce a new lock for the purpose of synchronizing access to the
alc [Fri, 9 Sep 2005 06:03:08 +0000 (06:03 +0000)]
Introduce a new lock for the purpose of synchronizing access to the
UMA boot pages.

Disable recursion on the general UMA lock now that startup_alloc() no
longer uses it.

Eliminate the variable uma_boot_free.  It serves no purpose.

Note: This change eliminates a lock-order reversal between a system
map mutex and the UMA lock.  See
http://sources.zabbadoz.net/freebsd/lor.html#109 for details.

MFC after: 3 days

18 years agoAvoid updating resolv.conf when no changes have actually occured.
brooks [Thu, 8 Sep 2005 22:49:17 +0000 (22:49 +0000)]
Avoid updating resolv.conf when no changes have actually occured.

Submitted by: ume

18 years agoWhen we fail to aquire a lease, our lease expires without a sucessful
brooks [Thu, 8 Sep 2005 22:15:19 +0000 (22:15 +0000)]
When we fail to aquire a lease, our lease expires without a sucessful
renewal, or we lose link, be more forceful about clearing interface
state so another interface that connects to the same network has a
chance of working.  This doesn't address attemping to connect to both at
once, but appears to allow unplugging from a wired interface and then
inserting a wireless card that associates with an AP bridged to the same
LAN.

18 years agoSet the G_PF_WITHER flag on the subdisk provider that is about to
le [Thu, 8 Sep 2005 20:08:46 +0000 (20:08 +0000)]
Set the G_PF_WITHER flag on the subdisk provider that is about to
be destroyed.  That way the GEOM system handles all deallocations
and we don't have to do it ourselves.

18 years agoUnbreak the build. Committed from the wrong directory.
mlaier [Thu, 8 Sep 2005 17:42:42 +0000 (17:42 +0000)]
Unbreak the build.  Committed from the wrong directory.

18 years agoMinor improvement for the suspend case for Ricoh based (and others)
imp [Thu, 8 Sep 2005 17:18:42 +0000 (17:18 +0000)]
Minor improvement for the suspend case for Ricoh based (and others)
CardBus bridges.

18 years agoThe ed driver lock is already held in the mii frobbing routines. Remove
imp [Thu, 8 Sep 2005 17:17:13 +0000 (17:17 +0000)]
The ed driver lock is already held in the mii frobbing routines.  Remove
locking from these routines.

18 years agoAdd note about what ED_DEFAULT_MAC_OFFSET applies to
imp [Thu, 8 Sep 2005 17:16:23 +0000 (17:16 +0000)]
Add note about what ED_DEFAULT_MAC_OFFSET applies to

18 years agoNote that pc98 specific defines maybe would be better in a header file.
imp [Thu, 8 Sep 2005 17:07:12 +0000 (17:07 +0000)]
Note that pc98 specific defines maybe would be better in a header file.

18 years agoCommit imported changes to HEAD:
mlaier [Thu, 8 Sep 2005 15:06:52 +0000 (15:06 +0000)]
Commit imported changes to HEAD:
 pf_ioctl.c Revision 1.153 Sun Aug 7 11:37:33 2005 UTC by dhartmei
 | verify ticket in DIOCADDADDR, from Boris Polevoy, ok deraadt@

 pf_ioctl.c Revision 1.158 Mon Sep 5 14:51:08 2005 UTC by dhartmei
 | in DIOCCHANGERULE, properly initialize table, if used in NAT rule.
 | from Boris Polevoy <vapcom at mail dot ru>, ok mcbride@

 pf.c Revision 1.502 Mon Aug 22 11:54:25 2005 UTC by dhartmei
 | when nat'ing icmp 'connections', replace icmp id with proxy values
 | (similar to proxy ports for tcp/udp). not all clients use
 | per-invokation random ids, this allows multiple concurrent
 | connections from such clients.
 | thanks for testing to Rod Whitworth, "looks ok" markus@

 pf.c Revision 1.501 Mon Aug 22 09:48:05 2005 UTC by dhartmei
 | fix rdr to bitmask replacement address pool. patch from Max Laier,
 | reported by Boris Polevoy, tested by Jean Debogue, ok henning@

Obtained from: OpenBSD
MFC after: 3 days

18 years agoFix an item leak, that happens when some node calls ng_callout() two
glebius [Thu, 8 Sep 2005 14:32:19 +0000 (14:32 +0000)]
Fix an item leak, that happens when some node calls ng_callout() two
times consequently, without checking whether callout has been serviced
or not. (ng_pptpgre and ng_ppp were catched in this behavior).

  - In ng_callout() save old item before calling callout_reset(). If the
    latter has returned 1, then free this item.
  - In ng_uncallout() clear c->c_arg.

Problem reported by: Alexandre Kardanev

18 years agoRework locking, that I have introduced recently, since it was incorrect:
glebius [Thu, 8 Sep 2005 14:26:23 +0000 (14:26 +0000)]
Rework locking, that I have introduced recently, since it was incorrect:

  First, mutexed callouts are incompatible with netgraph nodes, because
  netgraph(4) can guarantee that the function will be called with mutex
  held.

  Second, nodes should not send data to their neighbor holding their
  mutex. A node does not know what stack can it enter sending data in
  some direction. May be executing will encounter a place to sleep.

New locking:

  - ng_pptpgre_recv() and ng_pptpgre_xmit() must be entered with mutex held.
  - ng_pptpgre_recv() and ng_pptpgre_xmit() unlock mutex before
    sending data and then return unlocked.
  - callout routines acquire mutex themselves.

18 years agoMake callout_reset() return a non-zero value if a pending callout
glebius [Thu, 8 Sep 2005 14:20:39 +0000 (14:20 +0000)]
Make callout_reset() return a non-zero value if a pending callout
was rescheduled. If there was no pending callout, then return 0.

Reviewed by: iedowse, cperciva

18 years agoFix a typo that broke LINT.
scottl [Thu, 8 Sep 2005 14:13:36 +0000 (14:13 +0000)]
Fix a typo that broke LINT.

18 years agoMove hme_stop() after ether_ifdetach() and if_free() to prevent a
kensmith [Thu, 8 Sep 2005 13:50:16 +0000 (13:50 +0000)]
Move hme_stop() after ether_ifdetach() and if_free() to prevent a
memory-referenced-after-free panic if the hme interface fails to
attach.

Patch obtained from: marius
Suggested same thing: brooks

MFC after: 3 days

18 years agoReflect a recent change in /etc/rc.subr that made ``-M''
yar [Thu, 8 Sep 2005 09:22:21 +0000 (09:22 +0000)]
Reflect a recent change in /etc/rc.subr that made ``-M''
appear in tmpmfs and varmfs default flags explicitly.
Explain why -M is good for these file systems (it maximizes
performance and makes the system more stable at low memory
conditions by reducing the chance of thrashing.)

Bump .Dd accordingly.

MFC after: 3 days

18 years agoAdd a new struct buf flag bit, B_PERSISTENT, and use it to tag
truckman [Thu, 8 Sep 2005 06:30:05 +0000 (06:30 +0000)]
Add a new struct buf flag bit, B_PERSISTENT, and use it to tag
struct bufs that are persistently held by ext2fs.  Ignore any buffers
with this flag in the code in boot() that counts "busy" and dirty
buffers and attempts to sync the dirty buffers, which is done before
attempting to unmount all the file systems during shutdown.

This fixes the problem caused by any ext2fs file systems that are
mounted at system shutdown time, which caused boot() to give up on
a non-zero number of buffers and skip the call to vfs_unmountall().
This left all the mounted file systems in a dirty state and caused
them to all require cleanup by fsck on reboot.

Move the two separate copies of the "busy" buffer test in boot()
to a separate function.

Nuke the useless spl() stuff in the ext2fs ULCK_BUF() macro.

Bring the PRINT_BUF_FLAGS definition in sys/buf.h up to date with
this and previous flag changes.

PR: kern/56675, kern/85163
Tested by: "Matthias Andree" matthias.andree at gmx.de
Reviewed by: bde
MFC after: 3 days

18 years agohptmv(4) now works on amd64.
brueffer [Thu, 8 Sep 2005 04:40:11 +0000 (04:40 +0000)]
hptmv(4) now works on amd64.

18 years agoHook up the hptmv driver for amd64.
scottl [Thu, 8 Sep 2005 03:29:18 +0000 (03:29 +0000)]
Hook up the hptmv driver for amd64.

MFC After: 3 days

18 years agoImport new version of the HPTMV driver from Highpoint. The major change
scottl [Wed, 7 Sep 2005 23:33:26 +0000 (23:33 +0000)]
Import new version of the HPTMV driver from Highpoint.  The major change
here is the support for amd64, as well as possible support for PAE.  Many
thanks to Highpoint for continuing to support FreeBSD.

Obtained from:  Steve Chang @ Highpoint
MFC After: 3 days.

18 years agoSorting the belly button lint of history:
imp [Wed, 7 Sep 2005 22:13:31 +0000 (22:13 +0000)]
Sorting the belly button lint of history:

o Note that the first 255 locations are reserved for JEDEC Ids from
  publication 106 (current revision Q, each one verified with
  JEDEC and the PMCICA).
o Move ADAPTEC2 to the right section.
o Sort TOSHIBA2 numerically.

18 years agoFix typo: Cowarly -> Cowardly.
cperciva [Wed, 7 Sep 2005 19:32:15 +0000 (19:32 +0000)]
Fix typo: Cowarly -> Cowardly.

Reported by: Joerg Sonnenberger

18 years agoFree the bpf descriptor array after we are done with it. This probably isnt
csjp [Wed, 7 Sep 2005 19:28:01 +0000 (19:28 +0000)]
Free the bpf descriptor array after we are done with it. This probably isnt
that critical as the program exits after this point anyway, but this may
not always be the case.

18 years agoUpdate usage to reflect the new option.
csjp [Wed, 7 Sep 2005 19:15:43 +0000 (19:15 +0000)]
Update usage to reflect the new option.

Pointed out by: ru