267417 Commits

Author SHA1 Message Date
maxv
661cae2406 Invalidate the cache before updating the microcode. Some platforms require
this. Seen in Illumos and FreeBSD.
2019-05-09 18:53:14 +00:00
bouyer
3eb5fd5e6d sti/cli are not allowed on Xen, we have to clear/set a bit in the
shared page. Revert x86_disable_intr/x86_enable_intr to plain function
calls on XENPV.
While there, clean up unused functions and macros, and change cli()/sti()
macros to x86_disable_intr/x86_enable_intr.
Makes Xen domU boot again
(http://www-soc.lip6.fr/~bouyer/NetBSD-tests/xen/HEAD/)
2019-05-09 17:09:50 +00:00
ryo
267add9d06 fix backtrace. it was broken.
- use db_read_bytes() to avoid faults.
- quite a few functions do not use frame pointers,
  therefore always detect stack depth without a frame pointer.
  however, since the framepointer(=r14) is used as a trapframe,
  the code to detect the frame pointer is still needed.
- dump the contents of trapframe during backtracing.
- KNF
2019-05-09 16:48:31 +00:00
scole
9198d9c263 Revert -O0 for pmap, avoid RAW dependency compilation warning 2019-05-09 15:48:55 +00:00
skrll
ffc73f781f Fix USB_DEBUG build 2019-05-09 14:50:38 +00:00
mgorny
873249d162 Add ptrace() tests for reading mm* and xmm* registers 2019-05-09 13:07:35 +00:00
skrll
6e867a675a toolify
PR/54182: Cross-building on Linux fails in rb.c
2019-05-09 10:56:24 +00:00
wiz
f96f071847 Sort options (no-argument options before ones demanding arguments).
Bump date.
2019-05-09 09:37:11 +00:00
wiz
d2dc8d6bf5 Bump date. 2019-05-09 09:35:18 +00:00
wiz
adb7f5e61d Improve wording, bump date. 2019-05-09 09:34:58 +00:00
wiz
2d27efa0f1 Improve wording, add more formatting. 2019-05-09 09:32:26 +00:00
wiz
89c9bc7330 Fix some typos, improve wording and formatting. 2019-05-09 09:22:13 +00:00
wiz
220b9b32b9 Remove trailing whitespace. 2019-05-09 09:09:38 +00:00
roy
a876fb76fb Fix build with MKYP=no 2019-05-09 08:20:35 +00:00
skrll
f77ca71313 Avoid KASSERT(!cpu_intr_p()) when breaking into ddb and issuing
show uvmexp
2019-05-09 08:16:14 +00:00
mrg
e288c0bcc9 when dumping a kernhist history replace "%s" with "%p" so that the
kernhist in kernel can be a little more usable without making the
userland dumping code crash.
2019-05-09 08:01:07 +00:00
mrg
13e211962f document 'devs' and 'procs' commands. 2019-05-09 07:59:49 +00:00
mrg
04ce020754 add cortex A-76 detection. 2019-05-09 07:38:44 +00:00
cnst
f923dad31e bio(4): .In dev/biovar.h in SYNOPSIS; .Xr envsys 4 et al in both DESCR && SEE ALSO 2019-05-09 07:12:38 +00:00
ozaki-r
00cd510af4 Avoid prepending a timestamp to lock debug outputs on ddb
Lock printer functions (lockops_t#lo_dump) use printf_nolog to print, but
printf_nolog now prepends a timestamp which is unnecessary for ddb:

    db{0}> show all locks/t
    [Locks tracked through LWPs]
    Locks held by an LWP (iperf):
    Lock 0 (initialized at soinit)
    lock address : 0xffffedeb84b06080 type     :     sleep/adaptive
    initialized  : 0xffffffff806d8c3f
    shared holds :                  0 exclusive:                  1
    shares wanted:                  0 exclusive:                 11
    current cpu  :                  0 last held:                  1
    current lwp  : 0xffffedeb849ff040 last held: 0xffffedeb7dfdb240
    last locked* : 0xffffffff806d8335 unlocked : 0xffffffff806d8385
    [ 79103.0868574] owner field  : 0xffffedeb7dfdb240 wait/spin:                1/0

Fix it by passing a printer function to lo_dump functions, i.e., make the
functions use db_printf on ddb.
2019-05-09 05:00:31 +00:00
ozaki-r
1180247a6a Make _kernel_lock_dump static 2019-05-09 04:53:52 +00:00
ozaki-r
e67774d0d4 Add missing "static" declaration 2019-05-09 04:52:59 +00:00
mrg
cc0cad1ec6 clean up ucom parents some more:
- it's always "bool sc_dying" now, with true/false
- heavy use of static functions
- remove all ucom parent ca_activate callbacks.  they're never called.
- callbacks should generally do little to nothing if sc_dying is set
- open resources should be released in detach after setting sc_dying
- don't complain about usbd_abort_pipe() or usbd_close_pipe() failure
- when releasing resources, zero the softc member as well
- remove ucom_methods members no longer destined to be filled in
- generally, DPRINTF() before sc_dying short circuit
- use EIO when dying, not ENXIO or 0
- add some ucom_open() callbacks that simply return EIO if dying
2019-05-09 02:43:35 +00:00
ozaki-r
d3665a665f Protect ether_multi list
The list can be racy if NET_MPSAFE is enabled and the driver is executed without
KERNEL_LOCK.

Fix PR 54153
2019-05-09 01:46:37 +00:00
nat
c057c3c17d Sync with reality. 2019-05-08 22:01:47 +00:00
cnst
d23a7a2d2c bio(4): document the state of setstate more thoroughly 2019-05-08 19:34:09 +00:00
christos
480f1f3667 fix acpica 2019-05-08 18:00:16 +00:00
chs
8d47d38e9e uvm_pagealloc() uses UVM_PGA_* flags, not UVM_KMF_* flags,
and it is always nowait.  fix uarea_poolpage_alloc() to not use
flags from the wrong collection for calling uvm_pagealloc()
and to wait itself if a page is not immediately available.
2019-05-08 16:00:01 +00:00
bad
a057d46c24 Clarify that strunvisx() and strnunvisx() take the same flags as unvis().
Document VIS_NOESCAPE for unvis().
Bump date.
2019-05-08 15:37:41 +00:00
isaki
017c116c97 Remove -p option. AUDIO_SETCHAN is insecure and is obsoleted. 2019-05-08 14:44:42 +00:00
isaki
0b88ff9914 Update respond to isaki-audio2 branch.
- Extend list command to display supported hardware formats.
- Add set command to set hardware format.
- Use correct /dev/audioctl instead of /dev/audio.
2019-05-08 14:36:12 +00:00
isaki
b040836639 Update manpages respond to isaki-audio2 branch. 2019-05-08 14:25:38 +00:00
christos
9beb52efed mention truncation of the result if the size in optlen is less that the
size of the option to be returned in optval.
2019-05-08 14:10:42 +00:00
christos
4267c2f8b0 PR/54176: Anthony Mallet:
getsockopt(2) does not silently truncate returned optval
2019-05-08 14:05:18 +00:00
leot
666793fa92 Fix a typo
Reported by Tobias Ulmer via netbsd-docs@ ML, thanks!
2019-05-08 14:03:57 +00:00
isaki
e0c9195986 Merge isaki-audio2 branch.
Welcome to 8.99.39.
2019-05-08 13:47:33 +00:00
isaki
e622eac459 Merge isaki-audio2 branch, the overhaul of audio subsystem.
- Interrupt-oriented system rather than thread-oriented.
- Improve stability, quality and performance.
- Split playback and record cleanly.  Improve halfduplex support.
- Many bugs are fixed including deadlocks, resource leaks, abuses, etc.
- Simplify audio filter mechanism.  The encoding/channels/frequency
  conversions are completely handled in the upper layer.  So the hard-
  ware driver only converts its hardware encoding (if necessary).
- audio_hw_if changes:
  - Obsoletes query_encoding and add query_format instead.
  - Obsoletes set_params and add set_format instead.
  - Remove drain, setfd, mappage.
  - The call sequences are changed.
- ioctl AUDIO_GETFD/SETFD, AUDIO_GETCHAN/SETCHAN are obsoleted.
- ioctl AUDIO_{QUERY,GET,SET}FORMAT are introduced.
- cleanup config attributes: au*conv and mulaw.
- All hardware drivers should follow it (I've done as much as possible).

Some file paths are changed:
- dev/audio.c         -> dev/audio/audio.c (rewritten)
- dev/audiovar.h      -> dev/audio/audiovar.h
- dev/audio_dai.h     -> dev/audio/audio_dai.h
- dev/audio_if.h      -> dev/audio/audio_if.h
- dev/audiobell.c     -> dev/audio/audiobell.c
- dev/audiobellvar.h  -> dev/audio/audiobellvar.h
- dev/mulaw.[ch]      -> dev/audio/mulaw.[ch] + dev/audio/alaw.c
2019-05-08 13:40:13 +00:00
skrll
24ef49d776 Really go back to pre-whitespace change (1.52) arm32_kernel_vm_init 2019-05-08 13:18:47 +00:00
ozaki-r
dfdcf19001 Protect ether_multi list
PR 54153
2019-05-08 09:53:43 +00:00
cnst
b87889e72c cac(4): Xr bio(4) and friends, and mention when it was first introduced 2019-05-08 07:44:28 +00:00
wiz
8edeed6684 Make enumerations consistent, and use Dv for BIO*. 2019-05-08 07:41:23 +00:00
wiz
c41ad8e441 Revert previous, misunderstanding. 2019-05-08 07:17:29 +00:00
cnst
f01a8d9eee bio(4): document which commands are supported by which drivers; 2019-05-08 06:57:18 +00:00
cnst
0f59c4847a mpt(4): remove ENOTTY / noop implementation of bio(4) setstate
* All other bio(4) drivers either do or don't implement each command.

* This changes the returned error code, but it does not seem to matter,
  as some bio(4) drivers always return ENOTTY in the default case, whilst
  others always return EINVAL (e.g., both cac(4) and ciss(4) for setstate).
2019-05-08 06:32:01 +00:00
mrg
0e5d2a543b new comment explains this hack:
* XXXMRG: Stall task can run after slot is disabled when yanked.
 * This hack notices that the xs has been memset() in
 * xhci_disable_slot() and returns.  Both xhci_reset_endpoint()
 * and xhci_set_dequeue() rely upon a valid ring setup for correct
 * operation, and the latter will fault, as would
 * usb_transfer_complete() if it got that far.

this truly fixes yanking active ucom devices (uchcom, uplcom and
umcs all tested.)  prior efforts largely worked by allowing the
stall task to run first, as a side effect to their actual work.

ok @skrll.

XXX: pullup.
2019-05-08 06:31:02 +00:00
wiz
3a5a3e206b Sort SEE ALSO. 2019-05-08 06:10:30 +00:00
wiz
85d5917a34 Fix typo. 2019-05-08 06:09:51 +00:00
cnst
ac84331e0e bio(4) drivers: remove noop fallthrough-to-default bio(4) cmd cases
* Makes it easier to do code/feature analysis by not having
  extra noop code/symbols spattered around.

* Only an issue in cac(4) and ciss(4); other drivers don't do this.

* No binary changes.
2019-05-08 05:40:51 +00:00
thorpej
88c316691b Use posix_madvise() rather than the legacy madvise() call, and
wrapp the calls in #ifdef for the advice we're giving.  Should
address reports of host tool build issues.
2019-05-08 04:34:33 +00:00
cnst
f11bc4e580 bioctl(8): Xr ataraid(4), mpii(4) && mfii(4); 2019-05-08 03:29:59 +00:00