<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/fs/devfs/devfs_devs.c, branch release/13.2.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=release%2F13.2.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=release%2F13.2.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2020-12-29T13:47:36Z</updated>
<entry>
<title>devfs(4): defer freeing until we drop devmtx ("cdev")</title>
<updated>2020-12-29T13:47:36Z</updated>
<author>
<name>Edward Tomasz Napierala</name>
<email>trasz@FreeBSD.org</email>
</author>
<published>2020-12-29T13:45:53Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=4ddb3cc5973b94b0502e1683accac87998235857'/>
<id>urn:sha1:4ddb3cc5973b94b0502e1683accac87998235857</id>
<content type='text'>
Before r332974 the old code would sometimes cause a rare lock order
reversal against pagequeue, which looked roughly like this:

witness_checkorder()
__mtx_lock-flags()
vm_page_alloc()
uma_small_alloc()
keg_alloc_slab()
keg_fetch-slab()
zone_fetch-slab()
zone_import()
zone_alloc_bucket()
uma_zalloc_arg()
bucket_alloc()
uma_zfree_arg()
free()
devfs_metoo()
devfs_populate_loop()
devfs_populate()
devfs_rioctl()
VOP_IOCTL_APV()
VOP_IOCTL()
vn_ioctl()
fo_ioctl()
kern_ioctl()
sys_ioctl()

Since r332974 the original problem no longer exists, but it still
makes sense to move things out of the - often congested - lock.

Reviewed By:	kib, markj
Sponsored by:	NetApp, Inc.
Sponsored by:	Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D27334
</content>
</entry>
<entry>
<title>fs: clean up empty lines in .c and .h files</title>
<updated>2020-09-01T21:18:40Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2020-09-01T21:18:40Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=586ee69f09c5060621486b34722a4a806581f93d'/>
<id>urn:sha1:586ee69f09c5060621486b34722a4a806581f93d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>devfs: Abstract locking assertions</title>
<updated>2020-08-12T00:32:31Z</updated>
<author>
<name>Conrad Meyer</name>
<email>cem@FreeBSD.org</email>
</author>
<published>2020-08-12T00:32:31Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=0ac9e27ba964b4d29ed180d5e546873de638822c'/>
<id>urn:sha1:0ac9e27ba964b4d29ed180d5e546873de638822c</id>
<content type='text'>
The conversion was largely mechanical: sed(1) with:

  -e 's|mtx_assert(&amp;devmtx, MA_OWNED)|dev_lock_assert_locked()|g'
  -e 's|mtx_assert(&amp;devmtx, MA_NOTOWNED)|dev_lock_assert_unlocked()|g'

The definitions of these abstractions in fs/devfs/devfs_int.h are the
only non-mechanical change.

No functional change.
</content>
</entry>
<entry>
<title>devfs: bool -&gt; int</title>
<updated>2020-08-10T11:46:39Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2020-08-10T11:46:39Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=ca423b858bf4800bb22963e8133b72499bb18d24'/>
<id>urn:sha1:ca423b858bf4800bb22963e8133b72499bb18d24</id>
<content type='text'>
Fixes buildworld after r364069
</content>
</entry>
<entry>
<title>devfs: save on spurious relocking for devfs_populate</title>
<updated>2020-08-10T10:36:43Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2020-08-10T10:36:43Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7b19bddac8f6ae5a356ffbca80f087d3654b8363'/>
<id>urn:sha1:7b19bddac8f6ae5a356ffbca80f087d3654b8363</id>
<content type='text'>
Tested by:	pho
</content>
</entry>
<entry>
<title>Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many)</title>
<updated>2020-02-26T14:26:36Z</updated>
<author>
<name>Pawel Biernacki</name>
<email>kaktus@FreeBSD.org</email>
</author>
<published>2020-02-26T14:26:36Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7029da5c36f2d3cf6bb6c81bf551229f416399e8'/>
<id>urn:sha1:7029da5c36f2d3cf6bb6c81bf551229f416399e8</id>
<content type='text'>
r357614 added CTLFLAG_NEEDGIANT to make it easier to find nodes that are
still not MPSAFE (or already are but aren’t properly marked).
Use it in preparation for a general review of all nodes.

This is non-functional change that adds annotations to SYSCTL_NODE and
SYSCTL_PROC nodes using one of the soon-to-be-required flags.

Mark all obvious cases as MPSAFE.  All entries that haven't been marked
as MPSAFE before are by default marked as NEEDGIANT

Approved by:	kib (mentor, blanket)
Commented by:	kib, gallatin, melifaro
Differential Revision:	https://reviews.freebsd.org/D23718
</content>
</entry>
<entry>
<title>vfs: drop the mostly unused flags argument from VOP_UNLOCK</title>
<updated>2020-01-03T22:29:58Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2020-01-03T22:29:58Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=b249ce48ea5560afdcff57e72a9880b7d3132434'/>
<id>urn:sha1:b249ce48ea5560afdcff57e72a9880b7d3132434</id>
<content type='text'>
Filesystems which want to use it in limited capacity can employ the
VOP_UNLOCK_FLAGS macro.

Reviewed by:	kib (previous version)
Differential Revision:	https://reviews.freebsd.org/D21427
</content>
</entry>
<entry>
<title>devfs: introduce a per-dev lock to protect -&gt;si_devsw</title>
<updated>2019-11-30T16:46:19Z</updated>
<author>
<name>Mateusz Guzik</name>
<email>mjg@FreeBSD.org</email>
</author>
<published>2019-11-30T16:46:19Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a02cab334c6148f1e1a495aa193e722622411a40'/>
<id>urn:sha1:a02cab334c6148f1e1a495aa193e722622411a40</id>
<content type='text'>
This allows bumping threadcount without taking the global devmtx lock.

In particular this eliminates contention on said lock while using bhyve
with multiple vms.

Reviewed by:	kib
Tested by:	markj
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D22548
</content>
</entry>
<entry>
<title>Ensure that directory entry padding bytes are zeroed.</title>
<updated>2018-11-23T22:24:59Z</updated>
<author>
<name>Mark Johnston</name>
<email>markj@FreeBSD.org</email>
</author>
<published>2018-11-23T22:24:59Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=6d2e2df764199f0a15fd743e79599391959cc17d'/>
<id>urn:sha1:6d2e2df764199f0a15fd743e79599391959cc17d</id>
<content type='text'>
Directory entries must be padded to maintain alignment; in many
filesystems the padding was not initialized, resulting in stack
memory being copied out to userspace.  With the ino64 work there
are also some explicit pad fields in struct dirent.  Add a subroutine
to clear these bytes and use it in the in-tree filesystems.  The
NFS client is omitted for now as it was fixed separately in r340787.

Reported by:	Thomas Barabosch, Fraunhofer FKIE
Reviewed by:	kib
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
</content>
</entry>
<entry>
<title>Move most of the contents of opt_compat.h to opt_global.h.</title>
<updated>2018-04-06T17:35:35Z</updated>
<author>
<name>Brooks Davis</name>
<email>brooks@FreeBSD.org</email>
</author>
<published>2018-04-06T17:35:35Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=6469bdcdb6a5968dc7edfcfb495d427b4bfdb3dd'/>
<id>urn:sha1:6469bdcdb6a5968dc7edfcfb495d427b4bfdb3dd</id>
<content type='text'>
opt_compat.h is mentioned in nearly 180 files. In-progress network
driver compabibility improvements may add over 100 more so this is
closer to "just about everywhere" than "only some files" per the
guidance in sys/conf/options.

Keep COMPAT_LINUX32 in opt_compat.h as it is confined to a subset of
sys/compat/linux/*.c.  A fake _COMPAT_LINUX option ensure opt_compat.h
is created on all architectures.

Move COMPAT_LINUXKPI to opt_dontuse.h as it is only used to control the
set of compiled files.

Reviewed by:	kib, cem, jhb, jtl
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D14941
</content>
</entry>
</feed>
