Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp4526779rdb; Tue, 12 Dec 2023 01:56:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IH3MK+XEVjq0mrU9qE4YYMmgO5T2bgawXjkaD5C7ezivcg8z2WewyDprLgxIT+yZHlPBySI X-Received: by 2002:a05:6870:bb1b:b0:1fb:27ca:738c with SMTP id nw27-20020a056870bb1b00b001fb27ca738cmr5804678oab.17.1702375005679; Tue, 12 Dec 2023 01:56:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1702375005; cv=none; d=google.com; s=arc-20160816; b=BkuMJwbPpNuaia8gViJYZd74EyMdlangMKZtqITN4i7byHmOm+Lsd+VenoEhuwzC8o 3STs775Z/7a+nuj3V00IIpAVJee11e8E3GjayzAJHkFJ+9C4H93z1tjAGxf3ZupwadA/ jciabdNLmgUmAsH90jsdrnNZ01cff/QV2rXjWP6XBFzvwHmTGneAX9U9axzHAANXu+Md TxdFjP5PeIAriOJMVcYYWz8K68CYIRkBt8uNZZ38JImohRKfLHqY1+tjKd0BaSfYwMdP a71J0DMn8w3V7svMZYORQOwDUXc4l/EjNM92sPxPwCfd0YPcYVNtJxZYuGAyOYNEUQ9k gJrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=l0x7ummZKoQ2iIdFhvwfnQrolsKlXVwo33HTSumY6yA=; fh=1CqPlySqPiCaeSrZ0glMCByHtsyOrAfvOKmHKyPOlJU=; b=c5idQ0j26Hg8kikkHUYXqDMKd+SbQc/YmHqT7qcTUmt11kdx5WnZaO7MzcXm9HpABZ +zUH0MhdlTBiZJrFLlP78yLKHqtKg4ejtV0TTnhFOBJCIFMNZhgPE0Ihgluxhc/7819z S0wSC+K8dd2myqyC4S4kZleEzccopOnF4fKcP3zwoPpwC146UjfArpXt2aEz/I6s0bIa XhTMq9cbM2Hpyh5BAh36qJtKypyNFehe1W+N0Bmf40yxm3hBnS+JDRbkG4FYy+ZvBW1m elQmxvm7CRAzEIm81LhkQlQNA8IzBp16vqWVNzw1CcP9niYfrOSSFaEj03xiKtv5dKVa HBFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=EeV7Q2yl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id x16-20020a634a10000000b005b96d038729si6460138pga.728.2023.12.12.01.56.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 01:56:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=EeV7Q2yl; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id ECFE980A2806; Tue, 12 Dec 2023 01:56:42 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230508AbjLLJ4G (ORCPT + 99 others); Tue, 12 Dec 2023 04:56:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45080 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346095AbjLLJ4D (ORCPT ); Tue, 12 Dec 2023 04:56:03 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9A571A6 for ; Tue, 12 Dec 2023 01:56:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1702374968; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=l0x7ummZKoQ2iIdFhvwfnQrolsKlXVwo33HTSumY6yA=; b=EeV7Q2ylUw57f2Az29+n70rkPb+Xw8XsZqXmeMY8gESU6neTZihyM9ank9FvLeSe3ATWT2 so10W7Tj42IP6EPzxO2kCTBR4+9pD3iaKmCnjaQvrVqD0JA/jgQWk/SPTyzSXQgqVed1oD p1tZFaa34xiGEOqC4RkGwleo5ZLdHbY= Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-115-3hb6mdX0NG-FfROuNqQppw-1; Tue, 12 Dec 2023 04:56:07 -0500 X-MC-Unique: 3hb6mdX0NG-FfROuNqQppw-1 Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-42577ba9d93so73931611cf.2 for ; Tue, 12 Dec 2023 01:56:07 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702374967; x=1702979767; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=l0x7ummZKoQ2iIdFhvwfnQrolsKlXVwo33HTSumY6yA=; b=ZLC1oXAgdT55jyhhMTljH43vtebFlD8t+R5lANvuNQhVpshq8enRy6lNU3eOCK/Q8C MchOmzguZ8GGMIkLVm/x2NcHa5rFKXFRdvZ9QK7uJCHBNPUAJP8tZ3VhDe65nsMpko5i UHhI9uQZLyd6+VdpFI5117Li9vNb70R+04b6sNchOTMN+WFPaahC24ngfTYJifkzXSgb ALfjL9zJnDNHdRLTBUOK436Dedw2QFgs8iTcMZE/4x9gqBZyF/J4G7JOKJyNFRyFN3k9 sCUKiSiW4XNBHlsqghSXH6blFGYdTorTEp/sc7IwHhfgT6plXEN0Ow4dtU1jqDmr1O3e d9sA== X-Gm-Message-State: AOJu0YzBSLGHRh1uAnbk7/NFKNjcywKx6+sdiesLpUCoGQKkRoH+QcYx XIfDQL1UZ3YLi3kfgd7p31Tv2/ywf1ZosL1bgwmyWikgUo/c1Hd1Ic9GZVVv7iAHn1BpNN5S1eT wGDYiSo8iuvPRjVGyCJJTXeoj X-Received: by 2002:a05:622a:1792:b0:425:4043:1d8c with SMTP id s18-20020a05622a179200b0042540431d8cmr7840992qtk.95.1702374966936; Tue, 12 Dec 2023 01:56:06 -0800 (PST) X-Received: by 2002:a05:622a:1792:b0:425:4043:1d8c with SMTP id s18-20020a05622a179200b0042540431d8cmr7840990qtk.95.1702374966679; Tue, 12 Dec 2023 01:56:06 -0800 (PST) Received: from localhost.localdomain ([151.29.78.8]) by smtp.gmail.com with ESMTPSA id l18-20020ac84592000000b00419732075b4sm3927478qtn.84.2023.12.12.01.56.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Dec 2023 01:56:06 -0800 (PST) Date: Tue, 12 Dec 2023 10:56:02 +0100 From: Juri Lelli To: Tejun Heo Cc: Aaron Tomlin , linux-kernel@vger.kernel.org, jiangshanlai@gmail.com, peterz@infradead.org Subject: Re: [RFC PATCH 0/2] workqueue: Introduce PF_WQ_RESCUE_WORKER Message-ID: References: <20230729135334.566138-1-atomlin@atomlin.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Tue, 12 Dec 2023 01:56:43 -0800 (PST) Hello, Thanks for the quick reply! On 11/12/23 08:39, Tejun Heo wrote: > Hello, > > On Mon, Dec 11, 2023 at 03:51:57PM +0100, Juri Lelli wrote: > > Guess this is a requirement because, if workqueue processing is stuck > > for some reason, getting rescuers to run on the same set of cpus > > workqueues have been restricted to already doesn't really have good > > chances of making any progress? > > The only problem rescuers try to solve is deadlocks caused by lack of > memory, so on the cpu side, it just follows whatever worker pool it's trying > to help. > > > Wonder if we still might need some sort of fail hard/warn mode in case > > strict isolation is in place? Or maybe we have that already? > > For both percpu and unbound workqueues, the rescuers just follow whatever > pool it's trying to help at the moment, so it shouldn't cause any surprises > in terms of isolation. It just temporarily joins the already active but > stuck pool. Hummm, OK, but in terms of which CPU the rescuer is possibly woken up, how are we making sure that the wake up is always happening on housekeeping CPUs (assuming unbound workqueues have been restricted to those)? AFAICS, we have send_mayday -> wake_up_process(wq->rescuer->task) which is not affined to the workqueue cpumask it's called to rescue, so in theory can be woken up anywhere? Thanks, Juri