Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp2210379ybt; Sun, 28 Jun 2020 11:33:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx4ijYT1mkophB7b8zoYUzHjrn8Xes/1Adb05VDIs8nIFfG9fJdw8G7KDaUNENPbF0WvAZu X-Received: by 2002:a05:6402:542:: with SMTP id i2mr12462974edx.318.1593369212093; Sun, 28 Jun 2020 11:33:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593369212; cv=none; d=google.com; s=arc-20160816; b=AawA437kSwvQA7Zm6TCrWiI3UslZ3Q3+d2U7eKVgiTCKkrVng3IbUxpsL8ITDyz5Ih Hqjk8HddfyWyirqzWIjbOD7JGwNgnKiUuPSUnpodNdw+FlE/3y8ONfpTxnEM6ZMMULJg NzidA49i1AKBlqNOivD2rLYkLoylSEwuJ317In4q5iL3XqRXAi/VuQ3caPXkUroZlMg7 qIw2+ucexf1JmPUFx+xXqIIfEnYKrLyY21jxkis8abkw0qEh/fjAiFtuH0s5Oiz1Tulx tEh/Dor75wn3fbPR0OUm5wxkTHX0mErNx+Or7un3tqrmcPj0g+iMWCga801B16X5JMkI vWiQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=C/AWghi0ggAWezCdD0yzAwGjS2bjfVCfdqGQLJ4bXU8=; b=ggLSdDmw36S9XxPmL+2r38NqdLb7DM/4d6vpgriaoer0VKrLgfibRjPrtDlXqa4vSC aS4UruoH+qqf4ynk9E3xtk5CG7SC7BFttbXWYSHE+e3myocJl2ELtgruf9TCdH8Lrq3w 9FdrNvd+kSya0qVWajhySx+lg95Hh6nDj8OZR4eyfaIOwcK9zCPy6CoQsxGVRUuXEPk2 j3/i+/tV1aT7OO65vPl8pMybZY0407gH1v85f3QOtJt8x74aa7ScPl+/GEyfh3+OF0Y1 MMv88Sm3Oum/ZkZUNvjb3I8/fROVg4NPuvIBv4VoSU1QYM3dX34DoYKMYtaOdjR33tXj s7fw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=nx+0kA+E; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b7si4312599edq.546.2020.06.28.11.33.09; Sun, 28 Jun 2020 11:33:32 -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=@gmail.com header.s=20161025 header.b=nx+0kA+E; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726685AbgF1Scm (ORCPT + 99 others); Sun, 28 Jun 2020 14:32:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40308 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726060AbgF1Scm (ORCPT ); Sun, 28 Jun 2020 14:32:42 -0400 Received: from mail-ej1-x643.google.com (mail-ej1-x643.google.com [IPv6:2a00:1450:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2BCB1C03E979; Sun, 28 Jun 2020 11:32:42 -0700 (PDT) Received: by mail-ej1-x643.google.com with SMTP id l12so14378640ejn.10; Sun, 28 Jun 2020 11:32:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=C/AWghi0ggAWezCdD0yzAwGjS2bjfVCfdqGQLJ4bXU8=; b=nx+0kA+ECOlB14AL7pgiSQnrsiMxEe8HCxwIzpw2ZGRZowJfqoNOtpp4pqy2G/GB6j deCGnBoDWpT4ikeuzV7fKfcpkUEp8TkaA2Y3TXvFf67w5CVhsD5dEZhkWCsjjLBxDXRL z6+l3hUPdMtICfRpl+DLSCiKu4qCwytIdgzaU9mz1RMzLYFGh7acjLXtsqG0S4gSh9wp EwXV8YyDfU6vbcvK+YxLVvx/UmGy0VeY8kwKXVrLDHzTUMNpzEVKmoge2UrFuTTQmJMv b6oKji/Su81LhtZgzkiY3ax25ipANws3bsyOPolbymdqYSHBdM67i4mSsRKxju0eqTtx 4m1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=C/AWghi0ggAWezCdD0yzAwGjS2bjfVCfdqGQLJ4bXU8=; b=DX4I/BLnP9vcMPOgKc0jVHBAS8kUFmQZfmJPIJOQONdSp9/074RbRjIyjeMsOfx45P 3o4v/tOQtzNZfi/Cu/xK3XsOh54v2kuct6uxsdKC6uBP1/y/6Y0ibM8V6pGtbSpKfH49 CBh8xhWoDn1ugcC5Wj/s9jC8+k5ApohleuCcBGRSwk8fOQMIUQegiUUIwG3sXxbSj0dS LbR3gBXZrLcrc6zbIRz+joeqPT/lfO63gLptcqzitsv157HK+xfJ8c8A5o01CeUz0TCI SnTJYACnzBegfUXJQWJJ18jTDfE1INVthgeX8+QwxXYTsPPxCsr2VM6mc27pDu2DZc/1 /6Hg== X-Gm-Message-State: AOAM533TSGiwFJFk+sRMkPzLzWyAVZO4t3z5qtbyleTEE97voffqMdUK EHPeYF02pZHSTA3pjcGqK40= X-Received: by 2002:a17:906:2b0e:: with SMTP id a14mr10659475ejg.459.1593369160913; Sun, 28 Jun 2020 11:32:40 -0700 (PDT) Received: from localhost.localdomain ([2a02:a03f:b7f9:7600:f145:9a83:6418:5a5c]) by smtp.gmail.com with ESMTPSA id v5sm7349888ejj.61.2020.06.28.11.32.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 28 Jun 2020 11:32:40 -0700 (PDT) From: Luc Van Oostenryck To: Adham Abozaeid , Ajay Singh , Greg Kroah-Hartman Cc: linux-wireless@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, Luc Van Oostenryck Subject: [PATCH] staging/wilc1000: let wilc_mac_xmit() to NETDEV_TX_OK Date: Sun, 28 Jun 2020 20:32:37 +0200 Message-Id: <20200628183237.74749-1-luc.vanoostenryck@gmail.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The method ndo_start_xmit() is defined as returning an 'netdev_tx_t', which is a typedef for an enum type defining 'NETDEV_TX_OK' but this driver returns '0' instead of 'NETDEV_TX_OK'. Fix this by returning ''NETDEV_TX_OK' instead of 0. Signed-off-by: Luc Van Oostenryck --- drivers/staging/wilc1000/netdev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/wilc1000/netdev.c b/drivers/staging/wilc1000/netdev.c index fda0ab97b02c..be3ae5486f44 100644 --- a/drivers/staging/wilc1000/netdev.c +++ b/drivers/staging/wilc1000/netdev.c @@ -678,14 +678,14 @@ netdev_tx_t wilc_mac_xmit(struct sk_buff *skb, struct net_device *ndev) if (skb->dev != ndev) { netdev_err(ndev, "Packet not destined to this device\n"); - return 0; + return NETDEV_TX_OK; } tx_data = kmalloc(sizeof(*tx_data), GFP_ATOMIC); if (!tx_data) { dev_kfree_skb(skb); netif_wake_queue(ndev); - return 0; + return NETDEV_TX_OK; } tx_data->buff = skb->data; @@ -710,7 +710,7 @@ netdev_tx_t wilc_mac_xmit(struct sk_buff *skb, struct net_device *ndev) srcu_read_unlock(&wilc->srcu, srcu_idx); } - return 0; + return NETDEV_TX_OK; } static int wilc_mac_close(struct net_device *ndev) -- 2.27.0