Commit Graph

123533 Commits

Author SHA1 Message Date
scottl
d86bd61d0c Rearrange locking in the alloc_commands and ioctl paths to avoid problems. 2006-04-08 06:05:29 +00:00
scottl
3ab858c374 After further review and discussion, partially revert the previous commit.
The real problem was that ioctl handlers needed to call amr_wait_command()
with the list lock held.  This not only solves the completion race, it also
prevents bounce buffer corruption that could arise from amr_start() being
called without the proper locks held.

Discussed with: ps
MFC After: 3 days
2006-04-08 05:08:17 +00:00
ps
e8f84ee984 Close a pesky race where after checking the BUSY flag in amr_wait_command,
the completion of the command can occur before tsleep is called and
the command ends up blocking forever since the wakeup has already
been called.

Submitted by:   ups
2006-04-08 02:23:27 +00:00
marcel
aa6df7801f Add the scc_hwmtx spin mutex, defined by scc(4). 2006-04-07 22:15:54 +00:00
marcel
6692456a36 Add kbdmux(4). This avoids having to use the hint.pcib.1.skipslot=26
trick on a PowerBook G4 and friends to get the USB keyboard as ukbd0.
2006-04-07 22:04:07 +00:00
jmg
d8abb8a512 spell unlock correctly, this is relatively minor as it's rare someone would
provide a lock method, and want the default unlock, but it is a bug...

PR:		95356
Submitted by:	Stephen Corteselli
MFC after:	3 days
2006-04-07 17:21:27 +00:00
marcel
a5bd277da0 Change gctl_set_param() to return an error instead of setting an
error on the request.  Add a wrapper, gctl_set_param_err(), that
sets the error on the request from the error returned by
gctl_set_param() and update current callers of gctl_set_param()
to call gctl_set_param_err() instead.
This makes gctl_set_param() much more usable in situations where
the caller knows better what to do with certain (apparent) error
conditions and setting an error on the request is not one of the
things that need to be done.
2006-04-07 16:19:48 +00:00
pjd
aa5c1066ff Allocate memory for NUL-termination as well.
MFC after:	2 days
2006-04-07 15:33:04 +00:00
des
b72fba923c Don't select a default value for $machine until after we've examined $arch.
Noticed by:	mjacob
2006-04-07 15:19:19 +00:00
ru
8fde273627 Fix the "make distribution" example; it should be run from src/. 2006-04-07 11:36:25 +00:00
glebius
c7e9ae3929 Restore accidentially removed rev. 1.3 2006-04-07 10:18:24 +00:00
sam
1a3481f3d8 backout rev 1.74
Requested by:	ssouhlal
2006-04-07 05:16:02 +00:00
csjp
be495bef58 Introduce a new MAC entry point for label initialization of the NFS daemon's
credential: mac_associate_nfsd_label()

This entry point can be utilized by various Mandatory Access Control policies
so they can properly initialize the label of files which get created
as a result of an NFS operation. This work will be useful for fixing kernel
panics associated with accessing un-initialized or invalid vnode labels.

The implementation of these entry points will come shortly.

Obtained from:	TrustedBSD
Requested by:	mdodd
MFC after:	3 weeks
2006-04-06 23:33:11 +00:00
jmg
eb74e00e0c bring in the necessary changes to make gdbserver compile and work (at
least on i386)...  fbsd-* changes started out as s/linux/fbsd/g and then
additional changes to handle different ptrace defines among other things..
(use vfork to eliminate a race for progress group creation)

reg-i386.c is generated by regdat.sh..
2006-04-06 22:24:01 +00:00
jmg
0bf49b8fa9 This commit was generated by cvs2svn to compensate for changes in r157571,
which included commits to RCS files with non-trunk default branches.
2006-04-06 21:32:05 +00:00
jmg
b76dbd3b4f import gdbserver Linux files renamed to fbsd... I have made gdbserver
work w/ minor modifications to these files, so keep the history...

These are stock files from GDB 6.1.1 w/ only the filename s/linux/fbsd/g
2006-04-06 21:32:05 +00:00
cognet
8b8bb58f45 MFp4: Catchup with recent UART changes. 2006-04-06 20:47:54 +00:00
mohans
a29f457114 Eliminate debug code that catches bugs in the hinting of sack variables
(tcp_sack_output_debug checks cached hints aginst computed values by walking the
scoreboard and reports discrepancies). The sack hinting code has been stable for
many months now so it is time for the debug code to go. Leaving tcp_sack_output_debug
ifdef'ed out in case we need to resurrect it at a later point.
2006-04-06 17:21:16 +00:00
jhb
dca0aae557 - Don't set CR0_NE and CR0_MP in npx_probe() as they are already set
earlier in cpu_setregs().
- If we know this CPU has a FPU via cpuid, then just assume the INT16
  interface and make the npx device quiet to not clutter the dmesg.  This
  is true for all Pentium and later CPUs and even some of the later 486dx
  CPUs.

Reviewed by:	bde
Tested by:	ps
MFC after:	1 week
2006-04-06 17:17:45 +00:00
cognet
067f218bcf Add a new option, XSCALE_DISABLE_CCNT, to not use the xscale ccnt as a
timecounter (because gxemul doesn't emule it yet).
2006-04-06 17:11:08 +00:00
glebius
4c89b5bc10 Merge in new driver from Intel, version 5.1.5. Adds support for some
new chips and improves support for already supported ones.

Some details, important for future merges:
  - if_em.c merged manually, viewing diff between new vendor
    driver and previous one.
  - if_em_hw.h dropped in from vendor, and then restored revisions
    1.16, 1.17, 1.18.
  - if_em_hw.c dropped in from vendor, and then two liner change made,
    that restores support for two rare chips.
2006-04-06 17:09:03 +00:00
ssouhlal
48062565de Replace FILEDESC_[UN]LOCK_FAST() with a critical section on UP.
Gives a small but measurable performance improvement.

Submitted by:	Divacky Roman <xdivac02@stud.fit.vutbr.cz>
MFC after:	1 month
2006-04-06 16:27:48 +00:00
imp
8694646e12 Add debug writes in error cases that, in theory, should never happen 2006-04-06 04:32:29 +00:00
imp
000b33975f Connect twi to the FreeBSD iicbus infrastructure. 2006-04-06 04:31:19 +00:00
imp
b8ec0fd91c Pull in numerous fixes from myself and cognet. With these fixes the
KB9202 eval board is finally stable with a nfs root.
2006-04-06 04:30:23 +00:00
imp
9a23a843f0 Remove unused bit definitions.
Minor style cleanup while I'm here.
2006-04-06 04:29:24 +00:00
imp
41d4c17769 Optimize the TX side of the part by using the PDC to move bytes out to
the wire.  This increases the speed considerably.  Start to put
infrastructure in place to do RX side, but that requires more study
before it can be done.
2006-04-06 04:27:19 +00:00
gad
20f9416a8f Re-correct commit 1.73, but this time in a way that does not cause
all column-headers to print in lowercase by default.  I was in too
much of a rush in committing 1.75, and didn't notice that the case
had changed.  This time I did considerably more testing, and used
'diff' instead of just quickly eyeballing the results...

Apologies.  I expect this means the dunce cap is mine for awhile.
If this doesn't work, I'll just drop back to 1.72 and hide under
my desk for awhile.
2006-04-06 03:24:31 +00:00
rwatson
d2dc014de0 Correct assertion in ng_detach().
Submitted by:	tegge
MFC after:	3 months
2006-04-06 02:54:42 +00:00
mohans
8a6c02da7d Keep track of the number of in-progress async direct IO writes in the nfsnode.
Make fsync/close wait until all of these drain. Add a check to nfs_getpage() and
nfs_putpage().
2006-04-06 01:20:30 +00:00
dd
4170173ab0 Fix typo/pasto: Make NGM_FEC_MODE_* match set_mode_*. 2006-04-06 00:32:28 +00:00
ceri
3c1848a696 Fix options broken when the birthtime related primaries were added.
Note to self: if a comment says a list must be lexically sorted, sort
the list lexically.

Submitted by:	Pawel Worach
Approved by:	jhb
MFC after:	2 weeks
2006-04-05 23:06:11 +00:00
pjd
c94d951bcd Typos. 2006-04-05 22:07:31 +00:00
brueffer
22d79ef7da Revert the backout in the last revision, it was committed to the wrong branch.
Pointy hat to:  brueffer
2006-04-05 21:51:40 +00:00
brueffer
77c154d78d Back out the fan control changes that were merged in revision 1.2.2.5.
The necessary changes to the driver haven't been merged yet, which won't
happen before 6.1-RELEASE.

Submitted by:	markus
Approved by:	re (scottl)
2006-04-05 21:40:14 +00:00
jhb
1dfdfa5677 Cache the value of the lower half of each I/O APIC redirection table entry
so that we only have to do an ioapic_write() instead of an ioapic_read()
followed by an ioapic_write() every time we mask and unmask level triggered
interrupts.  This cuts the execution time for these operations roughly in
half.

Profiled by:	Paolo Pisati <p.pisati@oltrelinux.com>
MFC after:	1 week
2006-04-05 20:43:19 +00:00
jasone
2f4016efa3 Add an unreachable return statement, in order to avoid a compiler warning
for non-standard optimization levels.

Reported by:	Michael Zach <zach@webges.com>
2006-04-05 18:46:24 +00:00
gad
8cc35ce532 Fix a problem introduced by change 1.73, which causes a seg-fault if
the user specifies a keyword which is an alias to some other keyword.
E.g.: stat (for state) or pcpu (for %cpu)..

Submitted by:	Kostik Belousov
MFC plans:	"soon"
2006-04-05 17:40:46 +00:00
jkoshy
435490fd44 When printing a map, print the number of samples recorded by each gmon.out file.
MFC after:	1 week
2006-04-05 15:12:25 +00:00
glebius
e41986c80d Add a new feature to ping(8) - possibility to specify maximum
wait time for a packet. This allows to:

 - Count number of packets received before and after specified
   time.
 - Shorten time of execution of 'ping -c 1' scripts.

Submitted by:	Lytochkin Boris <lytboris gmail.com>
2006-04-05 12:30:42 +00:00
rwatson
4f906aab35 Don't unlock a timewait structure if the pointer is NULL in
tcp_timewait().  This corrects a bug (or lack of fixing of a bug)
in tcp_input.c:1.295.

Submitted by:	Kazuaki Oda <kaakun at highway dot ne dot jp>
MFC after:	3 months
2006-04-05 08:45:59 +00:00
jasone
53b0978842 Only initialize the first per-chunk page map element for free runs. This
makes run split/coalesce operations of complexity lg(n) rather than n.
2006-04-05 04:15:12 +00:00
mohans
0e65e2a5a1 Certain (bad) values of sack blocks can end up corrupting the sack scoreboard.
Make the checks in tcp_sack_doack() more robust to prevent this.

Submitted by: Raja Mukerji (raja@mukerji.com)
Reviewed by:  Mohan Srinivasan
2006-04-05 00:11:04 +00:00
imp
db765ca50b newbus will zero softc, so no need to duplicate the zeroing here.
Plus a minor formatting nit in nearby code.
2006-04-04 23:29:17 +00:00
jmg
7ad8a72278 add links for the functions documented in bus_space.9... 2006-04-04 22:56:08 +00:00
alepulver
e4b3750023 Add my birthday.
Approved by:	garga (mentor)
2006-04-04 22:32:14 +00:00
pjd
521777141e Don't call bfe_release_resources() twice.
Found by:	Coverity Prevent analysis tool
CID:		600
MFC after:	1 week
2006-04-04 22:30:12 +00:00
marius
8ea6d154a2 For USIII CPUs the type of the trap caused by peeking/poking non-existent
PCI devices apparently was changed from a special deferred trap with TPC
pointing to the membar #Sync following the failing load/store instruction
to a precise trap with TPC pointing to the failing load/store instruction.
Thus remove the check the check whether TPC points to a membar #Sync in
case of a data access trap as it's off-by-one for USIII CPUs and it should
be sufficient to check whether the trap happend while in fasword*() to
properly detect traps caused by peeking/poking. This also corresponds to
what other OSs do. Note that also only the USIIi manual suggests to check
the TPC for such traps while the USII one doesn't (in the public USIII
manual device peeking/poking isn't mentioned at all).
2006-04-04 21:00:44 +00:00
jasone
06e487e0f3 Add malloc_usable_size() to the RETURN VALUES section. 2006-04-04 20:27:53 +00:00
andre
bfe18768df Undo damage from wrong MFC to HEAD.
Pointed out by:	jkim, remko
2006-04-04 20:20:51 +00:00