Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp669372pxb; Thu, 21 Oct 2021 07:17:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyvqa5uK/XSkYuwtkomTrAL3g08R1+a7ivgSRG2ZE2zYX2t6XnzUbi9S/QVQ9PEJAWXZRMt X-Received: by 2002:a17:906:ecf6:: with SMTP id qt22mr7666620ejb.292.1634825868101; Thu, 21 Oct 2021 07:17:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634825868; cv=none; d=google.com; s=arc-20160816; b=sSlrRFEo+YXgkemvqdMngPtLQhtkvjyBASSWR8GZAze0RP542RvJX0Pzq/+5KkueCP pC7QFPd7kN7FBZyckMsST6ZrikSef6d8lPu/whYeSrJhJcM1SoMowLXOkv4E1fOAszPq 0lPzWaIRv9eObO7EbYWIj3X2rH8x5HqOJPRsCD2JpwaqsMWVDRQLwvqk0vKufdf5IMMh 2ZywKQQ+RTBh+ufQvQbPNegSFnR6lmvlTRQrMLM0qv8/NhjYw+MPabCZ7n+dQ92hlZ8M aT6U3eG9V/EHDq6360SOaRjY7YnEREwpJj7CWMw662PMXtk6dWhRJOtKkaD1zZnES4v8 G31w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:importance:sensitivity:mime-version :content-transfer-encoding:message-id:date:cc:to:from:subject :in-reply-to:dkim-signature; bh=PBUpBgQG1ihopG41zAX4JDk/NFFh4GdrZaKJzCGzAuY=; b=A2dLl0vmy/nceB1GaQpWFMXTpOg/HmnsKcyinfV1glJd8eA70BHhh3lhp2fTSMyaCS 4P3KzlREgaPTsusBSe1FiWh7qUIthDxgwy+MpeyM+XqJz1HQK4uy77qhBPxGg4pLTAw7 7yXhg2hdccgjbRMs4cB75hB0Kr26fXzFmQ7o9cw/SodmptdU/PRm5cHANkWOy/ftlUlL C3oYpdWoJTqwhwMGAyJBJfz/qLDwoMAWi8x6lvJChf3fPB9HQWdbeif09SSJygcUFldD JZM81kjjq90QEQoVFA+HhDAfHbQoh36nuuQNRx3Hdl8lNeCNYqHm3BjXIgsKCNF+WbRP c+Sg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ibm.com header.s=pp1 header.b=ohxF8dKO; 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=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x2si6855382edq.409.2021.10.21.07.17.22; Thu, 21 Oct 2021 07:17:48 -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=@ibm.com header.s=pp1 header.b=ohxF8dKO; 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=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231404AbhJUOR0 (ORCPT + 99 others); Thu, 21 Oct 2021 10:17:26 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:26190 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231206AbhJUORZ (ORCPT ); Thu, 21 Oct 2021 10:17:25 -0400 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 19LEC0EL009673; Thu, 21 Oct 2021 10:14:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ibm.com; h=in-reply-to : subject : from : to : cc : date : message-id : content-transfer-encoding : content-type : mime-version : references; s=pp1; bh=PBUpBgQG1ihopG41zAX4JDk/NFFh4GdrZaKJzCGzAuY=; b=ohxF8dKOIJs5CWEfprq7xvs/t0SqufXxQdDetKYPCJGO/+uS/WGyw+RV3WqF9CMdbY+x Hj7lYLeTeO+0Pkn2lO1Zx35gVs+Gf3AoZ6timPBOWGfKvPD8f+JSFCEFwi5TcHv6Zj2Z ySykdjxcAO7nxDK98SffUcLtAse6GDFJLOMZYxhvIsmg+unBpsvGuA+Vm66a0B6xpEJA 9Aa20mQlbEj0b+jSoWhvRQp4eGNNS6HQPH1YOkUKATQ2hLm71vuFy/4LINYMZURgF4Fe WqW5vi0IQNZNo/OSPkzv8i4EGBavS74HsrxNyCzZxhEBMMMczEBrFkOexj0cKiaE/sC8 Fw== Received: from pps.reinject (localhost [127.0.0.1]) by mx0a-001b2d01.pphosted.com with ESMTP id 3bu8h8a67v-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 21 Oct 2021 10:14:44 -0400 Received: from m0098399.ppops.net (m0098399.ppops.net [127.0.0.1]) by pps.reinject (8.16.0.43/8.16.0.43) with SMTP id 19LECf4f013699; Thu, 21 Oct 2021 10:14:43 -0400 Received: from ppma05wdc.us.ibm.com (1b.90.2fa9.ip4.static.sl-reverse.com [169.47.144.27]) by mx0a-001b2d01.pphosted.com with ESMTP id 3bu8h8a679-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 21 Oct 2021 10:14:43 -0400 Received: from pps.filterd (ppma05wdc.us.ibm.com [127.0.0.1]) by ppma05wdc.us.ibm.com (8.16.1.2/8.16.1.2) with SMTP id 19LE88qF020843; Thu, 21 Oct 2021 14:14:41 GMT Received: from b01cxnp22033.gho.pok.ibm.com (b01cxnp22033.gho.pok.ibm.com [9.57.198.23]) by ppma05wdc.us.ibm.com with ESMTP id 3bqpccx3k0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Thu, 21 Oct 2021 14:14:41 +0000 Received: from b01ledav004.gho.pok.ibm.com (b01ledav004.gho.pok.ibm.com [9.57.199.109]) by b01cxnp22033.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id 19LEEfHa37355946 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 21 Oct 2021 14:14:41 GMT Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 51552112062; Thu, 21 Oct 2021 14:14:41 +0000 (GMT) Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 3AD0B112066; Thu, 21 Oct 2021 14:14:41 +0000 (GMT) Received: from mww0301.wdc07m.mail.ibm.com (unknown [9.208.64.45]) by b01ledav004.gho.pok.ibm.com (Postfix) with ESMTPS; Thu, 21 Oct 2021 14:14:41 +0000 (GMT) In-Reply-To: <20211021140755.GA3448@LAPTOP-UKSR4ENP.internal.baidu.com> Subject: Re: Re: [PATCH 0/6] kthread: Add the helper macro kthread_run_on_cpu() From: "Bernard Metzler" To: "Cai Huoqing" Cc: "Doug Ledford" , "Jason Gunthorpe" , "Davidlohr Bueso" , "Paul E. McKenney" , "Josh Triplett" , "Steven Rostedt" , "Mathieu Desnoyers" , "Lai Jiangshan" , "Joel Fernandes" , "Ingo Molnar" , "Daniel Bristot de Oliveira" , , , Date: Thu, 21 Oct 2021 14:14:39 +0000 Message-ID: Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 MIME-Version: 1.0 Sensitivity: Importance: Normal X-Priority: 3 (Normal) References: <20211021140755.GA3448@LAPTOP-UKSR4ENP.internal.baidu.com>,<20211021120135.3003-1-caihuoqing@baidu.com> X-Mailer: Lotus Domino Web Server Release 11.0.1FP2HF117 October 6, 2021 X-MIMETrack: Serialize by http on MWW0301/01/M/IBM at 10/21/2021 14:14:39,Serialize complete at 10/21/2021 14:14:39 X-Disclaimed: 43643 X-TM-AS-GCONF: 00 X-Proofpoint-GUID: rdaui_dDQj1rHp2A99r3bdTCha09_jUJ X-Proofpoint-ORIG-GUID: au9D6ywHx9lIErgJ2kfG4r11-dLiCFju X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.425,FMLib:17.0.607.475 definitions=2021-10-21_04,2021-10-21_02,2020-04-07_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 impostorscore=0 adultscore=0 malwarescore=0 suspectscore=0 bulkscore=0 clxscore=1015 priorityscore=1501 lowpriorityscore=0 phishscore=0 mlxlogscore=999 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2109230001 definitions=main-2110210076 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org -----"Cai Huoqing" wrote: ----- >To: "Bernard Metzler" >From: "Cai Huoqing" >Date: 10/21/2021 04:08PM >Cc: "Doug Ledford" , "Jason Gunthorpe" >, "Davidlohr Bueso" , "Paul E. >McKenney" , "Josh Triplett" >, "Steven Rostedt" , >"Mathieu Desnoyers" , "Lai Jiangshan" >, "Joel Fernandes" , >"Ingo Molnar" , "Daniel Bristot de Oliveira" >, , >, >Subject: [EXTERNAL] Re: [PATCH 0/6] kthread: Add the helper macro >kthread=5Frun=5Fon=5Fcpu() > >On 21 10=E6=9C=88 21 13:48:15, Bernard Metzler wrote: >> -----"Cai Huoqing" wrote: ----- >>=20 >> >To: >> >From: "Cai Huoqing" >> >Date: 10/21/2021 02:02PM >> >Cc: "Bernard Metzler" , "Doug Ledford" >> >, "Jason Gunthorpe" , >"Davidlohr >> >Bueso" , "Paul E. McKenney" >, >> >"Josh Triplett" , "Steven Rostedt" >> >, "Mathieu Desnoyers" >> >, "Lai Jiangshan" >> >, "Joel Fernandes" >, >> >"Ingo Molnar" , "Daniel Bristot de Oliveira" >> >, , >> >, >> >Subject: [EXTERNAL] [PATCH 0/6] kthread: Add the helper macro >> >kthread=5Frun=5Fon=5Fcpu() >> > >> >the helper macro kthread=5Frun=5Fon=5Fcpu() inculdes >> >kthread=5Fcreate=5Fon=5Fcpu/wake=5Fup=5Fprocess(). >> >In some cases, use kthread=5Frun=5Fon=5Fcpu() directly instead of >> >kthread=5Fcreate=5Fon=5Fnode/kthread=5Fbind/wake=5Fup=5Fprocess() or >> >kthread=5Fcreate=5Fon=5Fcpu/wake=5Fup=5Fprocess() or >> >kthreadd=5Fcreate/kthread=5Fbind/wake=5Fup=5Fprocess() to simplify the >code. >>=20 >> I do not see kthread=5Fbind() being covered by the helper, >> as claimed? rcutorture, ring-buffer, siw are using it in >> the code potentially being replaced by the helper. >> kthread=5Fbind() is best to be called before thread starts >> running, so should be part of it. >Hi, >kthread=5Fbind() is already part of kthread=5Fcreate=5Fon=5Fcpu which is >called by kthread=5Frun=5Fon=5Fcpu() here. > Indeed! Thanks, Bernard. >Thanks, >Cai. >>=20 >> Thanks, >> Bernard. >> > >> >Cai Huoqing (6): >> > kthread: Add the helper macro kthread=5Frun=5Fon=5Fcpu() >> > RDMA/siw: Make use of the helper macro kthread=5Frun=5Fon=5Fcpu() >> > ring-buffer: Make use of the helper macro kthread=5Frun=5Fon=5Fcpu() >> > rcutorture: Make use of the helper macro kthread=5Frun=5Fon=5Fcpu() >> > trace/osnoise: Make use of the helper macro kthread=5Frun=5Fon=5Fcpu() >> > trace/hwlat: Make use of the helper macro kthread=5Frun=5Fon=5Fcpu() >> > >> > drivers/infiniband/sw/siw/siw=5Fmain.c | 7 +++---- >> > include/linux/kthread.h | 22 ++++++++++++++++++++++ >> > kernel/rcu/rcutorture.c | 7 ++----- >> > kernel/trace/ring=5Fbuffer.c | 7 ++----- >> > kernel/trace/trace=5Fhwlat.c | 6 +----- >> > kernel/trace/trace=5Fosnoise.c | 3 +-- >> > 6 files changed, 31 insertions(+), 21 deletions(-) >> > >> >--=20 >> >2.25.1 >> > >> > >