linux-sg2042/Documentation
Ahmed S. Darwish 80793c3471 seqlock: Introduce seqcount_latch_t
Latch sequence counters are a multiversion concurrency control mechanism
where the seqcount_t counter even/odd value is used to switch between
two copies of protected data. This allows the seqcount_t read path to
safely interrupt its write side critical section (e.g. from NMIs).

Initially, latch sequence counters were implemented as a single write
function above plain seqcount_t: raw_write_seqcount_latch(). The read
side was expected to use plain seqcount_t raw_read_seqcount().

A specialized latch read function, raw_read_seqcount_latch(), was later
added. It became the standardized way for latch read paths.  Due to the
dependent load, it has one read memory barrier less than the plain
seqcount_t raw_read_seqcount() API.

Only raw_write_seqcount_latch() and raw_read_seqcount_latch() should be
used with latch sequence counters. Having *unique* read and write path
APIs means that latch sequence counters are actually a data type of
their own -- just inappropriately overloading plain seqcount_t.

Introduce seqcount_latch_t. This adds type-safety and ensures that only
the correct latch-safe APIs are to be used.

Not to break bisection, let the latch APIs also accept plain seqcount_t
or seqcount_raw_spinlock_t. After converting all call sites to
seqcount_latch_t, only that new data type will be allowed.

References: 9b0fd802e8 ("seqcount: Add raw_write_seqcount_latch()")
References: 7fc26327b7 ("seqlock: Introduce raw_read_seqcount_latch()")
References: aadd6e5caa ("time/sched_clock: Use raw_read_seqcount_latch()")
Signed-off-by: Ahmed S. Darwish <a.darwish@linutronix.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20200827114044.11173-4-a.darwish@linutronix.de
2020-09-10 11:19:28 +02:00
..
ABI powerpc/perf/hv-24x7: Move cpumask file to top folder of hv-24x7 driver 2020-08-21 23:35:27 +10:00
PCI pci-v5.9-changes 2020-08-07 18:48:15 -07:00
RCU These are the latest RCU bits for v5.9: 2020-08-03 14:31:33 -07:00
accounting
admin-guide A set of EFI fixes: 2020-08-23 11:08:32 -07:00
arm ARM development for 5.9-rc1: 2020-08-06 10:17:00 -07:00
arm64 IOMMU Updates for Linux v5.9 2020-08-11 14:13:24 -07:00
block for-5.9/drivers-20200803 2020-08-05 10:51:40 -07:00
bpf doc: Add link to bpf helpers man page 2020-08-13 22:48:06 +02:00
cdrom A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
core-api A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
cpu-freq
crypto It's been a busy cycle for documentation - hopefully the busiest for a 2020-08-04 22:47:54 -07:00
dev-tools A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
devicetree Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-08-23 10:52:33 -07:00
doc-guide A handful of late-arriving docs fixes, along with a patch changing a lot of 2020-06-10 14:12:15 -07:00
driver-api - Core Frameworks 2020-08-15 08:09:38 -07:00
fault-injection block: rename generic_make_request to submit_bio_noacct 2020-07-01 07:27:24 -06:00
fb drm next for 5.9-rc1 2020-08-05 19:50:06 -07:00
features A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
filesystems Improvements to ext4's block allocator performance for very large file 2020-08-21 11:03:38 -07:00
firmware-guide ACPI: Replace HTTP links with HTTPS ones 2020-07-27 14:47:08 +02:00
firmware_class
fpga Char/Misc driver patches for 5.9-rc1 2020-08-05 11:43:47 -07:00
gpu - Core Frameworks 2020-08-11 13:48:02 -07:00
hid docs: hid: Convert link to https 2020-07-13 11:26:37 -06:00
hwmon hwmon updates for v5.9 2020-08-05 13:13:57 -07:00
i2c Merge branch 'i2c/for-5.9' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux 2020-08-13 18:41:00 -07:00
ia64 docs: ia64: correct typo 2020-07-31 11:09:09 -06:00
ide
iio
infiniband
input Input: uinput - fix typo in function name documentation 2020-07-28 18:24:11 -07:00
isdn
kbuild Kbuild updates for v5.9 2020-08-09 14:10:26 -07:00
kernel-hacking
leds LEDs changes for 5.9-rc1. 2020-08-05 19:24:27 -07:00
litmus-tests Documentation/litmus-tests: Add note on herd7 7.56 in atomic litmus test 2020-06-29 12:05:18 -07:00
livepatch
locking seqlock: Introduce seqcount_latch_t 2020-09-10 11:19:28 +02:00
m68k
maintainer Documentation: maintainer-entry-profile: eliminate duplicated word 2020-07-13 09:44:07 -06:00
mhi
mips It's been a busy cycle for documentation - hopefully the busiest for a 2020-08-04 22:47:54 -07:00
misc-devices Documentation: misc/xilinx_sdfec: eliminate duplicated word 2020-07-13 09:44:07 -06:00
netlabel
networking docs: networking: bonding.rst resources section cleanup 2020-08-14 16:44:20 -07:00
nios2
nvdimm
openrisc docs: openrisc: Replace HTTP links with HTTPS ones 2020-07-13 11:34:09 -06:00
parisc
pcmcia
power Merge branches 'pm-sleep', 'pm-domains', 'powercap' and 'pm-tools' 2020-08-03 13:12:44 +02:00
powerpc PPC KVM update for 5.9 2020-08-09 13:24:02 -04:00
process A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
riscv
s390 It's been a busy cycle for documentation - hopefully the busiest for a 2020-08-04 22:47:54 -07:00
scheduler sched/doc: Factorize bits between sched-energy.rst & sched-capacity.rst 2020-08-01 09:19:43 +02:00
scsi scsi: advansys: docs: Eliminate duplicated word 2020-07-08 01:32:11 -04:00
security Documentation: security/keys: eliminate duplicated word 2020-07-13 09:45:03 -06:00
sh docs: sh: convert register-banks.txt to ReST 2020-06-19 14:10:13 -06:00
sound ASoC: Updates for v5.9 2020-08-03 14:41:43 +02:00
sparc
sphinx Replace HTTP links with HTTPS ones: Documentation/sphinx/parse-headers.pl 2020-06-26 10:57:33 -06:00
sphinx-static
spi SPI SUBSYSTEM: Replace HTTP links with HTTPS ones 2020-07-09 22:41:11 +01:00
staging remoteproc updates for v5.9 2020-08-11 11:17:45 -07:00
target doc: don't use deprecated "---help---" markers in target docs 2020-06-13 13:32:40 -07:00
timers docs: timers: drop documentation about LB_BIAS 2020-07-23 14:32:44 -06:00
trace A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
translations A handful of obvious fixes that wandered in during the merge window. 2020-08-13 13:57:45 -07:00
usb USB: Replace HTTP links with HTTPS ones 2020-07-21 13:41:57 +02:00
userspace-api remoteproc updates for v5.9 2020-08-11 11:17:45 -07:00
virt powerpc updates for 5.9 2020-08-07 10:33:50 -07:00
vm mm/vmstat: add events for THP migration without split 2020-08-12 10:57:57 -07:00
w1
watchdog watchdog: add support for adjusting last known HW keepalive time 2020-08-05 18:43:02 +02:00
x86 It's been a busy cycle for documentation - hopefully the busiest for a 2020-08-04 22:47:54 -07:00
xtensa
.gitignore
COPYING-logo Replace HTTP links with HTTPS ones: documentation 2020-06-08 09:30:19 -06:00
Changes
CodingStyle
Kconfig
Makefile media updates for v5.8-rc1 2020-06-03 20:59:38 -07:00
SubmittingPatches
asm-annotations.rst
atomic_bitops.txt
atomic_t.txt Documentation/litmus-tests/atomic: Add a test for smp_mb__after_atomic() 2020-06-29 12:05:18 -07:00
conf.py Replace HTTP links with HTTPS ones: documentation 2020-06-08 09:30:19 -06:00
docutils.conf
dontdiff Documentation: dontdiff: Add zstd compressed files 2020-07-31 11:51:10 +02:00
index.rst docs: index.rst: Add watch_queue 2020-07-23 14:13:23 -06:00
logo.gif
memory-barriers.txt powerpc updates for 5.9 2020-08-07 10:33:50 -07:00
watch_queue.rst