dri-devel.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [patch 00/30] genirq: Treewide hunt for irq descriptor abuse and assorted fixes
@ 2020-12-10 19:25 Thomas Gleixner
  2020-12-10 19:25 ` [patch 01/30] genirq: Move irq_has_action() into core code Thomas Gleixner
                   ` (29 more replies)
  0 siblings, 30 replies; 73+ messages in thread
From: Thomas Gleixner @ 2020-12-10 19:25 UTC (permalink / raw)
  To: LKML
  Cc: Mark Rutland, Karthikeyan Mitran, Peter Zijlstra,
	Catalin Marinas, dri-devel, Chris Wilson, James E.J. Bottomley,
	Saeed Mahameed, netdev, Will Deacon, Michal Simek, linux-s390,
	afzal mohammed, Lorenzo Pieralisi, Dave Jiang, xen-devel,
	Leon Romanovsky, linux-rdma, Marc Zyngier, Helge Deller,
	Russell King, Christian Borntraeger, linux-pci, Jakub Kicinski,
	Heiko Carstens, Wambui Karuga, Allen Hubbe, Juergen Gross,
	David Airlie, linux-gpio, Stefano Stabellini, Rodrigo Vivi,
	Bjorn Helgaas, Lee Jones, linux-arm-kernel, Boris Ostrovsky,
	Tvrtko Ursulin, linux-parisc, Pankaj Bharadiya, Hou Zhiqiang,
	Tariq Toukan, Jon Mason, linux-ntb, intel-gfx, David S. Miller

A recent request to export kstat_irqs() pointed to a copy of the same in
the i915 code, which made me look for further usage of irq descriptors in
drivers.

The usage in drivers ranges from creative to broken in all colours.

irqdesc.h clearly says that this is core functionality and the fact C does
not allow full encapsulation is not a justification to fiddle with it just
because. It took us a lot of effort to make the core functionality provide
what drivers need.

If there is a shortcoming, it's not asked too much to talk to the relevant
maintainers instead of going off and fiddling with the guts of interrupt
descriptors and often enough without understanding lifetime and locking
rules.

As people insist on not respecting boundaries, this series cleans up the
(ab)use and at the end removes the export of irq_to_desc() to make it at
least harder. All legitimate users of this are built in.

While at it I stumbled over some other oddities related to interrupt
counting and cleaned them up as well.

The series applies on top of

   git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git irq/core

and is also available from git:

  git://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git genirq

Thanks,

	tglx
---
 arch/alpha/kernel/sys_jensen.c                       |    2 
 arch/arm/kernel/smp.c                                |    2 
 arch/parisc/kernel/irq.c                             |    7 
 arch/s390/kernel/irq.c                               |    2 
 arch/x86/kernel/topology.c                           |    1 
 arch/arm64/kernel/smp.c                              |    2 
 drivers/gpu/drm/i915/display/intel_lpe_audio.c       |    4 
 drivers/gpu/drm/i915/i915_irq.c                      |   34 +++
 drivers/gpu/drm/i915/i915_pmu.c                      |   18 -
 drivers/gpu/drm/i915/i915_pmu.h                      |    8 
 drivers/mfd/ab8500-debugfs.c                         |   16 -
 drivers/net/ethernet/mellanox/mlx4/en_cq.c           |    8 
 drivers/net/ethernet/mellanox/mlx4/en_rx.c           |    6 
 drivers/net/ethernet/mellanox/mlx4/mlx4_en.h         |    3 
 drivers/net/ethernet/mellanox/mlx5/core/en.h         |    2 
 drivers/net/ethernet/mellanox/mlx5/core/en_main.c    |    2 
 drivers/net/ethernet/mellanox/mlx5/core/en_txrx.c    |    6 
 drivers/ntb/msi.c                                    |    4 
 drivers/pci/controller/mobiveil/pcie-mobiveil-host.c |    8 
 drivers/pci/controller/pcie-xilinx-nwl.c             |    8 
 drivers/pinctrl/nomadik/pinctrl-nomadik.c            |    3 
 drivers/xen/events/events_base.c                     |  172 +++++++++++--------
 drivers/xen/evtchn.c                                 |   34 ---
 include/linux/interrupt.h                            |    1 
 include/linux/irq.h                                  |    7 
 include/linux/irqdesc.h                              |   40 +---
 include/linux/kernel_stat.h                          |    1 
 kernel/irq/irqdesc.c                                 |   42 ++--
 kernel/irq/manage.c                                  |   37 ++++
 kernel/irq/proc.c                                    |    5 
 30 files changed, 263 insertions(+), 222 deletions(-)


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 73+ messages in thread

end of thread, other threads:[~2021-01-12  7:58 UTC | newest]

Thread overview: 73+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-10 19:25 [patch 00/30] genirq: Treewide hunt for irq descriptor abuse and assorted fixes Thomas Gleixner
2020-12-10 19:25 ` [patch 01/30] genirq: Move irq_has_action() into core code Thomas Gleixner
2020-12-10 19:25 ` [patch 02/30] genirq: Move status flag checks to core Thomas Gleixner
2020-12-27 19:20   ` Guenter Roeck
2021-01-11 10:14     ` Thomas Gleixner
2020-12-10 19:25 ` [patch 03/30] genirq: Move irq_set_lockdep_class() " Thomas Gleixner
2020-12-11 17:53   ` Andy Shevchenko
2020-12-11 21:08     ` Thomas Gleixner
2020-12-11 22:07       ` Thomas Gleixner
2020-12-12 13:22         ` Andy Shevchenko
2020-12-10 19:25 ` [patch 04/30] genirq: Provide irq_get_effective_affinity() Thomas Gleixner
2020-12-10 19:25 ` [patch 05/30] genirq: Annotate irq stats data races Thomas Gleixner
2020-12-10 19:25 ` [patch 06/30] parisc/irq: Simplify irq count output for /proc/interrupts Thomas Gleixner
2020-12-10 19:25 ` [patch 07/30] genirq: Make kstat_irqs() static Thomas Gleixner
2020-12-10 19:25 ` [patch 08/30] genirq: Provide kstat_irqdesc_cpu() Thomas Gleixner
2020-12-10 19:25 ` [patch 09/30] ARM: smp: Use irq_desc_kstat_cpu() in show_ipi_list() Thomas Gleixner
2020-12-11 18:08   ` Marc Zyngier
2020-12-10 19:25 ` [patch 10/30] arm64/smp: Use irq_desc_kstat_cpu() in arch_show_interrupts() Thomas Gleixner
2020-12-11 18:08   ` Marc Zyngier
2020-12-10 19:25 ` [patch 11/30] parisc/irq: Use irq_desc_kstat_cpu() in show_interrupts() Thomas Gleixner
2020-12-10 19:25 ` [patch 12/30] s390/irq: Use irq_desc_kstat_cpu() in show_msi_interrupt() Thomas Gleixner
2020-12-10 20:31   ` Heiko Carstens
2020-12-10 19:25 ` [patch 13/30] drm/i915/lpe_audio: Remove pointless irq_to_desc() usage Thomas Gleixner
2020-12-10 19:48   ` [Intel-gfx] " Ville Syrjälä
2020-12-11  9:51     ` Jani Nikula
2020-12-10 19:25 ` [patch 14/30] drm/i915/pmu: Replace open coded kstat_irqs() copy Thomas Gleixner
2020-12-11  9:54   ` Jani Nikula
2020-12-11 10:13   ` Tvrtko Ursulin
2020-12-11 12:57     ` Thomas Gleixner
2020-12-11 14:19       ` David Laight
2020-12-11 21:10         ` Thomas Gleixner
2020-12-11 22:06           ` David Laight
2020-12-10 19:25 ` [patch 15/30] pinctrl: nomadik: Use irq_has_action() Thomas Gleixner
2020-12-12  0:45   ` Linus Walleij
2020-12-10 19:25 ` [patch 16/30] mfd: ab8500-debugfs: Remove the racy fiddling with irq_desc Thomas Gleixner
2020-12-11  8:22   ` Linus Walleij
2020-12-11 10:04   ` Lee Jones
2020-12-11 18:12   ` Andy Shevchenko
2020-12-10 19:25 ` [patch 17/30] NTB/msi: Use irq_has_action() Thomas Gleixner
2020-12-10 20:33   ` Logan Gunthorpe
2020-12-10 19:25 ` [patch 18/30] PCI: xilinx-nwl: Use irq_data_get_irq_chip_data() Thomas Gleixner
2020-12-10 22:56   ` Rob Herring
2020-12-10 19:25 ` [patch 19/30] PCI: mobiveil: " Thomas Gleixner
2020-12-10 22:56   ` Rob Herring
2020-12-10 19:25 ` [patch 20/30] net/mlx4: Replace irq_to_desc() abuse Thomas Gleixner
2020-12-13 11:24   ` Tariq Toukan
2020-12-10 19:25 ` [patch 21/30] net/mlx4: Use effective interrupt affinity Thomas Gleixner
2020-12-13 11:31   ` Tariq Toukan
2020-12-10 19:25 ` [patch 22/30] net/mlx5: Replace irq_to_desc() abuse Thomas Gleixner
2020-12-13 11:34   ` Tariq Toukan
2020-12-14 21:13   ` Saeed Mahameed
2020-12-10 19:25 ` [patch 23/30] net/mlx5: Use effective interrupt affinity Thomas Gleixner
2020-12-13 11:35   ` Tariq Toukan
2020-12-14 20:58   ` Saeed Mahameed
2020-12-10 19:26 ` [patch 24/30] xen/events: Remove unused bind_evtchn_to_irq_lateeoi() Thomas Gleixner
2020-12-10 23:19   ` boris.ostrovsky
2020-12-11  0:04     ` Thomas Gleixner
2020-12-10 19:26 ` [patch 25/30] xen/events: Remove disfunct affinity spreading Thomas Gleixner
2020-12-10 19:26 ` [patch 26/30] xen/events: Use immediate affinity setting Thomas Gleixner
2020-12-10 19:26 ` [patch 27/30] xen/events: Only force affinity mask for percpu interrupts Thomas Gleixner
2020-12-10 23:20   ` boris.ostrovsky
2020-12-11  0:06     ` Thomas Gleixner
2020-12-11  6:17     ` Jürgen Groß
     [not found]       ` <874kksiras.fsf@nanos.tec.linutronix.de>
2020-12-11 10:23         ` Jürgen Groß
2020-12-11 12:10     ` Jürgen Groß
2020-12-11 12:37       ` Thomas Gleixner
2020-12-11 14:29         ` boris.ostrovsky
2020-12-11 21:27           ` Thomas Gleixner
2020-12-11 22:21             ` Andrew Cooper
2020-12-11 22:56               ` Thomas Gleixner
2020-12-10 19:26 ` [patch 28/30] xen/events: Reduce irq_info::spurious_cnt storage size Thomas Gleixner
2020-12-10 19:26 ` [patch 29/30] xen/events: Implement irq distribution Thomas Gleixner
2020-12-10 19:26 ` [patch 30/30] genirq: Remove export of irq_to_desc() Thomas Gleixner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).