Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp4049684rwb; Sun, 9 Oct 2022 16:50:31 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6TzJo7PK9/m2hwbhyMCNm27B8mGVzdgjkkbLBYaGru62sXPrgd7wYaNF7xn/yTV8O5XEkE X-Received: by 2002:a17:90a:fe92:b0:20a:daaf:75ea with SMTP id co18-20020a17090afe9200b0020adaaf75eamr27722081pjb.221.1665359430863; Sun, 09 Oct 2022 16:50:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665359430; cv=none; d=google.com; s=arc-20160816; b=Y4ezvW97OQIVv0xhr0uK4wtnz2/sXb4ZNauBeDMnEAuAwXr9kkMGR8uMR/OY+3sTu8 AjX+CEYX9S3h4NpbLSUxqoLammpEr3jSKmJlKdryeIIz+ZKKTCjIgKR/SAgaVlLWDWKE pv8lE+EjeFCKPqrj07T4IOCRG6EJ7SVb3QZgQLDSIAu54jSNFDgDj3vhz2guvIZf1DMr qHx2pGF72yEJQhuivMn3wbUqv7BIg0HTyrgrW+FXHbyIp9my8G2JFNEa27PtPRHimQWT K4NvU/DTnNwGQPbpZArHmXWF1EEmmEX4IRX4patOVhwYXRVsEA6JrJfZm1MoPByiAh81 /wig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=mJdzxpiG8btGKm4y8wibe+jQj+Rex2s24JN0XMFt5ls=; b=ZfMTrEuHLsU2xVaz+stOt+kJCcYr2orHH57raZ/Ncd7EIsaR55nUZ2WP2ufQ4qwBp0 Wiwdmv7+NTs/g6dh5ytQqD3TIXYtz7zb+/1aapLTbEqBUQsxo92+vXKSaPuQlS0+1OG3 QDjkMBSu5oZ901oI5kJUxN6WesleJ4SVIZGfN9nk1BXqKldTLF0/KPa7280mrJ8wgeI+ k/J1FDFJrTUsf4mE9S6/pLhYfbjA4hYk6IkBKeGK+G2aVDL313z1jbAh3EsXNQCzN4oy B3ab8gx7J1jDxzfxK/N+p/oTVWx4+m3rJCVmL9l7hEHxZ7O52XIbE4/eGWA/zM94Lyot 5pMw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PpzVxBFA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d18-20020a63d652000000b0044ae0c2fbf0si10789792pgj.168.2022.10.09.16.50.19; Sun, 09 Oct 2022 16:50:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=PpzVxBFA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231755AbiJIWYb (ORCPT + 99 others); Sun, 9 Oct 2022 18:24:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231441AbiJIWXe (ORCPT ); Sun, 9 Oct 2022 18:23:34 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F1B7011140; Sun, 9 Oct 2022 15:18:04 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 8CD1760CBB; Sun, 9 Oct 2022 22:17:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 53D4AC433D7; Sun, 9 Oct 2022 22:17:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1665353876; bh=EV1aWa0RnASqulCvNKmsejHYmsYcScF6Ye+v3g617V4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=PpzVxBFAoLhEEEYVE7mi4+Mzl9uG4TfofoRl7o/brAfdjBa0jV/pD0NXb35GIHpoA Ebyq7vSODjgxC7TEVvxuAFy1se2ShlI8yBTM04ta8XdIG30jPagQEOqOjzFwl9eK/Y 5RMpaaQ0CUIzubukNwQekRpfO7LXtbXtQdQNuYbAuOa7XGpv6OWwpl7s7HKlrXw5B3 sPbHM7ld5VPz9eBHJ3tpZVG0HHCTRMSE2oFAZeP2f30NhUZQE6pcoOzfZ1yg+IOCvX 6dx2j3hym6NqyPj2O1mLMnR8i05OmuSm5XoXRHoyip9khe1xpstb3uguvykP2Px8Cs zECapGFVWeprQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Nathan Huckleberry , Dan Carpenter , llvm@lists.linux.dev, Sergey Ryazanov , Jakub Kicinski , Sasha Levin , chandrashekar.devegowda@intel.com, linuxwwan@intel.com, loic.poulain@linaro.org, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, nathan@kernel.org, ndesaulniers@google.com, netdev@vger.kernel.org Subject: [PATCH AUTOSEL 5.19 48/73] net: wwan: t7xx: Fix return type of t7xx_ccmni_start_xmit Date: Sun, 9 Oct 2022 18:14:26 -0400 Message-Id: <20221009221453.1216158-48-sashal@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221009221453.1216158-1-sashal@kernel.org> References: <20221009221453.1216158-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Nathan Huckleberry [ Upstream commit 73c99e26036529e633a0f2d628ad7ddff6594668 ] The ndo_start_xmit field in net_device_ops is expected to be of type netdev_tx_t (*ndo_start_xmit)(struct sk_buff *skb, struct net_device *dev). The mismatched return type breaks forward edge kCFI since the underlying function definition does not match the function hook definition. The return type of t7xx_ccmni_start_xmit should be changed from int to netdev_tx_t. Reported-by: Dan Carpenter Link: https://github.com/ClangBuiltLinux/linux/issues/1703 Cc: llvm@lists.linux.dev Signed-off-by: Nathan Huckleberry Acked-by: Sergey Ryazanov Link: https://lore.kernel.org/r/20220912214510.929070-1-nhuck@google.com Signed-off-by: Jakub Kicinski Signed-off-by: Sasha Levin --- drivers/net/wwan/t7xx/t7xx_netdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wwan/t7xx/t7xx_netdev.c b/drivers/net/wwan/t7xx/t7xx_netdev.c index c6b6547f2c6f..f71d3bc3b237 100644 --- a/drivers/net/wwan/t7xx/t7xx_netdev.c +++ b/drivers/net/wwan/t7xx/t7xx_netdev.c @@ -74,7 +74,7 @@ static int t7xx_ccmni_send_packet(struct t7xx_ccmni *ccmni, struct sk_buff *skb, return 0; } -static int t7xx_ccmni_start_xmit(struct sk_buff *skb, struct net_device *dev) +static netdev_tx_t t7xx_ccmni_start_xmit(struct sk_buff *skb, struct net_device *dev) { struct t7xx_ccmni *ccmni = wwan_netdev_drvpriv(dev); int skb_len = skb->len; -- 2.35.1