]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
13 years agoFix r223695 to compile on architectures which don't use the MBR scheme; wrap
Marius Strobl [Fri, 1 Jul 2011 18:31:59 +0000 (18:31 +0000)]
Fix r223695 to compile on architectures which don't use the MBR scheme; wrap
the MBR support in the common part of the loader in #ifdef's and enable it
only for userboot for now.

13 years agoDefine cap_rights_t and DTYPE_CAPABILITY, which are required to
Jonathan Anderson [Fri, 1 Jul 2011 12:13:48 +0000 (12:13 +0000)]
Define cap_rights_t and DTYPE_CAPABILITY, which are required to
implement Capsicum capabilities.

Approved by: mentor (rwatson), re (bz)

13 years agoBump date after the previous commit.
Sergey Kandaurov [Fri, 1 Jul 2011 10:57:10 +0000 (10:57 +0000)]
Bump date after the previous commit.

13 years agoUpdate and sort the list of the available keywords.
Sergey Kandaurov [Fri, 1 Jul 2011 10:54:47 +0000 (10:54 +0000)]
Update and sort the list of the available keywords.

13 years agoFix double free.
Gleb Smirnoff [Fri, 1 Jul 2011 08:27:03 +0000 (08:27 +0000)]
Fix double free.

Submitted by: Alexander V. Chernikov <melifaro ipfw.ru>

13 years agoMake lukemftpd properly set login class and cpumask.
Edward Tomasz Napierala [Thu, 30 Jun 2011 20:58:38 +0000 (20:58 +0000)]
Make lukemftpd properly set login class and cpumask.

13 years agoMake Sendmail properly set login class and cpumask.
Edward Tomasz Napierala [Thu, 30 Jun 2011 20:55:16 +0000 (20:55 +0000)]
Make Sendmail properly set login class and cpumask.

13 years agoChange the management of nested faults by switching to physical
Marcel Moolenaar [Thu, 30 Jun 2011 20:34:55 +0000 (20:34 +0000)]
Change the management of nested faults by switching to physical
addressing while reading or writing the trap frame. It's not
possible to guarantee that the one translation cache entry that
we depend on is not going to get purged by the CPU. We already
know that global shootdowns (ptc.g and/or ptc.ga) can (and will)
cause multiple TC entries to get purged and we initialize tried
to handle that by serializing kernel entry with these operations.
However, we need to serialize kernel exit as well.

But even if we can serialize, it appears that CPU threads within
a core can affect each other's TC entries beyond the global
shootdown. This would mean serializing any and all translatation
cache updates with the threads in a core with the kernel entry
and exit of any thread in that core. This is just too painful
and complicated.

Since we already properly coded for the 2 nested faults that we
can get, all we need to do is use those to obtain the physical
address of the trap frame, switch to physical mode and in that
way eliminate any further faults. The trap frame is already
aligned to 1KB boundaries to make sure we don't cross the page
boundary, this is safe to do.

We still need to serialize ptc.g or ptc.ga across CPUs because
the platform can only have 1 such operation outstanding at the
same time. We can now use a regular (spin) lock for this.

Also, it has been observed that we can get a nested TLB faults
for region 7 virtual addresses. This was unexpected. For now,
we enhance the nested TLB fault handler to deal with those as
well, but it needs to be understood.

13 years agoAdd ID for Marvell 88SE9125 SATA controller.
Alexander Motin [Thu, 30 Jun 2011 19:23:17 +0000 (19:23 +0000)]
Add ID for Marvell 88SE9125 SATA controller.

PR: kern/157843
MFC after: 1 week

13 years agoAdd the missing sca_keylength field to the sctp_authkey structure,
Michael Tuexen [Thu, 30 Jun 2011 16:56:55 +0000 (16:56 +0000)]
Add the missing sca_keylength field to the sctp_authkey structure,
which is used the the SCTP_AUTH_KEY socket option.

MFC after: 1 month.

13 years agoAdd a version of the FreeBSD bootloader which can run in userland, packaged
Doug Rabson [Thu, 30 Jun 2011 16:08:56 +0000 (16:08 +0000)]
Add a version of the FreeBSD bootloader which can run in userland, packaged
as a shared library. This is intended to be used by BHyVe to load FreeBSD
kernels into new virtual machines.

13 years agoWhen Capsicum starts creating capabilities to wrap existing file
Jonathan Anderson [Thu, 30 Jun 2011 15:22:49 +0000 (15:22 +0000)]
When Capsicum starts creating capabilities to wrap existing file
descriptors, we will want to allocate a new descriptor without installing
it in the FD array.

Split falloc() into falloc_noinstall() and finstall(), and rewrite
falloc() to call them with appropriate atomicity.

Approved by: mentor (rwatson), re (bz)

13 years agoAdd some checks to ensure that Capsicum is behaving correctly, and add some
Jonathan Anderson [Thu, 30 Jun 2011 10:56:02 +0000 (10:56 +0000)]
Add some checks to ensure that Capsicum is behaving correctly, and add some
more explicit comments about what's going on and what future maintainers
need to do when e.g. adding a new operation to a sys_machdep.c.

Approved by: mentor(rwatson), re(bz)

13 years agoFix quota(1) output.
Sergey Kandaurov [Thu, 30 Jun 2011 09:20:26 +0000 (09:20 +0000)]
Fix quota(1) output.

- Fix calculation of 1024-byte sized blocks from disk blocks shown when -h
option isn't specified. It was broken with quota64 integration.
- In prthumanval(): limit the size of a buffer passed to humanize_number()
to a width of 5 bytes but allow a shorter length if requested. That's what
users expect.

PR: bin/150151
Reviewed by: Kirk McKusick

13 years ago - Handle the JOP_SYNC case as appropriate.
Jeff Roberson [Thu, 30 Jun 2011 05:28:10 +0000 (05:28 +0000)]
 - Handle the JOP_SYNC case as appropriate.

Reported by: pho

13 years agoAdd detection for the Marvel 88E1149R and treat it just like the
Warner Losh [Thu, 30 Jun 2011 05:20:02 +0000 (05:20 +0000)]
Add detection for the Marvel 88E1149R and treat it just like the
88E1149.

13 years agoHandle the FREEDEP case in softdep_sync_buf().
Kirk McKusick [Wed, 29 Jun 2011 22:12:43 +0000 (22:12 +0000)]
Handle the FREEDEP case in softdep_sync_buf().
This fix failed to get added in -r223325.

Submitted by: Peter Holm

13 years agoDocument two known hardware errata which requires manual link
Pyun YongHyeon [Wed, 29 Jun 2011 17:32:52 +0000 (17:32 +0000)]
Document two known hardware errata which requires manual link
configuration.

Submitted by: Aries Lee (arieslee <> jmicron com)

13 years agoAdd a new option, OBJPR_NOTMAPPED, to vm_object_page_remove(). Passing this
Alan Cox [Wed, 29 Jun 2011 16:40:41 +0000 (16:40 +0000)]
Add a new option, OBJPR_NOTMAPPED, to vm_object_page_remove().  Passing this
option to vm_object_page_remove() asserts that the specified range of pages
is not mapped, or more precisely that none of these pages have any managed
mappings.  Thus, vm_object_page_remove() need not call pmap_remove_all() on
the pages.

This change not only saves time by eliminating pointless calls to
pmap_remove_all(), but it also eliminates an inconsistency in the use of
pmap_remove_all() versus related functions, like pmap_remove_write().  It
eliminates harmless but pointless calls to pmap_remove_all() that were being
performed on PG_UNMANAGED pages.

Update all of the existing assertions on pmap_remove_all() to reflect this
change.

Reviewed by: kib

13 years ago- Add read-only sysctls for all of the tunables supported by the igb and
John Baldwin [Wed, 29 Jun 2011 16:20:52 +0000 (16:20 +0000)]
- Add read-only sysctls for all of the tunables supported by the igb and
  em drivers.
- Make the per-instance 'enable_aim' sysctl truly per-instance by having it
  change a per-instance variable (which is used to control AIM) rather
  than having all of the per-instance sysctls operate on a single global
  variable.

Reviewed by: jfv (earlier version)
MFC after: 1 week

13 years agoSet proper root device name when legacy NFS client is compiled into kernel.
Grzegorz Bernacki [Wed, 29 Jun 2011 15:17:29 +0000 (15:17 +0000)]
Set proper root device name when legacy NFS client is compiled into kernel.

Approved by:     cognet (mentor)

13 years agoAdd support for a MosChip PCI express serial port adapter.
Hans Petter Selasky [Wed, 29 Jun 2011 14:47:20 +0000 (14:47 +0000)]
Add support for a MosChip PCI express serial port adapter.

MFC after: 1 week

13 years agoFix a corner case in STA beacon processing when a CSA is received but
Adrian Chadd [Wed, 29 Jun 2011 13:21:52 +0000 (13:21 +0000)]
Fix a corner case in STA beacon processing when a CSA is received but
the AP doesn't transmit beacons.

If the AP requests a CSA (ie, a channel switch) and then enters CAC
(channel availability check) for 60 seconds, it doesn't send beacons
and it just listens for radar events (and other things which we don't
do yet.)

Now, ath_newstate() was not resetting the beacon timer config on
a transition to the RUN state when in STA mode - it was setting
sc_syncbeacon, which simply updates the beacon config from the
contents of the next received beacon.

This means the STA never generates beacon miss events.

If the AP goes into CAC for 60 seconds and recovers, the STA will
happily receive the first beacon and reconfigure timers.
But if it gets a radar event after that, it'll change channel
again, not notify the station that it's changed channel..
and since the station is happily waiting for the first beacon
to configure the beacon timer details from, it won't ever
generate a beacon miss interrupt and it'll sit there forever
(or until the AP appears on that channel once again.)

This change forces the last known beacon timer config to be
written to hardware on a transition from CSA->RUN in STA mode.
This forces bmiss events to occur and the STA will eventually
(after a handful of beacon miss events) begin scanning for
another access point.

13 years agoClarify that we broke pfsync(4) backward compat with the pf commit r223637.
Bjoern A. Zeeb [Wed, 29 Jun 2011 13:12:15 +0000 (13:12 +0000)]
Clarify that we broke pfsync(4) backward compat with the pf commit r223637.

Suggested by: Anton Yuzhaninov (citrin citrin.ru)

13 years agoWe may split today's CAPABILITIES into CAPABILITY_MODE (which has
Jonathan Anderson [Wed, 29 Jun 2011 13:03:05 +0000 (13:03 +0000)]
We may split today's CAPABILITIES into CAPABILITY_MODE (which has
to do with global namespaces) and CAPABILITIES (which has to do with
constraining file descriptors). Just in case, and because it's a better
name anyway, let's move CAPABILITIES out of the way.

Also, change opt_capabilities.h to opt_capsicum.h; for now, this will
only hold CAPABILITY_MODE, but it will probably also hold the new
CAPABILITIES (implying constrained file descriptors) in the future.

Approved by: rwatson
Sponsored by: Google UK Ltd

13 years agoIn case ntp cannot resolve a hostname on startup it will queue the entry
Bjoern A. Zeeb [Wed, 29 Jun 2011 13:01:10 +0000 (13:01 +0000)]
In case ntp cannot resolve a hostname on startup it will queue the entry
for resolving by a child process that, upon success, will add the entry
to the config of the running running parent process.

Unfortunately there are a couple of bugs with this, fixed in various
later versions of upstream in potentially different ways due to other
code changes:

1) Upon server [-46] <FQDN> the [-46] are used as FQDN for later resolving
   which does not work.  Make sure we always pass the name (or IP there).

2) The intermediate file to carry the information to the child process
   does not know about -4/-6 restrictions, so that a dual-stacked host
   could resolve to an IPv6 address but that might be unreachable (see
   r223626) leading to no working synchronization ignoring a IPv4 record.
   Thus alter the intermediate format to also pass the address family
   (AF_UNSPEC (default), AF_INET or AF_INET6) to the child process
   depending on -4 or -6.

3) Make the child process to parse the new intermediate file format and
   save the address family for getaddrinfo() hints flags.

4) Change child to always reload resolv.conf calling res_init() before
   trying to resolve names.  This will pick up resolv.conf changes or
   new resolv.confs should they have not existed or been empty or
   unusable on ntp startup.  This fix is more conditional in upstream
   versions but given FreeBSD has res_init there is no need for the
   configure logic as well.

Approved by: roberto
Sponsored by: Sandvine Incorporated
MFC after: 9 days

13 years agoAdd new rule actions "call" and "return" to ipfw. They make
Andrey V. Elsukov [Wed, 29 Jun 2011 10:06:58 +0000 (10:06 +0000)]
Add new rule actions "call" and "return" to ipfw. They make
possible to organize subroutines with rules.

The "call" action saves the current rule number in the internal
stack and rules processing continues from the first rule with
specified number (similar to skipto action). If later a rule with
"return" action is encountered, the processing returns to the first
rule with number of "call" rule saved in the stack plus one or higher.

Submitted by: Vadim Goncharov
Discussed by: ipfw@, luigi@

13 years agoTypo
Kevin Lo [Wed, 29 Jun 2011 09:35:40 +0000 (09:35 +0000)]
Typo

Submitted by: Damjan Marion <damjan dot marion at gmail dot com>
MFC after: 3 days

13 years agoadd SNDCTL_DSP_HALT specified by OSS
Andriy Gapon [Wed, 29 Jun 2011 08:32:37 +0000 (08:32 +0000)]
add SNDCTL_DSP_HALT specified by OSS

This is really a new name for SNDCTL_DSP_RESET.
And this what commit r222723 should really have been in the first place.

PR: kern/156874
Submitted by: gerald
MFC after: 1 week

13 years agorevert r222723: wrong change was committed
Andriy Gapon [Wed, 29 Jun 2011 08:28:39 +0000 (08:28 +0000)]
revert r222723: wrong change was committed

The commit intended to add SNDCTL_DSP_HALT, but actually added
SNDCTL_SEQ_HALT, which is not defined in the OSS specs.

Reported by: Pan Tsu <inyaoo@gmail.com>
Pointyhat to: gerald, avg

13 years agoImprove error reporting. Use corresponding error message when file to be
Andrey V. Elsukov [Wed, 29 Jun 2011 06:45:44 +0000 (06:45 +0000)]
Improve error reporting. Use corresponding error message when file to be
preprocessed is missing. Also suggest to use absolute pathname if -p option
is specified.

PR:             bin/156653
MFC after:      2 weeks

13 years agoInitialize elements of state array when creating the GPT table.
Andrey V. Elsukov [Wed, 29 Jun 2011 05:41:14 +0000 (05:41 +0000)]
Initialize elements of state array when creating the GPT table.
This fixes the problem, when the secondary GPT header is not erased when
partition table destroyed. Move equal operations from g_part_gpt_create
and g_part_gpt_recover to the separate function g_gpt_set_defaults.

Reported by: dwhite
MFC after: 1 week

13 years agoFix the new NFSv4 client so that it doesn't fill the cached
Rick Macklem [Tue, 28 Jun 2011 22:52:38 +0000 (22:52 +0000)]
Fix the new NFSv4 client so that it doesn't fill the cached
mode attribute in as 0 when doing writes. The change adds
the Mode attribute plus the others except Owner and Owner_group
to the list requested by the NFSv4 Write Operation. This fixed
a problem where an executable file built by "cc" would get mode
0111 instead of 0755 for some NFSv4 servers.
Found at the recent NFSv4 interoperability Bakeathon.

Tested by: tdh at excfb.com
MFC after: 2 weeks

13 years agoCheck the returned value of activemap_write_complete() and update matadata on
Mikolaj Golub [Tue, 28 Jun 2011 21:01:32 +0000 (21:01 +0000)]
Check the returned value of activemap_write_complete() and update matadata on
disk if needed. This should fix a potential case when extents are cleared in
activemap but metadata is not updated on disk.

Suggested by: pjd
Approved by: pjd (mentor)

13 years agoMake activemap_write_start/complete check the keepdirty list, when
Mikolaj Golub [Tue, 28 Jun 2011 20:57:54 +0000 (20:57 +0000)]
Make activemap_write_start/complete check the keepdirty list, when
stating if we need to update activemap on disk. This makes keepdirty
serve its purpose -- to reduce number of metadata updates.

Discussed with: pjd
Approved by: pjd (mentor)

13 years agoRevert the mechanical change from 'file system' to 'filesystem', committed
Edward Tomasz Napierala [Tue, 28 Jun 2011 19:59:46 +0000 (19:59 +0000)]
Revert the mechanical change from 'file system' to 'filesystem', committed
in r223429.  As bde@ pointed out, it was mostly backwards.

13 years agoFix typo in r223648 which was accidentally committed
Marius Strobl [Tue, 28 Jun 2011 16:44:02 +0000 (16:44 +0000)]
Fix typo in r223648 which was accidentally committed

13 years ago- In gem_reset_rx() also reset the RX MAC which is necessary in order to
Marius Strobl [Tue, 28 Jun 2011 16:16:43 +0000 (16:16 +0000)]
- In gem_reset_rx() also reset the RX MAC which is necessary in order to
  get it out of a stuck condition that can be caused by GEM_MAC_RX_OVERFLOW.
- In gem_reset_rxdma() call gem_setladrf() in order to reprogram the RX
  filter and restore the previous content of GEM_MAC_RX_CONFIG. While at it
  consistently use the newly introduced sc_mac_rxcfg throughout the driver
  instead of reading the its old content.
- Increment if_iqdrops instead of if_ierrors in case of RX buffer allocation
  failure.
- According to the GEM datasheet the RX MAC should also be disabled in
  gem_setladrf() before changing its configuration.
- Add error messages to gem_disable_{r,t}x() and take advantage of these
  throughout the driver instead of duplicating their functionality all over
  the place.

In joint forces with: yongari

13 years agoRun load_rc_config before stop_cmd definition, so that ${quotaoff_flags}
Sergey Kandaurov [Tue, 28 Jun 2011 14:26:34 +0000 (14:26 +0000)]
Run load_rc_config before stop_cmd definition, so that ${quotaoff_flags}
is correctly expanded inside stop_cmd instead of getting nothing.

PR: conf/157687
Reported by: Dmitry Banschikov <d.banschikov peterhost ru>
MFC after: 1 week

13 years agoLibUSB v1.0: Need at least one frame when doing the dummy open
Hans Petter Selasky [Tue, 28 Jun 2011 14:07:28 +0000 (14:07 +0000)]
LibUSB v1.0: Need at least one frame when doing the dummy open
else clear stall won't work in that case.

13 years agoRemove needless file due to Russia scraps DST in 2011.
Sergey A. Osokin [Tue, 28 Jun 2011 12:32:24 +0000 (12:32 +0000)]
Remove needless file due to Russia scraps DST in 2011.

13 years agoUpdate packet filter (pf) code to OpenBSD 4.5.
Bjoern A. Zeeb [Tue, 28 Jun 2011 11:57:25 +0000 (11:57 +0000)]
Update packet filter (pf) code to OpenBSD 4.5.

You need to update userland (world and ports) tools
to be in sync with the kernel.

Submitted by: mlaier
Submitted by: eri

13 years agoRemove AN again now that tzdata2011h has been imported.
Edwin Groothuis [Tue, 28 Jun 2011 10:38:12 +0000 (10:38 +0000)]
Remove AN again now that tzdata2011h has been imported.

13 years agoMFV of tzdata2011h, r223627
Edwin Groothuis [Tue, 28 Jun 2011 10:24:01 +0000 (10:24 +0000)]
MFV of tzdata2011h, r223627

- Russia scraps DST in 2011
- Remove Netherlands Antilles, add Bonaire, Curacao, Sint Maarten

13 years agoVendor import of tzdata2011h:
Edwin Groothuis [Tue, 28 Jun 2011 10:11:40 +0000 (10:11 +0000)]
Vendor import of tzdata2011h:

- Russia scraps DST in 2011
- Remove Netherlands Antilles, add Bonaire, Curacao, Sint Maarten

Obtained from: ftp://elsie.nci.nih.gov/pub/

13 years agoCompare port numbers correctly. They are stored by SRCPORT()
Bjoern A. Zeeb [Tue, 28 Jun 2011 09:46:25 +0000 (09:46 +0000)]
Compare port numbers correctly.  They are stored by SRCPORT()
in host byte order, so we need to compare them as such.
Properly compare IPv6 addresses as well.

This allows the, by default, 8 badaddrs slots per address
family to work correctly and only print sendto() errors once.

The change is no longer applicable to any latest upstream versions.

Approved by: roberto
Sponsored by: Sandvine Incorporated
MFC after: 1 week

13 years agoUpdate ifc_len field of struct ifconf passed for the ioctl SIOCGIFCONF32
Sergey Kandaurov [Tue, 28 Jun 2011 08:41:44 +0000 (08:41 +0000)]
Update ifc_len field of struct ifconf passed for the ioctl SIOCGIFCONF32
(i.e. under COMPAT_FREEBSD32) in case ifconf() returned success to match
the native SIOCGIFCONF behavior.

PR: kern/158369
Reported by: Paul Procacci <pprocacci att gmail com>
MFC after: 1 week

13 years agoRemove duplicate header includes
Kevin Lo [Tue, 28 Jun 2011 08:36:48 +0000 (08:36 +0000)]
Remove duplicate header includes

13 years agoAdd a new "REFCOMPRESSRATIO" property.
Martin Matuska [Tue, 28 Jun 2011 07:52:01 +0000 (07:52 +0000)]
Add a new "REFCOMPRESSRATIO" property.

For snapshots, this is the same as COMPRESSRATIO, but for
filesystems/volumes, the COMPRESSRATIO is based on the data "USED" (ie,
includes blocks in children, but not blocks shared with the origin).

This is needed to figure out how much space a filesystem would use if it
were not compressed (ignoring snapshots).

Illumos-gate revision: 13387

Obtained from: Illumos (Feature #1092)
MFC after: 2 weeks

13 years agoDisable vdev cache (readahead) by default.
Martin Matuska [Tue, 28 Jun 2011 06:32:35 +0000 (06:32 +0000)]
Disable vdev cache (readahead) by default.

The vdev cache is very underutilized (hit ratio 30%-70%) and may consume
excessive memory on systems with many vdevs.

Illumos-gate revision: 13346

Obtained from: Illumos (Bug #175)
MFC after: 1 week

13 years agoAllow mountpoints as arguments for the 'zfs get' command.
Martin Matuska [Tue, 28 Jun 2011 06:16:33 +0000 (06:16 +0000)]
Allow mountpoints as arguments for the 'zfs get' command.

Illumos-gate revision: 13295

Obtained from: Illumos (Feature #510)
MFC after: 1 week

13 years agoIncorporate vendor commit ecdc5c0a7f7591a7cd4a:
Xin LI [Tue, 28 Jun 2011 00:58:12 +0000 (00:58 +0000)]
Incorporate vendor commit ecdc5c0a7f7591a7cd4a:

In userland, sign extend the offset for JA instructions.

We currently use that to implement "ip6 protochain", and "pc" might be
wider than "pc->k", in which case we need to arrange that "pc->k" be
sign-extended, by casting it to bpf_int32.

PR: kern/157188
Submitted by: plosher
MFC after: 2 weeks

13 years agoMake sure the extended regdomain word is initialised.
Adrian Chadd [Tue, 28 Jun 2011 00:01:55 +0000 (00:01 +0000)]
Make sure the extended regdomain word is initialised.

As with the AR9285, the AR9287 has a default word of 0x1F which means
all the various bits in that field are set on by default.

13 years agoAdd support for SCTP_PR_SCTP_NONE which I misded to add.
Michael Tuexen [Mon, 27 Jun 2011 22:03:33 +0000 (22:03 +0000)]
Add support for SCTP_PR_SCTP_NONE which I misded to add.
This constant is defined in the socket API ID.

MFC after: 2 months.

13 years agoRevert the entry point label to 'start' to unbreak the build.
John Baldwin [Mon, 27 Jun 2011 21:43:56 +0000 (21:43 +0000)]
Revert the entry point label to 'start' to unbreak the build.

Pointy hat to: jhb

13 years agoEnable CPUSaver D102 E-step microcode loading for 82551 revision
Pyun YongHyeon [Mon, 27 Jun 2011 21:37:38 +0000 (21:37 +0000)]
Enable CPUSaver D102 E-step microcode loading for 82551 revision
0x10.

13 years agoDisable microcode loading for 82550 and 82550C controllers. Loading
Pyun YongHyeon [Mon, 27 Jun 2011 21:27:12 +0000 (21:27 +0000)]
Disable microcode loading for 82550 and 82550C controllers. Loading
the microcode caused SCB timeouts. Linux driver does not allow
microcode loading for these controllers and jfv also confirmed that
there is no need to do and it shouldn't.

PR: kern/103332
Additional confirmation from: jfv
MFC after: 1 week

13 years agoRegenerate usb.conf after r223566.
Hans Petter Selasky [Mon, 27 Jun 2011 20:32:19 +0000 (20:32 +0000)]
Regenerate usb.conf after r223566.

13 years agoBuild Scrt.o on powerpc64. Its introduction on other platforms got lost
Nathan Whitehorn [Mon, 27 Jun 2011 16:24:36 +0000 (16:24 +0000)]
Build Scrt.o on powerpc64. Its introduction on other platforms got lost
during the period of time the powerpc64 port was on a project branch.

13 years ago- Remove the fake BPB from zfsldr. zfsldr doesn't support booting from
John Baldwin [Mon, 27 Jun 2011 13:58:24 +0000 (13:58 +0000)]
- Remove the fake BPB from zfsldr.  zfsldr doesn't support booting from
  floppies, so it will not be used as the start of an emulated floppy
  image on a bootable CD which is what the fake BPB was used for.
- Only check that EDD packet mode is available once at the start of
  zfsldr rather than for each disk sector now that we read data in one
  sector at a time.  As a result, collapse the remaining bits of read
  up into nread and rename nread to read.
- Restore a return at the end of putstr that I removed in the previous
  revision.

Tested by: Henri Hennebert (earlier version)
MFC after: 1 week

13 years agoAdd macros to specify owner, group and mode of config files for installation.
Stefan Eßer [Mon, 27 Jun 2011 13:23:51 +0000 (13:23 +0000)]
Add macros to specify owner, group and mode of config files for installation.

Submitted by: Chris Rees (crees)

13 years agoEBR could contain an early stage of boot code. But we do not support it.
Andrey V. Elsukov [Mon, 27 Jun 2011 12:42:48 +0000 (12:42 +0000)]
EBR could contain an early stage of boot code. But we do not support it.
Remove message about non empty bootcode, we can not break something
while GEOM_PART_EBR_COMPAT is defined.

But without GEOM_PART_EBR_COMPAT any changes in EBR are allowed and we
can accidentally wipe the boot code. To do not break anything save
the first EBR chunk and keep it untouched each time when we are
changing EBR. Note that we are still not support boot code for EBR.

PR: kern/141235
MFC after: 1 month

13 years agoAdd possibility to pass IPv6 packets to a divert(4) socket.
Gleb Smirnoff [Mon, 27 Jun 2011 12:21:11 +0000 (12:21 +0000)]
Add possibility to pass IPv6 packets to a divert(4) socket.

Submitted by: sem

13 years agoMS Windows NT+ uses 4 bytes at offset 0x1b8 in the MBR to identify
Andrey V. Elsukov [Mon, 27 Jun 2011 10:42:06 +0000 (10:42 +0000)]
MS Windows NT+ uses 4 bytes at offset 0x1b8 in the MBR to identify
disk drive. The boot0cfg(8) utility preserves these 4 bytes when is
writing bootcode to keep a multiboot ability.
Change gpart's bootcode method to keep DSN if it is not zero. Also
do not allow writing bootcode with size not equal to MBRSIZE.

PR: kern/157819
Tested by: Eir Nym
MFC after: 1 month

13 years agoCompile hastd and hastctl with capsicum support.
Pawel Jakub Dawidek [Mon, 27 Jun 2011 09:15:41 +0000 (09:15 +0000)]
Compile hastd and hastctl with capsicum support.

X-MFC after: capsicum merge

13 years agoCompile capsicum support only if HAVE_CAPSICUM is defined.
Pawel Jakub Dawidek [Mon, 27 Jun 2011 09:14:25 +0000 (09:14 +0000)]
Compile capsicum support only if HAVE_CAPSICUM is defined.

MFC after: 3 days

13 years agoLog a warning if we cannot sandbox using capsicum, but only under debug level 1.
Pawel Jakub Dawidek [Mon, 27 Jun 2011 09:10:48 +0000 (09:10 +0000)]
Log a warning if we cannot sandbox using capsicum, but only under debug level 1.
It would be too noisy to log it as a proper warning as CAPABILITIES are not
compiled into GENERIC by default.

MFC after: 3 days

13 years agoPrint out a big warning if DFS can't find a channel to use.
Adrian Chadd [Mon, 27 Jun 2011 05:57:14 +0000 (05:57 +0000)]
Print out a big warning if DFS can't find a channel to use.
This way people debugging DFS won't be surprised when their
AP stops talking.

13 years agoRewrite HISTORY: The SHA256 code first appeared in 6.0, and the SHA512
Colin Percival [Mon, 27 Jun 2011 02:10:10 +0000 (02:10 +0000)]
Rewrite HISTORY: The SHA256 code first appeared in 6.0, and the SHA512
code in 9.0; neither existed in FreeBSD 4.0.

13 years agosh: Include <limits.h> instead of non-standard <sys/limits.h>.
Jilles Tjoelker [Sun, 26 Jun 2011 20:12:05 +0000 (20:12 +0000)]
sh: Include <limits.h> instead of non-standard <sys/limits.h>.

13 years agoFor some reason, contrib/traceroute/traceroute.c ensures MAXHOSTNAMELEN
Dimitry Andric [Sun, 26 Jun 2011 19:03:33 +0000 (19:03 +0000)]
For some reason, contrib/traceroute/traceroute.c ensures MAXHOSTNAMELEN
is defined, but then proceeds to use a hardcoded maximum hostname length
of 64 anyway.  Fix this by checking against MAXHOSTNAMELEN instead.

PR: bin/157732
MFC after: 3 days

13 years agoFix whitespace inconsistencies in libc in files copyrighted by me.
Ed Schouten [Sun, 26 Jun 2011 18:27:17 +0000 (18:27 +0000)]
Fix whitespace inconsistencies in libc in files copyrighted by me.

13 years agoFix whitespace inconsistencies in the TTY layer and its drivers owned by me.
Ed Schouten [Sun, 26 Jun 2011 18:26:20 +0000 (18:26 +0000)]
Fix whitespace inconsistencies in the TTY layer and its drivers owned by me.

13 years agoFix various whitespace inconsistencies in sys/teken.
Ed Schouten [Sun, 26 Jun 2011 18:25:10 +0000 (18:25 +0000)]
Fix various whitespace inconsistencies in sys/teken.

13 years agoThe --newer-than test should descend into old
Tim Kientzle [Sun, 26 Jun 2011 17:54:11 +0000 (17:54 +0000)]
The --newer-than test should descend into old
directories to look for new files.

PR: bin/150890
Submitted by: Tobias Herre
MFC after: 3 weeks

13 years agoAdd better error handling for RTAS calls. These can potentially cause
Nathan Whitehorn [Sun, 26 Jun 2011 16:11:36 +0000 (16:11 +0000)]
Add better error handling for RTAS calls. These can potentially cause
machine checks (e.g. invalid PCI configuration cycles), but these can
be caught and recovered from. This change also the RTAS PCI driver to
work without modification as a replacement for the Grackle driver on
Grackle-based Powermacs.

13 years agoRevert r223479. It is unnecessary and served only to slightly ameliorate
Nathan Whitehorn [Sun, 26 Jun 2011 15:08:14 +0000 (15:08 +0000)]
Revert r223479. It is unnecessary and served only to slightly ameliorate
some manifestations of the bug actually fixed in r223485.

13 years ago.. this wasn't supposed to be committed! sorry.
Adrian Chadd [Sun, 26 Jun 2011 14:29:49 +0000 (14:29 +0000)]
.. this wasn't supposed to be committed! sorry.

13 years agoFix beacon transmission after a channel set.
Adrian Chadd [Sun, 26 Jun 2011 13:53:24 +0000 (13:53 +0000)]
Fix beacon transmission after a channel set.

The DFS code was tickling the channel set directly whilst going
through the state RUN -> CSA -> RUN. This only changed the channel;
it didn't go via ath_reset(). However in this driver, a channel
change always causes a chip reset, which resets the beacon timer
configuration and interrupt setup. This meant that data would go
out but as the beacon timers never fired, beacons would never
be queued.

The confusing part is that sometimes the state transition was
RUN -> SCAN -> CAC -> RUN (with CSA being in there sometimes);
going via SCAN would clear sc_beacons and thus the transition
to RUN would reprogram beacon transmission.

In case someone tries debugging why suspending a device currently
beaconing (versus just RX'ing beacons which is what occurs in STA
mode), add a silly comment which should hopefully land them at
this commit message. The call to ath_hal_reset() will be clearing
the beacon config and it may not be always reset.

13 years agoAdd ATH_ENABLE_DFS which enables the DFS flag so the DFS code
Adrian Chadd [Sun, 26 Jun 2011 13:43:15 +0000 (13:43 +0000)]
Add ATH_ENABLE_DFS which enables the DFS flag so the DFS code
can be tested.

This doesn't at all actually do radar detection! It's just
so developers who wish to test the net80211 DFS code can easily
do so. Without this flag, the DFS channels are never marked
DFS and thus the DFS stuff doesn't run.

13 years agoThe SMCWUSBG is a zyd(4) device, not an uath(4) device. Remove from the
Gavin Atkinson [Sun, 26 Jun 2011 11:37:24 +0000 (11:37 +0000)]
The SMCWUSBG is a zyd(4) device, not an uath(4) device.  Remove from the
latter.

It appears that the addition to uath(4) came in through PR kern/135009,
which had tested another device, the SMCWUSBTG2, successfully with uath(4)
and included the SMCWUSBG as it "has the same chipset".  I can find no
other evidence that these two do actually share the same chipset.  Moreover,
Linux treats the SMCWUSBG as a zyd(4) device also.

This reverts r223537.

Discussed with: hselasky, kevlo
MFC after: 1 week

13 years agoI think 23dBm is the correct value to use here. CRDA uses 20dBm + 3dB max antenna
Adrian Chadd [Sun, 26 Jun 2011 10:34:01 +0000 (10:34 +0000)]
I think 23dBm is the correct value to use here. CRDA uses 20dBm + 3dB max antenna
gain; I believe net80211 doesn't take antenna gain into account and leaves it
up to the driver to enforce. (ath_hal(4) certainly tries to do this.)

13 years agoAdd a couple more frequency ranges to the FCC3 (FCC + DFS) regulatory domain.
Adrian Chadd [Sun, 26 Jun 2011 10:32:09 +0000 (10:32 +0000)]
Add a couple more frequency ranges to the FCC3 (FCC + DFS) regulatory domain.

The frequency range 5490MHz -> 5710MHz was opened up sometime in 2009, but
regdomain.xml wasn't updated.

FCC reference: (Section 15.407): http://louise.hallikainen.org/FCC/FccRules/2009/15/407/

The hole between 5600-5650MHz is due to a request from Airports using
a weather radar system which also utilises this range.
The GIT commit explaining this hole in more detail can be found here:

http://git.kernel.org/?p=linux/kernel/git/linville/wireless-regdb.git;a=commit;h=fcbf9225d56e82d9a4e506187d42285e76d81523

13 years agoRemove duplicate header includes
Kevin Lo [Sun, 26 Jun 2011 10:07:48 +0000 (10:07 +0000)]
Remove duplicate header includes

13 years agoReplace tab with 8 spaces, bringing it in line with the rest of the file.
Adrian Chadd [Sun, 26 Jun 2011 09:32:46 +0000 (09:32 +0000)]
Replace tab with 8 spaces, bringing it in line with the rest of the file.

13 years agocam/scsi/scsi_cd.c:
Justin T. Gibbs [Sun, 26 Jun 2011 01:32:46 +0000 (01:32 +0000)]
cam/scsi/scsi_cd.c:
In cdregister(), hold the periph lock semaphore during changer
probe/configuration.  This removes a window where an open of the
cd device may succeed before probe processing has completed.

13 years agocam/cam_xpt.c:
Justin T. Gibbs [Sun, 26 Jun 2011 01:14:54 +0000 (01:14 +0000)]
cam/cam_xpt.c:
In camisr_runqueue(), we need to run the sims queue regardless of
whether or not the current peripheral has more work to do.  This
reverts a change mistakenly made in revision 223081.

Reported by: ache

13 years agoTurn the minimum PWM fan speed down to 30 from 40. It turns out the burning
Nathan Whitehorn [Sun, 26 Jun 2011 00:49:17 +0000 (00:49 +0000)]
Turn the minimum PWM fan speed down to 30 from 40. It turns out the burning
smell that caused me to turn this up was due to a failed fan burning, not
a CPU (plus a healthy dose of paranoia).

Submitted by: Paul Mather <paul at gromit dot dlib dot vt dot edu>

13 years agoDo not attach to the sound device on G5 Xserves, which is actually an
Nathan Whitehorn [Sun, 26 Jun 2011 00:35:11 +0000 (00:35 +0000)]
Do not attach to the sound device on G5 Xserves, which is actually an
LED controller used to run the load graph on the server's front panel.

Reported by: Paul Mather <paul at gromit dot dlib dot vt dot edu>
MFC after: 3 days

13 years agosh: Test that '!' is literal if quoted and first char of bracket expression
Jilles Tjoelker [Sat, 25 Jun 2011 20:37:43 +0000 (20:37 +0000)]
sh: Test that '!' is literal if quoted and first char of bracket expression

This also works on stable/8.

13 years agoMore accurate birthplace.
Joel Dahl [Sat, 25 Jun 2011 19:21:54 +0000 (19:21 +0000)]
More accurate birthplace.

13 years agoOops. The sec field of struct bintime is *not* a 32-bit type.
Marcel Moolenaar [Sat, 25 Jun 2011 17:58:35 +0000 (17:58 +0000)]
Oops. The sec field of struct bintime is *not* a 32-bit type.
It's time_t, which is 64 bits on ia64.

13 years ago- Move bus_auto.conf back into /etc/devd/
Hans Petter Selasky [Sat, 25 Jun 2011 17:01:46 +0000 (17:01 +0000)]
- Move bus_auto.conf back into /etc/devd/
- Rename bus_auto.conf into usb.conf

Requested by: imp @
MFC after: 14 days

13 years agoDefine the minimum fractional period in terms of hz. We know hz is
Marcel Moolenaar [Sat, 25 Jun 2011 16:35:43 +0000 (16:35 +0000)]
Define the minimum fractional period in terms of hz. We know hz is
a magnitude smaller than itc_freq. A minimum period of 10*hz is
sufficient precision. As a side-effect, the number of clocks per
second, when the machine is idle, dropped by more than 50%.
Be anal and define the maximum period to be at least 4G seconds.
With a 64-bit counter and an ITC frequency that's expected to be
always less than 4Ghz, it takes longer than that to wrap around.

13 years agoIf there is a read error reading Y/N confirmation from the keyboard,
Tim Kientzle [Sat, 25 Jun 2011 16:27:49 +0000 (16:27 +0000)]
If there is a read error reading Y/N confirmation from the keyboard,
exit immediately with an error.

If there is an error opening or reading a file to put into the archive,
set the return value for a deferred error exit.

PR: bin/154407

13 years agoThe kerberos5 tools are only used as build tools but not otherwise and
Marius Strobl [Sat, 25 Jun 2011 16:13:56 +0000 (16:13 +0000)]
The kerberos5 tools are only used as build tools but not otherwise and
didn't get installed either.

MFC after: 1 week

13 years agoAs with EFI, OFW and U-Boot etc only compile FDT support on those
Marius Strobl [Sat, 25 Jun 2011 16:01:45 +0000 (16:01 +0000)]
As with EFI, OFW and U-Boot etc only compile FDT support on those
architectures that actually use it.

13 years ago- Export the USB device ID format to userspace tools.
Hans Petter Selasky [Sat, 25 Jun 2011 15:51:44 +0000 (15:51 +0000)]
- Export the USB device ID format to userspace tools.

MFC after: 14 days

13 years ago- Remove duplicate USB ID.
Hans Petter Selasky [Sat, 25 Jun 2011 15:46:24 +0000 (15:46 +0000)]
- Remove duplicate USB ID.

MFC after: 3 days

13 years ago- Move auto-load devd config file into etc/defaults folder.
Hans Petter Selasky [Sat, 25 Jun 2011 15:42:33 +0000 (15:42 +0000)]
- Move auto-load devd config file into etc/defaults folder.
- Regenerate file after bugfix in the generator.

Suggested by: Jeremy Messenger
MFC after: 14 days