200752 Commits

Author SHA1 Message Date
bdrewery
d296342cfb MFC r289870,r289871:
r289870:
    Add bsd.crunchgen.mk to bsd.README.
  r289871:
    Sort properly.
2015-12-04 18:04:09 +00:00
bdrewery
16aebaeaea MFC r289736:
Document that we use {} for variable expansion.
2015-12-04 18:01:11 +00:00
bdrewery
16f32e49cb MFC r289379:
Remove directories disconnected since r169718.
2015-12-04 17:59:45 +00:00
bdrewery
ed825ef326 MFC r289375:
Fix wrong use of .for; the iteration variable is not used in the loop.
2015-12-04 17:58:31 +00:00
bdrewery
74816b797c MFC r289374:
Remove excess .else
2015-12-04 17:57:36 +00:00
bdrewery
28f8b6600d MFC r289360,r289361,r289378,r289430,r289605,r289676:
r289360:
    Add temporary workaround for .MAKE being applied to _worldtmp, since
    r251750.
  r289361:
    Consider top-level targets to be .PHONY as bmake won't build them otherwise
    if a file with the same name is found in the directory.
  r289378:
    Mark sub-make targets as .MAKE and .PHONY to handle -n and always-build
    properly.
  r289430:
    Remove .MAKE from targets that do more than just run sub-makes, such as
    calling rm or mtree.
  r289605:
    Add missing .PHONY for parallel subdir target.
  r289676:
    Add some missing '+', .MAKE, and .PHONY modifiers.
2015-12-04 17:56:10 +00:00
bdrewery
1c5b4d7b40 MFC r284105,r284106,r284163:
r284105:
    Cleanup some indentation issues.
  r284106:
    Implement '-s' to copy as symlink, similar to the current -l link(2)
    handling.
  r284163:
    Cleanup some style(9) issues.

Relnotes:	yes
2015-12-04 17:36:35 +00:00
bdrewery
b490558ee6 MFC r291001:
ipfw: Fix dynamic IPv6 rules showing junk for non-specified address masks.

Relnotes:	yes
2015-12-04 17:33:33 +00:00
des
72c7e45913 MFH (r287917, r287918, r289063): upgrade to latest Unbound
MFH (r283301, r289592, r291582): rc script improvements
MFH (r287880): respect manually configured forwarders when using DHCP
MFH (r289321): deconfuse man page

PR:		184047 203580 204931
2015-12-04 13:26:12 +00:00
ngie
fc230dcf44 MFC r290913,r291181:
r290913:

Port contrib/netbsd-tests/kernel/t_mqueue.c to FreeBSD

- Add missing headers
- Ensure mqueuefs is loaded
- Make sure the mqueuefs path is absolute and relative to /
- Cast the result of mq_open returning -1 to (mqd_t) to mute a compiler
  warning

Sponsored by: EMC / Isilon Storage Division

r291181:

Integrate contrib/netbsd-tests/kernel/t_mqueue into the FreeBSD test
suite as tests/sys/kern/mqueue_test
2015-12-04 09:32:03 +00:00
ngie
634df7f08c MFC r291180:
Fix up convert.c generation

- Use a temporary file for convert.c to reduce likelihood of an interrupted
  build resulting in bad code being written to convert.c
- Truncate the file instead of appending to it to ensure that the file being
  touched will not result in duplicate declarations/definitions from
  kern_acct.c if/when kern_acct.c changes.
2015-12-04 09:29:47 +00:00
ngie
6091b94628 MFC r291359,r291362:
r291359:

Skip over lines that start with # (comments)

r291362:

r291359 was incorrect. Skip over tokens that start with `#' as fgetln can
return more than one '\n' delimited line in a buffer

Handle empty lines too, just in case
2015-12-04 09:25:13 +00:00
ngie
a0e8b14feb MFC r291363:
Clean up trailing whitespace
2015-12-04 09:18:12 +00:00
ngie
8f93b93db6 MFC r291358:
Remove cnftp.bjpu.edu.cn (it no longer resolves)
Add localhost to resolv/mach for parity with nss/mach
2015-12-04 09:10:49 +00:00
kib
fb0b76eb8f MFC r291379:
Move the comment about resident pages preventing vnode from leaving
active list, into the header comment for vdrop().
2015-12-04 09:09:19 +00:00
ngie
e6a699bf60 MFC r284527,r284528,r284608,r285219,r291166,r291167:
r284527 (by imp):

Update style.9 to reflect consensus on developer's mailing list
allowing redundant braces.

Differential Revision: https://reviews.freebsd.org/D2842

r284528 (by imp):

Bump date.

Submitted by: Xin Li

r284608 (by imp):

Back out contested change until dispute is resolved. This proved to be
more contentious than I expected.

r285219 (by imp):

The results of the vote are in. This reflects that vote. Single
line statements inside of braces is recognized as an acceptable
style.
	http://reviews.freebsd.org/V3
As always, this isn't license for wholesale change, etc.

r291166:

Recommend cc -Wall instead of gcc -Wall

r291167:

Bump .Dd
2015-12-04 09:07:18 +00:00
jkim
fdc1215ebe Merge OpenSSL 1.0.1q. 2015-12-03 21:18:48 +00:00
rodrigc
68a4f44cfa Fix bad MFC (r291173)
Replace SRCTOP with the relevant path via .CURDIR

Reviewed by: bdrewery
2015-12-03 18:04:43 +00:00
royger
e9bddfef0b MFC r291024:
xen: fix dropping bitmap IPIs during resume

Sponsored by:		Citrix Systems R&D
2015-12-03 11:05:35 +00:00
rmacklem
68e44b1d70 MFC: r291035
The problem report was for a crash that happened when smbfs was
trying to do a mount. Given the backtrace,
it appears that the crash occurred when smb_vc_create() failed and then
called smb_vc_put() with vcp->vc_iod == NULL. smb_vc_put() subsequently
called smb_vc_disconnect() with vcp->vc_iod == NULL, causing the crash.
This patch adds a check for vcp->vc_iod != NULL in smb_vc_disconnect() to
avoid the crash. It also fixes the case in smb_vc_create() where
kproc_create() fails so that it destroys the mutexes and sets
vcp->vc_iod == NULL before free()'ing the iod structure.
2015-12-02 21:48:34 +00:00
fabient
ccce6feaa4 MFC r291301:
The r241129 description was wrong that the scenario is possible
 only for read locks on pcbs. The same race can happen with write
 lock semantics as well.

 The race scenario:

 - Two threads (1 and 2) locate pcb with writer semantics (INPLOOKUP_WLOCKPCB)
  and do in_pcbref() on it.
 - 1 and 2 both drop the inp hash lock.
 - Another thread (3) grabs the inp hash lock. Then it runs in_pcbfree(),
  which wlocks the pcb. They must happen faster than 1 or 2 come INP_WLOCK()!
 - 1 and 2 congest in INP_WLOCK().
 - 3 does in_pcbremlists(), drops hash lock, and runs in_pcbrele_wlocked(),
  which doesn't free the pcb due to two references on it.
  Then it unlocks the pcb.
 - 1 (or 2) gets wlock on the pcb, runs in_pcbrele_wlocked(), which doesn't
  report inp as freed, due to 2 (or 1) still helding extra reference on it.
  The thread tries to do smth with a disconnected pcb and crashes.

 Submitted by:	emeric.poupon@stormshield.eu
 Reviewed by:	glebius@
 Sponsored by: Stormshield
 Tested by: Cassiano Peixoto, Stormshield
2015-12-02 17:26:37 +00:00
royger
904bdb8bc2 Revert MFC of r291023:
Due to the delta between HEAD and stable/10 event channel code, this fix is
not needed on stable/10 and was also causing build issues. Revert it.
2015-12-02 12:58:20 +00:00
royger
b1833e1562 MFC r291023:
xen/intr: properly dispose event channels on resume

Sponsored by:		Citrix Systems R&D
2015-12-02 10:26:34 +00:00
royger
28836b5874 MFC r291022:
x86/intr: allow mutex recursion in intr_remove_handler

Sponsored by:		Citrix Systems R&D
2015-12-02 10:23:54 +00:00
ngie
90fda359a4 MFC r269902,r270101:
r269902:

Convert bin/sh/tests to ATF

The new code uses a "test discovery mechanism" to determine
what tests are available for execution

The test shell can be specified via:

  kyua test -v test_suites.FreeBSD.bin.sh.test_shell=/path/to/test/sh

Sponsored by: EMC / Isilon Storage Division
Approved by: jmmv (mentor)
Reviewed by: jilles (maintainer)

r270101 (by jilles):

sh: Don't hardcode relative paths in the tests stderr files.

These paths have had to be adjusted to changes in the testsuite runner
several times, so modify the tests to remove the need for such adjustment.

A cp in functional_test.sh is now unneeded, but this matters little in
performance.
2015-12-01 18:27:38 +00:00
ngie
394e9d5dd4 MFC r285118:
r285118 (by jmmv):

Add missing shebang

Plain test programs are not preprocessed by the build system (as opposed to
ATF test cases, which automatically gain a shebang pointing at atf-sh), so
we must take care of providing the shebang ourselves.

I'm not sure why this was not causing problems with Kyua 0.11, but the
upcoming 0.12 release chokes on this particular issue.
2015-12-01 18:21:25 +00:00
ngie
f2f170ddd8 MFC r285140:
r285140 (by oshogbo):

Add fdclose(3) function.

This function is equivalent to fclose(3) function except that it
does not close the underlying file descriptor.
fdclose(3) is step forward to make FILE structure private.

Reviewed by:	wblock, jilles, jhb, pjd
Approved by:	pjd (mentor)
Differential Revision:	https://reviews.freebsd.org/D2697
2015-12-01 18:19:23 +00:00
ngie
ff68307fb4 MFC r278932:
r278932 (by pfg):

libc: clean some set-but-not-used errors.

These were found by gcc 5.0 on Dragonfly BSD, however I
made no attempt to silence the false positives.

Obtained from:	DragonFly (cf515c3a6f3a8964ad592e524442bc628f8ed63b)
2015-12-01 07:32:35 +00:00
ngie
194e32cbb7 MFC r269326:
r269326 (by n_hibma):

Fix the example: free the memory that was allocated by getline().
2015-12-01 07:16:05 +00:00
rmacklem
f72e7ffb57 MFC: r290970
mnt_stat.f_iosize (which is used to set bo_bsize) must be set to
the largest size of buffer cache block or the mapping of the buffer
is bogus. When a mount with rsize=4096,wsize=4096 was done, f_iosize
would be set to 4096. This resulted in corrupted directory data, since
the buffer cache block size for directories is NFS_DIRBLKSIZ (8192).
This patch fixes the code so that it always sets f_iosize to at least
NFS_DIRBLKSIZ.
2015-12-01 02:30:41 +00:00
smh
ee4f717293 MFC r291004:
Fix early kernel dump via dumpdev env

Sponsored by:	Multiplay
2015-12-01 00:53:03 +00:00
smh
acd245f48b MFC r288153:
Use kenv 'dumpdev' in the same way as etc/rc.d/dumpon

Sponsored by:	Multiplay
2015-12-01 00:48:31 +00:00
mav
8cd0a777b2 MFC r291143: Update Qlogic 23XX firmware from 3.03.26 to 3.03.28 2015-11-30 23:00:22 +00:00
mav
096c78a938 MFC r291132: Update firmware for QLogic 22xx from 2.02.06 to 2.02.08. 2015-11-30 22:59:32 +00:00
mav
7ea9902b0d MFC r289755: Remove residual verbosity.
firmware_register() already reports errors.
2015-11-30 22:58:48 +00:00
mav
9718915814 MFC r291365, r291369: One more round of port scanner rewrite.
- Make scan aborted by event restart immediately and infinitely.
 - Improve handling of some loop events from firmware.
 - Remove loop down timer, adding its functionality to scanner thread.
 - Some more unification and simplification.
2015-11-30 21:58:51 +00:00
mav
7e42579757 MFC r291265: Rename ASYNC_LIP_F8 to ASYNC_LIP_NOS_OLS_RECV.
New name better repsents its meaning for modern chips.
2015-11-30 21:57:54 +00:00
mav
b7a97f6338 MFC r291221: Remove "disable" hint, which duplicates system-wide "disabled". 2015-11-30 21:57:16 +00:00
mav
4cf0c712d6 MFC r291209: Fix target mode support for Qlogic 2200 FC adapters.
Now target mode works for all supported FC adapters except ancient 2100,
which is not tested.
2015-11-30 21:56:31 +00:00
mav
a492c3be47 MFC r291188: Rip off target mode support for parallel SCSI QLogic adapters.
Hacks to enable target mode there complicated code, while didn't really
work.  And for outdated hardware fixing it is not really interesting.

Initiator mode tested with Qlogic 1080 adapter is still working fine.
2015-11-30 21:55:35 +00:00
mav
f6a1230f6d MFC r290138, r290139: Some updates to isp(4) manual page. 2015-11-30 21:53:38 +00:00
mav
e0856d3372 MFC r275374: Document ISP 2532 support and hint.isp.0.vports tunable. 2015-11-30 21:52:19 +00:00
mav
140ab93a08 MFC r291163:
Explicitly call SEND CHANGE REQUEST for pre-24xx chips in target mode.

While later firmware always registers for RSCN requests, older one does
it only in initiator mode.  But in target mode there RSCN can be the only
way to detect gone intiator.
2015-11-30 21:47:11 +00:00
mav
90295bb24a MFC r291162: Generate fake ISPASYNC_CHANGE_PDB on fake login on pre-24xx.
This makes port scanner fix absent port ID for added initiator.
2015-11-30 21:46:21 +00:00
mav
ea4ecdf74c MFC r291161: Gracefully stop firmware before resetting chip when changing role. 2015-11-30 21:45:24 +00:00
mav
a9c72ce3b2 MFC r291160: Add some more asynchronous event status codes. 2015-11-30 21:44:38 +00:00
mav
81646eff8a MFC r291159: Add more mailbox command codes. 2015-11-30 21:44:03 +00:00
mav
7b3194de40 MFC r291147: Increase maximal value of vports tunable to 254.
I am not sure this value is really viable yet, but that is what chips
officially support in NPIV mode (in loop mode maximum is 125).
2015-11-30 21:43:20 +00:00
mav
7dd0f6589b MFC r291144: Fix target mode with fabric for pre-24xx chips.
For those chips we are not receiving login events, adding initiators
based on ATIO requests.  But there is no port ID in that structure, so
in fabric mode we have to explicitly fetch it from firmware to be able
to do normal scan after that.
2015-11-30 21:42:35 +00:00
mav
9ab138f53b MFC r291099: Some cosmetics for ancient cards. 2015-11-30 21:41:56 +00:00