Commit Graph

274514 Commits

Author SHA1 Message Date
christos
facc5599b7 Add libcbor 2020-03-03 00:36:29 +00:00
christos
946da905e8 Add build glue 2020-03-03 00:36:18 +00:00
christos
5dd36a3bc8 Import libcbor from: https://github.com/PJK/libcbor.git 2020-03-03 00:34:28 +00:00
christos
4e9fe299d1 Add libfido2 and pam-u2f 2020-03-03 00:29:41 +00:00
christos
0dd853b540 Add build glue 2020-03-03 00:28:50 +00:00
christos
eaea677c03 Add cast 2020-03-03 00:27:31 +00:00
christos
4379517986 add casts, change to multiline. 2020-03-03 00:27:08 +00:00
christos
9f5cccf32d - fix order initialization: debug_file was not getting properly initialized
- fix free casts
- add pam module entry for OpenPAM
2020-03-03 00:22:29 +00:00
christos
bf007de0f4 back to LOG_DEBUG 2020-03-03 00:21:20 +00:00
christos
ee4f39b036 define as empty when not debugging. 2020-03-03 00:20:45 +00:00
christos
9b07d16d3c define as empty when not debugging 2020-03-03 00:20:20 +00:00
christos
46988a0ecd Import Yubico's pam-u2f from https://github.com/Yubico/pam-u2f.git 2020-03-03 00:18:44 +00:00
christos
95f430ca15 Add build glue 2020-03-03 00:14:17 +00:00
christos
ba9bdd8b2f Import Yubico's libfido2 from https://github.com/Yubico/libfido2.git 2020-03-03 00:11:43 +00:00
is
ec2f924d9d Fix word accesses on Gayle (Amiga1200) pcmcia. Patch by Martin Åberg. 2020-03-02 20:04:42 +00:00
is
07364bf8b0 The Gayle interface uses swapped (little-endian) word accesses, so we
need to use the amiga_bus_stride_1swap methods for the word accesses.

Analyzed and submitted via port-amiga@ by Martin Åberg.

Tested on formerly working hardware

- by Jukka Andberg	with Dlink DE-660+		(ne)
- by Frank Wille	with D-Link DFE-670TXD		(ne)

Tested on formerly not working hardware:

- by Martin		with 3Com 3c589 Etherling III	(ep)
- by Martin and Frank	with CompactFlash cards		(wdc)
2020-03-02 19:48:23 +00:00
nisimura
9750246e9b minor knits in mcast handling. 2020-03-02 19:16:02 +00:00
christos
141531ce86 Add fido constants, and turn hid "raw" mode for fido devices. 2020-03-02 18:15:28 +00:00
roy
00fb306ae0 ramdisk-zfsroot: Build with -D_REENTRANT
zpool(8) requires libhack built with it.
2020-03-02 16:04:49 +00:00
riastradh
ffcf681ee3 New ioctl DIOCGSECTORALIGN returns sector alignment parameters.
struct disk_sectoralign {
	/* First aligned sector number.  */
	uint32_t dsa_firstaligned;

	/* Number of sectors per aligned unit.  */
	uint32_t dsa_alignment;
};

- Teach wd(4) to get it from ATA.
- Teach cgd(4) to pass it through from the underlying disk.
- Teach dk(4) to pass it through with adjustments.
- Teach zpool (zfs) to take advantage of it.
  => XXX zpool doesn't seem to understand when the vdev's starting
     sector is misaligned.

Missing:

- ccd(4) and raidframe(4) support -- these should support _using_
  DIOCGSECTORALIGN to decide where to start putting ccd or raid
  stripes on disk, and these should perhaps _implement_
  DIOCGSECTORALIGN by reporting the stripe/interleave factor.

- sd(4) support -- I don't know any obvious way to get it from SCSI,
  but if any SCSI wizards know better than I, please feel free to
  teach sd(4) about it!

- any ld(4) attachments -- might be worth teaching the ld drivers for
  nvme and various raid controllers to get the aligned sector size

There's some duplicate logic here for now.  I'm doing it this way,
rather than gathering the logic into a new disklabel_sectoralign
function or something, so that this change is limited to adding a new
ioctl, without any new kernel symbols, in order to make it easy to
pull up to netbsd-9 without worrying about the module ABI.
2020-03-02 16:01:56 +00:00
roy
1d37b848af libhack: revert prior, will be done per consumer instead. 2020-03-02 16:01:52 +00:00
riastradh
54e08fd152 Include kern_crashme.c in non-DEBUG kernels.
This is useful for simulating crashes in production to test failover.
2020-03-02 16:00:54 +00:00
riastradh
db3a54e6ae Create /dev/ipmi0 in `MAKEDEV all'.
Works on my machine with sysutils/ipmitool if the latter is built
with CONFIGURE_ARGS+= --enable-intf-open.
2020-03-02 15:49:30 +00:00
kamil
ce57424237 Fix undefined behavior in misaligned pointer usage
Detected by UBSan and already fixed upstream.

Cherry-pick:
From aa0218d6a12814fac50b287214f9f3b0b99e11b1 Mon Sep 17 00:00:00 2001
From: Brian Behlendorf <behlendorf1@llnl.gov>
Date: Tue, 7 Jan 2014 23:24:37 +0100
Subject: [PATCH] Fix nvlist 'Bus Error' for Sparc

The mis-aligned memory accesses in nvpair_native_embedded() and
nvpair_native_embedded_array() will cause a 'Bus Error' for
architectures such as Sparc which not fully byte addressible.
To avoid this issue care is taken to avoid dereferencing the
potentially mis-aligned packed nvlist_t.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ned Bass <bass6@llnl.gov>
Signed-off-by: marku89 <mar42@kola.li>
Issue #1700
2020-03-02 15:45:33 +00:00
christos
454e43c47d Add sysloglike attr. 2020-03-02 15:30:25 +00:00
christos
30f9a377b9 Enable compression 2020-03-02 15:23:17 +00:00
thorpej
8c87d22cb1 Duh, acctually use all 64-bits when giving the rings to the chip. 2020-03-02 15:13:23 +00:00
christos
f064f71d05 fix print-like attrs 2020-03-02 14:18:50 +00:00
christos
74707f6a8a PR/55041: Fix printf format in syslog(3) error message. 2020-03-02 14:10:24 +00:00
christos
a587044e6f zfs needs rumpkern_sysproxy 2020-03-02 11:09:13 +00:00
mrg
befa44380d increase slot slop space from 100 to 1000 before giving up.
from Paul Ripke on current-users.  thanks!
2020-03-02 09:50:12 +00:00
ryo
cc77489e20 oops, fix incorrect usage of daif_enable() in my previous commit. 2020-03-02 08:39:36 +00:00
msaitoh
df8278196c KNF. No functional change. 2020-03-02 06:38:06 +00:00
isaki
37e454b408 Re-add -lrumpdev dropped in the previous commit. 2020-03-02 04:25:08 +00:00
rin
dab4c0baea Let copyinstr(9) return ENAMETOOLONG correctly if source is not
NUL-terminated; it cannot be determined by (uint8_t)data == '\0'
since data is right shifted at the end of loop.

Found by POOL_REDZONE.
2020-03-02 03:34:28 +00:00
thorpej
044836a3c5 The PCI I/O space extent map needs to reflect the BUS_{START,END}
not the SYS_{START,END}.

This fixes mapping of the viaide DMA registers on my Qube2.
2020-03-02 01:46:02 +00:00
rin
fd255ae543 Implement workaround for IBM405 Errata 77 (aka CPU_210), where
interrupted stwcx. may errantly write data to memory:

    https://elinux.org/images/1/1d/Ppc405gp-errata.pdf

This is because stwcx. is split into two pieces in the pipeline.

We need to
(1) insert dcbt before every stwcx. instruction, as well as
(2) insert sync before every rfi/rfci instruction.

It is unclear which processors are affected, but according to Linux,
all 405-based cores up until 405GPR and 405EP are affected:

    https://github.com/torvalds/linux/blob/master/arch/powerpc/platforms/40x/Kconfig#L140

For kernel, this workaround can be restricted to affected processors.
However, for kernel modules and userland, we have to enable it for all
32bit powerpc archs in order to share common binaries as before.

Proposed on port-powerpc:

    http://mail-index.netbsd.org/port-powerpc/2020/02/21/msg003583.html
2020-03-01 23:23:36 +00:00
roy
0d1a142685 libhack: build with -D_REENTRANT
Some tools that use libhack expect thread locking.
An example of this is zpool(8).

Without it, it randomly crashes. As such, force _REENTRANT to avoid
debugging future random crashes from any other applications which
rely on this.
2020-03-01 22:47:26 +00:00
kamil
11ca7e9ab1 Revert previous
Requested by joerg who wants to fix (ab)users.
2020-03-01 22:08:17 +00:00
ad
f53d289035 uvm_pglistalloc() / uvm_pglistfree() musn't be called from interrupt
context.  Assert it.
2020-03-01 21:43:56 +00:00
ad
da592a19d4 - Give pmap uvm_objects an empty pagerops to avoid special casing in UVM.
(This use of uvm_object causes a disproportionate amount of work.)

- Undo the pmap_destroy()/pmap_delref() split.  I misunderstood the flow of
  control, and there's no need for this.

- For pmap_remove_pv(), always look up the pv_entry in advance as those
  calls will need to be covered by lock again soon.
2020-03-01 21:42:58 +00:00
ad
3b6fd4ab5b Give pmap uvm_objects an empty pagerops to avoid special casing in UVM.
(This use of uvm_object causes a disproportionate amount of work.)
2020-03-01 21:40:45 +00:00
ad
85d880250e reassignbuf(), brelvp(): VI_WRMAPDIRTY is always clear if the object has no
pages, so assert that instead of trying to clear it.
2020-03-01 21:39:07 +00:00
ad
9064fbc297 child_return():
- This was assuming arg == curlwp, but NULL is passed to lwp_create(), as
  evidenced by a random panic during testing.  How did this ever work?

- Replace a goto.
2020-03-01 21:37:26 +00:00
christos
a2362fee00 Redo the sshsk_sign() stuff properly, but putting the helper in libssh.so 2020-03-01 20:59:52 +00:00
christos
3e9309baa0 fix variable name 2020-03-01 20:24:07 +00:00
christos
638ad1a643 fix build by adding a Makefile.inc that chains up. 2020-03-01 20:19:54 +00:00
christos
6627000f9f Fix sun2 2020-03-01 18:30:05 +00:00
kamil
bee75e2d31 Add new signal trap entry tests in t_ptrace_wait*
New tests:
 - syscall_signal_on_sce
 - syscall_detach_on_sce

The first one fails as a signal emitted to the child is caught by the
debugger.

The second one passes.
2020-03-01 18:22:00 +00:00
christos
0dc8cda9a3 Centralize the base rump libraries into a variable used by all the other
Makefiles so that we can make changes to it centrally as needed and have
less mess. Fixes the sun2 build that needs rumpvfs after librump after
the latest changes.
2020-03-01 18:08:12 +00:00