eric [Wed, 18 Mar 2020 20:17:14 +0000 (20:17 +0000)]
use CRLF line-ending during the SMTP dialog in the local enqueuer
ok millert@
mpi [Wed, 18 Mar 2020 20:10:34 +0000 (20:10 +0000)]
Whitelist 'map' type in order to use them in real (non BEGIN/END) rules.
anton [Wed, 18 Mar 2020 19:35:00 +0000 (19:35 +0000)]
regen
anton [Wed, 18 Mar 2020 19:33:36 +0000 (19:33 +0000)]
Unlock flock(2).
ok mpi@ visa@
visa [Wed, 18 Mar 2020 15:48:21 +0000 (15:48 +0000)]
Restart child process scan in dowait4() if single_thread_wait() sleeps.
This ensures that the conditions checked are still in force. The sleep
breaks atomicity, allowing another thread to alter the state.
single_thread_set() should return immediately after sleep when called
from dowait4() because there is no guarantee that the process pr still
exists. When called from single_thread_set(), the process is that of
the calling thread, which prevents process pr from disappearing.
OK anton@, mpi@, claudio@
mpi [Wed, 18 Mar 2020 11:56:40 +0000 (11:56 +0000)]
Plug mem leak in SADB_REGISTER.
From Benjamin Baier, ok tobhe@
nicm [Wed, 18 Mar 2020 09:13:49 +0000 (09:13 +0000)]
Break position calculation into a helper function.
kn [Tue, 17 Mar 2020 21:24:22 +0000 (21:24 +0000)]
Print IO device names next to path with "list-io"
Names help identify the right iodevice to be assigned in ldom.conf(5);
they directly match the structure seen in the iLOM shell, and the output
format is similar to Solaris "ldm list-io".
OK kettenis
kettenis [Tue, 17 Mar 2020 17:27:12 +0000 (17:27 +0000)]
Mark a few functions as .globl such that they show up with their name
in btreace(8) output.
ok deraadt@, patrick@
nicm [Tue, 17 Mar 2020 16:02:38 +0000 (16:02 +0000)]
getopt is not required to set optarg to NULL when there is no argument
and some do not, so set it explicitly each time.
kettenis [Tue, 17 Mar 2020 15:49:38 +0000 (15:49 +0000)]
Hook this up to the drm(4) panel code and add an override for the
"boe,nv140fhmn49" panel, which is the panel found on the pinebook pro.
This particular panel advertizes a mode which on some machines isn't
usuable (but works fine on other machines).
ok patrick@
nicm [Tue, 17 Mar 2020 12:20:12 +0000 (12:20 +0000)]
Do not return early if no bits changed because may still need to change the style.
nicm [Tue, 17 Mar 2020 11:10:12 +0000 (11:10 +0000)]
Ignore default-shell (and use /bin/sh) if it invalid not just if it is
tmux itself, also refuse to set the option to something invalid in the
first place. GitHub issue 2120.
kettenis [Tue, 17 Mar 2020 10:14:45 +0000 (10:14 +0000)]
Fix inline assembly in ppc_mftb(); using %L0 instead of %0+1 makes this work
for both gcc and clang. From NetBSD. Thanks to some serious detective work
by ghoehler@.
ok deraadt@, gkeohler@
tobhe [Tue, 17 Mar 2020 09:53:59 +0000 (09:53 +0000)]
Use strlcpy instead of strncpy to ensure results are NUL terminated.
ok mpi@
mpi [Tue, 17 Mar 2020 09:34:52 +0000 (09:34 +0000)]
Prevent out-of-bound read if `rate' doesn't match known values.
CID
1453258
ok kettenis@
tobhe [Tue, 17 Mar 2020 09:01:53 +0000 (09:01 +0000)]
Exit when m_get_string() returns NULL to prevent nullptr dereference in
strlen().
ok millert@
dlg [Tue, 17 Mar 2020 03:09:04 +0000 (03:09 +0000)]
rework amd (not intel) smt/core/package detection.
the previous code relied on newer cpus having properly filled in
values for som e new cpuid fields, but these are definitely not
filled in properly if you're running in a certain type of virtual
machine, which meant a lot of cores were misidentified as threads.
this new code follows what most other operating systems seem to do.
they read the "initial local apic id", which is globally unique in
a system, and cut it up into the package, core, and smt values. the
line between a package and the cores/threads inside a package is
determined by the "ApicIdSize". once the package is masked off, the
remaining core/thread ids is divided up by the ThreadsPerCore value.
the latter defaults to 1, unless we're on a newer (eg, zen) chip
that provides a higher value.
this seems to work well across a variety of machines of different
vintages.
thanks to mark patruck, hrvoje popovski, and sthen@ for a lot of testing.
ok sthen@
millert [Mon, 16 Mar 2020 23:34:02 +0000 (23:34 +0000)]
Initialize session.rcptto to NULL before parsing command line optinos.
Otherwise, if neither -r nor -u is specified, it will be used uninitialized.
Found by tobhe@; OK tobhe@ deraadt@
kettenis [Mon, 16 Mar 2020 22:44:12 +0000 (22:44 +0000)]
Actually attach panel (if we have one).
ok patrick@
kettenis [Mon, 16 Mar 2020 21:51:25 +0000 (21:51 +0000)]
Replace video "framework" with a more generic port/endpoint "framework".
This also adds panel support to rkanxdp(4). Code to hook up simplepanel(4)
is still missing and will come later.
ok patrick@
benno [Mon, 16 Mar 2020 20:46:44 +0000 (20:46 +0000)]
fix cast in isdigit() calls.
ok eric@ deraadt@
nicm [Mon, 16 Mar 2020 18:08:39 +0000 (18:08 +0000)]
Do not attempt to close a NULL pane when failing to create a new one.
jasper [Mon, 16 Mar 2020 16:12:43 +0000 (16:12 +0000)]
Prevent a NULL derefence in alloc_all_endpoints_fixed_ep()
when no IO endpoints were found. Coverity CID
1453263,
1453156
Check return value of usbd_interface2endpoint_descriptor() in
alloc_all_endpoints_yamaha() as it may return NULL which ends up being
dereferenced by the UE_GET_XFERTYPE() macro. Coverity CID 271356
ok ratchov@
tb [Mon, 16 Mar 2020 15:25:13 +0000 (15:25 +0000)]
Consistently spell 'unsigned' as 'unsigned int', as style(9) seems
to prefer that. No binary change except in d1_srtp.c where the
generated assembly differs only in line numbers (due to a wrapped
long line) and in s3_cbc.c where there is no change in the generated
assembly.
ok inoguchi jsing
tb [Mon, 16 Mar 2020 15:13:15 +0000 (15:13 +0000)]
Adapt to tls13_record_layer.c r1.30 (the sequence number shouldn't wrap).
tb [Mon, 16 Mar 2020 15:11:35 +0000 (15:11 +0000)]
The RFC is clear (section 5.3) that sequence number should never wrap.
We currently throw an error on overflow, but still wrap. Check up front
if we would need to wrap and only increment if that case is excluded.
This simplifies the increment loop and makes the returns in this function
less magic.
ok jsing
claudio [Mon, 16 Mar 2020 14:47:30 +0000 (14:47 +0000)]
The assumption that in roa tables a prefix / source-as combo only appears
once in the input file is not correct. I thought the RPKI validators would
aggreagte these entries but that is not necessarily the case.
There are cases where prefixes show up with the same source-as multiple times
with different maxlen lenght. In those cases merge these multiple entries
and keep the one entry with the longest maxlen length since that is the VRP
which covers all others.
Found by job@ OK benno@
nicm [Mon, 16 Mar 2020 14:17:56 +0000 (14:17 +0000)]
Adjust selection correctly when scrolling, from Anindya Mukherjee.
mpi [Mon, 16 Mar 2020 13:17:17 +0000 (13:17 +0000)]
Remove unused function argument.
CID
1453335.
mpi [Mon, 16 Mar 2020 12:00:19 +0000 (12:00 +0000)]
Enable tests now that the original parent see the exit status after the
debugger.
mpi [Mon, 16 Mar 2020 11:58:46 +0000 (11:58 +0000)]
Keep track of traced child under a list of orphans while they are being
reparented to a debugger process.
Also re-parent exiting traced processes to their original parent, if it
is still alive, after the debugger has seen the exit status.
Logic comes from FreeBSD pointed out by guenther@.
While here rename proc_reparent() into process_reparent() and get rid of
superfluous checks.
ok visa@
nicm [Mon, 16 Mar 2020 10:49:06 +0000 (10:49 +0000)]
VTE treats each mouse mode bit as independent, so turning off 1000
doesn't also turn off 1001, so don't rely on that behaviour. GitHub
issue 2116.
nicm [Mon, 16 Mar 2020 09:18:47 +0000 (09:18 +0000)]
Turn off mouse mode 1003 as well as the rest when exiting.
tobhe [Mon, 16 Mar 2020 09:13:01 +0000 (09:13 +0000)]
Handle allocation failure in reallocarry. Print errors with log_info.
Reported by Hiltjo Posthuma <hiltjo (at) codemadness (dot) org>
ok patrick@
nicm [Mon, 16 Mar 2020 09:12:44 +0000 (09:12 +0000)]
Terminate the output buffer for control mode output - it is now used as
a string. GitHub issue 2114.
tobhe [Mon, 16 Mar 2020 09:07:40 +0000 (09:07 +0000)]
Correctly calculate IPv6 address leases from small address pools.
Bug report and fix from Chuck Zmudzinski <frchuckz (at) gmail (dot) com>
ok patrick@
mpi [Mon, 16 Mar 2020 08:54:08 +0000 (08:54 +0000)]
Fix affectation that should be conditionnal tests inside asserts.
From tom@
jasper [Mon, 16 Mar 2020 08:51:48 +0000 (08:51 +0000)]
fix a bunch of weird indentations and extra whitespace; no binary change
nicm [Mon, 16 Mar 2020 08:23:24 +0000 (08:23 +0000)]
FIx type for %u, from Thomas Adam.
jasper [Mon, 16 Mar 2020 08:21:16 +0000 (08:21 +0000)]
Make the check for vmm_softc->mode exhaustive and return an error
when not running on a supported mode. This matches code elsewhere
in the file and prevents using the uninitialized vrs later in
the function.
Coverity CID 148078
as discussed with mike larkin
otto [Mon, 16 Mar 2020 07:02:10 +0000 (07:02 +0000)]
Teach macppc ofwboot(8) about ffs2. Test and ok gkoehler@
nicm [Mon, 16 Mar 2020 06:12:42 +0000 (06:12 +0000)]
Send mouse down event immediately rather than waiting for double click
to finish which would now mean it was out of order. Reported by Mark
Kelly.
cheloha [Mon, 16 Mar 2020 04:15:19 +0000 (04:15 +0000)]
spkr(4): fix compilation under SPKRDEBUG
uio.uio_resid is a size_t, not an int. Change the format string
accordingly.
dtucker [Mon, 16 Mar 2020 02:17:02 +0000 (02:17 +0000)]
Cast lifetime to u_long for comparison to prevent unsigned comparison
warning on 32bit arches. Spotted by deraadt, ok djm.
krw [Sun, 15 Mar 2020 20:50:46 +0000 (20:50 +0000)]
sparc64 issue being identified and removed, reapply r1.73:
"Bump nvme(4) max physio() i/o size to 128K"
nicm [Sun, 15 Mar 2020 20:44:19 +0000 (20:44 +0000)]
Reset selection flag when clearing or stopping selection, from Mark
Kelly.
nicm [Sun, 15 Mar 2020 20:35:52 +0000 (20:35 +0000)]
Fix C-Space key string.
kmos [Sun, 15 Mar 2020 18:55:20 +0000 (18:55 +0000)]
Revert nvme back to last working commit for sparc64.
The coverity-related diff breaks sparc64's ability to read the disk.
ok deraadt
otto [Sun, 15 Mar 2020 17:44:20 +0000 (17:44 +0000)]
Teach sparc64 boot(8) about ffs2 and fix a bug while there: devopen()
can be called multiple times so nfsys needs to be initialized to 0 each time.
Note that the sparc64 bootblocks have no clue yet about ffs2 so this is not
the complete solution. ok kettenis@
millert [Sun, 15 Mar 2020 16:34:57 +0000 (16:34 +0000)]
Add missing casts to unsigned char when using ctype(3).
From Hiltjo Posthuma
claudio [Sun, 15 Mar 2020 10:14:49 +0000 (10:14 +0000)]
kthread_park() and kthread_stop() don't need PCATCH the linux API does
not interrupt either and not checking the return value of tsleep_nsec()
could actually result in a infinite loop if a signal is pending.
Remove PCATCH also from kthread_parkme() for the same reason but this
function is only called for kthreads and those have no signals anyway.
OK kettenis@
visa [Sun, 15 Mar 2020 05:58:48 +0000 (05:58 +0000)]
Fix memory corruption with kern.witness.locktrace.
The allocating of lock stacks does not handle correctly the case where
the system-wide free list becomes empty. Consequently, the returned
stack buffer can still be on the CPU's free list.
This patch fixes the bug by simplifying the code. Lock stack buffers are
now allocated and freed one by one from the system-wide free list
instead of using batching.
The fix additionally addresses a buffer hoarding problem that can arise
under workloads where some CPUs are net acquirers and some other CPUs
net releasers of rwlocks.
Panic reported by Hrvoje Popovski
visa [Sun, 15 Mar 2020 05:34:13 +0000 (05:34 +0000)]
Guard SIOCDELMULTI if_ioctl calls with KERNEL_LOCK() where the call is
made from socket close path. Most device drivers are not MP-safe yet,
and the closing of AF_INET and AF_INET6 sockets is no longer under the
kernel lock.
This fixes a panic seen by jcs@.
OK mpi@
krw [Sat, 14 Mar 2020 18:53:13 +0000 (18:53 +0000)]
ahci_get_pmp_ccb() returns a non-NULL pointer, fails a
KASSERT(), or has already blown up by dereferencing the
pointer.
Two of the four invocations of ahci_get_pmp_ccb() check for
NULL. Save a couple of bytes by not bothering. Add comments
to the invocations to docuement the assumption.
krw [Sat, 14 Mar 2020 16:46:51 +0000 (16:46 +0000)]
Trailing whitespace, long lines, incorrect function names in
printf()'s.
jsg [Sat, 14 Mar 2020 02:53:16 +0000 (02:53 +0000)]
drm/i915: Don't try to use the hardware frame counter with i965gm TV output
From Ville Syrjala
32db0b6501d97b09e92e70caefc74fa35aa9a8d6 in mainline linux
Jon Whalen reported on misc@ that a 965gm with svideo on a
Dell Inspiron 1525 had excesively long timeouts. On the order of 30
seconds when booting and 60 seconds when starting xenocara with errors
showing up in dmesg.
While the other commit referenced in
https://bugs.freedesktop.org/show_bug.cgi?id=93782 appeared in the
4.19 lts branch this one while being marked for stable in the linux
commit never did.
jsg [Sat, 14 Mar 2020 01:30:34 +0000 (01:30 +0000)]
On fdt platforms attempt to load system specific .txt and .bin files
with filenames constructed from the first compatible string of the root
node. Matches the format used in the linux-firmware repository.
If these are not found fallback to the generic filenames.
When the compatible string contains a '/' as in 'solidrun,cubox-i/q' it
will be handled as everything before the '/' so the cubox filename is
brcmfmac4330-sdio.solidrun,cubox-i.txt.
ok kurt@ patrick@
tb [Fri, 13 Mar 2020 17:47:38 +0000 (17:47 +0000)]
Increment a few more sequence numbers where the carry is close to
crossing a byte boundary.
jsing [Fri, 13 Mar 2020 16:40:42 +0000 (16:40 +0000)]
Remove dtls1_enc().
Like much of the original DTLS code, dtls1_enc() is effectively a renamed
copy of tls1_enc(). Since then tls1_enc() has been modified, however the
non-AEAD code remains largely the same. As such, remove dtls1_enc() and
instead call tls1_enc() from the DTLS code.
The tls1_enc() AEAD code does not currently work correctly with DTLS,
however this is a non-issue since we do not support AEAD cipher suites with
DTLS currently.
ok tb@
claudio [Fri, 13 Mar 2020 16:35:09 +0000 (16:35 +0000)]
Initialize sls_sig to 0 and not 1. sls_sig stores the signal number of a
possible signal that was caught during sleep setup. It does not make sense
to have a default of 1 (SIGHUP) for this.
OK visa@ mpi@
schwarze [Fri, 13 Mar 2020 16:14:14 +0000 (16:14 +0000)]
Properly reset the validation part of the tagging module between files.
This fixes a crash in makewhatis(8) encountered by naddy@.
I'm very sorry for the disruption of the build.
jsing [Fri, 13 Mar 2020 16:04:31 +0000 (16:04 +0000)]
Add regress for TLSv1.3 sequence number handling.
jsing [Fri, 13 Mar 2020 16:03:27 +0000 (16:03 +0000)]
Correct TLSv1.3 sequence number increment and wrapping check.
Fix proposed by tb@
jsing [Fri, 13 Mar 2020 16:01:12 +0000 (16:01 +0000)]
Add missing $OpenBSD$ tag.
jsing [Fri, 13 Mar 2020 15:55:00 +0000 (15:55 +0000)]
Add regress for CBB_add_space().
jsing [Fri, 13 Mar 2020 15:54:34 +0000 (15:54 +0000)]
Ensure that CBB_add_space() always provides zeroed memory.
ok tb@
patrick [Fri, 13 Mar 2020 15:30:58 +0000 (15:30 +0000)]
Recognize BCM43341 as a BCM43340 variant.
From Rob Schmersel
krw [Fri, 13 Mar 2020 14:55:46 +0000 (14:55 +0000)]
Bump nvme(4) max physio() i/o size to 128K.
patrick [Fri, 13 Mar 2020 13:14:40 +0000 (13:14 +0000)]
Run getty on all /dev/ttyC* apart from ttyC0, since it might conflict
with /dev/console.
Feedback from and ok kettenis@
anton [Fri, 13 Mar 2020 10:07:01 +0000 (10:07 +0000)]
In order to unlock flock(2), make writes to the f_iflags field of struct
file atomic. This also gets rid of the last kernel lock protected field
in the scope of struct file.
ok mpi@ visa@
deraadt [Fri, 13 Mar 2020 09:31:24 +0000 (09:31 +0000)]
Anthony Steinhauser reports that 32-bit arm cpus have the same speculation
problems as 64-bit models. To resolve the syscall speculation, as a first
step "nop; nop" was added after all occurances of the syscall ("swi 0")
instruction. Then the kernel was changed to jump over the 2 extra instructions.
In this final step, those pair of nops are converted into the speculation-blocking
sequence ("dsb nsh; isb").
Don't try to build through these multiple steps, use a snapshot instead.
Packages matching the new ABI will be out in a while...
ok kettenis
mpi [Fri, 13 Mar 2020 09:30:22 +0000 (09:30 +0000)]
Simplify logic, the "netboot" interface is always related to `bootdv'.
Logic is hard, so keep only one of two logically equivalent statements.
CID 271085
ok kettenis@, deraadt@, miod@
mpi [Fri, 13 Mar 2020 09:25:21 +0000 (09:25 +0000)]
Rename "sigacts" flag field to avoid conflict with the "process" one.
This shows that atomic_* operations should not be necessery to write
to this field unlike with the process one.
The advantage of using a somewhat-unique prefix for struct member is
moot when multiple definitions use the same prefix :o)
From Amit Kulkarni, ok claudio@
jca [Fri, 13 Mar 2020 09:08:58 +0000 (09:08 +0000)]
Block autoaction after it kicks in, until 60 seconds after resume
This prevents your laptop from immediately going back to sleep after
resume, leaving you some time to look up stuff or even stop apmd in
case you need the machine RIGHT NOW.
Blocking autoaction until the laptop resumes prevents spurious
suspend/resume cycles.
Advices from cheloha@
deraadt [Fri, 13 Mar 2020 08:46:50 +0000 (08:46 +0000)]
Anthony Steinhauser reports that 32-bit arm cpus have the same speculation
problems as 64-bit models. All syscall instructions ("swi 0") now have a
nop;nop after them. We make the kernel skip over these when returning, so
that we can (soon) change the nops into a speculation barrier.
ok kettenis
deraadt [Fri, 13 Mar 2020 06:38:55 +0000 (06:38 +0000)]
Anthony Steinhauser reports that 32-bit arm cpus have the same speculation
problems as 64-bit models. For the syscall instruction issue, add nop;nop
after swi 0, in preparation for jumping over a speculation barrier here later.
(a lonely swi 0 was hiding in __asm in this file)
nicm [Fri, 13 Mar 2020 06:19:33 +0000 (06:19 +0000)]
Do not add a reference to the session if no session is present.
deraadt [Fri, 13 Mar 2020 05:20:07 +0000 (05:20 +0000)]
improve comment about the speculation barrier
djm [Fri, 13 Mar 2020 04:16:27 +0000 (04:16 +0000)]
improve error messages for some common PKCS#11 C_Login failure cases;
based on patch from Jacob Hoffman-Andrews in bz3130; ok dtucker
djm [Fri, 13 Mar 2020 04:01:56 +0000 (04:01 +0000)]
use sshpkt_fatal() for kex_exchange_identification() errors.
This ensures that the logged errors are consistent with other transport-
layer errors and that the relevant IP addresses are logged. bz3129
ok dtucker@
djm [Fri, 13 Mar 2020 03:25:45 +0000 (03:25 +0000)]
typo in comment
spotted at https://fossies.org/linux/misc/openssh-8.2p1.tar.gz/codespell.html
dtucker [Fri, 13 Mar 2020 03:24:49 +0000 (03:24 +0000)]
Don't clear alarm timers in listening sshd. Previously these timers were
used for regenerating the SSH1 ephemeral host keys but those are now gone
so there's no need to clear the timers either. ok deraadt@
djm [Fri, 13 Mar 2020 03:18:45 +0000 (03:18 +0000)]
some more speeling mistakes from
https://fossies.org/linux/misc/openssh-8.2p1.tar.gz/codespell.html
djm [Fri, 13 Mar 2020 03:17:07 +0000 (03:17 +0000)]
spelling errors in comments; no code change
from https://fossies.org/linux/misc/openssh-8.2p1.tar.gz/codespell.html
djm [Fri, 13 Mar 2020 03:12:17 +0000 (03:12 +0000)]
when downloading FIDO2 resident keys from a token, don't prompt for a PIN
until the token has told us that it needs one. Avoids double-prompting on
devices that implement on-device authentication (e.g. a touchscreen PIN
pad on the Trezor Model T). ok dtucker@
schwarze [Fri, 13 Mar 2020 00:58:48 +0000 (00:58 +0000)]
typos resulted in two tests not being run
schwarze [Fri, 13 Mar 2020 00:31:04 +0000 (00:31 +0000)]
Split tagging into a validation part including prioritization
in tag.{h,c} and {mdoc,man}_validate.c
and into a formatting part including command line argument checking
in term_tag.{h,c}, html.c, and {mdoc|man}_{term|html}.c.
Immediate functional benefits include:
* Improved prioritization of automatic tags for .Em and .Sy.
* Avoiding bogus automatic tags when .Em, .Fn, or .Sy are explicitly tagged.
* Explicit tagging of .Er and .Fl now works in HTML output.
* Automatic tagging of .IP and .TP now works in HTML output.
But mainly, this patch provides clean earth to build further improvements on.
Technical changes:
* Main program: Write a tag file for ASCII and UTF-8 output only.
* All formatters: There is no more need to delay writing the tags.
* mdoc(7)+man(7) formatters: No more need for elaborate syntax tree inspection.
* HTML formatter: If available, use the "string" attribute as the tag.
* HTML formatter: New function to write permalinks, to reduce code duplication.
Style cleanup in the vicinity while here:
* mdoc(7) terminal formatter: To set up bold font for children,
defer to termp_bold_pre() rather than calling term_fontpush() manually.
* mdoc(7) terminal formatter: Garbage collect some duplicate functions.
* mdoc(7) HTML formatter: Unify <code> handling, delete redundant functions.
* Where possible, use switch statements rather than if cascades.
* Get rid of some more Yoda notation.
The necessity for such changes was first discussed with kn@, but i didn't
bother him with a request to review the resulting -673/+782 line patch.
kettenis [Fri, 13 Mar 2020 00:14:38 +0000 (00:14 +0000)]
Add speciulation barrier after the last remaining naked ERET instruction.
While the barrier isn't really needed here, it doesn't hurt and having
it there establishes a pattern for people to follow.
idiomatic deraadt@
tobhe [Thu, 12 Mar 2020 22:14:20 +0000 (22:14 +0000)]
Use strlcpy to make sure 'vm_name' and 'vir_name' are NUL terminated.
CID
1453255
ok deraadt@
krw [Thu, 12 Mar 2020 19:21:01 +0000 (19:21 +0000)]
Pass scsi_mode_sense_buf pointers to scsi_mode_sense[_buf]() rather
than scsi_mode_header[_big] pointers to the same data.
Continues the umtamgling and simplification of the mode sense code.
CID
1491299
CID
1491297
otto [Thu, 12 Mar 2020 19:19:37 +0000 (19:19 +0000)]
Allow hppa boot(8) to read from an ffs2 filesystem; ok kettenis@
visa [Thu, 12 Mar 2020 17:38:02 +0000 (17:38 +0000)]
Revert previous. Something in it causes unexpected slowdown.
jsing [Thu, 12 Mar 2020 17:17:12 +0000 (17:17 +0000)]
Use calloc() rather than malloc() when allocating initial CBB buffer.
CBB uses recallocarray() to expand buffers, however was still using
malloc() for the initial buffer, which could result in memory being leaked
in incorrect use cases.
While here also use calloc() to allocate internal structs.
ok inoguchi@ tb@
jsing [Thu, 12 Mar 2020 17:15:33 +0000 (17:15 +0000)]
Use calloc() rather than malloc() when allocating buffers.
This reduces the chance of accidently leaking stack memory.
ok inoguchi@ tb@
jsing [Thu, 12 Mar 2020 17:09:02 +0000 (17:09 +0000)]
Stop overloading the record type for padding length.
Currently the CBC related code stuffs the padding length in the upper bits
of the type field... stop doing that and add a padding_length field to the
record struct instead.
ok inoguchi@ tb@
jsing [Thu, 12 Mar 2020 17:01:53 +0000 (17:01 +0000)]
Use internal versions of SSL3_BUFFER, SSL3_RECORD and DTLS1_RECORD_DATA.
SSL3_BUFFER, SSL3_RECORD and DTLS1_RECORD_DATA are currently still in
public headers, even though their usage is internal. This moves to
using _INTERNAL suffixed versions that are in internal headers, which
then allows us to change them without any potential public API fallout.
ok inoguchi@ tb@
patrick [Thu, 12 Mar 2020 16:39:07 +0000 (16:39 +0000)]
sync
patrick [Thu, 12 Mar 2020 16:38:58 +0000 (16:38 +0000)]
Add /dev/drm[0-3].
ok deraadt@
krw [Thu, 12 Mar 2020 16:15:03 +0000 (16:15 +0000)]
Check for short mode sense error inside scsi_mode_sense_big()
rather than after the only invocation.
No functional change.