From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 09AC8C433F5 for ; Fri, 18 Feb 2022 16:39:26 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 66B036B0074; Fri, 18 Feb 2022 11:39:26 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 61B1C6B0075; Fri, 18 Feb 2022 11:39:26 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4BA726B0078; Fri, 18 Feb 2022 11:39:26 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0040.hostedemail.com [216.40.44.40]) by kanga.kvack.org (Postfix) with ESMTP id 395516B0074 for ; Fri, 18 Feb 2022 11:39:26 -0500 (EST) Received: from smtpin27.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id E790F18105252 for ; Fri, 18 Feb 2022 16:39:25 +0000 (UTC) X-FDA: 79156461090.27.160E40D Received: from mail-lj1-f172.google.com (mail-lj1-f172.google.com [209.85.208.172]) by imf11.hostedemail.com (Postfix) with ESMTP id 6981240013 for ; Fri, 18 Feb 2022 16:39:25 +0000 (UTC) Received: by mail-lj1-f172.google.com with SMTP id n24so5108611ljj.10 for ; Fri, 18 Feb 2022 08:39:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=ZsaJ/52U7cZLmE6ctPyXK8XUe33/stjG8THMIu6wVGU=; b=RlQ/Wx7QFlwknPTQbVvjrxcl4E9RzQ2/VKYDGLGK3WW8txbJIsltBAIVTI5JcNwXK0 iC5zOzJsOU6rKE+QZ7O3I3HYWBGzvq/2tdD+IyWDNJpEg3GbHdCCabSJ/s/CR9YEZmHX byRKHpIwAmFwny9oi9nwOwjo0yVzfG8ECrC0xIvtON8BR5FzQvZgQXw+Y8IO7vrRrDxp fulBnbHk6nI1z+KEDQVYwuXz3vg9vvlMZuDBm60mvAHxVxmiHAaXVYsHREDOKWfDgkRP 4OX24fchdF5eAppQGXTXDOMF3lbC1N/HnbHVnsTHaGdfhLFiZ9EqJ8qVksLN/yzuOvyo QIRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=ZsaJ/52U7cZLmE6ctPyXK8XUe33/stjG8THMIu6wVGU=; b=2QmdwpAdiYas9/9CRu9+tYvIfnVyrblnNqX3BDZ358OChixEQ32irVKFHOAeBE23Mr VNJDuHd21GdOWf5A2WhUDBT4/RRB3sqjexVflRuTFmDq6ROUJyzTA1YGv+yH7rgoaLy0 NXACCubpgRW5p4n/lXTxooVmv39aSIz+jdofDkOoeN7KsRrvi6xrZCSzYlji01dsBjPk lD7IUH1i3nWESpf+43KGMhco3OZyvqBVxiuQ+iqAkjd6JLAJjt4Tz0cIQVei4kmJ3hLf lQcNyjK3+Y3NHSpC5HS1s7L1q89cYETgf27yIjzBRoo17F493eqJG55PkePXR0E0alWI OLKw== X-Gm-Message-State: AOAM532robasoBsbynwcRBIfEcfUTIJ+Uf+igKlRNOLxk/hWCXE3dd8c G/fCnN+DCD7+iTuaM3G1NoTpqrQSCl3yI1e+oyl+xw== X-Google-Smtp-Source: ABdhPJwk+ekDMb1/Vp1di+Fw3CVEgfEyZGbPeNiKh55+gY80alFolcT8I6MhKqljhmb9I5u8VpxFy8JukZM0L4u3+Nk= X-Received: by 2002:a2e:954:0:b0:241:73c:cb5e with SMTP id 81-20020a2e0954000000b00241073ccb5emr6619311ljj.86.1645202363662; Fri, 18 Feb 2022 08:39:23 -0800 (PST) MIME-Version: 1.0 References: <20220217094802.3644569-1-bigeasy@linutronix.de> <20220217094802.3644569-3-bigeasy@linutronix.de> In-Reply-To: <20220217094802.3644569-3-bigeasy@linutronix.de> From: Shakeel Butt Date: Fri, 18 Feb 2022 08:39:12 -0800 Message-ID: Subject: Re: [PATCH v3 2/5] mm/memcg: Disable threshold event handlers on PREEMPT_RT To: Sebastian Andrzej Siewior Cc: Cgroups , Linux MM , Andrew Morton , Johannes Weiner , Michal Hocko , =?UTF-8?Q?Michal_Koutn=C3=BD?= , Peter Zijlstra , Thomas Gleixner , Vladimir Davydov , Waiman Long , Roman Gushchin Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Stat-Signature: 6p5afunqfjtzhquqgsrqniybw1o37h88 X-Rspam-User: Authentication-Results: imf11.hostedemail.com; dkim=pass header.d=google.com header.s=20210112 header.b="RlQ/Wx7Q"; spf=pass (imf11.hostedemail.com: domain of shakeelb@google.com designates 209.85.208.172 as permitted sender) smtp.mailfrom=shakeelb@google.com; dmarc=pass (policy=reject) header.from=google.com X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: 6981240013 X-HE-Tag: 1645202365-810073 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu, Feb 17, 2022 at 1:48 AM Sebastian Andrzej Siewior wrote: > > During the integration of PREEMPT_RT support, the code flow around > memcg_check_events() resulted in `twisted code'. Moving the code around > and avoiding then would then lead to an additional local-irq-save > section within memcg_check_events(). While looking better, it adds a > local-irq-save section to code flow which is usually within an > local-irq-off block on non-PREEMPT_RT configurations. > > The threshold event handler is a deprecated memcg v1 feature. Instead of > trying to get it to work under PREEMPT_RT just disable it. There should > be no users on PREEMPT_RT. From that perspective it makes even less > sense to get it to work under PREEMPT_RT while having zero users. > > Make memory.soft_limit_in_bytes and cgroup.event_control return > -EOPNOTSUPP on PREEMPT_RT. Make an empty memcg_check_events() and > memcg_write_event_control() which return only -EOPNOTSUPP on PREEMPT_RT. > Document that the two knobs are disabled on PREEMPT_RT. > > Suggested-by: Michal Hocko > Suggested-by: Michal Koutn=C3=BD > Signed-off-by: Sebastian Andrzej Siewior > Acked-by: Roman Gushchin > Acked-by: Johannes Weiner Reviewed-by: Shakeel Butt