Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp124007ybl; Wed, 11 Dec 2019 15:08:39 -0800 (PST) X-Google-Smtp-Source: APXvYqzX7bGFNjKP/G6LwYnZ0jUupaPzIluLUv+sRmrud+QJz3hRfJ0W4MvOJKxmYDEqKyrpwKer X-Received: by 2002:aca:c3c6:: with SMTP id t189mr4564839oif.98.1576105719333; Wed, 11 Dec 2019 15:08:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576105719; cv=none; d=google.com; s=arc-20160816; b=dmLOq84CWTYbGjtEJCrSA0zax+VmDLfcALrOvkzv6hYhh1hZIky+ZVM8i/uXjt+sqN eXflNNAgzdfmJKR+ktF12sRrpwzFtg1s8zg+8t20+yxNp/GTcUcBfLJ9XHvaaeUk+thx vAkchZPFSDmQJ6y20Ut617G+XAUl1DWi6PCMmRyn+5XpICO3186/pM1mByLHjWBJgNOS RPdqWYcXi2euX5fBHgtWFug6BU9hlSTssG1ahCe0u+dIH60OQYs6+z8//I0sXZLfwDU3 61dz6CWb6LT9hbIw92CissgjD9d0KOtp2QiUilbfXl2vLw/X7oW+fIYmipAIFIti6PBf Vo6w== 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=ufg6Zi8cXXhjldm/WLu/ZNOlbeAvLg5Mqf76gkYPaqo=; b=MTVPPYcwjUSLGWFQGlJg2mFalMUc/RpqY71Ups5oZefBrKfR+p1pUJ38BdLXUqpEv8 UvRr9yM/G9oWJbOmgArx8w0K613VQDV3XxIqwcLsBhQgQJhPzhnN8Bfe5vOpYU/vxVvq /Q8en0tEe2Tm/mEz/IW06RvZSOnQvCSP8qrGcf824tlQSxp0HK+ZQinJuKO4fr14CsqF OWbG0ZULVcF3oW+7T7NKdwW/TmuSodBGn+4jWwrggj+IN+RAxUUc6ECCJx9ZjTj31Mqt Wc8Q6Oy6qbGmMDKxMoF8ESZsn8cJDZNq3LDqTq2YstUIPPmuw19UMSkN+5jUndqOqymc KdrQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2019-08-05 header.b=osGbMjhE; 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=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q189si2011544oib.179.2019.12.11.15.08.16; Wed, 11 Dec 2019 15:08:39 -0800 (PST) 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=@oracle.com header.s=corp-2019-08-05 header.b=osGbMjhE; 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=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726691AbfLKXHi (ORCPT + 99 others); Wed, 11 Dec 2019 18:07:38 -0500 Received: from aserp2120.oracle.com ([141.146.126.78]:47946 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726411AbfLKXHi (ORCPT ); Wed, 11 Dec 2019 18:07:38 -0500 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id xBBMxTM1119188; Wed, 11 Dec 2019 23:07:29 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : mime-version : content-type : in-reply-to; s=corp-2019-08-05; bh=ufg6Zi8cXXhjldm/WLu/ZNOlbeAvLg5Mqf76gkYPaqo=; b=osGbMjhE11T+clp3ggTD1+REK5tSbHM7okTn1yz6Jsy5TY3KfIUwxkF3AcVy8lrmgIFb 7zVnX+AImlr/z9C2eTRKKMmS6UcSD7F24ZTIBc+gOkty0vjCaCUy4lmxJoiEIdBaw8AK hVo6qZ0RmvmcNlsiOH/T65ughqwFjJ2oI2JyB4+kQMs3BaI1xm85fKQqcS4veFLXbnwX 377fDsSTC8QET8aiOych9HAAlvqmR0c/VCn1dz+ftUmlPaXzfHgjlJKqtefrdYmd0Sqj n5JpAZ7Y9lUAPcxRN+EDwBaNUxQa4g2fhuRnD2FAMeo15O3Euf4z9BUPPPr7SgXiSBI5 +w== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by aserp2120.oracle.com with ESMTP id 2wr41qfqun-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 11 Dec 2019 23:07:29 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id xBBMxLqm135047; Wed, 11 Dec 2019 23:07:29 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3020.oracle.com with ESMTP id 2wtqgdt4bt-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 11 Dec 2019 23:07:28 +0000 Received: from abhmp0013.oracle.com (abhmp0013.oracle.com [141.146.116.19]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id xBBN7Q04031969; Wed, 11 Dec 2019 23:07:26 GMT Received: from ca-dmjordan1.us.oracle.com (/10.211.9.48) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 11 Dec 2019 15:07:26 -0800 Date: Wed, 11 Dec 2019 18:07:35 -0500 From: Daniel Jordan To: Hillf Danton Cc: linux-kernel , linux-mm , Tejun Heo , Lai Jiangshan Subject: Re: [RFC 1/4] workqueue: fix selecting cpu for queuing work Message-ID: <20191211230735.r5xpmgwfjjkzxwaf@ca-dmjordan1.us.oracle.com> References: <20191211104601.16468-1-hdanton@sina.com> <20191211105919.10652-1-hdanton@sina.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20191211105919.10652-1-hdanton@sina.com> User-Agent: NeoMutt/20180716 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9468 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=983 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1911140001 definitions=main-1912110181 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9468 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1011 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1911140001 definitions=main-1912110181 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org [please cc maintainers] On Wed, Dec 11, 2019 at 06:59:19PM +0800, Hillf Danton wrote: > Round robin is needed only for unbound workqueue and wq_unbound_cpumask > has nothing to do with standard workqueues, so we have to select cpu in > case of WORK_CPU_UNBOUND also with workqueue type taken into account. Good catch. I'd include something like this in the changelog. Otherwise, work queued on a bound workqueue with WORK_CPU_UNBOUND might not prefer the local CPU if wq_unbound_cpumask is non-empty and doesn't include that CPU. With that you can add Reviewed-by: Daniel Jordan