From: Sean Christopherson <seanjc@google.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: kvm@vger.kernel.org, zxwang42@gmail.com, marcorr@google.com,
jroedel@suse.de, varad.gautam@suse.com,
Jim Mattson <jmattson@google.com>
Subject: Re: [PATCH kvm-unit-tests 2/2] replace tss_descr global with a function
Date: Wed, 20 Oct 2021 18:01:26 +0000 [thread overview]
Message-ID: <YXBZdoeeRqmqU76l@google.com> (raw)
In-Reply-To: <20211020165333.953978-3-pbonzini@redhat.com>
+Jim again
On Wed, Oct 20, 2021, Paolo Bonzini wrote:
> @@ -255,4 +255,16 @@ static inline void *get_idt_addr(idt_entry_t *entry)
> return (void *)addr;
> }
>
> +extern gdt_desc_entry_t *get_tss_descr(void);
> +
> +static inline unsigned long get_gdt_entry_base(gdt_desc_entry_t *entry)
Bad naming again, base4 doesn't exist for segment descriptors. It's a bit
wordy, but maybe this?
static inline unsigned long get_system_desc_base(gdt_system_desc_entry_t *entry)
> +{
> + unsigned long base;
> + base = entry->base1 | ((u32)entry->base2 << 16) | ((u32)entry->base3 << 24);
> +#ifdef __x86_64__
> + base |= (u64)entry->base4 << 32;
> +#endif
> + return base;
> +}
> +
> #endif
prev parent reply other threads:[~2021-10-20 18:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-20 16:53 [PATCH kvm-unit-tests 0/2] remove tss_descr, replace with a function Paolo Bonzini
2021-10-20 16:53 ` [PATCH kvm-unit-tests 1/2] unify structs for GDT descriptors Paolo Bonzini
2021-10-20 17:58 ` Sean Christopherson
2021-10-20 19:10 ` Paolo Bonzini
2021-10-20 20:05 ` Jim Mattson
2021-10-20 16:53 ` [PATCH kvm-unit-tests 2/2] replace tss_descr global with a function Paolo Bonzini
2021-10-20 18:01 ` Sean Christopherson [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=YXBZdoeeRqmqU76l@google.com \
--to=seanjc@google.com \
--cc=jmattson@google.com \
--cc=jroedel@suse.de \
--cc=kvm@vger.kernel.org \
--cc=marcorr@google.com \
--cc=pbonzini@redhat.com \
--cc=varad.gautam@suse.com \
--cc=zxwang42@gmail.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