Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp201885ybz; Tue, 21 Apr 2020 07:29:51 -0700 (PDT) X-Google-Smtp-Source: APiQypJj8+a/oemx3I5xF2bSQDjzb5pSSWVE/veI1LniJdQQjwGcmfI+ZPpt51W+X/p3en+QgxK9 X-Received: by 2002:a17:906:18a1:: with SMTP id c1mr20754196ejf.344.1587479391602; Tue, 21 Apr 2020 07:29:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587479391; cv=none; d=google.com; s=arc-20160816; b=gUyKoPP9klMDk+Xpiyete/dl0c6TwgEfyfBLxmRgkPmIjF2DFy8aO3V/WZoGdrn265 LjBmUAIP43viiMecO2KTxCcmYawDhHA6eRoR12+loFiZ4Z0RISvFcgCKjCkl4wmK7uAp gmB/6AOv4rYnyEAAe1zr8WV5qmA7Y2msZjrRY9fnGisdxaLc517skhBDHoEnmySUGcfi tw5jk15f+1lLXOBEl9+gehQYDWWCfS8sTN9kDPRKAYvp+FK2Md1dHbFsRDncex1/BQAK P1QV30Ci2RbXo3Zrn8t7Xh1QKyjsQLCHESTQ8p6qPNSezIROzVuj7hlMHXnCqV8L/0/j bsxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:message-id:references :in-reply-to:subject:cc:to:from:date:content-transfer-encoding :mime-version:dkim-signature; bh=sRI276zESpueO/YyJN9Ank4FAvU/TM8Yohl4HkB9bGA=; b=gayJumjNuUMrn7/igHcFlGH7Hq3x7rAEXH545vPAfrjwUR/A7GiYM3eEhXmnZsKGyS p/j1fFHkuAz5ZiM2Iyzvqyv41CWWpFt7x+19T1/fdPdKXLqc4ZiXCgEupLP+eAjstOkl O6oqEGLCtdvxK/+R9KgMJEw6RfYSD1toOXCFjJWWynUlrXbtyO3zgRNnFC/P8XgWfP7J BBdMp8Egj3Ay5AR2GpmIOet3vWokxEnamuwbMc7jPCy1KbuktKOZN50JWf3zPqDV0Bfs g4U3MqDZ7qVAdytPtqtahfv5ygXIVkl9o07+vJDWqFjSbhtIy2xeO0QO2kjQnlACtqcu QOMg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="2Rks/Hcb"; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id gt7si1658263ejb.360.2020.04.21.07.29.24; Tue, 21 Apr 2020 07:29:51 -0700 (PDT) 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=@kernel.org header.s=default header.b="2Rks/Hcb"; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728576AbgDUO20 (ORCPT + 99 others); Tue, 21 Apr 2020 10:28:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:41314 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726628AbgDUO2Z (ORCPT ); Tue, 21 Apr 2020 10:28:25 -0400 Received: from disco-boy.misterjones.org (disco-boy.misterjones.org [51.254.78.96]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0EE732070B; Tue, 21 Apr 2020 14:28:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1587479305; bh=Xr2aHCVPREjxYqnUK45weJ1M8pScDICNbeHtjVJ7HW0=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=2Rks/Hcb8IQM75c8pfMxGWS5IZRVIKSpGk1wjdcLlVh3LTzjhpoATd1EmkhNx42Tr 7f3QJe2RuJRnD1RXTtH91re/zBQI/ujoZhqdQJnN+vK5xSqou1IxWGrSGi8SWu13qM 0m8a0DZmkN1cNv4UYDoWU1v//pyd9oIf1v4RsBlo= Received: from disco-boy.misterjones.org ([51.254.78.96] helo=www.loen.fr) by disco-boy.misterjones.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jQtst-005DDg-DF; Tue, 21 Apr 2020 15:28:23 +0100 MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Tue, 21 Apr 2020 15:28:23 +0100 From: Marc Zyngier To: Qais Yousef Cc: Valentin Schneider , Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Andrew Morton , Thomas Gleixner , Yury Norov , Paul Turner , Alexey Dobriyan , Josh Don , Pavan Kondeti , linux-kernel@vger.kernel.org, "Rafael J. Wysocki" Subject: Re: [PATCH 0/4] sched/rt: Distribute tasks in find_lowest_rq() In-Reply-To: <20200421142243.lea26mnmxnjpynlf@e107158-lin.cambridge.arm.com> References: <20200414150556.10920-1-qais.yousef@arm.com> <20200421121305.ziu3dfqwo7cw6ymu@e107158-lin.cambridge.arm.com> <20200421142243.lea26mnmxnjpynlf@e107158-lin.cambridge.arm.com> Message-ID: <1c21b8e7b08e6db7fb97dc46d1246d9a@kernel.org> X-Sender: maz@kernel.org User-Agent: Roundcube Webmail/1.3.10 X-SA-Exim-Connect-IP: 51.254.78.96 X-SA-Exim-Rcpt-To: qais.yousef@arm.com, valentin.schneider@arm.com, mingo@redhat.com, peterz@infradead.org, juri.lelli@redhat.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de, akpm@linux-foundation.org, tglx@linutronix.de, yury.norov@gmail.com, pjt@google.com, adobriyan@gmail.com, joshdon@google.com, pkondeti@codeaurora.org, linux-kernel@vger.kernel.org, rjw@rjwysocki.net X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020-04-21 15:22, Qais Yousef wrote: > On 04/21/20 15:09, Marc Zyngier wrote: >> On 2020-04-21 14:18, Valentin Schneider wrote: >> > On 21/04/20 13:13, Qais Yousef wrote: >> >> [...] >> >> > > I CCed Marc who's the maintainer of this file who can clarify better >> > > if this >> > > really breaks anything. >> > > >> > > If any interrupt expects to be affined to a specific CPU then this >> > > must be >> > > described in DT/driver. I think the GIC controller is free to >> > > distribute them >> > > to any cpu otherwise if !force. Which is usually done by >> > > irq_balancer anyway >> > > in userspace, IIUC. >> > > >> > > I don't see how cpumask_any_and() break anything here too. I >> > > actually think it >> > > improves on things by better distribute the irqs on the system by >> > > default. >> >> That's a pretty bold statement. Unfortunately, it isn't universally >> true. >> Some workload will be very happy with interrupts spread all over the >> map, >> and some others will suffer from it because, well, it interrupts >> userspace. >> >> > As you say, if someone wants smarter IRQ affinity they can do >> > irq_balancer >> > and whatnot. The default kernel policy for now has been to shove >> > everything >> > on the lowest-numbered CPU, and I see no valid reason to change that. >> >> Exactly. I would like to keep the kernel policy as simple as possible >> for >> non-managed interrupts (managed interrupts are another kettle of fish >> entirely). >> Userpace is in control to place things "intelligently", so let's not >> try and >> make the kernel smarter than it strictly needs to be. > > Fair enough. But why is it asking for cpumask_any() in the first place? Implementation detail. Turn it into cpumask_first_and() if you want. M. -- Jazz is not dead. It just smells funny...