mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Cooper <andrew.cooper3@citrix.com>
To: zokeefe@google.com
Cc: Andrew Cooper <andrew.cooper3@citrix.com>,
	Liam.Howlett@oracle.com, akpm@linux-foundation.org, bp@alien8.de,
	dave.hansen@intel.com, dave.hansen@linux.intel.com,
	david@kernel.org, hpa@zytor.com, kees@kernel.org,
	linus.walleij@linaro.org, linux-kernel@vger.kernel.org,
	linux-mm@kvack.org, ljs@kernel.org, luto@kernel.org,
	mhocko@suse.com, mingo@redhat.com, pasha.tatashin@soleen.com,
	peterz@infradead.org, qperret@google.com, rppt@kernel.org,
	stevensd@google.com, surenb@google.com, tglx@kernel.org,
	urezki@gmail.com, vbabka@kernel.org, willdeacon@google.com,
	x86@kernel.org, xin@zytor.com
Subject: Re: [PATCH v2 00/13] Dynamic Kernel Stacks
Date: Thu, 25 Jun 2026 12:56:00 +0100	[thread overview]
Message-ID: <bfb0fea2-ce59-4c10-8597-58e495ad6d81@citrix.com> (raw)
In-Reply-To: <CAAa6QmRw6QLnVJ8+uvMV8ASreLXzSab5Jii3Ju11qCZYio6Few@mail.gmail.com>

> However, I'd still like to work with you to understand what feasible
> path forward you see, hoping you can proactively steer us away from
> some of the bigger headaches.
>
> I think we are fine being forward-looking, and only supporting this
> for FRED (which is on our doorstep). That said, understanding the
> issues you foresee with the IST approach

For IST, read
https://docs.google.com/document/d/1hWejnyDkjRRAW-JEsRjA5c9CKLOPc6VKJQsuvODlQEI/edit?usp=sharing

This was written prior to the first public drafts of FRED and SEE specs,
and FRED evolved quite a lot from the first draft to where we are today.

>  would still be valuable, as
> it might save us internal trouble should we choose to carry it
> temporarily to bridge the gap with FRED.

A lot has been said about the invasiveness and tradeoffs.  I don't wish
to dwell on or rehash that.

There is one critical point which has not been made as far as I can tell:

In x86, if delivering an interrupt (NMI or INTR) causes an exception
(any exception, not just pagefault), the original interrupt is lost.

If you are aware of this, then in principle you can look at the LAPIC
state to figure out when an INTR was missed.  However there is no
ability at all to figure out when an NMI was missed.  Worse, it is both
vendor and IDT-vs-FRED specific as to whether NMIs are blocked following
a missed NMI, and that too is state you cannot recover.

If you wish to make dynamic stacks works, then you *must* find a
non-fault based approach on x86.

~Andrew

  parent reply	other threads:[~2026-06-25 11:56 UTC|newest]

Thread overview: 72+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-24 19:14 David Stevens
2026-04-24 19:14 ` [PATCH v2 01/13] fork: Remove assumption that vm_area->nr_pages equals to THREAD_SIZE David Stevens
2026-04-24 19:14 ` [PATCH v2 02/13] fork: Don't assume fully populated stack during reuse David Stevens
2026-04-24 19:14 ` [PATCH v2 03/13] fork: Move vm_stack to the beginning of the stack David Stevens
2026-04-24 19:14 ` [PATCH v2 04/13] fork: separate vmap stack allocation and free calls David Stevens
2026-04-24 19:14 ` [PATCH v2 05/13] mm/vmalloc: Add a get_vm_area_node() and vmap_pages_range() public functions David Stevens
2026-04-24 19:14 ` [PATCH v2 06/13] fork: Move vmap stack freeing to work queue David Stevens
2026-04-24 19:14 ` [PATCH v2 07/13] fork: Dynamic Kernel Stacks David Stevens
2026-04-24 19:14 ` [PATCH v2 08/13] task_stack.h: Add stack_not_used() support for dynamic stack David Stevens
2026-04-24 19:14 ` [PATCH v2 09/13] fork: Dynamic Kernel Stack accounting David Stevens
2026-04-24 19:14 ` [PATCH v2 10/13] fork: Store task pointer in unpopulated stack ptes David Stevens
2026-06-26 22:46   ` Thomas Gleixner
2026-06-27 23:11     ` Thomas Gleixner
2026-04-24 19:14 ` [PATCH v2 11/13] x86/entry/fred: encode frame pointer on entry David Stevens
2026-05-20 22:24   ` David Stevens
2026-05-22 22:25     ` H. Peter Anvin
2026-05-24 18:22       ` Xin Li
2026-07-14 23:09   ` [tip: x86/entry] x86/entry/fred: Encode " tip-bot2 for David Stevens
2026-04-24 19:14 ` [PATCH v2 12/13] x86: Add support for dynamic kernel stacks via FRED David Stevens
2026-06-26 22:39   ` Thomas Gleixner
2026-06-27  4:05     ` David Stevens
2026-06-28 16:46       ` Thomas Gleixner
2026-06-28 20:33         ` H. Peter Anvin
2026-06-29  8:41           ` Thomas Gleixner
2026-06-29 14:52             ` H. Peter Anvin
2026-06-30  8:28               ` Thomas Gleixner
2026-04-24 19:14 ` [PATCH v2 13/13] x86: Add support for dynamic kernel stacks via IST David Stevens
2026-04-24 19:41 ` [PATCH v2 00/13] Dynamic Kernel Stacks Dave Hansen
2026-04-24 21:35   ` Pasha Tatashin
2026-04-24 22:21     ` Dave Hansen
2026-04-24 22:49       ` David Stevens
2026-04-24 22:26     ` David Laight
2026-04-24 23:06       ` Pasha Tatashin
2026-06-19  0:29       ` Dave Hansen
2026-06-19 19:56         ` Zach O'Keefe
2026-06-20  5:25         ` David Stevens
2026-06-20 23:22           ` Dave Hansen
2026-04-25  9:19   ` H. Peter Anvin
2026-04-27 16:17     ` Dave Hansen
2026-06-18 14:50       ` Zach O'Keefe
2026-06-18 18:53         ` Dave Hansen
2026-06-18 22:28           ` H. Peter Anvin
2026-06-19  0:40             ` David Stevens
2026-06-19  0:44               ` H. Peter Anvin
2026-06-19 12:45           ` Thomas Gleixner
2026-06-19 19:20             ` Zach O'Keefe
2026-06-19 21:59               ` Thomas Gleixner
2026-06-20  5:02                 ` David Stevens
2026-06-20 21:59                   ` Thomas Gleixner
2026-06-20 19:33                 ` Zach O'Keefe
2026-06-20 19:44                   ` H. Peter Anvin
2026-06-20 20:01                     ` Zach O'Keefe
2026-06-20 23:34                   ` Thomas Gleixner
2026-06-22 23:00                     ` Zach O'Keefe
2026-06-23  7:50                       ` David Hildenbrand (Arm)
2026-06-23  9:10                         ` David Laight
2026-06-23  9:19                           ` David Hildenbrand (Arm)
2026-06-23 21:58                       ` Thomas Gleixner
2026-06-29 16:02                         ` Dave Hansen
2026-06-29 16:12                           ` H. Peter Anvin
2026-06-29 16:18                           ` Vlastimil Babka (SUSE)
2026-06-29 16:21                             ` H. Peter Anvin
2026-06-29 17:29                               ` Zach O'Keefe
2026-06-29 17:38                                 ` Dave Hansen
2026-06-29 19:43                                 ` David Laight
2026-06-29 20:17                           ` Matthew Wilcox
2026-06-29 21:13                             ` Dave Hansen
2026-06-29 20:28                           ` David Laight
2026-06-25 11:56         ` Andrew Cooper [this message]
2026-06-25 21:38           ` H. Peter Anvin
2026-06-26  8:16         ` David Laight
2026-04-27 16:31     ` Pasha Tatashin

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=bfb0fea2-ce59-4c10-8597-58e495ad6d81@citrix.com \
    --to=andrew.cooper3@citrix.com \
    --cc=Liam.Howlett@oracle.com \
    --cc=akpm@linux-foundation.org \
    --cc=bp@alien8.de \
    --cc=dave.hansen@intel.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=david@kernel.org \
    --cc=hpa@zytor.com \
    --cc=kees@kernel.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=ljs@kernel.org \
    --cc=luto@kernel.org \
    --cc=mhocko@suse.com \
    --cc=mingo@redhat.com \
    --cc=pasha.tatashin@soleen.com \
    --cc=peterz@infradead.org \
    --cc=qperret@google.com \
    --cc=rppt@kernel.org \
    --cc=stevensd@google.com \
    --cc=surenb@google.com \
    --cc=tglx@kernel.org \
    --cc=urezki@gmail.com \
    --cc=vbabka@kernel.org \
    --cc=willdeacon@google.com \
    --cc=x86@kernel.org \
    --cc=xin@zytor.com \
    --cc=zokeefe@google.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