Commit Graph

197964 Commits

Author SHA1 Message Date
ngie
964f5a1f13 MFC r273803,r273810:
r273803:

  Filter out TESTS_SUBDIRS already added to SUBDIR instead of blindly
  appending the TESTS_SUBDIRS variable to SUBDIR

  Duplicate directory entries can cause unexpected side effects, like
  installing the same files multiple times. This can be easily
  reproduced via the following testcase prior to this commit:

    SUBDIR= dir
    TESTS_SUBDIRS+= dir

    .include <bsd.test.mk>

  Sponsored by: EMC / Isilon Storage Division

r273810:

  Fix the logic inversion in the previous commit by ensuring that the matched
  expression (:M) is empty, not the not matched (:N) is empty. The former case
  means we have not found the TEST_SUBDIR value in SUBDIR

  Reported by: rodrigc
  Pointyhat to: me (did not use a clean install root)
  Sponsored by: EMC / Isilon Storage Division
2014-12-22 00:50:08 +00:00
ngie
8cd5c94ddb MFC r273186,r273873:
r273186:

  Don't define rules based on PROGS if PROGS is empty.

  Reviewed by:	sjg, ngie
  Sponsored by:	EMC / Isilon Storage Division

r273873:

  Use the right depend file for each program.

  bsd.progs.mk generates a separate depend file for every program being
  built, but then it does not properly tell each submake to use those
  individual files.  Properly propagate the depend file to use.

  Discovered while preparing the update of atf to 0.21 and noticing that
  the test programs were not being relinked to the new library.

  This change is "make tinderbox" clean.
2014-12-22 00:21:24 +00:00
smh
5f92f0907a MFC r272223:
Prevent possible use after free in ahci direct mode

Sponsored by:	Multiplay
2014-12-21 16:43:56 +00:00
smh
3b6e56e0bc MFC r268156:
Various bugfixes from Stefano GarzarellaA

This has been proved to fix reproducable panics on 10.x.

Sponsored by:	Multiplay
2014-12-21 15:39:19 +00:00
trasz
d7139ba7f6 MFC r274784:
Fix smbfs to not zero out statfs f_flags field. Previously, this
made getmntinfo() return empty flags for smbfs filesystems when
called with MNT_WAIT. It's not visible with mount(8), since it uses
MNT_NOWAIT, but broke autounmount(8) operation.

PR:		195161
Sponsored by:	The FreeBSD Foundation
2014-12-21 11:33:18 +00:00
trasz
40ef49f52b MFC r274742:
Uniformly refer to a file system as "file system".

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:26:51 +00:00
trasz
84195308d0 MFC r274741:
Add example on how to use gpart before growfs.  While here, reorder examples
so that the simplest one comes first.

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:25:26 +00:00
trasz
950a2d5097 MFC r274738:
Document growfs(8) feature apparently nobody knows about.

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:23:59 +00:00
trasz
83b038683b MFC r274737:
Use proper ordering in EXAMPLES section in growfs(8).

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:22:15 +00:00
trasz
0ba11869de MFC r274796:
Document use of wildcards (*) and ampersands (&) in autofs map files.

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:15:35 +00:00
ngie
2e865a9c0a MFC r273482,r274078:
r273482:

  The NetBSD libc tests use several definitions/macros that aren't available in
  FreeBSD

  Add the missing compat definitions/macros to lib/libnetbsd so the testcases
  can be compiled with libnetbsd without having to invent ad hoc #define's, or
  having to convert things over to FreeBSD idioms

  Reviewed by: brooks
  Phabric: D993
  Sponsored by: EMC / Isilon Storage Division

r274078:

  Commit missing header for sys/time.h compat on NetBSD to unbreak the amd64/i386
  build

  Pointyhat to: me (forgot to svn add it sooner)
2014-12-21 11:11:17 +00:00
trasz
88d4dfb90e MFC r274723:
Make the auto_master(5) man page clearer on how auto_master
and map files work together, and add example for smbfs.

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:03:59 +00:00
trasz
a740f64591 MFC r274621:
The "intr" option is NFS-specific; fix examples in auto_master(5).

Sponsored by:	The FreeBSD Foundation
2014-12-21 11:00:48 +00:00
trasz
5654688c96 MFC r274549:
Make it possible to do "iscsictl -Rt xxx -p yyy", to remove a session
that matches both -t and -p.

Sponsored by:	The FreeBSD Foundation
2014-12-21 10:56:06 +00:00
ngie
dc3ad5131f MFC r273929:
r273929 (by jmmv):

  MFV: Import atf-0.21.
2014-12-21 08:30:18 +00:00
dchagin
1a3934911c Regen for r275986 (ppoll). 2014-12-21 08:00:38 +00:00
dchagin
dfe2ad4d46 MFC r274462: Add the ppoll() system call. 2014-12-21 07:58:28 +00:00
smh
f73f068967 MFC r274819:
Prevent overflow issues in timeout processing

MFC r274852:
Fix build with asr driver

Sponsored by:	Multiplay
2014-12-21 03:06:11 +00:00
smh
4ae371d305 MFC r269615:
Various fixes to hptrr(4)

Sponsored by:	Multiplay
2014-12-21 03:00:44 +00:00
smh
4ffc79821f MFC r269613:
Various fixes to hptnr(4)

Sponsored by:	Multiplay
2014-12-21 02:57:03 +00:00
smh
c7e8e234ac MFC r267290:
Make the hpt27xx(4) driver MPSAFE

Sponsored by:	Multiplay
2014-12-21 02:52:40 +00:00
smh
e3ea8796d6 MFC r266772:
Various cleanups and fixes including switching from timeout to callout

Sponsored by:	Multiplay
2014-12-21 02:47:38 +00:00
smh
34faa04ea6 MFC r272000:
Switch from timeout(9) to callout(9)

Sponsored by:	Multiplay
2014-12-21 02:39:10 +00:00
smh
4749aacddd MFC r272735:
Support upto 256VD.

MFC r272737:
Support 32-bit linux binaries on FreeBSD 64bit.

MFC r272738:
Fix the minor svn add issue.

MFC r272739:
Extended MSI-x vectors support for Invader and Fury(12Gb/s HBA).

MFC r272740:
Add d_poll support.

MFC r272741:
Fix leak of mfi cmd in the passthru and correctly limit oustanding.

MFC r272742:
Import vendor Phase 6.5 driver

MFC r272744:
Style (9) fixes.

MFC r273040:
Fix for build issue on i386.xen and amd64.xen.

Sponsored by:	Multiplay
2014-12-21 02:35:22 +00:00
smh
90167d8975 MFC: r274487
Lock iir(4) and mark it MPSAFE.

Sponsored by:	Multiplay
2014-12-21 01:39:21 +00:00
kib
32facbd8ab MFC r275744:
Only sleep interruptible while waiting for suspension end when
filesystem specified VFCF_SBDRY flag, i.e. for NFS.
2014-12-20 15:49:12 +00:00
kib
febae1567d MFC r275743:
Put the buffer cleanup code after inactivation.
2014-12-20 15:46:15 +00:00
brueffer
f419d174a9 MFC: r274960 (slightly modified)
Limit descriptors and enter capability mode.  Since the header was renamed in HEAD, this
commit includes sys/capability.h.

Differential:	D1009
Reviewed by:	jonathan, pjd
Relnotes:	yes
2014-12-19 23:18:22 +00:00
ae
98ddab22ac MFC r275729:
Increase the buffer size to keep the list of programm names when
  parsing programm specification. It is safe to not check out of bounds
  access, because !isprint(p[i]) check will stop reading, when '\0'
  character will be read from the input string.

Sponsored by:	Yandex LLC
2014-12-19 13:22:02 +00:00
kib
492a1d38b5 MFC r275833:
The iret instruction may generate #np and #ss fault, besides #gp.
When returning to usermode, the handler for that exceptions is also
executed with wrong gs base.  Handle all three possible faults in the
same way, checking for iret fault, and performing full iret.
2014-12-19 09:36:59 +00:00
kib
bf07138622 MFC r275727:
For architectures where time_t is wide enough, in particular, 64bit
platforms, avoid overflow after year 2038 in clock_ct_to_ts().

PR:	195868
2014-12-19 09:34:14 +00:00
mav
eac5956a91 MFC r275503:
Avoid unneeded malloc/memcpy/free if there is no metadata on disk.

Submitted by:	Dmitry Luhtionov <dmitryluhtionov@gmail.com>
2014-12-19 01:13:41 +00:00
jhb
3f663b8b40 MFC 273871:
Skip the smap sysctl instead of panicing if no kernel metadata can be
found.
2014-12-18 23:00:17 +00:00
avg
a691672ca9 MFC r275401: zfs_putpages: actually update mtime and ctime 2014-12-18 13:46:11 +00:00
kib
55c41429c0 MFC r271315 (by joel):
Minor mdoc nit.

MFC r275806:
Markup fixes for kqueue(2), no content changes.
2014-12-18 11:36:14 +00:00
kib
9f63b4b4d8 MFC r268843 (by bapt):
Extend kqueue's EVFILT_TIMER by adding precision unit flags support.
2014-12-18 11:30:51 +00:00
kib
3abf5d53d8 MFC r259609 (by se):
Fix overflow for timeout values of more than 68 years, which is the maximum
covered by sbintime (LONG_MAX seconds).

MFC r259633 (by se):
Fix compilation on 32 bit architectures and use INT64_MAX instead of
LONG_MAX for the upper bound check.
2014-12-18 11:10:15 +00:00
mav
66c7f00f29 MFC r275482: Document r275481 changes. 2014-12-18 08:49:50 +00:00
mav
a0e66849d7 MFC r275568:
Count consecutive read requests as blocking in CTL for files and ZVOLs.

Technically read requests can be executed in any order or simultaneously
since they are not changing any data.  But ZFS prefetcher goes crasy when
it receives consecutive requests from different threads.  Since prefetcher
works on level of separate blocks, instead of two consecutive 128K requests
it may receive 32 8K requests in mixed order.

This patch is more workaround then a real fix, and it does not fix all of
prefetcher problems, but it improves sequential read speed by 3-4x times
in some configurations.  On the other side it may hurt performance if
some backing store has no prefetch, that is why it is disabled by default
for raw devices.
2014-12-18 08:46:53 +00:00
mav
fe777840de MFC r275512:
In addition to r275481 allow threshold notifications work without UNMAP.

While without UNMAP support there is not much initiator can do about it,
the administrator still better be notified about the storage overflow.

Sponsored by:   iXsystems, Inc.
2014-12-18 08:45:28 +00:00
mav
57c600c3f5 MFC r275481:
Add to CTL support for threshold notifications for file-backed LUNs.

Previously it was supported only for ZVOL-backed LUNs, but now should work
for file-backed LUNs too.  Used value in this case is a space occupied by
the backing file, while available value is an available space on file
system.  Pool thresholds are still not implemented in this case.

Sponsored by:   iXsystems, Inc.
2014-12-18 08:43:36 +00:00
mav
4ff47ae9ab MFC r275474: Add GET LBA STATUS command support to CTL.
It is implemented for LUNs backed by ZVOLs in "dev" mode and files.
GEOM has no such API, so for LUNs backed by raw devices all LBAs will
be reported as mapped/unknown.

Sponsored by:   iXsystems, Inc.
2014-12-18 08:38:07 +00:00
mav
251a95deec MFC r275461:
Increase CTL ports limit from 128 to 256 and LUNs limit from 256 to 1024.

After recent optimizations this change is no longer blocked by CTL memory
consumption.  Those limits are still not free, but much cheaper now.

Relnotes:	yes
Sponsored by:	iXsystems, Inc.
2014-12-18 08:37:09 +00:00
mav
e99b295765 MFC r275459: Unify function names after r275458. 2014-12-18 08:32:56 +00:00
mav
510c6d695e MFC r275458:
Do not pre-allocate UNIT ATTENTIONs storage for every possible initiator.

Abusing ability of major UAs cover minor ones we may not account UAs for
inactive ports.  Allocate UAs storage for port and start accounting only
after some initiator from that port fetched its first POWER ON OCCURRED.

This reduces per-LUN CTL memory usage from >1MB to less then 100K.
2014-12-18 08:32:06 +00:00
mav
e998495ddf MFC r275455: Remove some unused code. 2014-12-18 08:31:13 +00:00
mav
ef698a8b3d MFC r275447:
Do not pre-allocate reservation keys memory for every possible initiator.

In configurations with many ports, like iSCSI, each LUN is typically
accessed only by limited subset of ports.  Allocating that memory on
demand allows to reduce CTL memory usage from 5.3MB/LUN to 1.3MB/LUN.
2014-12-18 08:30:28 +00:00
mav
a4403fd4b3 MFC r275405: Convert persis_offset from global variable to softc field. 2014-12-18 08:28:44 +00:00
mav
be8a551758 MFC r275404: Reduce code duplication by creating ctl_set_res_ua() helper. 2014-12-18 08:27:46 +00:00
mav
f47cf8ca42 MFC r275403: Removed unused variable and unify some names. 2014-12-18 08:27:00 +00:00