Commit Graph

161681 Commits

Author SHA1 Message Date
Ulrich Spörlein
1cc06c674e Remove bsdlabel.5, which hasn't been installed in over 7 years
and contains little more than an out-dated copy of <sys/disklabel.h>
2011-03-10 08:23:58 +00:00
Adrian Chadd
0c89688b3b Now that the power curve adjustment code is in, disable the error check
I introduced earlier, and turn it into debugging output.
2011-03-10 06:09:55 +00:00
Adrian Chadd
cc5c884d02 Port over the v14 eeprom PDADC curve changes from ath9k.
It looks like these apply in both open and closed loop TX power control,
but the only merlin boards i have either have OL -or- a non-default power
offset, not both.
2011-03-10 06:08:24 +00:00
Adrian Chadd
b2b029190f Merlin fix - first pdadc gain index is 0 - minpwr/2 .
Obtained from:	Linux ath9k
2011-03-10 06:06:26 +00:00
Adrian Chadd
c48e24c122 Migrate the regulatory database definitions into separate header files
to both make things clearer, and to make it easier to write userland
code which pulls in these definitions without needing to pull in the
rest of the HAL.

This stuff should be deprecated at some point in the future once
the net80211 regulatory domain support encapsulates all of the
defintions here.
2011-03-10 03:13:56 +00:00
Adrian Chadd
c50678682f Introduce the Merlin PWDCLKIND workaround.
This is something bus clock related from what I can gather. It is needed for
the AR9220 based Ubiquiti SR71-12 and SR71-15 Mini-PCI NICs.

(Note: those NICs don't work right now because of earlier changes to handle
power table offset correctly. That'll be resolved in a follow-up commit.)
2011-03-10 02:09:06 +00:00
Pawel Jakub Dawidek
7a0452188b Few initial ftruncate(2) tests. One of them covers stand/154873.
PR:	stand/154873
2011-03-09 23:11:30 +00:00
Pawel Jakub Dawidek
7535f6533c Pass descriptor number to write(2), now that it is possible. 2011-03-09 22:50:15 +00:00
Pawel Jakub Dawidek
446727a7a4 Add support for the following syscalls:
- fchmod(2),
- fchown(2),
- fchflags(2),
- fstat(2),
- ftruncate(2),
- fpathconf(2),
- lpathconf(2).
Make write(2) syscall to take descriptor instead of file name.

We implement descriptors by keeping track of open files and allowing to
reference them by the following syscalls. Because pjdfstest already supports
executing multiple syscalls from one command it works pretty well.

For example, the following command:

	pjdfstest open foo "O_CREAT,O_RDWR" 0 : open bar "O_CREAT,O_RDONLY" 640 : fchmod 0 0666 : fchown 0 -1 20 : fchmod 1 0444

is equivalent of (error checking omitted):

	int fd[2];

	fd[0] = open("foo", O_CREAT | O_RDWR, 0);
	fd[1] = open("bar", O_CREAT | O_RDONLY, 0640);
	fchmod(fd[0], 0666);
	fchown(fd[0], -1, 20);
	fchmod(fd[1], 0444);
2011-03-09 22:39:10 +00:00
Navdeep Parhar
d986a01abf Display holdoff timers and packet counts as a list of numbers.
MFC after:	1 week
2011-03-09 21:07:09 +00:00
Julian Elischer
a8066a9d3b Add a small change to the comment in the GENRIC config files that include udbp
Submitted by:	Chris Forgron, cforgeron at acsi dot ca
MFC after:	1 week
2011-03-09 17:15:11 +00:00
Ruslan Ermilov
b17e9548f8 Sync manpage's SYNOPSIS with program's usage. 2011-03-09 17:07:36 +00:00
Jung-uk Kim
e09faf083f Remove custom interrupt dispatcher. This is a pointless micro-optimization
and it may cause problems if SS and SP are modified by real-mode code.

MFC after:	1 month
2011-03-09 16:16:38 +00:00
Nathan Whitehorn
797c37ee2b Fix whitespace nit. 2011-03-09 15:03:42 +00:00
Nathan Whitehorn
6cc28b780f Remove a redundant rm and avoiding tarring up work directories in ports
trees.
2011-03-09 15:02:23 +00:00
Dag-Erling Smørgrav
8e391be103 No newline required.
MFC after:	2 weeks
2011-03-09 14:38:00 +00:00
Pawel Jakub Dawidek
7a9611bf5e Change example to not be controversial.
I'm sorry to anyone who felt offended by this.

PR:		docs/155385
Reported by:	maga_lena <mirto@riseup.net>
MFC after:	1 week
2011-03-09 07:43:51 +00:00
Dmitry Chagin
a2cd91cf28 Indeed, remove bogus since r219405 check of the Linux ABI.
Pointed out:	jhb

MFC after:	2 Week
2011-03-09 05:59:33 +00:00
Adrian Chadd
d445d5407a The regdomain entries are 16 bits, not 8. Print out all 16 bits. 2011-03-09 04:48:06 +00:00
Adrian Chadd
beb4faf377 For chips that are full reset in ar5416ChipReset(), save and restore the TSF.
Merlin (ar9280) and later were full-reset if they're doing open-loop TX
power control but the TSF wasn't being saved/restored.

Add ar5212SetTsf64() which sets the 64 bit TSF appropriately.
2011-03-09 04:39:35 +00:00
Ed Maste
bdbd7b1333 Remove stray semicolon. This fix appears in later upstream gdb versions.
Submitted by:	eadler
2011-03-09 02:23:21 +00:00
Andrey V. Elsukov
bd727a6884 It is better to sometimes have not aligned columns than
often have wrapped lines.

MFC after:	2 weeks
2011-03-08 22:01:47 +00:00
Andrey V. Elsukov
acefd268d6 Add -p option to gpart show command to show provider's names of
partitions instead of partition's indexes. This may be useful with
GPT partitioning scheme or EBR without GEOM_PART_EBR_COMPAT option.

MFC after:	2 weeks
2011-03-08 21:36:42 +00:00
Edwin Groothuis
f2ad6fdc5c MFV of tzdata2011c, r219409
- No leapsecond in June 2011
- Add and update timezones for America/Juneau, America/Sitka,
  America/Metlakatla
- Change of Summer time to Winter time in Chili happens in April
  2011, not in March 2011.
2011-03-08 21:11:31 +00:00
Edwin Groothuis
e7cf356919 Vendor import of tzdata2011c
- No leapsecond in June 2011
- Add and update timezones for America/Juneau, America/Sitka,
  America/Metlakatla
- Change of Summer time to Winter time in Chili happens in April
  2011, not in March 2011.

Obtained from:	ftp://elsie.nci.nih.gov/pub/
2011-03-08 21:06:17 +00:00
Jung-uk Kim
644af48df6 Stop hard-coding default directory mode as 0777. 2011-03-08 20:13:29 +00:00
Pyun YongHyeon
d9efae0351 Rearrange dc_tx_underrun() a bit to correctly set TX FIFO threshold
value. Controllers that always require "store and forward" mode(
Davicom and PNIC 82C168) have no way to recover from TX underrun
except completely reinitializing hardware. Previously only Davicom
was reinitialized and the TX FIFO threshold was changed not to use
"store and forward" mode after reinitialization since the default
FIFO threshold value was 0. This effectively disabled Davicom
controller's "store and forward" mode once it encountered TX
underruns. In theory, this can cause watchodg timeouts.

Intel 21143 controller requires TX MAC should be idle before
changing TX FIFO threshold. So driver tried to disable TX MAC and
checked whether it saw the idle state of TX MAC. Driver should
perform full hardware reinitialization on failing to enter to idle
state and it should not touch TX MAC again once it performed full
reinitialization.

While I'm here remove resetting TX FIFO threshold to 0 when
interface is put into down state. If driver ever encountered TX
underrun, it's likely to trigger TX underrun again whenever
interface is brought to up again. Keeping old/learned TX FIFO
threshold value shall reduce the chance of seeing TX underrns in
next run.
2011-03-08 19:49:16 +00:00
Dmitry Chagin
e3b36f9b6a Bump __FreeBSD_version for struct sysvec (sv_schedtail) changes. 2011-03-08 19:05:14 +00:00
Dmitry Chagin
e5d81ef1b5 Extend struct sysvec with new method sv_schedtail, which is used for an
explicit process at fork trampoline path instead of eventhadler(schedtail)
invocation for each child process.

Remove eventhandler(schedtail) code and change linux ABI to use newly added
sysvec method.

While here replace explicit comparing of module sysentvec structure with the
newly created process sysentvec to detect the linux ABI.

Discussed with:	kib

MFC after:	2 Week
2011-03-08 19:01:45 +00:00
Pawel Jakub Dawidek
cae905e5d0 Correct readdir over ZFS handling.
Reported by:	Pierre Beyssac <pb@fasterix.frmug.org>
MFC after:	1 month
2011-03-08 18:39:41 +00:00
Maxim Sobolev
20cc2dc42e Some linux distros put mount point into the ext2fs labels, such as '/', or
'/boot', which confuses the devfs code and can cause userland programs to
fail reading /dev/ext2fs directory with weird error code, such as any
program that uses pwlib.

Strip any leading slashes before feeding the label to the geom_label code.

Sponsored by:	Sippy Software, Inc.

MFC after:	1 week
2011-03-08 17:00:31 +00:00
John Baldwin
e84c2db137 When constructing a new cpuset, apply the parent cpuset's mask to the new
set's mask rather than the root mask.  This was causing the root mask to
be modified incorrectly.

Reviewed by:	jeff
MFC after:	1 week
2011-03-08 14:18:21 +00:00
Adrian Chadd
87cd3ddacc Update to keep in sync with the HAL 2011-03-08 12:08:23 +00:00
Randall Stewart
f79aab1866 Tunes and fixes the new DC-CC to seem to hit the
right mix.  Still may need some tweaks but it
appears to almost not give away too much to an
RFC2581 flow, but can really minimize the amount of
buffers used in the net.

MFC after:	3 months
2011-03-08 11:58:25 +00:00
Konstantin Belousov
fd7032e1b3 Do not assert buffer lock in VFS_STRATEGY() when kernel already paniced.
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
2011-03-08 11:50:59 +00:00
Hans Petter Selasky
56b57046f4 - Bugfix: Root HUBs do not support re-enumeration.
MFC after:	14 days
Approved by:	thompsa (mentor)
2011-03-08 08:02:39 +00:00
Adrian Chadd
2836e2ae73 Break out the ath regulatory domain structures into a separate header file. 2011-03-08 07:42:09 +00:00
Adrian Chadd
48c1d36479 Implement open-loop TX power control (OLC) for Merlin (AR9280) and
generally tidy up the TX power programming code.

Enforce that the TX power offset for Merlin is -5 dBm, rather than
any other value programmable in the EEPROM. This requires some
further code to be ported over from ath9k, so until that is done
and tested, fail to attach NICs whose TX power offset isn't -5
dBm.

This improves both legacy and HT transmission on my merlin board.
It allows for stable MCS TX up to MCS15.

Specifics:

* Refactor out a bunch of the TX power calibration code -
  setting/obtaining the power detector / gain boundaries,
  programming the PDADC
* Take the -5 dBm TX power offset into account on Merlin -
  "0" in the per-rate TX power register means -5 dBm, not
  0 dBm
* When doing OLC
* Enforce min (0) and max (AR5416_MAX_RATE_POWER) when fiddling
  with the TX power, to avoid the TX power values from wrapping
  when low.
* Implement the 1 dBm cck power offset when doing OLC
* Implement temperature compensation for 2.4ghz mode when doing OLC
* Implement an AR9280 specific TX power calibration routine which
  includes the OLC twiddles, leaving the earlier chipset path
  (AR5416, AR9160) alone

Whilst here, use these refactored routines for the AR9285 TX power
calibration/programming code and enforce correct overflow/underflow
handling when fiddling with TX power values.

Obtained from:	linux ath9k
2011-03-08 06:59:59 +00:00
Navdeep Parhar
9458619309 cxgbe shouldn't directly know of the UMA zones where network buffers
come from.

MFC after:	1 week
2011-03-08 03:04:07 +00:00
Nathan Whitehorn
3b613c28c5 Only validate the partition setup when the user presses "Save". If the user
wants to exit without saving, it's not a problem if the disk is set up
in an invalid way.
2011-03-08 01:17:30 +00:00
Jilles Tjoelker
7b8b6c9c46 sh: Test that . /dev/null returns exit status 0 and does not preserve $?.
Preserving $? may cause problems particularly if set -e is in effect.

It may be useful to preserve the old value of $? in the dot script but this
must not be implemented in such a way that it would break this test.
2011-03-07 23:52:23 +00:00
Konstantin Belousov
0714775845 Simplify uses of the web of pointers.
Reviewed by:	mckusick
MFC after:	1 week
2011-03-07 22:36:11 +00:00
Hans Petter Selasky
7cf9b284fc - Remove superfluous ucom device lines in USB manual pages.
Submitted by:	Carl @ telus.net
MFC after:	14 days
Approved by:	thompsa (mentor)
2011-03-07 21:53:15 +00:00
Nathan Whitehorn
a43ce960b5 Remove dead code that snuck in from the 32-bit PowerPC version of this
file. The error being checked for does not exist on 64-bit systems.
2011-03-07 20:32:46 +00:00
Pawel Jakub Dawidek
a98bce2941 Unbreak the build.
MFC after:	2 weeks
2011-03-07 19:54:51 +00:00
John Baldwin
8587289fb8 The UFS dirhash code was attempting to update shared state in the dirhash
from multiple threads while holding a shared lock during a lookup operation.
This could result in incorrect ENOENT failures which could then be
permanently stored in the name cache.

Specifically, the dirhash code optimizes the case that a single thread is
walking a directory sequentially opening (or stat'ing) each file.  It uses
state in the dirhash structure to determine if a given lookup is using the
optimization.  If the optimization fails, it disables it and restarts the
lookup.  The problem arises when two threads both attempt the optimization
and fail.  The first thread will restart the loop, but the second thread
will incorrectly think that it did not try the optimization and will only
examine a subset of the directory entires in its hash chain.  As a result,
it may fail to find its directory entry and incorrectly fail with ENOENT.

To make this safe for use with shared locks, simplify the state stored in
the dirhash and move some of the state (the part that determines if the
current thread is trying the optimization) into a local variable.  One
result is that we will now try the optimization more often.  We still
update the value under the shared lock, but it is a single atomic store
similar to i_diroff that is stored in UFS directory i-nodes for the
non-dirhash lookup.

Reviewed by:	kib
MFC after:	1 week
2011-03-07 18:33:29 +00:00
David Schultz
cf3943e4d5 Add missing declarations that I intended to commit with r219359.
Not sure why we have math.h in lib/msun/ and complex.h in include/.
2011-03-07 16:05:45 +00:00
Ryan Stone
f88f24de4d Correct a typo in the malloc(3) manpage. Malloc options are set in the
MALLOC_OPTIONS environment variable, not JEMALLOC_OPTIONS.

Reviewed by:	jasone
Approved by:	emaste (mentor)
2011-03-07 15:19:17 +00:00
Martin Matuska
d93806e2f1 Add AMD Geode CPU type to bsd.cpu.mk and examples/etc/make.conf
For CPUTYPE=core2 use -march=core2

PR:		gnu/155308
MFC after:	2 weeks
2011-03-07 14:58:23 +00:00
Martin Matuska
91b1eb9429 Backport Intel Core 2 and AMD Geode CPU types from gcc-4.3 (GPLv2)
These options are supported in this shape in all newer GCC versions.

PR:		gnu/155308
Obtained from:	gcc 4.3 (rev. 118090, 118973, 120846; GPLv2)
MFC after:	2 weeks
2011-03-07 14:48:22 +00:00