From: Rob Landley <rob@landley.net>
To: Oleg <lego12239@yandex.ru>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [docs] /proc/irq/
Date: Mon, 04 Feb 2013 09:06:44 -0600 [thread overview]
Message-ID: <1359990404.12062.9@driftwood> (raw)
In-Reply-To: <20130130094432.GA30556@localhost> (from lego12239@yandex.ru on Wed Jan 30 03:44:32 2013)
On 01/30/2013 03:44:32 AM, Oleg wrote:
> Hello.
>
> Where can i find an info about /proc/irq/*/affinity_hint ?
> Documentation/filesystems/proc.txt says nothing about it (3.2.37
> kernel).
The general procedure is to look for the git commit, which may have a
good commit comment, and also gives you an idea when it went in so you
can look in the mailing list archives:
cd linux
find . -name '"affinity_hint"'
git annotate kernel/proc/irq.c
(search for "affinity_hint" in quotes, line 331 here, the bit on the
left edge is the commit hash.)
commit e7a297b0d7d6049bd4e423ac1e17da31e4c401b8
Author: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com>
Date: Fri Apr 30 14:44:50 2010 -0700
genirq: Add CPU mask affinity hint
This patch adds a cpumask affinity hint to the irq_desc structure,
along with a registration function and a read-only proc entry for
each
interrupt.
This affinity_hint handle for each interrupt can be used by
underlying
drivers that need a better mechanism to control interrupt affinity.
The underlying driver can register a cpumask for the interrupt,
which
will allow the driver to provide the CPU mask for the interrupt to
anything that requests it. The intent is to extend the userspace
daemon, irqbalance, to help hint to it a preferred CPU mask to
balance
the interrupt into.
[ tglx: Fixed compile warnings, added WARN_ON, made SMP only ]
Signed-off-by: Peter P Waskiewicz Jr
<peter.p.waskiewicz.jr@intel.com>
That doesn't clarifiy much. Grepping the source for irq_affinity it
looks like the kernel treats this as a write-only property, and never
does anything with the info. However, include/linux/irqdesc.h has
documentation for the structure containing the property, and it says
this about that field:
* @affinity_hint: hint to user space for preferred irq affinity
So this "irqbalance" daemon you're probably not running (unless it got
sucked into the systemd hairball, in which case you don't know you're
running it and can't stop it) reads this process and tells the kernel
to move the irq worker thread to this CPU while load balancing.
It sounds like you're saying Documentation/filesystems/proc.txt should
be updated to include this information?
Rob
prev parent reply other threads:[~2013-02-04 15:06 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-30 9:44 [docs] /proc/irq/ Oleg
2013-02-04 15:06 ` Rob Landley [this message]
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=1359990404.12062.9@driftwood \
--to=rob@landley.net \
--cc=lego12239@yandex.ru \
--cc=linux-kernel@vger.kernel.org \
/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