Received: by 2002:a17:90a:1609:0:0:0:0 with SMTP id n9csp2112033pja; Thu, 26 Mar 2020 09:52:33 -0700 (PDT) X-Google-Smtp-Source: ADFU+vsQhJzuZNxWshoiyPPUgXhkaBXzZL2pjZyq5TANu/WyecJDyoZTEXEDZZNNuTZ/qRvtHWFp X-Received: by 2002:a4a:d88b:: with SMTP id b11mr1723419oov.42.1585241553026; Thu, 26 Mar 2020 09:52:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585241553; cv=none; d=google.com; s=arc-20160816; b=U1q+b85Y+qmxG1IbOK4Ci5LQnxwwKoHLASqHAEbIvsuKpDVNevQJ8mBykY2/yDa2mY PGzu0iqTh1Ll8L9Z4WHJkVipb9U1KdLmqp7FqtHfMiEOYMqdS0zTCeMKEEp13hyRKwe7 JbeIwr5YsrnDYunvR1lThMybb/u22JY5tqt/pBvS/CaWh34+bJMxWhdOAoclQJvw6GT2 uVrz6Lmx1MYqwSF3PCUhYAhzDniAToR6n4BGzV42sWINXV1F8sM7QkmPK8orsgIuOPAp SAD49eCqETs/DZq/fS9KouAbG30MKjEe8r8OVn1VzGAYRFzDo8yvn/TLzSPY+RXvoJxv u+Ig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=wMj7d8pJB8FFWCU/yPv8ultCQD2c+N6ke4Ca+PIKlDM=; b=NHdkuBKMXkDUVfhXxs9tt69TdeWwtdD86fYQ+WpovYFobNx+qjmWM8/C8W5HTD7q6s AXmwwv9eeQVy+BF/VGKitKxGt12WgJsuDxziUjRLtMVijEL+L32tT0pC/WBfTQhhkdZG t0r2kZaGAG9S3Tz8kfMJgL3Sloq8mqLk+g3EGdgfsgyFCAwuiV5IgmhphTZQD04WDhE+ tlk80+WsbhjtZOGDpzKS+arHLuiQCjkdPQGM8N7YhxxtVU90NeENmokxUc64dBE69gY3 kwalacXP8y9z7f6ZkI85OVgK4PgwymQBO+AFAsM9EXZ90hxpiB7JeYs5s4SaK36rdGmP QWHw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Kp3hy16T; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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. [209.132.180.67]) by mx.google.com with ESMTP id x5si1091623ooj.75.2020.03.26.09.52.15; Thu, 26 Mar 2020 09:52:33 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Kp3hy16T; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 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 S1727751AbgCZQvc (ORCPT + 99 others); Thu, 26 Mar 2020 12:51:32 -0400 Received: from mail.kernel.org ([198.145.29.99]:57110 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727502AbgCZQvc (ORCPT ); Thu, 26 Mar 2020 12:51:32 -0400 Received: from localhost (lfbn-ncy-1-985-231.w90-101.abo.wanadoo.fr [90.101.63.231]) (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 1FDAB20719; Thu, 26 Mar 2020 16:51:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585241491; bh=WRS7dXwEeofqJh7HUcKH/2tDA/tCPxCJVqOGqM+0NQQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Kp3hy16TFHznlAeKnaobd1Y08K1gbPVGHur/Nv9M5JC9ge6ysBemLbDaB2jAPG+Yf w/WgqYDw0DSqL/+ZjDaB0Fnj2ufI4IVwvF4E1AKJN//lDplUWn9a72NflZ0g/IYaIU JTOG8rscVX0+sxjV5TUoTX073IDjHDjOBq60h4Yo= Date: Thu, 26 Mar 2020 17:51:29 +0100 From: Frederic Weisbecker To: Chris Friesen Cc: David Laight , 'Marcelo Tosatti' , Thomas Gleixner , "linux-kernel@vger.kernel.org" , Christoph Lameter , Jim Somerville , Andrew Morton , Frederic Weisbecker , Peter Zijlstra Subject: Re: [PATCH v2] isolcpus: affine kernel threads to specified cpumask Message-ID: <20200326165128.GC3946@lenoir> References: <20200323135414.GA28634@fuller.cnet> <87k13boxcn.fsf@nanos.tec.linutronix.de> <87imiuq0cg.fsf@nanos.tec.linutronix.de> <20200324152016.GA25422@fuller.cnet> <20200326162218.GB3946@lenoir> <76fa0270-40c5-aac7-1c53-38384fa3467d@windriver.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <76fa0270-40c5-aac7-1c53-38384fa3467d@windriver.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 26, 2020 at 10:32:51AM -0600, Chris Friesen wrote: > On 3/26/2020 10:22 AM, Frederic Weisbecker wrote: > > On Wed, Mar 25, 2020 at 06:05:27PM +0000, David Laight wrote: > > > > How about making it possible to change the default affinity > > > for new kthreads at run time? > > > Is it possible to change the affinity of existing threads? > > > Or maybe only those that didn't specify an explicit one?? > > > > That's already possible yes, most unbound kthreads are accessible > > through /proc including kthreadd from which new kthread will inherit > > their CPU affinity. > > Are you sure that the new kthread will inherit the CPU affinity? > > __kthread_create_on_node() explicitly sets the new thread as SCHED_NORMAL > with a mask of "cpu_all_mask". Ah, ok that's the part I missed. What a weird behaviour... Anyway, I'm working on making all those isolcpus options controllable through cpusets. So that should be possible at some future.