Re: [PATCH v4 0/3] cgroup: New misc cgroup controller

2021-04-04 Thread Vipin Sharma
On Sun, Apr 4, 2021 at 10:35 AM Tejun Heo wrote: > > Applied to cgroup/for-5.13. If there are further issues, let's address them > incrementally. > > Thanks. > > -- > tejun Thanks Tejun for accepting and guiding through each version of this patch series.

[PATCH v4 3/3] svm/sev: Register SEV and SEV-ES ASIDs to the misc controller

2021-03-29 Thread Vipin Sharma
. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- arch/x86/kvm/svm/sev.c | 70 +++-- arch/x86/kvm/svm/svm.h | 1 + include/linux/misc_cgroup.h | 6 kernel/cgroup/misc.c| 6 4 files changed, 73 insertions(+), 10 deletions

[PATCH v4 1/3] cgroup: Add misc cgroup controller

2021-03-29 Thread Vipin Sharma
be set to max by:: # echo res_a max > misc.max Limits can be set more than the capacity value in the misc.capacity file. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- include/linux/cgroup_subsys.h | 4 + include/linux/misc_cgroup.h | 126 +++ init/K

[PATCH v4 2/3] cgroup: Miscellaneous cgroup documentation.

2021-03-29 Thread Vipin Sharma
Documentation of miscellaneous cgroup controller. This new controller is used to track and limit the usage of scalar resources. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- Documentation/admin-guide/cgroup-v1/index.rst | 1 + Documentation/admin-guide/cgroup-v1/misc.rst | 4

[PATCH v4 0/3] cgroup: New misc cgroup controller

2021-03-29 Thread Vipin Sharma
://lore.kernel.org/lkml/20210304231946.2766648-1-vipi...@google.com/ Vipin Sharma (3): cgroup: Add misc cgroup controller cgroup: Miscellaneous cgroup documentation. svm/sev: Register SEV and SEV-ES ASIDs to the misc controller Documentation/admin-guide/cgroup-v1/index.rst | 1 + Documentation/admin

Re: [Patch v3 1/2] cgroup: sev: Add misc cgroup controller

2021-03-24 Thread Vipin Sharma
On Wed, Mar 24, 2021 at 09:17:01AM -0700, Jacob Pan wrote: > I didn't mean the users of misc_cgroup will use css directly. I meant if I > want to use misc cgruop in ioasid.c, I have to do the following to avoid > undefined css: > #include > #include > > So it might be simpler if you do #include

Re: [Patch v3 1/2] cgroup: sev: Add misc cgroup controller

2021-03-22 Thread Vipin Sharma
On Fri, Mar 19, 2021 at 02:28:01PM -0700, Jacob Pan wrote: > On Thu, 4 Mar 2021 15:19:45 -0800, Vipin Sharma wrote: > > +#ifndef _MISC_CGROUP_H_ > > +#define _MISC_CGROUP_H_ > > + > nit: should you do #include ? > Otherwise, css may be undefined. User

Re: [Patch v3 0/2] cgroup: New misc cgroup controller

2021-03-22 Thread Vipin Sharma
On Mon, Mar 15, 2021 at 08:10:09PM +0100, Michal Koutný wrote: > On Fri, Mar 12, 2021 at 09:49:26AM -0800, Vipin Sharma > wrote: > > I will add some more information in the cover letter of the next version. > Thanks. > > > Each one coming up with their own interacti

Re: [RFC v2 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-03-12 Thread Vipin Sharma
gt; Hello, > > > > On Wed, Mar 03, 2021 at 10:22:03PM -0800, Vipin Sharma wrote: > > > > I am trying to see if IOASIDs cgroup can also fit in this misc > > > > controller as yet another resource type. > > > > https://lore.kernel.org/linux-iommu/2021030

Re: [Patch v3 1/2] cgroup: sev: Add misc cgroup controller

2021-03-12 Thread Vipin Sharma
On Thu, Mar 11, 2021 at 07:59:03PM +0100, Michal Koutný wrote: > > +#ifndef CONFIG_KVM_AMD_SEV > > +/* > > + * When this config is not defined, SEV feature is not supported and APIs > > in > > + * this file are not used but this file still gets compiled into the KVM > > AMD > > + * module. > > +

Re: [Patch v3 1/2] cgroup: sev: Add misc cgroup controller

2021-03-12 Thread Vipin Sharma
On Thu, Mar 11, 2021 at 07:59:03PM +0100, Michal Koutný wrote: > Given different two-fold nature (SEV caller vs misc controller) of some > remarks below, I think it makes sense to split this into two patches: > a) generic controller implementation, > b) hooking the controller into SEV ASIDs managem

Re: [Patch v3 0/2] cgroup: New misc cgroup controller

2021-03-12 Thread Vipin Sharma
On Thu, Mar 11, 2021 at 07:58:19PM +0100, Michal Koutný wrote: > I admit, I didn't follow the past dicussions completely, however, > (Vipin) could it be in the cover letter/commit messages shortly > summarized why cgroups and a controller were chosen to implement > restrictions of these resources,

[Patch v3 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-03-04 Thread Vipin Sharma
Documentation of miscellaneous cgroup controller. This new controller is used to track and limit the usage of scalar resources. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- Documentation/admin-guide/cgroup-v1/index.rst | 1 + Documentation/admin-guide/cgroup-v1/misc.rst | 4

[Patch v3 1/2] cgroup: sev: Add misc cgroup controller

2021-03-04 Thread Vipin Sharma
by:: # echo sev 1 > misc.max Limit can be set to max by:: # echo sev max > misc.max Limits can be set more than the capacity value in the misc.capacity file. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- arch/x86/kvm/svm/sev.c| 65 +-

[Patch v3 0/2] cgroup: New misc cgroup controller

2021-03-04 Thread Vipin Sharma
messages. 3. Changed charge API to treat misc_cg as input parameter. 4. Added helper APIs to get and release references on the cgroup. [1] https://lore.kernel.org/lkml/20210218195549.1696769-1-vipi...@google.com [2] https://lore.kernel.org/lkml/20210302081705.1990283-1-vipi...@google.com/ Vipin

Re: [RFC v2 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-03-03 Thread Vipin Sharma
On Wed, Mar 03, 2021 at 06:55:13PM -0800, Jacob Pan wrote: > Hi Vipin, > > On Tue, 2 Mar 2021 00:17:05 -0800, Vipin Sharma wrote: > > > +Migration and Ownership > > +~~~ > > + > > +A miscellaneous scalar resource is charged to the cgroup

Re: [RFC v2 1/2] cgroup: sev: Add misc cgroup controller

2021-03-03 Thread Vipin Sharma
On Wed, Mar 03, 2021 at 10:42:37AM -0500, Tejun Heo wrote: > > + atomic_t usage; > > +}; > > Can we do 64bits so that something which counts memory can use this too? > Sure. > > + > > + if (usage > capacity) > > + return -EBUSY; > > I'd rather go with allowing brin

[RFC v2 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-03-02 Thread Vipin Sharma
Documentation of miscellaneous cgroup controller. This new controller is used to track and limit the usage of scalar resources. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- Documentation/admin-guide/cgroup-v1/index.rst | 1 + Documentation/admin-guide/cgroup-v1/misc.rst | 4

[RFC v2 1/2] cgroup: sev: Add misc cgroup controller

2021-03-02 Thread Vipin Sharma
by:: # echo sev 1 > misc.max Limit can be set to max by:: # echo sev max > misc.max Limits can be set more than the capacity value in the misc.capacity file. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- arch/x86/kvm/svm/sev.c| 65 +-

[RFC v2 0/2] cgroup: New misc cgroup controller

2021-03-02 Thread Vipin Sharma
/20210218195549.1696769-1-vipi...@google.com Vipin Sharma (2): cgroup: sev: Add misc cgroup controller cgroup: sev: Miscellaneous cgroup documentation. Documentation/admin-guide/cgroup-v1/index.rst | 1 + Documentation/admin-guide/cgroup-v1/misc.rst | 4 + Documentation/admin-guide/cgroup-v2.rst

Re: [RFC 1/2] cgroup: sev: Add misc cgroup controller

2021-02-25 Thread Vipin Sharma
On Thu, Feb 25, 2021 at 10:52:49AM +0100, Michal Koutný wrote: > On Wed, Feb 24, 2021 at 08:57:36PM -0800, Vipin Sharma > wrote: > > This function is meant for hot unplug functionality too. > Then I'm wondering if the current form is sufficient, i.e. the generic > controll

Re: [RFC 1/2] cgroup: sev: Add misc cgroup controller

2021-02-24 Thread Vipin Sharma
On Tue, Feb 23, 2021 at 07:24:55PM +0100, Michal Koutný wrote: > On Thu, Feb 18, 2021 at 11:55:48AM -0800, Vipin Sharma > wrote: > > --- a/arch/x86/kvm/svm/sev.c > > +++ b/arch/x86/kvm/svm/sev.c > > [...] > > +#ifndef CONFIG_KVM_AMD_SEV > > +/* > >

Re: [RFC 0/2] cgroup: New misc cgroup controller

2021-02-24 Thread Vipin Sharma
On Tue, Feb 23, 2021 at 07:24:33PM +0100, Michal Koutný wrote: > Hello. > > On Thu, Feb 18, 2021 at 11:55:47AM -0800, Vipin Sharma > wrote: > > This patch is creating a new misc cgroup controller for allocation and > > tracking of resources which are not ab

Re: [RFC 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-02-24 Thread Vipin Sharma
On Fri, Feb 19, 2021 at 11:02:41AM -0800, Randy Dunlap wrote: > > +++ b/Documentation/admin-guide/cgroup-v1/misc.rst > > @@ -0,0 +1 @@ > > +/Documentation/admin-guide/cgroup-v2.rst > What is the purpose of this (above) file? This new controller has both cgroup v1 and v2 support. Tejun suggested if

[RFC 2/2] cgroup: sev: Miscellaneous cgroup documentation.

2021-02-18 Thread Vipin Sharma
Documentation of miscellaneous cgroup controller. This new controller is used to track and limit usage of scalar resources. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- Documentation/admin-guide/cgroup-v1/misc.rst | 1 + Documentation/admin-guide/cgroup-v2.rst | 64

[RFC 1/2] cgroup: sev: Add misc cgroup controller

2021-02-18 Thread Vipin Sharma
:: # echo sev 1 > misc.max Limit can be set to max by:: # echo sev max > misc.max Limits can be set more than the capacity value in the misc.capacity file. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes --- arch/x86/kvm/svm/sev.c| 60 - arch/x

[RFC 0/2] cgroup: New misc cgroup controller

2021-02-18 Thread Vipin Sharma
hanks Vipin Sharma (2): cgroup: sev: Add misc cgroup controller cgroup: sev: Miscellaneous cgroup documentation. Documentation/admin-guide/cgroup-v1/misc.rst | 1 + Documentation/admin-guide/cgroup-v2.rst | 64 ++- arch/x86/kvm/svm/sev.c | 60 ++- arch/x86/kv

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-26 Thread Vipin Sharma
On Tue, Jan 26, 2021 at 05:01:04PM -0500, Tejun Heo wrote: > The whole thing seems pretty immature to me and I agree with you that coming > up with an abstraction at this stage feels risky. > > I'm leaning towards creating a misc controller to shove these things into: > > * misc.max and misc.curr

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-21 Thread Vipin Sharma
On Wed, Jan 20, 2021 at 06:32:56PM -0500, Tejun Heo wrote: > I don't know how many times I have to repeat the same point to get it > across. For any question about actual abstraction, you haven't provided any > kind of actual research or analysis and just keep pushing the same thing > over and over

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-20 Thread Vipin Sharma
On Wed, Jan 20, 2021 at 11:40:18AM -0500, Tejun Heo wrote: > Hello, > > On Tue, Jan 19, 2021 at 11:13:51PM -0800, Vipin Sharma wrote: > > > Can you please elaborate? I skimmed through the amd manual and it seemed > > > to > > > say that SEV-ES ASIDs are super

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-19 Thread Vipin Sharma
On Tue, Jan 19, 2021 at 10:51:24AM -0500, Tejun Heo wrote: > Hello, > > On Fri, Jan 15, 2021 at 08:32:19PM -0800, Vipin Sharma wrote: > > SEV-ES has stronger memory encryption gurantees compared to SEV, apart > > from encrypting the application memory it also encrypts reg

Re: [Patch v5 2/2] cgroup: svm: Encryption IDs cgroup documentation.

2021-01-19 Thread Vipin Sharma
On Mon, Jan 18, 2021 at 9:55 AM Randy Dunlap wrote: > > On 1/15/21 6:32 PM, Vipin Sharma wrote: > > Documentation of Encryption IDs controller. This new controller is used > > to track and limit usage of hardware memory encryption capabilities on > > the CPUs. > > &

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-15 Thread Vipin Sharma
On Fri, Jan 15, 2021 at 10:43:32PM -0500, Tejun Heo wrote: > On Fri, Jan 15, 2021 at 02:18:40PM -0800, Vipin Sharma wrote: > > > * Why is .sev a separate namespace? Isn't the controller supposed to cover > > > encryption ids across different implementations? It's

[Patch v5 2/2] cgroup: svm: Encryption IDs cgroup documentation.

2021-01-15 Thread Vipin Sharma
Documentation of Encryption IDs controller. This new controller is used to track and limit usage of hardware memory encryption capabilities on the CPUs. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- .../admin-guide/cgroup-v1/encryption_ids.rst | 1

[Patch v5 1/2] cgroup: svm: Add Encryption ID controller

2021-01-15 Thread Vipin Sharma
f --git a/include/linux/encryption_ids_cgroup.h b/include/linux/encryption_ids_cgroup.h new file mode 100644 index ..af428a4beb28 --- /dev/null +++ b/include/linux/encryption_ids_cgroup.h @@ -0,0 +1,72 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Encryption IDs cgroup controller. + * +

[Patch v5 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2021-01-15 Thread Vipin Sharma
rent [1] https://lore.kernel.org/lkml/20200922004024.3699923-1-vipi...@google.com/ [2] https://lore.kernel.org/lkml/20201208213531.2626955-1-vipi...@google.com/ [3] https://lore.kernel.org/lkml/20201209205413.3391139-1-vipi...@google.com/ [4] https://lore.kernel.org/lkml/20210108012846.4134815-1-vipi...@google.com

Re: [Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-15 Thread Vipin Sharma
On Fri, Jan 15, 2021 at 03:59:25PM -0500, Tejun Heo wrote: > Hello, > > On Thu, Jan 07, 2021 at 05:28:45PM -0800, Vipin Sharma wrote: > > 1. encrpytion_ids.sev.max > > Sets the maximum usage of SEV IDs in the cgroup. > > 2. encryption_ids.sev.current > >

Re: [Patch v4 2/2] cgroup: svm: Encryption IDs cgroup documentation.

2021-01-15 Thread Vipin Sharma
On Fri, Jan 15, 2021 at 04:00:26PM -0500, Tejun Heo wrote: > On Thu, Jan 07, 2021 at 05:28:46PM -0800, Vipin Sharma wrote: > > Documentation for both cgroup versions, v1 and v2, of Encryption IDs > > controller. This new controller is used to track and limit usage of > > hardw

[Patch v4 1/2] cgroup: svm: Add Encryption ID controller

2021-01-07 Thread Vipin Sharma
. Other ID types can be easily added in the controller in the same way. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- arch/x86/kvm/svm/sev.c| 52 +++- include/linux/cgroup_subsys.h | 4 + include/linux/encryption_ids_cgroup.h

[Patch v4 2/2] cgroup: svm: Encryption IDs cgroup documentation.

2021-01-07 Thread Vipin Sharma
Documentation for both cgroup versions, v1 and v2, of Encryption IDs controller. This new controller is used to track and limit usage of hardware memory encryption capabilities on the CPUs. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- .../admin-guide

[Patch v4 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2021-01-07 Thread Vipin Sharma
.com/ [3] https://lore.kernel.org/lkml/20201209205413.3391139-1-vipi...@google.com/ Vipin Sharma (2): cgroup: svm: Add Encryption ID controller cgroup: svm: Encryption IDs cgroup documentation. .../admin-guide/cgroup-v1/encryption_ids.rst | 108 + Documentation/admin-guide/cgroup-v2.

Re: [Patch v3 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2021-01-06 Thread Vipin Sharma
On Tue, Jan 05, 2021 at 10:36:40AM -0500, Tejun Heo wrote: > Happy new year! > > On Wed, Dec 16, 2020 at 12:02:37PM -0800, Vipin Sharma wrote: > > I like the idea of having a separate controller to keep the code simple and > > easier for maintenance. > > Yeah, the mor

Re: [Patch v3 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2020-12-16 Thread Vipin Sharma
On Wed, Dec 9, 2020 at 12:59 PM Tejun Heo wrote: > * I don't have an overall objection. In terms of behavior, the only thing > which stood out was input rejection depending on the current usage. The > preferred way of handling that is rejecting future allocations rather than > failing config

[Patch v3 2/2] cgroup: svm: Encryption IDs cgroup documentation.

2020-12-09 Thread Vipin Sharma
Documentation for both cgroup versions, v1 and v2, of Encryption IDs controller. This new controller is used to track and limit usage of hardware memory encryption capabilities on the CPUs. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- .../admin-guide

[Patch v3 1/2] cgroup: svm: Add Encryption ID controller

2020-12-09 Thread Vipin Sharma
. Other ID types can be easily added in the controller in the same way. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze Reported-by: kernel test robot --- arch/x86/kvm/svm/sev.c| 28 +- include/linux/cgroup_subsys.h | 4 + include

[Patch v3 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2020-12-09 Thread Vipin Sharma
ion_ids.sev.max - encryption_ids.sev.current Thanks Vipin Sharma [1] https://lore.kernel.org/lkml/20200922004024.3699923-1-vipi...@google.com/#r [2] https://lore.kernel.org/lkml/20201208213531.2626955-1-vipi...@google.com/ .../admin-guide/cgroup-v1/encryption_ids.rst | 108 + Documentat

Re: [Patch v2 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2020-12-09 Thread Vipin Sharma
On Tue, Dec 08, 2020 at 01:35:29PM -0800, Vipin Sharma wrote: > Hello, > > This patch adds a new cgroup controller, Encryption IDs, to track and > limit the usage of encryption IDs on a host. > > AMD provides Secure Encrypted Virtualization (SEV) and SEV with > Encryp

[Patch v2 2/2] cgroup: SVM: Encryption IDs cgroup documentation.

2020-12-08 Thread Vipin Sharma
Documentation for both cgroup versions, v1 and v2, of Encryption IDs controller. This new controller is used to track and limit usage of hardware memory encryption capabilities on the CPUs. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- .../admin-guide

[Patch v2 1/2] cgroup: SVM: Add Encryption ID controller

2020-12-08 Thread Vipin Sharma
. Other ID types can be easily added in the controller in the same way. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze --- arch/x86/kvm/svm/sev.c| 28 +- include/linux/cgroup_subsys.h | 4 + include/linux/encryption_ids_cgroup.h | 70

[Patch v2 0/2] cgroup: KVM: New Encryption IDs cgroup controller

2020-12-08 Thread Vipin Sharma
- Replaced SEV specific names in APIs and documentations with generic encryption IDs. - Providing 3 cgroup files per encryption ID type. For example in SEV, - encryption_ids.sev.stat (only in the root cgroup directory). - encryption_ids.sev.max - encryption_ids.sev.current Thanks Vipin Sh

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-11-24 Thread Vipin Sharma
On Tue, Nov 24, 2020 at 09:27:25PM +, Sean Christopherson wrote: > On Tue, Nov 24, 2020, Vipin Sharma wrote: > > On Tue, Nov 24, 2020 at 12:18:45PM -0800, David Rientjes wrote: > > > On Tue, 24 Nov 2020, Vipin Sharma wrote: > > > > > > > > > Loopi

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-11-24 Thread Vipin Sharma
On Tue, Nov 24, 2020 at 12:18:45PM -0800, David Rientjes wrote: > On Tue, 24 Nov 2020, Vipin Sharma wrote: > > > > > Looping Janosch and Christian ba

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-11-24 Thread Vipin Sharma
ean Christopherson wrote: > > > > > > > > > On Fri, Oct 02, 2020 at 01:48:10PM -0700, Vipin Sharma wrote: > > > > >

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-10-02 Thread Vipin Sharma
On Fri, Sep 25, 2020 at 03:22:20PM -0700, Vipin Sharma wrote: > On Thu, Sep 24, 2020 at 02:55:18PM -0500, Tom Lendacky wrote: > > On 9/24/20 2:21 PM, Sean Christopherson wrote: > > > On Tue, Sep 22, 2020 at 02:14:04PM -0700, Vipin Sharma wrote: > > > > On Mon, Se

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-09-25 Thread Vipin Sharma
On Thu, Sep 24, 2020 at 02:55:18PM -0500, Tom Lendacky wrote: > On 9/24/20 2:21 PM, Sean Christopherson wrote: > > On Tue, Sep 22, 2020 at 02:14:04PM -0700, Vipin Sharma wrote: > > > On Mon, Sep 21, 2020 at 06:48:38PM -0700, Sean Christopherson wrote: > > > > On M

Re: [RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-09-22 Thread Vipin Sharma
On Mon, Sep 21, 2020 at 06:48:38PM -0700, Sean Christopherson wrote: > On Mon, Sep 21, 2020 at 05:40:22PM -0700, Vipin Sharma wrote: > > Hello, > > > > This patch series adds a new SEV controller for tracking and limiting > > the usage of SEV ASIDs on the AMD SVM platf

Re: [RFC Patch 1/2] KVM: SVM: Create SEV cgroup controller.

2020-09-22 Thread Vipin Sharma
On Mon, Sep 21, 2020 at 06:22:28PM -0700, Sean Christopherson wrote: > On Mon, Sep 21, 2020 at 06:04:04PM -0700, Randy Dunlap wrote: > > Hi, > > > > On 9/21/20 5:40 PM, Vipin Sharma wrote: > > > diff --git a/init/Kconfig b/init/Kconfig > > > index d6a0b3

[RFC Patch 1/2] KVM: SVM: Create SEV cgroup controller.

2020-09-21 Thread Vipin Sharma
pping when the cgroup is deleted. Mapping array is freed when kvm-amd module is unloaded. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze Reviewed-by: Erdem Aktas --- arch/x86/kvm/Makefile | 1 + arch/x86/kvm/svm/sev.c| 16 +- arch/x86/kv

[RFC Patch 0/2] KVM: SVM: Cgroup support for SVM SEV ASIDs

2020-09-21 Thread Vipin Sharma
both cgroup v1 and v2. Thanks Vipin Sharma (2): KVM: SVM: Create SEV cgroup controller. KVM: SVM: SEV cgroup controller documentation Documentation/admin-guide/cgroup-v1/sev.rst | 94 + Documentation/admin-guide/cgroup-v2.rst | 56 ++- arch/x86/kvm/Makefile

[RFC Patch 2/2] KVM: SVM: SEV cgroup controller documentation

2020-09-21 Thread Vipin Sharma
SEV cgroup controller documentation. Documentation for both cgroup versions, v1 and v2, of SEV cgroup controller. SEV controller is used to distribute and account SEV ASIDs usage by KVM on AMD processor. Signed-off-by: Vipin Sharma Reviewed-by: David Rientjes Reviewed-by: Dionna Glaze