From: Thomas Gleixner <tglx@linutronix.de>
To: "Bae, Chang Seok" <chang.seok.bae@intel.com>
Cc: "bp@suse.de" <bp@suse.de>, "Lutomirski, Andy" <luto@kernel.org>,
"mingo@kernel.org" <mingo@kernel.org>,
"x86@kernel.org" <x86@kernel.org>,
"Brown, Len" <len.brown@intel.com>,
"lenb@kernel.org" <lenb@kernel.org>,
"Hansen, Dave" <dave.hansen@intel.com>,
"Macieira, Thiago" <thiago.macieira@intel.com>,
"Liu, Jing2" <jing2.liu@intel.com>,
"Shankar, Ravi V" <ravi.v.shankar@intel.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"kvm@vger.kernel.org" <kvm@vger.kernel.org>
Subject: Re: [PATCH v10 04/28] x86/fpu/xstate: Modify address finders to handle both static and dynamic buffers
Date: Mon, 04 Oct 2021 14:54:48 +0200 [thread overview]
Message-ID: <878rz9gdbb.ffs@tglx> (raw)
In-Reply-To: <B7F1A300-3E61-4CB4-8BCA-316FE68B7222@intel.com>
On Sun, Oct 03 2021 at 22:35, Chang Seok Bae wrote:
> On Oct 1, 2021, at 06:15, Thomas Gleixner <tglx@linutronix.de> wrote:
>
> Okay, a NULL pointer is odd and it as an argument should be avoided. Defining
> a separate struct fpu for the initial state can make every function expect a
> valid struct fpu pointer.
>
> I think that the patch set will have such order (once [1] is dropped out) of,
> - patch1 (new): a cleanup patch for fpstate_init_xstate() in patch1
> - patch2 (new): the above init_fpu goes into this, and
> - patch3-5: changes arguments to fpu,
So actually I sat down over the weekend and looked at that again. Adding this
to struct fpu is wrong. The size and features information belongs into
something like this:
struct fpstate {
unsigned int size;
u64 xfeatures;
union fpregs_state regs;
};
Why? Simply because fpstate is the container for the dynamically sized
regs and that's where it semantically belongs.
While staring at that I just started to cleanup stuff all over the place
to make the integration of this simpler.
The patches are completely untested and have no changelogs yet, but if
you want a preview, I've uploaded a patch series to:
https://tglx.de/~tglx/patches.tar
I'm still staring at some of the dynamic feature integrations, but this
is roughly where this should be heading.
Thanks,
tglx
next prev parent reply other threads:[~2021-10-04 12:55 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20210825155413.19673-1-chang.seok.bae@intel.com>
2021-08-25 15:53 ` [PATCH v10 02/28] x86/fpu/xstate: Modify the initialization helper to handle both static and dynamic buffers Chang S. Bae
2021-10-01 12:45 ` Thomas Gleixner
2021-10-03 22:35 ` Bae, Chang Seok
2021-08-25 15:53 ` [PATCH v10 04/28] x86/fpu/xstate: Modify address finders " Chang S. Bae
2021-10-01 13:15 ` Thomas Gleixner
2021-10-03 22:35 ` Bae, Chang Seok
2021-10-04 12:54 ` Thomas Gleixner [this message]
2021-08-25 15:53 ` [PATCH v10 06/28] x86/fpu/xstate: Add new variables to indicate dynamic XSTATE buffer size Chang S. Bae
2021-10-01 13:32 ` Thomas Gleixner
2021-10-03 22:36 ` Bae, Chang Seok
2021-08-25 15:53 ` [PATCH v10 08/28] x86/fpu/xstate: Convert the struct fpu 'state' field to a pointer Chang S. Bae
2021-08-25 15:53 ` [PATCH v10 10/28] x86/fpu/xstate: Update the XSTATE save function to support dynamic states Chang S. Bae
2021-10-01 15:41 ` Thomas Gleixner
2021-10-02 21:31 ` Thomas Gleixner
2021-10-02 22:54 ` Bae, Chang Seok
2021-10-05 8:16 ` Paolo Bonzini
2021-10-05 7:50 ` Paolo Bonzini
2021-10-05 9:55 ` Thomas Gleixner
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=878rz9gdbb.ffs@tglx \
--to=tglx@linutronix.de \
--cc=bp@suse.de \
--cc=chang.seok.bae@intel.com \
--cc=dave.hansen@intel.com \
--cc=jing2.liu@intel.com \
--cc=kvm@vger.kernel.org \
--cc=len.brown@intel.com \
--cc=lenb@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@kernel.org \
--cc=mingo@kernel.org \
--cc=ravi.v.shankar@intel.com \
--cc=thiago.macieira@intel.com \
--cc=x86@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