From patchwork Mon Apr 17 20:55:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 84465 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2404717vqo; Mon, 17 Apr 2023 14:11:41 -0700 (PDT) X-Google-Smtp-Source: AKy350ZwcpC1rP1wh0yK8gkVWH5bcwTtB/RDEEd8yJ3TMjzfnrJv93JRjBHMdg/abSfXq99VUc5z X-Received: by 2002:a17:90b:380c:b0:246:fdcc:f84c with SMTP id mq12-20020a17090b380c00b00246fdccf84cmr15265330pjb.35.1681765900744; Mon, 17 Apr 2023 14:11:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681765900; cv=none; d=google.com; s=arc-20160816; b=RoEdw6n/GvQVBXryyCb/cGQlF4jZAoZbAwzqPMFdnVp6W7CjzbGBE+vWsUoEhYdX8f ku6K/eaaK1EAvSdyIr6FAPnC8Q4f//aKMhg8xhFZuF3+xGsGig2Z85hfTu7YT0TgVL9S LYwUmWyDTgV/GKql9oRMfooOCKT/gMqCQMwvzJ+LHQiMvcUBowDK+uTaz2NsoXtzLAFC DE9Rxrp4Ew2vXc19Jv28RFX9nPiRkxYU90JIFuzku0hQOvd/7iDowF8E3miBiL/ifenS NytZNYCmikToAg2WcVjr7p197jtMgEknfeBOBLKWBYZ5heGfu1lUcpWXH0PTHWYi/9F6 jU2Q== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=Y5PSG8AavjoBPAFJwWSD1jFIcE5sqZs1O35q3ykZ1hI=; b=faNiJ1c/urkSN/1w0nHaQpa4iUc6gefZflwxwrPQfFS62td4X+u82/w7k5YGuhBPGO /vVOgzS7wqkEQpBNneKfGbL0LTFiNoedN9t3IGKROYvfIEZCYq5Tp08gNN/UvayuzPTZ 65QrraN13Pfs7WhllvFsfQjp0Acp36ryX08hhZXpNg7kGPmCXLorDTPaAXqctmeR0U0T 4HIDqx6T3Fu5rsHvP5KfVuAkCyrHMpbnWpu7R/I2ebevNAxaZQVlHIji/IbxY82OcMfw JDO8H2cEo4KGHJ4jzajaZtPGw0Wa76bkgTxa7atpQbdeoFNHMfHbDyZ66AfSA0BdDPxc HXng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Yi/vRXGl"; 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: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id pi19-20020a17090b1e5300b002477ddfa2f3si5624038pjb.182.2023.04.17.14.11.28; Mon, 17 Apr 2023 14:11:40 -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="Yi/vRXGl"; 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 S231307AbjDQU6z (ORCPT + 99 others); Mon, 17 Apr 2023 16:58:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46068 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231130AbjDQU6e (ORCPT ); Mon, 17 Apr 2023 16:58:34 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 38D039747; Mon, 17 Apr 2023 13:56:28 -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 DF82062A6A; Mon, 17 Apr 2023 20:55:37 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B9C33C433EF; Mon, 17 Apr 2023 20:55:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1681764937; bh=buAWzCxZJq6sFI4FVlHCCkhTeXIXRB+HhrOpnqKq2Bo=; h=From:To:Cc:Subject:Date:From; b=Yi/vRXGl+Fe7SQP2xUdVEqghN1XlXMudVEM97w32prLWMGIYMUIuY0ZcCTdrbu1f5 J9NkrHqcnFDdmdDp5Pd8Hsf/BGymT+zhvTr/0cTdnZQBTNLlUUdicBBLFR95ShPeA9 K65/Nr7u7QJ4b/afXFxmGEQsGyxp5wjCRicJt/FpnnRTOR3K8pmhLn9BXllMawhzAe S5t2qDBsXvyjNSX3CY9IjGwiBm8UZCA7P2SdwDHuwq4eN4mNjKDsb9ZkEVJCpHLrcZ +MldcW6U/WPovGo6wYxJztk4NxK2ZvwjjnTJ3zp+JHeywP0t9UXrYcrYR2Fc0W1RIj 7mB6ACQheIrkA== From: Arnd Bergmann To: Vladimir Oltean , Claudiu Manoil , Alexandre Belloni , UNGLinuxDriver@microchip.com, "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Jacob Keller Cc: Arnd Bergmann , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] net: mscc: ocelot: remove incompatible prototypes Date: Mon, 17 Apr 2023 22:55:25 +0200 Message-Id: <20230417205531.1880657-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 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,T_SCC_BODY_TEXT_LINE 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1763459360792510995?= X-GMAIL-MSGID: =?utf-8?q?1763459360792510995?= From: Arnd Bergmann The types for the register argument changed recently, but there are still incompatible prototypes that got left behind, and gcc-13 warns about these: In file included from drivers/net/ethernet/mscc/ocelot.c:13: drivers/net/ethernet/mscc/ocelot.h:97:5: error: conflicting types for 'ocelot_port_readl' due to enum/integer mismatch; have 'u32(struct ocelot_port *, u32)' {aka 'unsigned int(struct ocelot_port *, unsigned int)'} [-Werror=enum-int-mismatch] 97 | u32 ocelot_port_readl(struct ocelot_port *port, u32 reg); | ^~~~~~~~~~~~~~~~~ Just remove the two prototypes, and rely on the copy in the global header. Fixes: 9ecd05794b8d ("net: mscc: ocelot: strengthen type of "u32 reg" in I/O accessors") Signed-off-by: Arnd Bergmann Reviewed-by: Vladimir Oltean --- drivers/net/ethernet/mscc/ocelot.h | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/mscc/ocelot.h b/drivers/net/ethernet/mscc/ocelot.h index d920ca930690..ed024d6504c5 100644 --- a/drivers/net/ethernet/mscc/ocelot.h +++ b/drivers/net/ethernet/mscc/ocelot.h @@ -94,9 +94,6 @@ int ocelot_mact_forget(struct ocelot *ocelot, struct net_device *ocelot_port_to_netdev(struct ocelot *ocelot, int port); int ocelot_netdev_to_port(struct net_device *dev); -u32 ocelot_port_readl(struct ocelot_port *port, u32 reg); -void ocelot_port_writel(struct ocelot_port *port, u32 val, u32 reg); - int ocelot_probe_port(struct ocelot *ocelot, int port, struct regmap *target, struct device_node *portnp); void ocelot_release_port(struct ocelot_port *ocelot_port);