LKML Archive on
help / color / mirror / Atom feed
From: Paolo Bonzini <>
To: Sean Christopherson <>,
	Mingwei Zhang <>
Cc: Vitaly Kuznetsov <>,
	Wanpeng Li <>,
	Jim Mattson <>, Joerg Roedel <>,,,
	Tom Lendacky <>,
	Marc Orr <>,
	David Rientjes <>,
	Alper Gun <>,
	Dionna Glaze <>,
	Vipin Sharma <>
Subject: Re: [PATCH] KVM: SEV: improve the code readability for ASID management
Date: Mon, 2 Aug 2021 18:52:54 +0200	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <YQgamDDn6TVY/>

On 02/08/21 18:17, Sean Christopherson wrote:
> Rather than adjusting the bitmap index, what about simply umping the bitmap size?
> IIRC, current CPUs have 512 ASIDs, counting ASID 0, i.e. bumping the size won't
> consume any additional memory.  And if it does, the cost is 8 bytes...
> It'd be a bigger refactoring, but it should completely eliminate the mod-by-1
> shenanigans, e.g. a partial patch could look like

This is also okay by me if Mingwei agrees, of course.  I have already 
queued his patch, but I can replace it with one using a nr_asids-sized 
bitmap too.


  reply	other threads:[~2021-08-02 16:53 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-31  1:13 [PATCH] KVM: SEV: improve the code readability for ASID management Mingwei Zhang
2021-08-02 13:38 ` Joerg Roedel
2021-08-02 16:00   ` Mingwei Zhang
2021-08-02 16:17 ` Sean Christopherson
2021-08-02 16:52   ` Paolo Bonzini [this message]
2021-08-02 17:25     ` Mingwei Zhang

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \

* 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 NNTP newsgroup(s).