From patchwork Mon Oct 9 13:37:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 13413743 X-Patchwork-Delegate: johannes@sipsolutions.net Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 264B0E95A8E for ; Mon, 9 Oct 2023 13:38:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377244AbjJINiJ (ORCPT ); Mon, 9 Oct 2023 09:38:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34708 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377238AbjJINiI (ORCPT ); Mon, 9 Oct 2023 09:38:08 -0400 Received: from mail-wr1-x42c.google.com (mail-wr1-x42c.google.com [IPv6:2a00:1450:4864:20::42c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B4925B6; Mon, 9 Oct 2023 06:38:05 -0700 (PDT) Received: by mail-wr1-x42c.google.com with SMTP id ffacd0b85a97d-317c3ac7339so4129354f8f.0; Mon, 09 Oct 2023 06:38:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1696858684; x=1697463484; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=u6KCxFngvX9I/hwQrj7ymkXhwkpFmhe1Y7OW2VCan1I=; b=ZYO3nvCbTBqkAi4X2pYJ6OWeQ9hxhUZ92YkkB2YHdsDfujYkaf/OVX+SB/KGZu3JUD b+1p6MDssuzcdK6PnVNVrO5hQXe/0jDSw4uj5ZQscR5LhF6sHoeXvW5UbRFF/7zGqk8f A1ncNhRzXR0lZ4gRZ5eDaFyYXTaiGYhXraQ1IEG+OOqowovcSemCcDSZvD6wRKhi1uqC i/ACFeUTKaZkYGHtEbMopT0joim5rrT4oDkOS/7F1zqGToT0xME09xq4pgb6Bv0L977w 4J5HBnLnhZ8P01uNFlZcin31dASH/S2D9fx5P2vu9AZk0jowOrXSa7NYmzLoWZX0ybD7 MGkw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696858684; x=1697463484; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=u6KCxFngvX9I/hwQrj7ymkXhwkpFmhe1Y7OW2VCan1I=; b=PuMlZScRtdFPBrOHgax2x6Z+z+dhn5pB0TeUH4aHMVzn9KdnN/7YVAmNTm+x/leiI+ UDIofIbqiP2x9rooVG1O7Un7E3259s3qW3sTTI95qpw4Du37kCKwiTIQtYfMeIPEr3qP +qaHBsdKyBg9fZIaZypW7DJgH5IKevV6GvZ4dNLUrMJLa+U22j91B81DLFbUWPHUkDTq DE0sTyleCBsbgoWsrQ5zoi/tBGNaCz0B0w56rc0LuxpkRUaCowLica/tP0HHGBsy2yd3 3OPAAf8y5dwCtHPBzQIncH0lwT8Ne4ghkgaf3J1Vgz4WxlF7EgRzJz6uYmbNJ8n73ccJ q9Ww== X-Gm-Message-State: AOJu0Yw5tsozulMudCfC0HN+OkQP93q70n9fajuv71geHT2ksKeC3d2a z6+uNmxe0nS4O09k3RohLpg= X-Google-Smtp-Source: AGHT+IEMzVE5102E/rR+PKbFb4Y1qJpv3S+lyAIEK40sgvEz//IRItxHur9Z7ZsOHs5xcO/iYCxqbg== X-Received: by 2002:adf:f78d:0:b0:320:926:26d5 with SMTP id q13-20020adff78d000000b00320092626d5mr13881386wrp.30.1696858683739; Mon, 09 Oct 2023 06:38:03 -0700 (PDT) Received: from localhost.localdomain (93-34-89-13.ip49.fastwebnet.it. [93.34.89.13]) by smtp.googlemail.com with ESMTPSA id t4-20020a0560001a4400b0032763287473sm9746160wry.75.2023.10.09.06.38.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 06:38:03 -0700 (PDT) From: Christian Marangi To: Jason Gunthorpe , Leon Romanovsky , Wolfgang Grandegger , Marc Kleine-Budde , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Chris Snook , Raju Rangoju , Jeroen de Borst , Praveen Kaligineedi , Shailend Chand , Douglas Miller , Nick Child , Michael Ellerman , Nicholas Piggin , Christophe Leroy , Haren Myneni , Rick Lindsley , Dany Madden , Thomas Falcon , Tariq Toukan , Alexandre Torgue , Jose Abreu , Maxime Coquelin , Krzysztof Halasa , Kalle Valo , Jeff Johnson , Gregory Greenman , Chandrashekar Devegowda , Intel Corporation , Chiranjeevi Rapolu , Liu Haijun , M Chetan Kumar , Ricardo Martinez , Loic Poulain , Sergey Ryazanov , Johannes Berg , Christian Marangi , Yuanjun Gong , Alex Elder , Bhupesh Sharma , Simon Horman , Rob Herring , Bailey Forrest , Junfeng Guo , "Gustavo A. R. Silva" , Ziwei Xiao , Rushil Gupta , Thomas Gleixner , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= , Krzysztof Kozlowski , Yuri Karpov , Andrew Lunn , Zheng Zengkai , Dawei Li , Anjaneyulu , Benjamin Berg , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org, linux-can@vger.kernel.org, netdev@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, ath10k@lists.infradead.org, linux-wireless@vger.kernel.org Subject: [net-next v3 1/5] netdev: replace simple napi_schedule_prep/__napi_schedule to napi_schedule Date: Mon, 9 Oct 2023 15:37:50 +0200 Message-Id: <20231009133754.9834-1-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Replace drivers that still use napi_schedule_prep/__napi_schedule with napi_schedule helper as it does the same exact check and call. Signed-off-by: Christian Marangi Reviewed-by: Eric Dumazet --- Changes v3: - Add Reviewed-by tag Changes v2: - Add missing semicolon --- drivers/net/ethernet/ni/nixge.c | 3 +-- drivers/net/ethernet/wiznet/w5100.c | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/drivers/net/ethernet/ni/nixge.c b/drivers/net/ethernet/ni/nixge.c index 97f4798f4b42..f71a4f8bbb89 100644 --- a/drivers/net/ethernet/ni/nixge.c +++ b/drivers/net/ethernet/ni/nixge.c @@ -755,8 +755,7 @@ static irqreturn_t nixge_rx_irq(int irq, void *_ndev) cr &= ~(XAXIDMA_IRQ_IOC_MASK | XAXIDMA_IRQ_DELAY_MASK); nixge_dma_write_reg(priv, XAXIDMA_RX_CR_OFFSET, cr); - if (napi_schedule_prep(&priv->napi)) - __napi_schedule(&priv->napi); + napi_schedule(&priv->napi); goto out; } if (!(status & XAXIDMA_IRQ_ALL_MASK)) { diff --git a/drivers/net/ethernet/wiznet/w5100.c b/drivers/net/ethernet/wiznet/w5100.c index 341ee2f249fd..b26fd15c25ae 100644 --- a/drivers/net/ethernet/wiznet/w5100.c +++ b/drivers/net/ethernet/wiznet/w5100.c @@ -930,8 +930,8 @@ static irqreturn_t w5100_interrupt(int irq, void *ndev_instance) if (priv->ops->may_sleep) queue_work(priv->xfer_wq, &priv->rx_work); - else if (napi_schedule_prep(&priv->napi)) - __napi_schedule(&priv->napi); + else + napi_schedule(&priv->napi); } return IRQ_HANDLED;