Linux-rt-users archive mirror
 help / color / mirror / Atom feed
From: Mike Galbraith <efault@gmx.de>
To: mfranklin@comfiletech.com, linux-rt-users@vger.kernel.org
Subject: Re: i2c jitter is worse in PREEMPT_RT kernel than stock Raspberry Pi kernel
Date: Wed, 13 Dec 2023 09:15:14 +0100	[thread overview]
Message-ID: <3457c4604d0b0318e26336b24a0b36808080a25e.camel@gmx.de> (raw)
In-Reply-To: <3feecb7c-72a9-4778-930f-764495a91448@comfiletech.com>

On Wed, 2023-12-13 at 12:33 +0900, Michael Franklin wrote:
> 
> I tested the stock kernel with `threadirqs` and indeed the jitter was worse, but the RT kernel still 
> seemed to be more jittery.
> 
> However, based on what you mentioned, I decided to look further interrupts/IRQ behavior, and found 
> this in /proc/interrupts:
> 
> PREEMPT_RT kernel:
>             CPU0       CPU1       CPU2       CPU3
> 109:   22625815          0          0          0  rp1_irq_chip   8 Level     1f00074000.i2c
> IPI0:     19640   12018430    6870398    5548908       Rescheduling interrupts
> IPI1:       713      26295      18104        367       Function call interrupts
> 
> Stock Kernel:
>             CPU0       CPU1       CPU2       CPU3
> 109:   11129247          0          0          0  rp1_irq_chip   8 Level     1f00074000.i2c
> IPI0:       582        620        572        694       Rescheduling interrupts
> IPI1:     40061      12360     108946    5475437       Function call interrupts
> 
> Stock Kernel with `threadirqs`:
>             CPU0       CPU1       CPU2       CPU3
> 109:   21774128          0          0          0  rp1_irq_chip   8 Level     1f00074000.i2c
> IPI0:       674        657        687        617       Rescheduling interrupts
> IPI1:     58655     127527   21331238    5780380       Function call interrupts
> 
> There you can see that, in the PREEMPT_RT kernel, there are a very large number of 'Rescheduling 
> interrupts' and only a few 'Function call interrupts'.  However, in the stock kernel it is the 
> opposite -- a large number of 'Function call interrupts' and a few 'Rescheduling interrupts'.

Part of that is mitigation ala 539fbb5be0, and part is RT being its
naturally twitchy self.


	-Mike

      parent reply	other threads:[~2023-12-13  8:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-12  2:53 i2c jitter is worse in PREEMPT_RT kernel than stock Raspberry Pi kernel Michael Franklin
2023-12-12 12:42 ` Mike Galbraith
2023-12-13  3:33   ` Michael Franklin
2023-12-13  4:37     ` Michael Franklin
2023-12-13  8:15     ` Mike Galbraith [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=3457c4604d0b0318e26336b24a0b36808080a25e.camel@gmx.de \
    --to=efault@gmx.de \
    --cc=linux-rt-users@vger.kernel.org \
    --cc=mfranklin@comfiletech.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).