linux/arch/ia64/kernel
Linus Torvalds 97d052ea3f A set of locking fixes and updates:
- Untangle the header spaghetti which causes build failures in various
     situations caused by the lockdep additions to seqcount to validate that
     the write side critical sections are non-preemptible.
 
   - The seqcount associated lock debug addons which were blocked by the
     above fallout.
 
     seqcount writers contrary to seqlock writers must be externally
     serialized, which usually happens via locking - except for strict per
     CPU seqcounts. As the lock is not part of the seqcount, lockdep cannot
     validate that the lock is held.
 
     This new debug mechanism adds the concept of associated locks.
     sequence count has now lock type variants and corresponding
     initializers which take a pointer to the associated lock used for
     writer serialization. If lockdep is enabled the pointer is stored and
     write_seqcount_begin() has a lockdep assertion to validate that the
     lock is held.
 
     Aside of the type and the initializer no other code changes are
     required at the seqcount usage sites. The rest of the seqcount API is
     unchanged and determines the type at compile time with the help of
     _Generic which is possible now that the minimal GCC version has been
     moved up.
 
     Adding this lockdep coverage unearthed a handful of seqcount bugs which
     have been addressed already independent of this.
 
     While generaly useful this comes with a Trojan Horse twist: On RT
     kernels the write side critical section can become preemtible if the
     writers are serialized by an associated lock, which leads to the well
     known reader preempts writer livelock. RT prevents this by storing the
     associated lock pointer independent of lockdep in the seqcount and
     changing the reader side to block on the lock when a reader detects
     that a writer is in the write side critical section.
 
  - Conversion of seqcount usage sites to associated types and initializers.
 -----BEGIN PGP SIGNATURE-----
 
 iQJHBAABCgAxFiEEQp8+kY+LLUocC4bMphj1TA10mKEFAl8xmPYTHHRnbHhAbGlu
 dXRyb25peC5kZQAKCRCmGPVMDXSYoTuQEACyzQCjU8PgehPp9oMqWzaX2fcVyuZO
 QU2yw6gmz2oTz3ZHUNwdW8UnzGh2OWosK3kDruoD9FtSS51lER1/ISfSPCGfyqxC
 KTjOcB1Kvxwq/3LcCx7Zi3ZxWApat74qs3EhYhKtEiQ2Y9xv9rLq8VV1UWAwyxq0
 eHpjlIJ6b6rbt+ARslaB7drnccOsdK+W/roNj4kfyt+gezjBfojGRdMGQNMFcpnv
 shuTC+vYurAVIiVA/0IuizgHfwZiXOtVpjVoEWaxg6bBH6HNuYMYzdSa/YrlDkZs
 n/aBI/Xkvx+Eacu8b1Zwmbzs5EnikUK/2dMqbzXKUZK61eV4hX5c2xrnr1yGWKTs
 F/juh69Squ7X6VZyKVgJ9RIccVueqwR2EprXWgH3+RMice5kjnXH4zURp0GHALxa
 DFPfB6fawcH3Ps87kcRFvjgm6FBo0hJ1AxmsW1dY4ACFB9azFa2euW+AARDzHOy2
 VRsUdhL9CGwtPjXcZ/9Rhej6fZLGBXKr8uq5QiMuvttp4b6+j9FEfBgD4S6h8csl
 AT2c2I9LcbWqyUM9P4S7zY/YgOZw88vHRuDH7tEBdIeoiHfrbSBU7EQ9jlAKq/59
 f+Htu2Io281c005g7DEeuCYvpzSYnJnAitj5Lmp/kzk2Wn3utY1uIAVszqwf95Ul
 81ppn2KlvzUK8g==
 =7Gj+
 -----END PGP SIGNATURE-----

Merge tag 'locking-urgent-2020-08-10' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull locking updates from Thomas Gleixner:
 "A set of locking fixes and updates:

   - Untangle the header spaghetti which causes build failures in
     various situations caused by the lockdep additions to seqcount to
     validate that the write side critical sections are non-preemptible.

   - The seqcount associated lock debug addons which were blocked by the
     above fallout.

     seqcount writers contrary to seqlock writers must be externally
     serialized, which usually happens via locking - except for strict
     per CPU seqcounts. As the lock is not part of the seqcount, lockdep
     cannot validate that the lock is held.

     This new debug mechanism adds the concept of associated locks.
     sequence count has now lock type variants and corresponding
     initializers which take a pointer to the associated lock used for
     writer serialization. If lockdep is enabled the pointer is stored
     and write_seqcount_begin() has a lockdep assertion to validate that
     the lock is held.

     Aside of the type and the initializer no other code changes are
     required at the seqcount usage sites. The rest of the seqcount API
     is unchanged and determines the type at compile time with the help
     of _Generic which is possible now that the minimal GCC version has
     been moved up.

     Adding this lockdep coverage unearthed a handful of seqcount bugs
     which have been addressed already independent of this.

     While generally useful this comes with a Trojan Horse twist: On RT
     kernels the write side critical section can become preemtible if
     the writers are serialized by an associated lock, which leads to
     the well known reader preempts writer livelock. RT prevents this by
     storing the associated lock pointer independent of lockdep in the
     seqcount and changing the reader side to block on the lock when a
     reader detects that a writer is in the write side critical section.

   - Conversion of seqcount usage sites to associated types and
     initializers"

* tag 'locking-urgent-2020-08-10' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (25 commits)
  locking/seqlock, headers: Untangle the spaghetti monster
  locking, arch/ia64: Reduce <asm/smp.h> header dependencies by moving XTP bits into the new <asm/xtp.h> header
  x86/headers: Remove APIC headers from <asm/smp.h>
  seqcount: More consistent seqprop names
  seqcount: Compress SEQCNT_LOCKNAME_ZERO()
  seqlock: Fold seqcount_LOCKNAME_init() definition
  seqlock: Fold seqcount_LOCKNAME_t definition
  seqlock: s/__SEQ_LOCKDEP/__SEQ_LOCK/g
  hrtimer: Use sequence counter with associated raw spinlock
  kvm/eventfd: Use sequence counter with associated spinlock
  userfaultfd: Use sequence counter with associated spinlock
  NFSv4: Use sequence counter with associated spinlock
  iocost: Use sequence counter with associated spinlock
  raid5: Use sequence counter with associated spinlock
  vfs: Use sequence counter with associated spinlock
  timekeeping: Use sequence counter with associated raw spinlock
  xfrm: policy: Use sequence counters with associated lock
  netfilter: nft_set_rbtree: Use sequence counter with associated rwlock
  netfilter: conntrack: Use sequence counter with associated spinlock
  sched: tasks: Use sequence counter with associated spinlock
  ...
2020-08-10 19:07:44 -07:00
..
syscalls arch: wire-up close_range() 2020-06-17 00:07:38 +02:00
.gitignore .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
acpi-ext.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
acpi.c ACPI/sleep: Convert acpi_wakeup_address into a function 2019-12-10 10:15:48 +01:00
asm-offsets.c y2038: vdso: change timespec to __kernel_old_timespec 2019-11-15 14:38:28 +01:00
audit.c
brl_emu.c signal: Remove the task parameter from force_sig_fault 2019-05-29 09:31:43 -05:00
crash_dump.c
crash.c mm: remove include/linux/bootmem.h 2018-10-31 08:54:16 -07:00
cyclone.c remove ioremap_nocache and devm_ioremap_nocache 2020-01-06 09:45:59 +01:00
dma-mapping.c dma-direct: provide mmap and get_sgtable method overrides 2019-11-11 10:52:15 +01:00
efi_stub.S
efi.c mm: don't include asm/pgtable.h if linux/mm.h is already included 2020-06-09 09:39:13 -07:00
elfcore.c
entry.h
entry.S ia64: enable HAVE_COPY_THREAD_TLS, switch to kernel_clone_args 2020-06-23 10:49:56 +02:00
err_inject.c ia64/err-inject: fix spelling mistake: "capapbilities" -> "capabilities" 2018-03-05 14:44:53 -08:00
esi_stub.S treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
esi.c efi/ia64: Use existing helpers to locate ESI table 2020-02-23 21:59:42 +01:00
fsys.S docs: ia64: convert to ReST 2019-07-15 09:20:25 -03:00
fsyscall_gtod_data.h Stop ia64 being the last holdout using GENERIC_TIME_VSYSCALL_OLD 2017-11-13 12:15:40 -08:00
ftrace.c maccess: rename probe_kernel_{read,write} to copy_{from,to}_kernel_nofault 2020-06-17 10:57:41 -07:00
gate-data.S
gate.lds.S
gate.S
head.S mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
ia64_ksyms.c mm: remove include/linux/bootmem.h 2018-10-31 08:54:16 -07:00
iosapic.c locking, arch/ia64: Reduce <asm/smp.h> header dependencies by moving XTP bits into the new <asm/xtp.h> header 2020-08-06 16:13:13 +02:00
irq_ia64.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
irq_lsapic.c
irq.c locking, arch/ia64: Reduce <asm/smp.h> header dependencies by moving XTP bits into the new <asm/xtp.h> header 2020-08-06 16:13:13 +02:00
irq.h ia64: replace setup_irq() by request_irq() 2020-03-13 15:21:28 -07:00
ivt.S mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
kprobes.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
machine_kexec.c ia64: remove now unused machvec indirections 2019-08-16 11:33:57 -07:00
Makefile ia64: remove support for machvecs 2019-08-16 14:32:26 -07:00
Makefile.gate ia64: require -Wl,--hash-style=sysv 2019-05-18 11:29:01 +09:00
mca_asm.S mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
mca_drv_asm.S
mca_drv.c ia64: remove support for machvecs 2019-08-16 14:32:26 -07:00
mca_drv.h
mca.c kernel: rename show_stack_loglvl() => show_stack() 2020-06-09 09:39:13 -07:00
minstate.h
module.c ia64:unwind: fix double free for mod->arch.init_unw_table 2019-08-06 10:19:35 -07:00
msi_ia64.c ia64: remove now unused machvec indirections 2019-08-16 11:33:57 -07:00
nr-irqs.c
numa.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 156 2019-05-30 11:26:35 -07:00
pal.S
palinfo.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
patch.c
pci-dma.c ia64 for v5.4 - big change here is removal of support for SGI Altix 2019-09-16 15:32:01 -07:00
perfmon_default_smpl.c treewide: Add SPDX license identifier for more missed files 2019-05-21 10:50:45 +02:00
perfmon_generic.h
perfmon_itanium.h
perfmon_mckinley.h
perfmon_montecito.h
perfmon.c mmap locking API: use coccinelle to convert mmap_sem rwsem call sites 2020-06-09 09:39:14 -07:00
process.c A set of locking fixes and updates: 2020-08-10 19:07:44 -07:00
ptrace.c ia64: switch to ->regset_get() 2020-07-27 14:31:09 -04:00
relocate_kernel.S mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
sal.c locking, arch/ia64: Reduce <asm/smp.h> header dependencies by moving XTP bits into the new <asm/xtp.h> header 2020-08-06 16:13:13 +02:00
salinfo.c proc: convert everything to "struct proc_ops" 2020-02-04 03:05:26 +00:00
setup.c locking, arch/ia64: Reduce <asm/smp.h> header dependencies by moving XTP bits into the new <asm/xtp.h> header 2020-08-06 16:13:13 +02:00
sigframe.h
signal.c ia64: annotate a switch fallthrough in ia64_do_signal 2019-08-12 09:52:36 -07:00
smp.c A set of locking fixes and updates: 2020-08-10 19:07:44 -07:00
smpboot.c mm: remove unneeded includes of <asm/pgalloc.h> 2020-08-07 11:33:26 -07:00
stacktrace.c
sys_ia64.c ia64: remove CONFIG_PCI ifdefs 2019-08-16 11:33:57 -07:00
time.c ia64: replace setup_irq() by request_irq() 2020-03-13 15:21:28 -07:00
topology.c ia64: remove CONFIG_ACPI ifdefs 2019-08-16 11:33:57 -07:00
traps.c signal: Remove the task parameter from force_sig_fault 2019-05-29 09:31:43 -05:00
unaligned.c ia64: annotate switch fallthroughs in ia64_handle_unaligned 2019-08-12 09:53:13 -07:00
uncached.c mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00
unwind_decoder.c
unwind_i.h ia64: kernel: unwind_i.h: Replace zero-length array with flexible-array 2020-06-15 23:08:31 -05:00
unwind.c mm: remove include/linux/bootmem.h 2018-10-31 08:54:16 -07:00
vmlinux.lds.S mm: reorder includes after introduction of linux/pgtable.h 2020-06-09 09:39:13 -07:00