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 3018BC28CF5 for ; Wed, 26 Jan 2022 15:21:43 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C39766B0074; Wed, 26 Jan 2022 10:21:42 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id BC4256B0075; Wed, 26 Jan 2022 10:21:42 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id A8A0A6B0078; Wed, 26 Jan 2022 10:21:42 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0203.hostedemail.com [216.40.44.203]) by kanga.kvack.org (Postfix) with ESMTP id 9ADDF6B0074 for ; Wed, 26 Jan 2022 10:21:42 -0500 (EST) Received: from smtpin06.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 5BFB4181CA741 for ; Wed, 26 Jan 2022 15:21:42 +0000 (UTC) X-FDA: 79072802844.06.7C18036 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by imf22.hostedemail.com (Postfix) with ESMTP id D3CF0C000F for ; Wed, 26 Jan 2022 15:21:41 +0000 (UTC) Received: from relay2.suse.de (relay2.suse.de [149.44.160.134]) by smtp-out1.suse.de (Postfix) with ESMTP id CE19B21900; Wed, 26 Jan 2022 15:21:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1643210500; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=9sue3kCU/ER/IRMi/KZAJ26mZGkZjDDlVHexxnqqTGg=; b=dfLKbiy0WMK2IkpK8jhJ+IeLwjkBdRovBxvwdU1hq0H/lvUXIU92Iaqh36UeOnOZl5Hj9f z38jbCewLromjpSf/P2y+iPKzY2uRj5pNMQzEaHGc90LTjtukT252VDBW1MvsjVjwY25xD pUttU46/HhTLQDkj11tWZO2E4uWAT8M= Received: from suse.cz (unknown [10.100.201.86]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by relay2.suse.de (Postfix) with ESMTPS id B792DA3B88; Wed, 26 Jan 2022 15:21:40 +0000 (UTC) Date: Wed, 26 Jan 2022 16:21:40 +0100 From: Michal Hocko To: Sebastian Andrzej Siewior Cc: cgroups@vger.kernel.org, linux-mm@kvack.org, Andrew Morton , Johannes Weiner , Michal =?iso-8859-1?Q?Koutn=FD?= , Peter Zijlstra , Thomas Gleixner , Vladimir Davydov , Waiman Long Subject: Re: [PATCH 1/4] mm/memcg: Disable threshold event handlers on PREEMPT_RT Message-ID: References: <20220125164337.2071854-1-bigeasy@linutronix.de> <20220125164337.2071854-2-bigeasy@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: X-Rspamd-Server: rspam11 X-Rspamd-Queue-Id: D3CF0C000F X-Stat-Signature: 7p1bh8ng9i3qc1fk4oiq1nn7m1iozk6b Authentication-Results: imf22.hostedemail.com; dkim=pass header.d=suse.com header.s=susede1 header.b=dfLKbiy0; dmarc=pass (policy=quarantine) header.from=suse.com; spf=pass (imf22.hostedemail.com: domain of mhocko@suse.com designates 195.135.220.28 as permitted sender) smtp.mailfrom=mhocko@suse.com X-Rspam-User: nil X-HE-Tag: 1643210501-131450 Content-Transfer-Encoding: quoted-printable 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 Wed 26-01-22 15:45:20, Sebastian Andrzej Siewior wrote: > On 2022-01-26 15:40:54 [+0100], Michal Hocko wrote: > > I still support this approach but the patch is much larger than > > necessary. The code moving shouldn't be really necessary and a simple > > "do not allow" to set any thresholds or soft limit should be good > > enough.=20 > >=20 > > While in general it is better to disable the unreachable code I do no= t > > think this is worth the code churn here. >=20 > I got the "defined but not used" warnings by the compiler after I > disabled the two functions. Then I moved everything to one code block t= o > avoid the multiple ifdefs. > If that is not good, let me think of something else=E2=80=A6 If this is really needed then just split the patch into two. First to add the special RT handling and the other one to move the code without any other changes. --=20 Michal Hocko SUSE Labs