freebsd-src/sys
Mark Johnston 919e7b5359 Prevent some kobj memory allocation failures from panicking the system.
Parts of the kobj(9) KPI assume a non-sleepable context for the purpose
of internal memory allocations, but currently have no way to signal an
allocation failure to the caller, so they just panic in this case.  This
can occur even when kobj_create() is called with M_WAITOK.  Fix some
instances of the problem by plumbing wait flags from kobj_create() through
internal subroutines.  Change kobj_class_compile() to assume a sleepable
context when called externally, since all existing callers use it in a
sleepable context.

To fix the problem fully the kobj_init() KPI must be changed.

Reported and tested by:	pho
Reviewed by:	kib (previous version)
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D19023
2019-01-31 22:27:39 +00:00
..
amd64 Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
arm awg: fix soft reset failure with no link 2019-01-21 14:35:36 +00:00
arm64 Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
bsm Create new EINTEGRITY error with message "Integrity check failed". 2019-01-17 06:35:45 +00:00
cam Remove stale now comment, forgotten in r343582. 2019-01-30 18:56:45 +00:00
cddl Remove BIO_ORDERED flag from BIO_FLUSH sent by ZFS. 2019-01-30 17:39:44 +00:00
compat Fix compilation with 'option NDISAPI + device ndis' and 2019-01-30 11:40:12 +00:00
conf Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
contrib Document the instance context pointer. 2019-01-31 04:16:52 +00:00
crypto Generalize AES iov optimization 2018-12-13 04:40:53 +00:00
ddb
dev ix(4),ixv(4): Fix TSO offloads when TXCSUM is disabled 2019-01-31 21:53:03 +00:00
dts [rpi] Reorganize spigen(4) overlays for Raspberry Pi 2019-01-16 01:08:34 +00:00
fs ext2fs: Add some extra consistency checks for the superblock. 2019-01-25 22:22:29 +00:00
gdb
geom geom_uzip(4): set 'gp != NULL' assertion on top of the function 2019-01-26 17:17:25 +00:00
gnu Import DTS from Linux 4.20 2019-01-11 09:40:34 +00:00
i386 Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
isa
kern Prevent some kobj memory allocation failures from panicking the system. 2019-01-31 22:27:39 +00:00
kgssapi
libkern
mips Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
modules Make iflib a loadable module: add seemingly missed header. 2019-01-31 20:04:18 +00:00
net Don't set IFCAP_TXRTLMT during lagg_clone_create(). 2019-01-31 21:35:37 +00:00
net80211 Remove 2GHz channel list copies from wireless drivers. 2019-01-26 17:00:55 +00:00
netgraph Allow ng_nat to be attached to a ethernet interface directly via ng_ether(4) 2018-12-17 16:00:35 +00:00
netinet Add a simple port filter to SIFTR. 2019-01-30 17:44:30 +00:00
netinet6 Fix refcounting leaks in IPv6 MLD code leading to loss of IPv6 2019-01-24 08:34:13 +00:00
netipsec Remove unused argument to priv_check_cred. 2018-12-11 19:32:16 +00:00
netpfil Revert r316461: Remove "IPFW static rules" rmlock, and use pfil's global lock. 2019-01-31 21:04:50 +00:00
netsmb Remove unused argument to priv_check_cred. 2018-12-11 19:32:16 +00:00
nfs
nfsclient
nfsserver
nlm
ofed Mechanical cleanup of epoch(9) usage in network stack. 2019-01-09 01:11:19 +00:00
opencrypto Plug memory leak for AES_*_NIST_GMAC algorithms. 2018-12-13 08:59:51 +00:00
powerpc Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
riscv Follow arm[32] and sparc64 KAPI and provide the FreeBSD standard spelling 2019-01-29 20:10:27 +00:00
rpc Add kern.rpc.gss.client_max, to make it possible to bump it easily. 2018-12-15 11:32:11 +00:00
security Create new EINTEGRITY error with message "Integrity check failed". 2019-01-17 06:35:45 +00:00
sparc64 Make iflib a loadable module. 2019-01-31 19:05:56 +00:00
sys Reserve a bit in the FreeBSD feature control note for marking the 2019-01-31 15:44:49 +00:00
teken
tests
tools make_dtb.sh: Use $CPP instead of assuming that cpp is in $PATH 2018-12-14 23:53:28 +00:00
ufs This bug was introduced with the change to use softdep_bp_to_mp() in 2019-01-28 21:36:45 +00:00
vm In zone_alloc_bucket() max argument was calculated based on uz_count. 2019-01-31 17:52:48 +00:00
x86 xen: introduce a new way to setup event channel upcall 2019-01-30 11:34:52 +00:00
xdr
xen xen: introduce a new way to setup event channel upcall 2019-01-30 11:34:52 +00:00
Makefile