public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Radu Rendec <rrendec@redhat.com>, linux-kernel@vger.kernel.org
Cc: Marc Zyngier <maz@kernel.org>
Subject: Re: [RFC PATCH 0/5] irq: sysfs interface improvements for SMP affinity control
Date: Wed, 31 May 2023 15:09:10 +0200	[thread overview]
Message-ID: <877csohcll.ffs@tglx> (raw)
In-Reply-To: <20230530214550.864894-1-rrendec@redhat.com>

On Tue, May 30 2023 at 17:45, Radu Rendec wrote:
> Note: I still need to update the Documentation/ directory for the new
>       sysfs interface, and I will address that in a future version.
>       At this point, I just want to get feedback about the current
>       approach.

From a conceptual POV I understand why this is required, which makes me
hate this chained mechanism even more.

Aside of having no visibility (counters, affinity, etc) the worst thing
about these chained hidden interrupts is:

  There is no control of runaway interrupts as they circumvent the core,
  which has caused hard to diagnose system hangups in the past. See
   
    ba714a9c1dea ("pinctrl/amd: Use regular interrupt instead of chained")

  for demonstration.

The argument I heard for this chained interrupt muck is that it's so
much more performant than using regular interrupt handlers via
request_irq(). It's obviously less overhead, but whether it matters and
most importantly whether it justifies the downsides is a different
question.

There is also the argument about double accounting. Right now the
chained handler is not accounted and only the childs are.

Though that is inconsistent with other demultiplex handlers which _must_
use regular interrupt handlers (threaded) to demultiplex interrupt chips
which sit behind SPI/I2C...

The sum of child interrupts is also not necessarily the number of parent
interrupts, unless there is always exactly only one child handler to
invoke.

Quite some of those demux handlers are also not RT compatible.

AFAICT, there is no real technical reason at least not for the vast
majority of usage sites why the demultiplex handler cannot run inside a
regular interrupt handler context.

So I personally would prefer to get rid of this chained oddball and just
have consistent mechanisms for dealing with interrupts, which would just
avoid exposing the affinity files in two different places.

Providing information about child/parent relationship is an orthogonal
issue.

If there is some good reason (aside of the chained muck) to have sysfs
based affinity management, then I'm not objecting as long as the
functionality is the same, i.e. effective affinity needs be exposed too.

Thanks,

        tglx

  parent reply	other threads:[~2023-05-31 13:09 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-30 21:45 [RFC PATCH 0/5] irq: sysfs interface improvements for SMP affinity control Radu Rendec
2023-05-30 21:45 ` [RFC PATCH 1/5] irq: Always enable parent interrupt tracking Radu Rendec
2023-05-31 13:10   ` Thomas Gleixner
2023-05-31 22:56     ` Radu Rendec
2023-05-30 21:45 ` [RFC PATCH 2/5] irq: Show the parent chained interrupt in debugfs Radu Rendec
2023-05-30 21:45 ` [RFC PATCH 3/5] irq: Expose chained interrupt parents in sysfs Radu Rendec
2023-05-30 21:45 ` [RFC PATCH 4/5] irq: Move SMP affinity write handler out of proc.c Radu Rendec
2023-05-30 21:45 ` [RFC PATCH 5/5] irq: Add smp_affinity/list attributes to sysfs Radu Rendec
2023-05-31 13:09 ` Thomas Gleixner [this message]
2023-05-31 22:54   ` [RFC PATCH 0/5] irq: sysfs interface improvements for SMP affinity control Radu Rendec
2023-06-20 15:58   ` Radu Rendec

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=877csohcll.ffs@tglx \
    --to=tglx@linutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=rrendec@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox