Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp945011pxb; Wed, 3 Mar 2021 22:02:47 -0800 (PST) X-Google-Smtp-Source: ABdhPJxQ+fXKtzwENz6xvn9l67QbRMikPdQHxudIA0bdRtKqy0nWZOquksodZf9ukdK6U/MTl8HD X-Received: by 2002:a50:fe17:: with SMTP id f23mr2668734edt.258.1614837767008; Wed, 03 Mar 2021 22:02:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614837767; cv=none; d=google.com; s=arc-20160816; b=EKGeahRhMVYqYOdKqr1Uf2DwYXmwGdHLognJuBCVK+A3CjFhXQIfaMiZdgTjkwhuPf vqEJEXXbF53sI1UlbpV9H/oRiuZyCpXHvDwJc7xZ+A+XvkqN9eRpeyLmOp1zRRO/fbQ8 4bfkb9ziOx2v3fYee8lU6cPzICqlHw+71JtxKFvwFXU0ybILycSevs9eKKyryjCe0Sdw KG6P7O/F6IhgUcz31TfQoxcUpzLGRSm6NH+sZ7jqlfUGEngZ8vZtXU87TN96fQPwGXZI etyNGq6dFlBEJS9ETKjR0Sjr3R0xGvOn+DCUnt2RrBNqVkO8U833zCVw3oa3pCQ+qKNT DKkg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:from:subject:references:mime-version :message-id:in-reply-to:date:sender:dkim-signature; bh=9IvSzdbIQqhRyiLJGvOnZfh3hjug63Y1v74jXsaZzZ4=; b=MF2rdvn0tpGSyys82hv1pgKZVWCnxpbZS27t7COe84kO7s3+ZRmOIj/g9GSnC+i8WA Bfk/SaKPj20kdp5RapFwEWag36vvlPa4CCBB1/Hb+z4l0PaM9KPJfMmGlwpcvUDS1SRD ccmj/oZTUde6PId2gZj/67CoZSO+9jE+EHjK/Nl267UWZd7ZdoPi5CBn8ggU8uc0gSZm n3VgAexlXO2Nn2JiYOIW59jn2yVFyvXZuziulDzo/39FrwxyfnGx726eR/C9NCioy1Ei 8Ak2NqscOpvoO/6GC2n1Sm9vR92W9Avsj1aIL5N55Mf501b+WBS939cmb8ibI6FAS8Uw L7Nw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=vjq0i7ut; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q19si15644861edv.67.2021.03.03.22.02.24; Wed, 03 Mar 2021 22:02:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=vjq0i7ut; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1837633AbhCBIdW (ORCPT + 99 others); Tue, 2 Mar 2021 03:33:22 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42702 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377357AbhCBISv (ORCPT ); Tue, 2 Mar 2021 03:18:51 -0500 Received: from mail-pl1-x649.google.com (mail-pl1-x649.google.com [IPv6:2607:f8b0:4864:20::649]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A9035C06121E for ; Tue, 2 Mar 2021 00:17:18 -0800 (PST) Received: by mail-pl1-x649.google.com with SMTP id d19so10849577plr.9 for ; Tue, 02 Mar 2021 00:17:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=sender:date:in-reply-to:message-id:mime-version:references:subject :from:to:cc; bh=9IvSzdbIQqhRyiLJGvOnZfh3hjug63Y1v74jXsaZzZ4=; b=vjq0i7utFQfq/ROgloM8fVCwD3GgQjSjJzxE39PPfoolW/2BTnmUwVxfnbfg/xE8xf nurEyFcMwK9nSlqkfz+TWWrBExl5stjBN3maC6gC31KMD3tBteKgPHUq12s7UUgkwI9M vp0ePmNo9Ra+e+AbeLvDNxW6QBHsadhycldlmZuWH02z7uHsyD1QYqllyYU3eT01p+fk N2vJPKSArl7dvqr7FyBPla3CszX6Ce2ByDzrrm12jXWuSi0kZ2yktEAiVYRWZrBI7lA/ KBQ/BHPJUdBBRMuJLk+UJD/X8LruP9bdJ6Fiw9PV3Pmud28l2jlck5kQNw4n2qMFnBC6 lbqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=9IvSzdbIQqhRyiLJGvOnZfh3hjug63Y1v74jXsaZzZ4=; b=H5xo520YHf+anUCbN0hsQGM54Ro7yJ2O2iR5n0e3pRiOS0fQ6Zvq7ZjwClhIPZVok+ sFVf6W82zOPnNdQ9Jjp/EhBQRdZvBGFaylTL+zLvpxC8lV2aPnbu2UijMAE8T2pZwlZB p4OoLaAkj2Eqs32ml6YfaBYi5CMP9lUpD8fcHGI8h5Pm5TkQAMV3A9dwZ3iNI/xBgi33 i0mhqMQ64vzgFnp1uYwG35V9S9vjWTNCAytlauGZ03dQ+U4z7Sihnk3wvCwZwoGsz2Dv sQfeIP+uuX2EyAKUYhc/z1rayhlxpCK50OawkCWx84D5wIOLjM3g1Rl+sQdJ7mnHyq64 XgtQ== X-Gm-Message-State: AOAM533jsoGSrygoETYiIDwBDFliwE8cPRDkeJIlFjeA9NFuK2dwke4n vmqa0lOLy66+QylpGmZeLV2Tt2pfFoZy Sender: "vipinsh via sendgmr" X-Received: from vipinsh.kir.corp.google.com ([2620:0:1008:10:e829:dc2a:968a:1370]) (user=vipinsh job=sendgmr) by 2002:a05:6a00:23c5:b029:1e6:2f2e:a438 with SMTP id g5-20020a056a0023c5b02901e62f2ea438mr19154226pfc.75.1614673038114; Tue, 02 Mar 2021 00:17:18 -0800 (PST) Date: Tue, 2 Mar 2021 00:17:05 -0800 In-Reply-To: <20210302081705.1990283-1-vipinsh@google.com> Message-Id: <20210302081705.1990283-3-vipinsh@google.com> Mime-Version: 1.0 References: <20210302081705.1990283-1-vipinsh@google.com> X-Mailer: git-send-email 2.30.1.766.gb4fecdf3b7-goog Subject: [RFC v2 2/2] cgroup: sev: Miscellaneous cgroup documentation. From: Vipin Sharma To: tj@kernel.org, mkoutny@suse.com, rdunlap@infradead.org, thomas.lendacky@amd.com, brijesh.singh@amd.com, jon.grimm@amd.com, eric.vantassell@amd.com, pbonzini@redhat.com, hannes@cmpxchg.org, frankja@linux.ibm.com, borntraeger@de.ibm.com Cc: corbet@lwn.net, seanjc@google.com, vkuznets@redhat.com, wanpengli@tencent.com, jmattson@google.com, joro@8bytes.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, hpa@zytor.com, gingell@google.com, rientjes@google.com, dionnaglaze@google.com, kvm@vger.kernel.org, x86@kernel.org, cgroups@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, Vipin Sharma Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 ++ Documentation/admin-guide/cgroup-v2.rst | 69 ++++++++++++++++++- 3 files changed, 72 insertions(+), 2 deletions(-) create mode 100644 Documentation/admin-guide/cgroup-v1/misc.rst diff --git a/Documentation/admin-guide/cgroup-v1/index.rst b/Documentation/admin-guide/cgroup-v1/index.rst index 226f64473e8e..99fbc8a64ba9 100644 --- a/Documentation/admin-guide/cgroup-v1/index.rst +++ b/Documentation/admin-guide/cgroup-v1/index.rst @@ -17,6 +17,7 @@ Control Groups version 1 hugetlb memcg_test memory + misc net_cls net_prio pids diff --git a/Documentation/admin-guide/cgroup-v1/misc.rst b/Documentation/admin-guide/cgroup-v1/misc.rst new file mode 100644 index 000000000000..661614c24df3 --- /dev/null +++ b/Documentation/admin-guide/cgroup-v1/misc.rst @@ -0,0 +1,4 @@ +=============== +Misc controller +=============== +Please refer "Misc" documentation in Documentation/admin-guide/cgroup-v2.rst diff --git a/Documentation/admin-guide/cgroup-v2.rst b/Documentation/admin-guide/cgroup-v2.rst index 1de8695c264b..74777323b7fd 100644 --- a/Documentation/admin-guide/cgroup-v2.rst +++ b/Documentation/admin-guide/cgroup-v2.rst @@ -63,8 +63,11 @@ v1 is available under :ref:`Documentation/admin-guide/cgroup-v1/index.rst misc.max + + Limit can be set to max by:: + + # echo sev max > misc.max + + Limits can be set higher than the capacity value in the misc.capacity + file. + +Migration and Ownership +~~~~~~~~~~~~~~~~~~~~~~~ + +A miscellaneous scalar resource is charged to the cgroup in which it is used +first, and stays charged to that cgroup until that resource is freed. Migrating +a process to a different cgroup does not move the charge to the destination +cgroup where the process has moved. + +Others +------ + perf_event ~~~~~~~~~~ -- 2.30.1.766.gb4fecdf3b7-goog