Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp2627909ybl; Thu, 29 Aug 2019 10:40:11 -0700 (PDT) X-Google-Smtp-Source: APXvYqzEIvtKB88/peEYR17w9DNRG+XqZvwPvFo2vQd7sDvD4qUYAeqjGjsPCpiFnCZDpMrWukpx X-Received: by 2002:a17:902:d906:: with SMTP id c6mr10779210plz.13.1567100411562; Thu, 29 Aug 2019 10:40:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567100411; cv=none; d=google.com; s=arc-20160816; b=WTp1gyCFn6x6a3GPPJysmnz7Q9EXEgkD7QM6/RhLnpY+ZU3IDi1GooEsSTACaCjDu0 jjRmYMUQ9/dThgCDKMLMWbZ4ZMlnxGigqUt6tAVD3Wlsc2hAK1lt8r8pqM9Syesg1fZj aFfO2njewqUi2cJPBbaofU79tAIqTYGSCisgx77x+mAayogpvaVm1HyYhzMFXFJpdSgd lASWPgT5aPHeAUTkAqske3YqPMxgY7IfsO3IFdG5zf1L8WCKnQ5UchzDjPbYpvKjobE3 0LTbFa17ZgxBsc4h7Twxotd6YNnf0HmNCmT6UeZ8PddW/fQjDCkuYBKJFsOoi9yPgbwk /T7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=dCNzWO/FXVDMwwImLRNfZxHktHml5H3w+6akEtHZx4s=; b=yAeSWolwg+lM0ePrfhPKMX+xZUi+d/7iAPYSPhbPy2bmO6ubJ725MIF1UK0RO9YnjT /k2O2Ky0zn1FcC/AeKH2+e8D2+QK1sXI4cvL5QRnokOMWggSgEARNh+O4aSe7EZrWFoH w6Sx+nR2jzsrTnsVr7ZMINYI2/BoWpxWnSaN5Ff8uZXlX6FI2YqJ0ZKcXoAOoDd8rIBf rn1VNdoVzc26TG+9sjH88LecxbBPOAblnnsosUdnAs/abXb16u8+nA57CmNoDR3+g0zc aTDr1aPtG8vBTfyAY0Ia8NZnjMOcIoE2yv1Yx++KOeWGLa1QxpZmzyAW2wNxjWmBIwmq lU0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2019-08-05 header.b=ELpX3mFg; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-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 h11si2441434pgr.555.2019.08.29.10.39.57; Thu, 29 Aug 2019 10:40:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-crypto-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=ELpX3mFg; spf=pass (google.com: best guess record for domain of linux-crypto-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-crypto-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 S1727352AbfH2Rin (ORCPT + 99 others); Thu, 29 Aug 2019 13:38:43 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:54956 "EHLO userp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727481AbfH2Rim (ORCPT ); Thu, 29 Aug 2019 13:38:42 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x7THXnmr134049; Thu, 29 Aug 2019 17:38:29 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=corp-2019-08-05; bh=dCNzWO/FXVDMwwImLRNfZxHktHml5H3w+6akEtHZx4s=; b=ELpX3mFgoUAmDW0wI07BKRQfphEC+5Iv8L9M4fQ+RSpQdUBXganuxRyOcdSts54mtdyW ssbyrpQrVfEyEoUi6zzcgzM8rvOUutK35EiLZCuTNU3lYf4+p94uaEhL0JfxFh0XZxeG 2HseAIxyUrED71QdV90a0blRudFmGpEUWjm44r2UsyuJt9NRoCBxuuGCWw4LpegWBY3R Rbw1wb4QTkb0CATgDOQ3Gsc2+3BZv5h8g7PdJNMUsfg9i68/7oq7T4GbmeG2jXTJHPmt q+/FtVNHz7WMGfHKdWCDpwLDl8lStTxO6XBteYU5C6fGvg4DWcswcqVBcUEYmfZ2BxYz lg== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by userp2120.oracle.com with ESMTP id 2upk4sr37n-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 29 Aug 2019 17:38: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 x7THWYcL057229; Thu, 29 Aug 2019 17:33:28 GMT Received: from aserv0121.oracle.com (aserv0121.oracle.com [141.146.126.235]) by aserp3020.oracle.com with ESMTP id 2upc8uy1ts-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 29 Aug 2019 17:33:28 +0000 Received: from abhmp0008.oracle.com (abhmp0008.oracle.com [141.146.116.14]) by aserv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x7THWgJ2002163; Thu, 29 Aug 2019 17:32:42 GMT Received: from zissou.us.oracle.com (/10.152.34.58) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Thu, 29 Aug 2019 10:32:42 -0700 From: Daniel Jordan To: Herbert Xu , Steffen Klassert Cc: Lai Jiangshan , Peter Zijlstra , Tejun Heo , linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org, Daniel Jordan Subject: [PATCH v2 9/9] padata: remove cpu_index from the parallel_queue Date: Thu, 29 Aug 2019 13:30:38 -0400 Message-Id: <20190829173038.21040-10-daniel.m.jordan@oracle.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190829173038.21040-1-daniel.m.jordan@oracle.com> References: <20190829173038.21040-1-daniel.m.jordan@oracle.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9364 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908290186 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9364 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=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1908290186 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org With the removal of the ENODATA case from padata_get_next, the cpu_index field is no longer useful, so it can go away. Signed-off-by: Daniel Jordan Acked-by: Steffen Klassert Cc: Herbert Xu Cc: Lai Jiangshan Cc: Peter Zijlstra Cc: Tejun Heo Cc: linux-crypto@vger.kernel.org Cc: linux-kernel@vger.kernel.org --- include/linux/padata.h | 2 -- kernel/padata.c | 13 ++----------- 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/include/linux/padata.h b/include/linux/padata.h index 4d2ba38d99fc..edc1d63a91e7 100644 --- a/include/linux/padata.h +++ b/include/linux/padata.h @@ -76,14 +76,12 @@ struct padata_serial_queue { * @swork: work struct for serialization. * @work: work struct for parallelization. * @num_obj: Number of objects that are processed by this cpu. - * @cpu_index: Index of the cpu. */ struct padata_parallel_queue { struct padata_list parallel; struct padata_list reorder; struct work_struct work; atomic_t num_obj; - int cpu_index; }; /** diff --git a/kernel/padata.c b/kernel/padata.c index 83889e0bf1c4..cbb6bb924046 100644 --- a/kernel/padata.c +++ b/kernel/padata.c @@ -399,21 +399,12 @@ static void padata_init_squeues(struct parallel_data *pd) /* Initialize all percpu queues used by parallel workers */ static void padata_init_pqueues(struct parallel_data *pd) { - int cpu_index, cpu; + int cpu; struct padata_parallel_queue *pqueue; - cpu_index = 0; - for_each_possible_cpu(cpu) { + for_each_cpu(cpu, pd->cpumask.pcpu) { pqueue = per_cpu_ptr(pd->pqueue, cpu); - if (!cpumask_test_cpu(cpu, pd->cpumask.pcpu)) { - pqueue->cpu_index = -1; - continue; - } - - pqueue->cpu_index = cpu_index; - cpu_index++; - __padata_list_init(&pqueue->reorder); __padata_list_init(&pqueue->parallel); INIT_WORK(&pqueue->work, padata_parallel_worker); -- 2.23.0