Commit Graph

179274 Commits

Author SHA1 Message Date
Marius Strobl
9e2585bfed Initialize count in order to appease clang.
Submitted by:	delphij
2013-03-01 22:05:20 +00:00
John Baldwin
f9379dc411 Replace the TDP_NOSLEEPING flag with a counter so that the
THREAD_NO_SLEEPING() and THREAD_SLEEPING_OK() macros can nest.

Reviewed by:	attilio
2013-03-01 22:03:31 +00:00
Andrew Turner
5f61931668 Increase the maximum text size on ARM to 64MiB. Without this clang would be
sent a SIGABRT when it is loaded as it is too large. This is the smallest
power of two MiB value that allows us to execute clang.

While here wrap it in an #ifndef to be consistent with the other
architectures.

Submitted by:	Daisuke Aoyama <aoyama at peach.ne.jp>
2013-03-01 21:59:23 +00:00
Pawel Jakub Dawidek
71ac38e896 Remove unnecessary variables. 2013-03-01 21:58:56 +00:00
Martin Matuska
4abd59512a MFV r247316:
Merge new read-only zfs properties from vendor (illumos)

Illumos ZFS issues:
  3588 provide zfs properties for logical (uncompressed) space used and
       referenced

References:
  https://www.illumos.org/issues/3588

MFC after:	2 weeks
2013-03-01 21:58:51 +00:00
Pawel Jakub Dawidek
f4d0191b22 Reduce lock scope a little. 2013-03-01 21:57:02 +00:00
Marius Strobl
a587c657ef - Move reporting of failures to disable RX/TX MAC under bootverbose as at
least the Saturn chips of 501-6738 cards may fail to do so the first
  time, which isn't fatal though.
  Reported by: Paul Keusemann
- Explain why we don't enable infinite bursts on sparc64.
- Given that these chips support memory write invalidate, make sure that
  it's enabled in the command register. Also make sure that PERR# and
  SERR# assertion is enabled.

MFC after:	1 week
2013-03-01 20:51:53 +00:00
Marius Strobl
22f19117ed - In sbbc_pci_attach() just pass the already obtained bus tag and handle
instead of acquiring these anew.
- Use NULL instead of 0 for pointers.

MFC after:	1 week
2013-03-01 20:36:59 +00:00
Marius Strobl
1a5a52f1f9 - Remove an unused header.
- Use NULL instead of 0 for pointers.
- Let ofw_pcib_probe() return BUS_PROBE_DEFAULT instead of 0 so specialized
  PCI-PCI-bridge drivers may attach instead.
- Add WARs for PLX Technology PEX 8114 bridges and PEX 8532 switches.
  Ideally, these should live in MI code but at least for the latter we're
  missing the necessary infrastructure there.

MFC after:	1 week
2013-03-01 20:34:02 +00:00
Marius Strobl
00ff5de585 - Apparently, r186520 was just wrong and the clock of Oxford OX16PCI958 is
neither DEFAULT_RCLK * 2 nor DEFAULT_RCLK * 10 but plain DEFAULT_RCLK
  and there's no (open) source indicating otherwise. This was tested with
  an EXSYS EX-41098-2, whose clock is not configurable and identifies as:
  puc0@pci0:5:1:0:        class=0x070200 card=0x06711415 chip=0x95381415 rev=0x01 hdr=0x00
      vendor     = 'Oxford Semiconductor Ltd'
      class      = simple comms
      subclass   = multiport serial

  Note that this exactly matches the card mentioned in PR 129665 so no
  sub-device/sub-vendor based quirking of the latter is possible. So maybe
  we should grow some sort of tunable, in case non-default cards such as
  the latter aren't configurable either (this also wouldn't be the first
  time an allegedly tested commit turns out to be wrong though).
- Make the TiMedia tables const.

MFC after:	1 week
2013-03-01 20:16:06 +00:00
Marius Strobl
da4882c200 - Make tables, device ID strings etc const. This includes #ifdef'ing 0
aac_command_status_table, which is actually unused since r111532.
  While at it, make aac_if a pointer to the now const interface tables
  instead of copying them over to the softc (this alone already reduces the
  size of aac.ko on amd64 by ~1 KiB).
- Remove redundant softc members.
- Use DEVMETHOD_END.
- Use NULL instead of 0 for pointers.
- Remove redundant bzero(9)'ing of the softc.
- Use pci_enable_busmaster(9) instead of duplicating it.
- Remove redundant checking for PCIM_CMD_MEMEN (resource allocation will
  just fail).
- Canonicalize the error messages in case of resource allocation failures.
- Add support for using MSI instead of INTx, controllable via the tunable
  hw.aac.enable_msi (defaulting to on).

MFC after:	1 month
2013-03-01 19:55:10 +00:00
Marius Strobl
499e58864a - Make tables, device ID strings etc const.
- Use NULL instead of 0 for pointers.
- Remove redundant bzero(9)'ing of the softc.
- Remove redundant/unused softc members.
- Don't allocate MSI/MSI-X as RF_SHAREABLE.
- Re-use bus accessor macros instead of duplicating them.
- In bce_miibus_{read,write}_reg(), remove superfluous limiting of the PHY
  address (missed in r213893).

MFC after:	1 week
2013-03-01 19:12:38 +00:00
Alan Cox
1f9d53d893 Eliminate a redundant #include: machine/pmap.h is already included
through vm/pmap.h.
2013-03-01 19:02:41 +00:00
Marius Strobl
db9066f798 - Use strdup(9) instead of reimplementing it.
- Use __DECONST instead of strange casts.
- Reduce code duplication and simplify name2oid().

PR:		176373
Submitted by:	Christoph Mallon
MFC after:	1 week
2013-03-01 18:49:14 +00:00
Konstantin Belousov
58248e57ab Make the default implementation of the VOP_VPTOCNP() fail if the
directory entry, matched by the inode number, is ".".

NFSv4 client might instantiate the distinct vnodes which have the same
inode number, since single v4 export can be combined from several
filesystems on the server.  For instance, a case when the nested
server mount point is exactly one directory below the top of the
export, causes directory and its parent to have the same inode number
2.  The vop_stdvptocnp() algorithm then returns "." as the name of the
lower directory.

Filtering out the "." entry with ENOENT works around this behaviour,
the error forces getcwd(3) to fall back to usermode implementation,
which compares both st_dev and st_ino.

Based on the submission by:	rmacklem
Tested by:	rmacklem
MFC after:	1 week
2013-03-01 18:40:14 +00:00
Kevin Lo
130f254b21 Fix typo. 2013-03-01 15:48:31 +00:00
Kevin Lo
5ee7403731 Assign the len field of the netbuf structure to the current length of
a sockaddr.

Obtained from:	NetBSD
2013-03-01 15:45:57 +00:00
Martin Matuska
bb508e7732 Fix the zfs_ioctl compat layer to support zfs_cmd size change introduced
in r247265 (ZFS deadman thread). Both new utilities now support the old
kernel and new kernel properly detects old utilities.

For future backwards compatibility, the vfs.zfs.version.ioctl read-only
sysctl has been introduced. With this sysctl zfs utilities will be able
to detect the ioctl interface version of the currently loaded zfs module.

As a side effect, the zfs utilities between r247265 and this revision don't
support the old kernel module. If you are using HEAD newer or equal than
r247265, install the new kernel module (or whole kernel) first.

MFC after:	10 days
2013-03-01 09:42:58 +00:00
Alan Cox
99c8999856 Copy the definition of VM_MAX_AUTOTUNE_MAXUSERS from i386. (See r242847.)
Tested by:	andrew
2013-03-01 08:30:31 +00:00
Ruslan Ermilov
d1a0cea48b Fixed documented prototype of kinfo_getproc(3). 2013-03-01 07:39:14 +00:00
Brooks Davis
0837595205 Provide slightly more helpful feedback when we can't figure out what
compiler the user is using.

PR:		misc/173914
2013-03-01 03:25:43 +00:00
Neel Natu
91039bb268 Specify the length of the mapping requested from 'paddr_guest2host()'.
This seems prudent to do in its own right but it also opens up the possibility
of not having to mmap the entire guest address space in the 'bhyve' process
context.

Discussed with:	grehan
Obtained from:	NetApp
2013-03-01 02:26:28 +00:00
Ganbold Tsagaankhuu
341d7df3da Enable uart driver for A10.
Approved by: gonzo@
2013-03-01 01:47:11 +00:00
Ganbold Tsagaankhuu
ac4adddf04 Add support for A10 uart.
A10 uart is derived from Synopsys DesignWare uart and requires
to read Uart Status Register when IIR_BUSY has detected.
Also this change includes FDT check, where it checks device
specific properties defined in dts and sets the busy_detect variable.
broken_txfifo is also needed to be set in order to make it work for
A10 uart case.

Reviewed by: marcel@
Approved by: gonzo@
2013-03-01 01:42:31 +00:00
Glen Barber
4cf5de800c Minor wordsmithing.
X-MFC-Needs:	r245617
2013-02-28 23:45:41 +00:00
Adrian Chadd
87c176d272 Add missing flags. 2013-02-28 23:39:38 +00:00
Adrian Chadd
7a27f0a338 Oops - fix an incorrect test. 2013-02-28 23:39:22 +00:00
Adrian Chadd
5612990623 Don't enable the HT flags for legacy rates.
I stumbled across this whilst trying to debug another weird hang reported
on the freebsd-wireless list.

Whilst here, add in the STBC check to ath_rateseries_setup().

Whilst here, fix the short preamble flag to be set only for legacy rates.

Whilst here, comment that we should be using the full set of decisions
made by ath_rateseries_setup() rather than recalculating them!
2013-02-28 23:31:23 +00:00
Jack F Vogel
5e59bc2138 Change the ixgbe module name to if_ixgbe to conform
to the usual naming convention.
2013-02-28 22:48:00 +00:00
Oleksandr Tymoshenko
adc99a8aa6 Add platform DMA support to SDHCI driver for BCM2835
Submitted by:	Daisuke Aoyama <aoyama at peach.ne.jp>
Reviewed by:	ian@
2013-02-28 19:51:30 +00:00
Oleksandr Tymoshenko
cdafe74e84 Add driver for BCM2835's DMA engine
This is a version of code submitted by Daisuke Aoyama <aoyama at peach.ne.jp>
with some architectural changes.
2013-02-28 19:48:19 +00:00
Oleksandr Tymoshenko
c3a0f75a9f Add hooks for plugging platform-provided transfer backend.
In order to use platorm backend hardware driver should
impement three methods:
- platform_start_transfer and platform_finish_transfer
    to start and finish transfer
- platform_will_handle - check whether transaction is
    suitable for backend. If not - driver will fall back
    to PIO mode.

Submitted by:	Daisuke Aoyama <aoyama at peach.ne.jp>
Approved by:	ian@
2013-02-28 19:43:14 +00:00
Davide Italiano
aa97685d73 Move the definition of sbintime_t type from <sys/time.h> to <sys/types.h>.
With this change we prevent gross namespace pollution.

Reported by:	bde
Suggested by:	attilio
2013-02-28 17:10:30 +00:00
Davide Italiano
e234a588cb MFcalloutng:
Style fixes.
2013-02-28 16:22:49 +00:00
Alexander Motin
fdc5dd2d2f MFcalloutng:
Switch eventtimers(9) from using struct bintime to sbintime_t.
Even before this not a single driver really supported full dynamic range of
struct bintime even in theory, not speaking about practical inexpediency.
This change legitimates the status quo and cleans up the code.
2013-02-28 13:46:03 +00:00
Davide Italiano
d9ddf0c057 MFcalloutng (r247427 by mav):
We don't need any precision here. Let it be fast and dirty shift then
slow and excessively precise 64-bit division.
2013-02-28 11:27:01 +00:00
Davide Italiano
acccf7d8b4 MFcalloutng:
When CPU becomes idle, cpu_idleclock() calculates time to the next timer
event in order to reprogram hw timer. Return that time in sbintime_t to
the caller and pass it to acpi_cpu_idle(), where it can be used as one
more factor (quite precise) to extimate furter sleep time and choose
optimal sleep state. This is a preparatory change for further callout
improvements will be committed in the next days.

The commmit is not targeted for MFC.
2013-02-28 10:46:54 +00:00
Alexander Motin
0f4fc79e2f Introduce sbintime_t type -- the simplified version of struct bintime,
using 32.32 fixed point in form of single int64_t.  It is much easier to
use in cases where additional precision and range of struct bintime is
not required.

Reviewed by:	bde (previous version), davide
2013-02-28 10:21:04 +00:00
Xin LI
35689395b3 Refresh vendor driver version which adds ARC-1224 support.
Many thanks to Areca for continuing to support FreeBSD.

Submitted by:	黃清隆 <ching2048 areca com tw>
MFC after:	3 days
2013-02-28 04:16:47 +00:00
Pawel Jakub Dawidek
a66ffea41d When we are waiting for new trail files we may have been disconnected and
reconnected in the meantime. Check if reset is set before opening next trail
file, as not doing so will result in sending OPEN message with the same
file name twice and this is illegal - the second OPEN is send without first
closing previous trail file.
2013-02-28 01:24:24 +00:00
Glen Barber
eff269ee18 Properly handle '-h' argument.
PR:		176332
Reviewed by:	scottl
MFC after:	3 days
2013-02-28 01:22:14 +00:00
Neel Natu
5bf80db676 Remove the quirk to allow use of MSI when the guest is running inside bhyve.
This became redundant after the hostbridge presented to the guest started
advertising the PCI-E capability (r246846).

Obtained from:	NetApp
2013-02-28 01:00:32 +00:00
Attilio Rao
ecf507c36b Complete r247297:
Remove unused inclusions of vm/vm_pager.h and vm/vnode_pager.h.

Sponsored by:	EMC / Isilon storage division
2013-02-28 00:18:56 +00:00
Steven Hartland
f108bdaa19 Adds hw.mfi.cmd_timeout loader / sysctl tuneable which controls the default
timeout used in the mfi driver. This is useful for long running commands
such as secure erase.

Reviewed by:	John Baldwin
Approved by:	pjd (mentor)
2013-02-27 23:17:45 +00:00
Xin LI
20a011d5b3 Add a reminder that the user should update boot block if they are upgrading
their existing system and use LZ4 compression for ZFS.

Suggested by:	mm
MFC after:	3 days
2013-02-27 21:58:06 +00:00
Joel Dahl
06db73ec2b Remove EOL whitespace. 2013-02-27 20:16:30 +00:00
Joel Dahl
42e7fa7e09 mdoc: begin sentence on new line. 2013-02-27 20:15:06 +00:00
Joel Dahl
1046c6427e mdoc: add missing El. 2013-02-27 20:09:25 +00:00
John-Mark Gurney
80ff58b89d fix this script so we don't expand the second $FreeBSD since svn thinks
the $ in $1 ends the keyword, and expands it...
2013-02-27 19:59:58 +00:00
Ian Lepore
62e939ea17 Fix a typo that prevented booting a kernel that had virtual addresses in
the elf headers.
2013-02-27 19:59:41 +00:00