]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
12 years agoDe-spl(9).
glebius [Thu, 13 Oct 2011 13:30:41 +0000 (13:30 +0000)]
De-spl(9).

12 years agoRestore functions in6_ifaddloop() and in6_ifremloop() that were
glebius [Thu, 13 Oct 2011 13:05:36 +0000 (13:05 +0000)]
Restore functions in6_ifaddloop() and in6_ifremloop() that were
inlined by Qing Li in his big new-ARP commit. I am going to utilize
them in my newcarp work, and also these functions left declared
in in6_var.h for all the time they were absent.

Reviewed by: bz

12 years agoMake kdump compile cleanly at WARNS level 6, with one exception: the
des [Wed, 12 Oct 2011 21:45:12 +0000 (21:45 +0000)]
Make kdump compile cleanly at WARNS level 6, with one exception: the
ipfilter headers contain a duplicated function declaration.  Turn off
-Werror to allow kdump to compile in spite of this.

It would be neat to be able to turn off -Werror on a file-by-file basis...

PR: bin/161478
Submitted by: Garrett Cooper <yanegomi@gmail.com>

12 years agoName these gpio pins better, they are on an external PLD and not the same as
thompsa [Wed, 12 Oct 2011 20:58:54 +0000 (20:58 +0000)]
Name these gpio pins better, they are on an external PLD and not the same as
the cpu wired gpio.

12 years agoDont just set the pin high when turning on output, use the current value. Also
thompsa [Wed, 12 Oct 2011 20:57:21 +0000 (20:57 +0000)]
Dont just set the pin high when turning on output, use the current value. Also
let this value be set when in input mode.

12 years agoAdd myself
gleb [Wed, 12 Oct 2011 20:18:13 +0000 (20:18 +0000)]
Add myself

Approved by: mdf (mentor)

12 years agoMake sure the inp wasn't dropped when rexmt let go of the inp and
np [Wed, 12 Oct 2011 19:52:23 +0000 (19:52 +0000)]
Make sure the inp wasn't dropped when rexmt let go of the inp and
pcbinfo locks.

Reviewed by: andre@
MFC after: 7 days

12 years agoDocument that memguard(9) now can guard uma(9) allocations.
glebius [Wed, 12 Oct 2011 18:46:48 +0000 (18:46 +0000)]
Document that memguard(9) now can guard uma(9) allocations.

12 years agoMake memguard(9) capable to guard uma(9) allocations.
glebius [Wed, 12 Oct 2011 18:08:28 +0000 (18:08 +0000)]
Make memguard(9) capable to guard uma(9) allocations.

12 years agoAdd symlink from clang to clang-cpp, so you can use CPP=clang-cpp in
dim [Wed, 12 Oct 2011 17:47:15 +0000 (17:47 +0000)]
Add symlink from clang to clang-cpp, so you can use CPP=clang-cpp in
Makefiles.  Also add a manpage symlink for it.

MFC after: 3 days

12 years agoAdd manpage symlink for clang++(1).
dim [Wed, 12 Oct 2011 17:25:49 +0000 (17:25 +0000)]
Add manpage symlink for clang++(1).

PR: docs/149051
MFC after: 3 days

12 years agoMissed file in r225937 (sysinstall removal).
nwhitehorn [Wed, 12 Oct 2011 15:34:25 +0000 (15:34 +0000)]
Missed file in r225937 (sysinstall removal).

12 years agoIf an allocation for a specific resource range fails because it is not in
jhb [Wed, 12 Oct 2011 14:13:32 +0000 (14:13 +0000)]
If an allocation for a specific resource range fails because it is not in
a decoded range for an ACPI Host-PCI bridge, try to allocate it from the
ACPI system resource range.  If that works, permit the resource allocation
regardless.

MFC after: 1 week

12 years agoCorrect a bug in export of capability-related information from the sysctls
rwatson [Wed, 12 Oct 2011 12:08:03 +0000 (12:08 +0000)]
Correct a bug in export of capability-related information from the sysctls
supporting procstat -f: properly provide capability rights information to
userspace.  The bug resulted from a merge-o during upstreaming (or rather,
a failure to properly merge FreeBSD-side changed downstream).

Spotted by:     des, kibab
MFC after:      3 days

12 years agoFix an unused variable warning/error when invariants isn't enabled.
adrian [Wed, 12 Oct 2011 10:19:55 +0000 (10:19 +0000)]
Fix an unused variable warning/error when invariants isn't enabled.

Reported by: bz

12 years agoDon't call fixup_filename() on each witness lock call.
adrian [Wed, 12 Oct 2011 09:21:02 +0000 (09:21 +0000)]
Don't call fixup_filename() on each witness lock call.

This has been irking me for a while. This causes significant
CPU use on bottlenecked CPUs (eg my older EEEPC w/ an earlier
Celeron CPU and my MIPS24k boards) when they're passing
a lot of traffic.

Since the file/line values are only used for printing, this
should only affect display. It should have no operational
change on the code, besides reducing CPU use.

12 years agoMFV of tzdata2011l, r226279
edwin [Wed, 12 Oct 2011 09:13:16 +0000 (09:13 +0000)]
MFV of tzdata2011l, r226279

Changes in 2011i:

    Africa
    - Added South Sudan: Africa/Juba

    Australasia:
    - Samoa will go forward 24 hours at 30 December 2011 to better match
      the day of the week with its neighbours.

    Europe:
    - Europe/Kaliningrad will have the timezone KALT.

    North America:
    - Updates to Metlakatla historical data
    - Newfoundland, Labrador and Resolute will do something which I
      can't figure out.

    iso3166tab;
    - Add SS for South Sudan.

Changes in 2011j:

    - Samoa will go from 29 December 23:59:59 to 31 December 00:00:00.
    - Samoa DST will end on 1 April 2012

Changes in 2011k:

    - Gaza / West Bank goes back to standard time on 02 August 2011.
    - West Bank went bac kto DST on 30 August 2011.
    - Lots of changes in Minsk (GMT+3 without DST) and other Russian
      regions. A new timezone has been created for them, FET: Further-eastern
      European Time aka GMT+3.
    - Add Asian/Hebron to the zone.tab file.

Changes in 2011l:

    - West Bank came out of DST on 30 September 2011.
    - Fiji will g oin DST on 23 October and out of it on 26 Februari
    - State Bahia might go back to DST in 16 October 2011

    Due to legal problems, ado and Paul Eggert have to temporary suspend
    their work on the timezone database
    (http://thread.gmane.org/gmane.comp.time.tz/4133). Their work has
    been continued by volunteers on the tz community and the hosting
    of the data files is done by Robert Elz at ftp://munnari.oz.au/pub/.

Obtained from: ftp://munnari.oz.au/pub, ftp://elsie.nci.nih.gov/pub/

12 years agoUpdates from Newsletter VI-9 and VI-10:
edwin [Wed, 12 Oct 2011 07:00:50 +0000 (07:00 +0000)]
Updates from Newsletter VI-9 and VI-10:

    Newsletter VI-9 2011-06-12
    Name changes for Fiji and Myanmar as well as other minor corrections

    Newsletter VI-10 2011-08-09
    Code elements for South Sudan.

Reviewed by: http://www.iso.org/iso/country_codes.html

12 years agoNow that the portsnap buildbox is generating the raw bits for INDEX-9,
cperciva [Wed, 12 Oct 2011 03:29:12 +0000 (03:29 +0000)]
Now that the portsnap buildbox is generating the raw bits for INDEX-9,
add it to the set of INDEX files built by portsnap.

12 years ago - Fix an off-by-one bug in addgroup().
delphij [Wed, 12 Oct 2011 01:19:12 +0000 (01:19 +0000)]
 - Fix an off-by-one bug in addgroup().
 - Fix the error message when setgid() failed.

PR: bin/161509
Submitted by: Jeremy Huddleston <jeremyhu apple com>
MFC after: 2 weeks

12 years ago- Fix counting of match limit (-m)
gabor [Wed, 12 Oct 2011 01:09:57 +0000 (01:09 +0000)]
- Fix counting of match limit (-m)

Reported by: Nali Toja <nalitoja@gmail.com>
Approved by: delphij (mentor)

12 years ago- Use getprogname() instead of __progname
gabor [Tue, 11 Oct 2011 22:27:23 +0000 (22:27 +0000)]
- Use getprogname() instead of __progname
- Allow disabling bzip2 support with WITHOUT_BZIP2
- Fix handling patterns that start with a dot
- Remove superfluous semicolon

Approved by: delphij (mentor)

12 years ago- Remove unused remnants of MII bitbang'ing.
marius [Tue, 11 Oct 2011 21:52:24 +0000 (21:52 +0000)]
- Remove unused remnants of MII bitbang'ing.
- Sprinkle const.

12 years agoAdd a new trace point, KTRFAC_CAPFAIL, which traces capability check
des [Tue, 11 Oct 2011 20:37:10 +0000 (20:37 +0000)]
Add a new trace point, KTRFAC_CAPFAIL, which traces capability check
failures.  It is included in the default set for ktrace(1) and kdump(1).

12 years agoAfter creating a filesystem using newfs -j the time stamps are all
mckusick [Tue, 11 Oct 2011 19:03:57 +0000 (19:03 +0000)]
After creating a filesystem using newfs -j the time stamps are all
zero and thus report as having been made in January 1970. Apart
from looking a bit silly, it also triggers alarms from scripts
that detect weird time stamps. This update sets all 4 (or 3, in
the case of UFS1) time stamps to the current time when enabling
journaling during newfs or later when enabling it with tunefs.

Reported by: Hans Ottevanger <hans@beastielabs.net>
MFC after:   1 week

12 years agoWhen unmounting a filesystem always wait for the vfs_busy lock to clear
mckusick [Tue, 11 Oct 2011 18:46:41 +0000 (18:46 +0000)]
When unmounting a filesystem always wait for the vfs_busy lock to clear
so that if no vnodes in the filesystem are actively in use the unmount
will succeed rather than failing with EBUSY.

Reported by: Garrett Cooper
Reviewed by: Attilio Rao and Kostik Belousov
Tested by:   Garrett Cooper
PR:          kern/161016
MFC after:   3 weeks

12 years agoFix date in last commit.
glebius [Tue, 11 Oct 2011 18:26:31 +0000 (18:26 +0000)]
Fix date in last commit.

Noticed by: Larry Rosenman <ler lerctr.org>

12 years agoProperly document default number of rx/tx descriptors for Intel cards.
glebius [Tue, 11 Oct 2011 15:41:07 +0000 (15:41 +0000)]
Properly document default number of rx/tx descriptors for Intel cards.

12 years agoThe previous commit did not fix the issue since it did not prevent sign
des [Tue, 11 Oct 2011 15:04:58 +0000 (15:04 +0000)]
The previous commit did not fix the issue since it did not prevent sign
extension.  Cast to u_register_t first, then to uintmax_t.

Submitted by: bde@

12 years agoAdd curly braces missed in r226247.
brueffer [Tue, 11 Oct 2011 13:40:37 +0000 (13:40 +0000)]
Add curly braces missed in r226247.

Pointy hat to: brueffer
Submitted by: many
MFC after: 1 week

12 years agoUse the most significant 6 bits of the dscp instead of the least
tuexen [Tue, 11 Oct 2011 13:24:37 +0000 (13:24 +0000)]
Use the most significant 6 bits of the dscp instead of the least
significant ones.
This has changed in the latest version of the socket API ID and
provides backwards compatibility and gets it in syn with the
usage of the IP_TOS socket option.

MFC after: 3 days.

12 years agoProperly free linux_gidset in case of an error.
brueffer [Tue, 11 Oct 2011 10:32:23 +0000 (10:32 +0000)]
Properly free linux_gidset in case of an error.

CID: 4136
Found with: Coverity Prevent(tm)
MFC after: 1 week

12 years agoCast to unsigned for %#jx.
des [Tue, 11 Oct 2011 07:46:45 +0000 (07:46 +0000)]
Cast to unsigned for %#jx.

Noticed by: jh@

12 years agoRefactor this code by introducing separate functions to handle the
das [Tue, 11 Oct 2011 05:17:45 +0000 (05:17 +0000)]
Refactor this code by introducing separate functions to handle the
extra-precision add and multiply operations. This simplifies future
work but shouldn't result in any functional change.

12 years agoAlso pass the -ansi flag through to mkdep (requested by bde), and fix
das [Tue, 11 Oct 2011 05:17:26 +0000 (05:17 +0000)]
Also pass the -ansi flag through to mkdep (requested by bde), and fix
a cut-and-paste-o (noticed by rdivacky).

12 years agoFix build after TARGET_BIG_ENDIAN was nuked from orbit.
thompsa [Tue, 11 Oct 2011 01:11:57 +0000 (01:11 +0000)]
Fix build after TARGET_BIG_ENDIAN was nuked from orbit.

12 years agoMake unionfs also clear VAPPEND when clearing VWRITE, since VAPPEND
trasz [Mon, 10 Oct 2011 21:32:08 +0000 (21:32 +0000)]
Make unionfs also clear VAPPEND when clearing VWRITE, since VAPPEND
is just a modifier for VWRITE.

Submitted by: rmacklem

12 years agoAll indirect routes will fail the rtcheck, except for a special host
qingli [Mon, 10 Oct 2011 17:41:11 +0000 (17:41 +0000)]
All indirect routes will fail the rtcheck, except for a special host
route where the destination IP and the gateway IP is the same. This
special case handling is only meant for backward compatibility reason.
The last commit introduced a bug in the route check logic, where a
valid special case is treated as an error. This patch fixes that bug
along with some code cleanup.

Suggested by: gleb
Reviewed by: kmacy, discussed with gleb
MFC after: 1 day

12 years agoGet struct sctp_net_route in tune with struct route.
tuexen [Mon, 10 Oct 2011 16:31:18 +0000 (16:31 +0000)]
Get struct sctp_net_route in tune with struct route.
struct route was changed in
http://svn.freebsd.org/changeset/base/225698
and since then SCTP support was broken.
This needs to be MFCed to stable/9 to unbreak SCTP support in 9.0
MFC after: 3 days.

12 years agoAdd USB mass storage quirk for device that emits errors after the automatic
hselasky [Mon, 10 Oct 2011 16:26:06 +0000 (16:26 +0000)]
Add USB mass storage quirk for device that emits errors after the automatic
no synchronize cache detection.

Submitted by: Scott Allendorf
MFC after: 3 days

12 years agoFix how libusb20_dev_kernel_driver_active() and
hselasky [Mon, 10 Oct 2011 16:13:33 +0000 (16:13 +0000)]
Fix how libusb20_dev_kernel_driver_active() and
libusb_dev_kernel_driver_active() works. In case of
libusb20 the manpage was wrong and in case of
libusb10 the implementation was wrong.

Submitted by: Kai Wang
MFC after: 3 days

12 years agoBugfix: The ucom detach function is sometimes called on zeroed structures.
hselasky [Mon, 10 Oct 2011 15:54:44 +0000 (15:54 +0000)]
Bugfix: The ucom detach function is sometimes called on zeroed structures.
Check for this case and just return, so that the UCOM unit number zero is
not accidentially freed.

Submitted by: Danish FreeBSD user at EuroBSDcon 2011
MFC after: 3 days

12 years agoProvide external definitions of all of the standardized functions in
das [Mon, 10 Oct 2011 15:43:09 +0000 (15:43 +0000)]
Provide external definitions of all of the standardized functions in
fenv.h that are currently inlined.

The definitions are provided in fenv.c via 'extern inline'
declaractions.  This assumes the compiler handles 'extern inline' as
specified in C99, which has been true under FreeBSD since 8.0.

The goal is to eventually remove the 'static' keyword from the inline
definitions in fenv.h, so that non-inlined references all wind up
pointing to the same external definition like they're supposed to.
I am deferring the second step to provide a window where
newly-compiled apps will still link against old math libraries.
(This isn't supported, but there's no need to cause undue breakage.)

Reviewed by:    stefanf, bde

12 years agoAdd a FBSD_1.3 namespace for FreeBSD 10.
das [Mon, 10 Oct 2011 15:42:33 +0000 (15:42 +0000)]
Add a FBSD_1.3 namespace for FreeBSD 10.

12 years agoPass -std= flags in CFLAGS to mkdep. Without this, preprocessor tests
das [Mon, 10 Oct 2011 15:39:29 +0000 (15:39 +0000)]
Pass -std= flags in CFLAGS to mkdep. Without this, preprocessor tests
for particular compiler features might be evaluated differently by
mkdep than they would be by cc.

12 years agoDo not ignore block offsets.
kib [Mon, 10 Oct 2011 13:26:53 +0000 (13:26 +0000)]
Do not ignore block offsets.

PR: kern/160943
Submitted by: Craig Boston <cb severious net>
Reviewed by: Danny Braniss <danny cs huji ac il>
MFC after: 1 week

12 years agoWhen moving an stcb to a new inp and we copy over the list of
tuexen [Mon, 10 Oct 2011 12:28:47 +0000 (12:28 +0000)]
When moving an stcb to a new inp and we copy over the list of
bound addresses, update the last used address pointer.
If not, it might result in a crash if the old inp goes away.

MFC after: 3 days.

12 years agoFree mbuf in case when protocol in unknown in ng_ipfw_rcvdata().
melifaro [Mon, 10 Oct 2011 09:33:07 +0000 (09:33 +0000)]
Free mbuf in case when protocol in unknown in ng_ipfw_rcvdata().
This change fixes (theoretically) possible mbuf leak introduced in
r225586. Reorder code a bit and change return codes to be more specific

Reviewed by: glebius
Approved by:    kib (mentor)

12 years agoAdd missing break statement to make sure all 3DES etypes really are treated
brueffer [Mon, 10 Oct 2011 09:13:07 +0000 (09:13 +0000)]
Add missing break statement to make sure all 3DES etypes really are treated
the same.

CID: 3624
Found with: Coverity Prevent(tm)
Reviewed by: dfr
MFC after: 1 week

12 years agoIncorporate recent changes from NetBSD. Most notable change is the addition
delphij [Mon, 10 Oct 2011 06:37:32 +0000 (06:37 +0000)]
Incorporate recent changes from NetBSD.  Most notable change is the addition
of support of decompressing xz files.

Obtained from: NetBSD

12 years agoProperly use the cursor to bound the position for CUP.
ed [Mon, 10 Oct 2011 06:13:27 +0000 (06:13 +0000)]
Properly use the cursor to bound the position for CUP.

We must take the origin region into account when clamping the cursor
position.

MFC after: 3 days

12 years agoFix an incorrect use of sizeof().
adrian [Mon, 10 Oct 2011 02:54:58 +0000 (02:54 +0000)]
Fix an incorrect use of sizeof().

Obtained from: OpenBSD sys/dev/ic/bwi.c r1.87

12 years agoUpdate from OpenBSD: Include 0x4402 in the bbp id mapping table used on older devices.
adrian [Mon, 10 Oct 2011 02:49:21 +0000 (02:49 +0000)]
Update from OpenBSD: Include 0x4402 in the bbp id mapping table used on older devices.

http://bcm-specs.sipsolutions.net/BackPlane agrees.

Obtained from: OpenBSD, sys/dev/ic/bwi.c r1.88

12 years agoAdd a "kern.features.ata_cam" sysctl in the kernel when the ATA_CAM kernel
rodrigc [Sun, 9 Oct 2011 21:42:02 +0000 (21:42 +0000)]
Add a "kern.features.ata_cam" sysctl in the kernel when the ATA_CAM kernel
option is defined.  This sysctl can be queried by feature_present(3).

Query for this feature in /sbin/atacontrol and /usr/sbin/burncd.
If these utilities detect that ATA_CAM is enabled, then these utilities
will error out.  These utilities are compatible with the old ATA
driver, but are incomptible with the new ATA_CAM driver.  By erroring out,
we give end-users an idea as to what remedies to use, and reduce the need for them
to file PR's.  For atacontrol, camcontrol must be used instead,
and for burncd, alternative utilties from the ports collection must be used
such as sysutils/cdrtools.

In future, maybe someone can re-write burncd to work with ATA_CAM,
but at least for now, we give a somewhat useful error message to end users.

PR: 160979
Reviewed by: jh, Arnaud Lacombe <lacombar at gmail dot com>
Reported by: Joe Barbish <fbsd8 at a1poweruser dot com>
MFC after: 3 days

12 years agoRecognize the Intel(R) Centrino(R) Wireless-N 130.
marius [Sun, 9 Oct 2011 21:36:14 +0000 (21:36 +0000)]
Recognize the Intel(R) Centrino(R) Wireless-N 130.

PR: 161162

12 years agoIn device_get_children() avoid malloc(0) in order to increase portability
marius [Sun, 9 Oct 2011 21:21:37 +0000 (21:21 +0000)]
In device_get_children() avoid malloc(0) in order to increase portability
to other operating systems.

PR:     154287

12 years agoPrefer KOBJMETHOD_END.
marius [Sun, 9 Oct 2011 20:27:20 +0000 (20:27 +0000)]
Prefer KOBJMETHOD_END.

12 years agoBump .Dd to reflect the date of the last content change, so MFC content
gjb [Sun, 9 Oct 2011 20:21:07 +0000 (20:21 +0000)]
Bump .Dd to reflect the date of the last content change, so MFC content
makes sense.

Pointy-hat to: gjb (myself)

12 years agoSprinkle const.
marius [Sun, 9 Oct 2011 20:16:51 +0000 (20:16 +0000)]
Sprinkle const.

12 years agoUse UFS labels and bsdlabels (like the 8.x memsticks) instead of GPT to
nwhitehorn [Sun, 9 Oct 2011 16:23:04 +0000 (16:23 +0000)]
Use UFS labels and bsdlabels (like the 8.x memsticks) instead of GPT to
fix problems with some BIOSes.

MFC after: 3 days

12 years agoAdd support to makefs(8) to add UFS labels to images.
nwhitehorn [Sun, 9 Oct 2011 16:22:31 +0000 (16:22 +0000)]
Add support to makefs(8) to add UFS labels to images.

Submitted by: avg
MFC after: 3 days

12 years agoUpdate the inp stored in a HB-timer when moving an stcb to a new inp.
tuexen [Sun, 9 Oct 2011 14:12:17 +0000 (14:12 +0000)]
Update the inp stored in a HB-timer when moving an stcb to a new inp.
Use only this stored inp when processing a HB timeout.
This fixes a bug which results in a crash.

MFC after: 3 days.

12 years agoLine up the struct declaration (yes, I know this isn't what it looks
des [Sun, 9 Oct 2011 10:58:58 +0000 (10:58 +0000)]
Line up the struct declaration (yes, I know this isn't what it looks
like in the header file)

12 years agoDocument some not-so-recently added trace points.
des [Sun, 9 Oct 2011 10:55:15 +0000 (10:55 +0000)]
Document some not-so-recently added trace points.

MFC after: 1 week

12 years agoRemove inphy(4), exphy(4) as well as ruephy(4) that no longer existed as a
marius [Sat, 8 Oct 2011 21:15:39 +0000 (21:15 +0000)]
Remove inphy(4), exphy(4) as well as ruephy(4) that no longer existed as a
separate config option, which was missed in r226154.

12 years agoAddress some of bde@'s concerns with the new code.
des [Sat, 8 Oct 2011 21:02:08 +0000 (21:02 +0000)]
Address some of bde@'s concerns with the new code.

12 years agoFix the handling of an empty kmem map by sysctl_kmem_map_free(). In
alc [Sat, 8 Oct 2011 18:29:30 +0000 (18:29 +0000)]
Fix the handling of an empty kmem map by sysctl_kmem_map_free().  In
the unlikely event that sysctl_kmem_map_free() was performed on an
empty kmem map, it would incorrectly report the free space as zero.

Discussed with: avg
MFC after: 1 week

12 years agoRevert unapproved commit to bsd.port.mk.
crees [Sat, 8 Oct 2011 18:25:01 +0000 (18:25 +0000)]
Revert unapproved commit to bsd.port.mk.

This would have had more discussion, but it was explicitly rejected at submission by portmgr:

http://lists.freebsd.org/pipermail/freebsd-ports/2011-September/070591.html

12 years agoAvoid magicking into existence sub-partitions due to leftover blocks when
nwhitehorn [Sat, 8 Oct 2011 16:45:03 +0000 (16:45 +0000)]
Avoid magicking into existence sub-partitions due to leftover blocks when
creating new ones by destroying any geom that may have come into
existence immediately after adding a partition. The EBR partition scheme
is particularly enthusiastic about false positives in this case.

MFC after: 3 days

12 years agoUsability enhancements: do not allow setting a mountpoint on bsdlabel
nwhitehorn [Sat, 8 Oct 2011 14:59:12 +0000 (14:59 +0000)]
Usability enhancements: do not allow setting a mountpoint on bsdlabel
container partitions, which didn't do anything anyway, and check for
an existing freebsd-boot partition before bothering the user to make one.

PR: bin/160931
MFC after: 3 days

12 years agoTeach kdump(1) to decode capability bitmasks.
des [Sat, 8 Oct 2011 13:01:38 +0000 (13:01 +0000)]
Teach kdump(1) to decode capability bitmasks.

MFC after: 3 weeks

12 years agoFix the dependency issue properly by a) moving kdump_subr.c to the front
des [Sat, 8 Oct 2011 12:59:41 +0000 (12:59 +0000)]
Fix the dependency issue properly by a) moving kdump_subr.c to the front
of the SRCS list and b) listing kdump_subr.h in DPSRCS.

12 years agoBring ioctlname() in line with all the other *name() functions, which
des [Sat, 8 Oct 2011 12:47:00 +0000 (12:47 +0000)]
Bring ioctlname() in line with all the other *name() functions, which
actually print the name (or the numeric value, if they can't figure out
the correct name) instead of just returning a pointer to it.  Also, since
ioctl numbers are not and probably never will be unique, drop support for
using a switch statement instead of an if/else chain.

12 years agoHandle the R_386_TLS_TPOFF32 relocation, which is similar to R_386_TLS_TPOFF,
kib [Sat, 8 Oct 2011 12:42:19 +0000 (12:42 +0000)]
Handle the R_386_TLS_TPOFF32 relocation, which is similar to R_386_TLS_TPOFF,
but with negative relocation value.

Found by: mpfr test suite, pointed to by ale
Reviewed by: kan
MFC after: 1 week

12 years agoSetting up TLS block for the main thread must be done after the
kib [Sat, 8 Oct 2011 12:39:47 +0000 (12:39 +0000)]
Setting up TLS block for the main thread must be done after the
relocations are processed, since tls initialization section might be
itself subject for relocations. Only set up of the block is postponed,
the tls block offsets are allocated before relocation processing, since
TLS-related relocations may need offsets ready.

Reported by: ale
PR: threads/161344
Reviewed by: kan
MFC after: 1 week

12 years ago- Follow the lead of dcphy(4) and pnphy(4) and move the reminder of the PHY
marius [Sat, 8 Oct 2011 12:33:10 +0000 (12:33 +0000)]
- Follow the lead of dcphy(4) and pnphy(4) and move the reminder of the PHY
  drivers that only ever attach to a particular MAC driver, i.e. inphy(4),
  ruephy(4) and xlphy(4), to the directory where the respective MAC driver
  lives and only compile it into the kernel when the latter is also there,
  also removing it from miibus.ko and moving it into the module of the
  respective MAC driver.
- While at it, rename exphy.c, which comes from NetBSD where the MAC driver
  it corresponds to also is named ex(4) instead of xl(4) but that in FreeBSD
  actually identifies itself as xlphy(4), and its function names accordingly
  for consistency.
- Additionally while at it, fix some minor style issues like whitespace
  in the register headers and add multi-inclusion protection to inphyreg.h.

12 years agoI appreciate the logic behind using a (void) cast to indicate that the
des [Sat, 8 Oct 2011 12:28:06 +0000 (12:28 +0000)]
I appreciate the logic behind using a (void) cast to indicate that the
return value is intentionally ignored, but frankly, all it does is
get in the way of the code.

Also fix a few other incorrect casts, such as (void *)malloc(foo) and
passing signed values to %x.

12 years agoFix casting.
des [Sat, 8 Oct 2011 12:21:51 +0000 (12:21 +0000)]
Fix casting.

12 years agoWhitespace.
des [Sat, 8 Oct 2011 12:10:16 +0000 (12:10 +0000)]
Whitespace.

12 years agoFix an infinite loop in siba_bwn_suspend().
brueffer [Sat, 8 Oct 2011 12:09:57 +0000 (12:09 +0000)]
Fix an infinite loop in siba_bwn_suspend().

CID: 3536
Found with: Coverity Prevent(tm)
MFC after: 1 week

12 years agoC has had swicth statements for 40 years or so. It's about time we
des [Sat, 8 Oct 2011 11:51:48 +0000 (11:51 +0000)]
C has had swicth statements for 40 years or so.  It's about time we
started using them.

12 years agoSort and line up.
des [Sat, 8 Oct 2011 11:39:00 +0000 (11:39 +0000)]
Sort and line up.

12 years agoRemove dead code, "error" doesn't change between this check and the
brueffer [Sat, 8 Oct 2011 10:50:48 +0000 (10:50 +0000)]
Remove dead code, "error" doesn't change between this check and the
previous one.

CID: 3254
Found with: Coverity Prevent(tm)
MFC after: 1 week

12 years ago1) Some of the #defines or enums for which we auto-generate naming
des [Sat, 8 Oct 2011 09:57:29 +0000 (09:57 +0000)]
1) Some of the #defines or enums for which we auto-generate naming
   functions may be wider than int, so use intmax_t throughout.  Also
   add missing casts in printf() calls.

2) Clean up some of the auto-generated code to improve readability.

3) Auto-generate kdump_subr.h.  Note that this requires a semi-ugly hack
   in the Makefile to make sure it is generated before make(1) tries to
   build kdump.c, or preprocess it for 'make depend'.

MFC after: 3 weeks

12 years agoRemove two dublicated assignments.
brueffer [Sat, 8 Oct 2011 09:14:18 +0000 (09:14 +0000)]
Remove two dublicated assignments.

CID: 9870
Found with: Coverity Prevent(tm)
Confirmed by: rwatson
MFC after: 1 week

12 years agoRemove extraneous WARNS=7.
ed [Sat, 8 Oct 2011 07:20:12 +0000 (07:20 +0000)]
Remove extraneous WARNS=7.

WARNS above 6 has no use. Also, all of usr.bin is also built with
WARNS=6 by default.

Discussed with: edwin

12 years ago- Add a couple of more sed subsitutions needed to get the correct
stas [Sat, 8 Oct 2011 00:01:17 +0000 (00:01 +0000)]
- Add a couple of more sed subsitutions needed to get the correct
  libtool.m4.  With these fixes libtool will correctly indentify the
  system as ELF (and not a.out).
- While here, change the substitutions so they're still correctly
  match freebsd1.x, freebsd2.x etc.

12 years agoBCE_MISC_ID register of BCM5716 returns the same id of BCM5709 so
yongari [Sat, 8 Oct 2011 00:00:54 +0000 (00:00 +0000)]
BCE_MISC_ID register of BCM5716 returns the same id of BCM5709 so
remove explicit checks for BCM5716.
The BCM5709 and BCM5716 chips are virtually indistinguishable by
software except for the PCI device ID.  The two chips differ in
that BCM5709 supports TCP/IP and iSCSI offload in Windows while
the BCM5716 doesn't.
While I'm here remove now unused definition of BCE_CHIP_NUM_5716
and BCE_CHIP_ID_5716_C0.

Reported by: sbruno
Reviewed by: davidch
Tested by: davidch

12 years ago- ${WRKSRC} might be missing when the autotools fixup is running.
stas [Fri, 7 Oct 2011 23:43:51 +0000 (23:43 +0000)]
- ${WRKSRC} might be missing when the autotools fixup is running.
  Account for this.

Reported by: Mykola Dzham <i@levsha.me>

12 years agoAdd myself.
jceel [Fri, 7 Oct 2011 23:12:33 +0000 (23:12 +0000)]
Add myself.

Approved by: wkoszek (mentor)

12 years agoDo not try removing an ARP entry associated with a given interface
qingli [Fri, 7 Oct 2011 22:22:19 +0000 (22:22 +0000)]
Do not try removing an ARP entry associated with a given interface
address if that interface does not support ARP. Otherwise the
system will generate error messages unnecessarily due to the missing
entry.

PR: kern/159602
Submitted by: pluknet
MFC after: 3 days

12 years agoMention tdsignal(9).
des [Fri, 7 Oct 2011 22:14:18 +0000 (22:14 +0000)]
Mention tdsignal(9).

MFC after: 1 week

12 years agoSync with ahc(4)/ahd(4)/sym(4) etc:
marius [Fri, 7 Oct 2011 21:23:42 +0000 (21:23 +0000)]
Sync with ahc(4)/ahd(4)/sym(4) etc:
Zero any sense not transferred by the device as the SCSI specification
mandates that any untransferred data should be assumed to be zero.

Reviewed by: ken

12 years agoAdd missing va_end() in an error case to clean up after va_start()
brueffer [Fri, 7 Oct 2011 21:00:26 +0000 (21:00 +0000)]
Add missing va_end() in an error case to clean up after va_start()
(already done in the non-error case).

CID: 4726
Found with: Coverity Prevent(tm)
MFC after: 1 week

12 years agoAdd missing va_end() to clean up after va_start().
brueffer [Fri, 7 Oct 2011 20:54:12 +0000 (20:54 +0000)]
Add missing va_end() to clean up after va_start().

CID: 4725
Found with: Coverity Prevent(tm)
MFC after: 1 week

12 years agoRemove the reference held on the loopback route when the interface
qingli [Fri, 7 Oct 2011 18:01:34 +0000 (18:01 +0000)]
Remove the reference held on the loopback route when the interface
address is being deleted. Only the last reference holder deletes the
loopback route. All other delete operations just clear the IFA_RTSELF
flag.

PR: kern/159601
Submitted by: pluknet
Reviewed by: discussed on net@
MFC after: 3 days

12 years agoPrevent TCP sessions from stalling indefinitely in reassembly
andre [Fri, 7 Oct 2011 16:39:03 +0000 (16:39 +0000)]
Prevent TCP sessions from stalling indefinitely in reassembly
when reaching the zone limit of reassembly queue entries.

When the zone limit was reached not even the missing segment
that would complete the sequence space could be processed
preventing the TCP session forever from making any further
progress.

Solve this deadlock by using a temporary on-stack queue entry
for the missing segment followed by an immediate dequeue again
by delivering the contiguous sequence space to the socket.

Add logging under net.inet.tcp.log_debug for reassembly queue
issues.

Reviewed by: lsteward (previous version)
Tested by:  Steven Hartland <killing-at-multiplay.co.uk>
MFC after: 3 days

12 years agoRemove unused define.
kib [Fri, 7 Oct 2011 16:09:44 +0000 (16:09 +0000)]
Remove unused define.

MFC after: 1 month

12 years agoFix whitespace inconsistencies found in homegrown Symbol.maps.
ed [Fri, 7 Oct 2011 15:05:24 +0000 (15:05 +0000)]
Fix whitespace inconsistencies found in homegrown Symbol.maps.

12 years agoAdd back the IP header length to the total packet length field on
andre [Fri, 7 Oct 2011 13:43:01 +0000 (13:43 +0000)]
Add back the IP header length to the total packet length field on
raw IP sockets.  It was deducted in ip_input() in preparation for
protocols interested only in the payload.

On raw sockets the IP header should be delivered as it at came in
from the network except for the byte order swaps in some fields.

This brings us in line with all other OS'es that provide raw
IP sockets.

Reported by: Matthew Cini Sarreo <mcins1-at-gmail.com>
MFC after: 3 days