From: Janosch Frank Date: Thu, 12 Sep 2019 11:31:41 +0000 Subject: Re: [PATCH 04/13] KVM: Drop kvm_arch_create_memslot() Message-Id: MIME-Version: 1 Content-Type: multipart/mixed; boundary="VFaGAeTCeRXorJeO4VEs9GCOZpf5lhFaI" List-Id: References: <20190911185038.24341-1-sean.j.christopherson@intel.com> <20190911185038.24341-5-sean.j.christopherson@intel.com> In-Reply-To: <20190911185038.24341-5-sean.j.christopherson@intel.com> To: Sean Christopherson , James Hogan , Paul Mackerras , Christian Borntraeger , Paolo Bonzini , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , Marc Zyngier Cc: David Hildenbrand , Cornelia Huck , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , James Morse , Julien Thierry , Suzuki K Pouloze , linux-mips@vger.kernel.org, kvm-ppc@vger.kernel.org, kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu, linux-kernel@vger.kernel.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --VFaGAeTCeRXorJeO4VEs9GCOZpf5lhFaI Content-Type: multipart/mixed; boundary="UU4cv3zIJan03aUPjGzvFvmBPuZejgoHK"; protected-headers="v1" From: Janosch Frank To: Sean Christopherson , James Hogan , Paul Mackerras , Christian Borntraeger , Paolo Bonzini , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , Marc Zyngier Cc: David Hildenbrand , Cornelia Huck , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Joerg Roedel , James Morse , Julien Thierry , Suzuki K Pouloze , linux-mips@vger.kernel.org, kvm-ppc@vger.kernel.org, kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu, linux-kernel@vger.kernel.org Message-ID: Subject: Re: [PATCH 04/13] KVM: Drop kvm_arch_create_memslot() References: <20190911185038.24341-1-sean.j.christopherson@intel.com> <20190911185038.24341-5-sean.j.christopherson@intel.com> In-Reply-To: <20190911185038.24341-5-sean.j.christopherson@intel.com> --UU4cv3zIJan03aUPjGzvFvmBPuZejgoHK Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 9/11/19 8:50 PM, Sean Christopherson wrote: > Remove kvm_arch_create_memslot() now that all arch implementations are > effectively nops. Explicitly free an allocated-but-unused dirty bitmap= > instead of relying on kvm_free_memslot() now that setting a memslot can= > no longer fail after arch code has allocated memory. In practice > this was already true, e.g. architectures that allocated memory via > kvm_arch_create_memslot() never failed kvm_arch_prepare_memory_region()= > and vice versa, but removing kvm_arch_create_memslot() eliminates the > potential for future code to stealthily change behavior. >=20 > Eliminating the error path's reliance on kvm_free_memslot() paves the > way for simplify kvm_free_memslot(), i.e. dropping its @dont param. >=20 > Signed-off-by: Sean Christopherson Please either split or adopt the patch title to include the freeing. I'd go for splitting. --UU4cv3zIJan03aUPjGzvFvmBPuZejgoHK-- --VFaGAeTCeRXorJeO4VEs9GCOZpf5lhFaI Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEwGNS88vfc9+v45Yq41TmuOI4ufgFAl16LJ0ACgkQ41TmuOI4 ufjw+RAAo+nTA45D/UJQFOtUY4vNWKZfGI7LFIZsBH6EvGMFdMDJOuJzlnd8qPAY jEb7EEQ6a8ypWQ+inQtsEQ27SX2+gsIP/nsrU54fhu32Wx9uX0y3wHRWPXOv346i Aqo8/NpulFkq1SSmQ/v2ikX1Bzqn/28FQ47hI21vbGt/Do97PUk8Mv1VUnKheMjJ hqq7m7CyFHAdbLFxwrhuKuPKblVyZVASaTJ7Z7xQ2wdmHaS9kpsedJlTAxD3ot/d o05LlRmLUIRH/u+yLEk+innoWRJuQ6gwVytMwEKer2kO+Yu8jsm9lXv52CYO7fZ9 B+pOzIfMaupMDGUBIsO93SZCvxZGELnzKoDjD9bZSOwFB/1wqrMpOvkTL28tRVrp Ia6ytDOW8shEzxv20xTK8bnFuPlPMwdm84GPpW/en/turzk/Ab7OQiKvVtpAHWLM CZsUdz4QEXeNeEjlZJesUcSnqsdviG/LCL7KqX8Ti6NDKI5g5rsu1bulD+7zQufB 4RbQd5jRQ77MDN+RRz2+8nUXThL0Pp67iMmOfhlvViBShiDuwiKpJ7qnVf+Vze1F VPzyxUAFaq7VFQn39tiQW3wnFfDLZzGg9kl9XPJDLoUeaqEiVpo4GiPvSnqebgsR MbM+Vn7FjJU4VeUxFONIoTmoBmHyK8SkMZgnHmOvesUCuOnPk9k= =oNBi -----END PGP SIGNATURE----- --VFaGAeTCeRXorJeO4VEs9GCOZpf5lhFaI--