From patchwork Tue Nov 29 00:05:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vincent Mailhol X-Patchwork-Id: 26986 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp23125wrr; Mon, 28 Nov 2022 16:13:27 -0800 (PST) X-Google-Smtp-Source: AA0mqf6aEAlDqYT18ClEjXEQSbjbqR94WVl84zNHAbEbt3Tfh0ikSY/wDAJp8ugR8ltxSK5WB3ZS X-Received: by 2002:a17:902:f707:b0:176:b0ce:3472 with SMTP id h7-20020a170902f70700b00176b0ce3472mr46743985plo.169.1669680807687; Mon, 28 Nov 2022 16:13:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669680807; cv=none; d=google.com; s=arc-20160816; b=XgOl9mHMeVARANMj4lx/k2vkfXliT6yXN+bPAmS7Ln41JIJKtac/jfi5cYjT0QNr+Q KmRJCqS+7k/Ms/Ua6y3X3oX0Bh8U7yEEQqFmjWkK+0A/W/kyKvkmib4pUHoCiSeuiQU2 cNsn+NJHhDYNxWTNRK6FydXnQ6AwCSwxH7E99H80BPf7utFlaTz/5expd22MvMdQTzHm CrOtVa5OOzyaY54pHhwwiGIv95GZdZUdCqeXuVNaBErbnkPfB8R9sD9IxWIE3e+3rJsy mSlV6UxuXVwrFiIthTknSbsomEWjKro6G76ZEPgALsu4EcHwfUzBtbf91p9alPToTr41 T10Q== 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:sender :dkim-signature; bh=DiKBx41kPdklVq60u1rvSJT+pX4e/ZYzQPE8Kx535cw=; b=cDyo+s69v1QHXX7E8kXiSYdzBaLOT4wYKLoiB4ftOSEv/BQEM+d8e+5VrdZh++Tq/Y 8BJjlibGT1LxW0IthekLUbcl5FWsCi+LxjxkOSIck0zTYthI8HDVsvkurw78kM9PCEwc LQ9kkLRRvI7AduxOG4kof86V46xPiFwqsCdmV05l0OGBUJSZgS7pisfxvtxHhNz/DERf QjY9ldP7vQc3FHh9x/kR3dO8rXTYoLI6np2u6uDADW2kCkfLgul/KTEVI0+nqcuhPHy+ SMPuX8t6MTrDaxKVK13HvXPpP1oXwlmwOk7+zwNhG2uiYvz/rznLx2kLKqurDnOjzdF4 /QBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=cuYXqB47; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id t6-20020a170902bc4600b001895a1d382dsi12147144plz.451.2022.11.28.16.13.07; Mon, 28 Nov 2022 16:13:27 -0800 (PST) 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=@gmail.com header.s=20210112 header.b=cuYXqB47; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234970AbiK2AH1 (ORCPT + 99 others); Mon, 28 Nov 2022 19:07:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40028 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234885AbiK2AGt (ORCPT ); Mon, 28 Nov 2022 19:06:49 -0500 Received: from mail-pj1-x1032.google.com (mail-pj1-x1032.google.com [IPv6:2607:f8b0:4864:20::1032]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D804B3F04D; Mon, 28 Nov 2022 16:06:39 -0800 (PST) Received: by mail-pj1-x1032.google.com with SMTP id t17so11074346pjo.3; Mon, 28 Nov 2022 16:06:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:from:to:cc:subject:date :message-id:reply-to; bh=DiKBx41kPdklVq60u1rvSJT+pX4e/ZYzQPE8Kx535cw=; b=cuYXqB47/KfnW4v14eUYsIp/vJ4Xx7KNP3dVstFmdoO9bHZ630CWx03yYvrh492DjD FHeaIW3sEwLURX7kvf2KKh9YFyW0Rpkd0OyiwVta4kAuxLqd0kdoduja3BGgFNO2CED4 V8vA6wK1ORYrSrV6VmUkU78b1OpyleUkYtxV6kfMtdZipam2QQR61cq/aMpkP97Alntx TnxPvdz5jPlV1RrFK5ZN+5lWIg/nkoGelr3V4jDtYFTChnHIhGEBRPnVGIV6sC7xaHmV JuzQ11I+cJKSJ5zwhIOR5LlOGBOD7ygXObJwKMmdjz1hS8pEHL4d9/WDR16T6EyY/pU+ DWgQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=DiKBx41kPdklVq60u1rvSJT+pX4e/ZYzQPE8Kx535cw=; b=swntjTGq5e0/pwXKzQjLBlXqwx3mqEtIG4HwGYGUapMuRORQqXdttbIX+O9ZBftrVj EN0RZfK5Dg0ll/yZ5XSK4LZ0DZDuSiNPMeYT6h+mRl7hiB5etnoy9r8JoQ6bNaUkNWVl qdgGtAFgAf2dAx4P6kFfDavguVkxQwARShB+4vtO43aZmAwpHrjpvHZSTfu9u4BtIdIz NyWmuwQWZbKK94lpBao/XEfH/dCdWa5cCQ2JjDfvn+yejXw4OLEI7wjcZ0qMcyf5/lQs y+rGKmLPjtiwiR0hc64Aq9oUt3Rkdz3Ak4iwCIaCiL+j4QYqjLTd3BhDiWr0j7c27+xX Azdg== X-Gm-Message-State: ANoB5pnudhG9/Aq8CD7/hKCvp1KoxjHqJ9jo1SfULCJuOIHs4mG5xTFx nrWgJrN82232T4mcD5ADWXg= X-Received: by 2002:a17:903:40c5:b0:186:738e:5703 with SMTP id t5-20020a17090340c500b00186738e5703mr46684785pld.136.1669680399242; Mon, 28 Nov 2022 16:06:39 -0800 (PST) Received: from XH22050090-L.ad.ts.tri-ad.global ([103.175.111.222]) by smtp.gmail.com with ESMTPSA id r2-20020aa79ec2000000b00572198393c2sm8588147pfq.194.2022.11.28.16.06.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Nov 2022 16:06:38 -0800 (PST) Sender: Vincent Mailhol From: Vincent Mailhol To: Jiri Pirko , netdev@vger.kernel.org, Jakub Kicinski Cc: "David S . Miller" , Eric Dumazet , Paolo Abeni , linux-kernel@vger.kernel.org, Boris Brezillon , Arnaud Ebalard , Srujana Challa , Kurt Kanzenbach , Andrew Lunn , Florian Fainelli , Vladimir Oltean , Michael Chan , Ioana Ciornei , Dimitris Michailidis , Yisen Zhuang , Salil Mehta , Jesse Brandeburg , Tony Nguyen , Sunil Goutham , Linu Cherian , Geetha sowjanya , Jerin Jacob , hariprasad , Subbaraya Sundeep , Taras Chornyi , Saeed Mahameed , Leon Romanovsky , Ido Schimmel , Petr Machata , Simon Horman , Shannon Nelson , drivers@pensando.io, Ariel Elior , Manish Chopra , Jonathan Lemon , Vadim Fedorenko , Richard Cochran , Vadim Pasternak , Shalom Toledo , linux-crypto@vger.kernel.org, intel-wired-lan@lists.osuosl.org, linux-rdma@vger.kernel.org, oss-drivers@corigine.com, Jiri Pirko , Herbert Xu , Hao Chen , Guangbin Huang , Minghao Chi , Shijith Thotton , Vincent Mailhol Subject: [PATCH net-next v5 4/4] net: devlink: clean-up empty devlink_ops::info_get() Date: Tue, 29 Nov 2022 09:05:50 +0900 Message-Id: <20221129000550.3833570-5-mailhol.vincent@wanadoo.fr> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221129000550.3833570-1-mailhol.vincent@wanadoo.fr> References: <20221129000550.3833570-1-mailhol.vincent@wanadoo.fr> MIME-Version: 1.0 X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE, SPF_PASS autolearn=no 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?1750787222590431034?= X-GMAIL-MSGID: =?utf-8?q?1750787222590431034?= devlink_ops::info_get() is now optional and devlink will continue to report information even if that callback gets removed. Remove all the empty devlink_ops::info_get() callbacks from the drivers. Signed-off-by: Vincent Mailhol Reviewed-by: Jiri Pirko --- drivers/net/ethernet/fungible/funeth/funeth_devlink.c | 7 ------- drivers/net/ethernet/marvell/octeontx2/af/rvu_devlink.c | 7 ------- drivers/net/ethernet/marvell/octeontx2/nic/otx2_devlink.c | 8 -------- 3 files changed, 22 deletions(-) diff --git a/drivers/net/ethernet/fungible/funeth/funeth_devlink.c b/drivers/net/ethernet/fungible/funeth/funeth_devlink.c index 6668375edff6..4fbeb3fd71a8 100644 --- a/drivers/net/ethernet/fungible/funeth/funeth_devlink.c +++ b/drivers/net/ethernet/fungible/funeth/funeth_devlink.c @@ -3,14 +3,7 @@ #include "funeth.h" #include "funeth_devlink.h" -static int fun_dl_info_get(struct devlink *dl, struct devlink_info_req *req, - struct netlink_ext_ack *extack) -{ - return 0; -} - static const struct devlink_ops fun_dl_ops = { - .info_get = fun_dl_info_get, }; struct devlink *fun_devlink_alloc(struct device *dev) diff --git a/drivers/net/ethernet/marvell/octeontx2/af/rvu_devlink.c b/drivers/net/ethernet/marvell/octeontx2/af/rvu_devlink.c index f15439d26d21..bda1a6fa2ec4 100644 --- a/drivers/net/ethernet/marvell/octeontx2/af/rvu_devlink.c +++ b/drivers/net/ethernet/marvell/octeontx2/af/rvu_devlink.c @@ -1547,14 +1547,7 @@ static int rvu_devlink_eswitch_mode_set(struct devlink *devlink, u16 mode, return 0; } -static int rvu_devlink_info_get(struct devlink *devlink, struct devlink_info_req *req, - struct netlink_ext_ack *extack) -{ - return 0; -} - static const struct devlink_ops rvu_devlink_ops = { - .info_get = rvu_devlink_info_get, .eswitch_mode_get = rvu_devlink_eswitch_mode_get, .eswitch_mode_set = rvu_devlink_eswitch_mode_set, }; diff --git a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_devlink.c b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_devlink.c index 5cc6416cf1a6..63ef7c41d18d 100644 --- a/drivers/net/ethernet/marvell/octeontx2/nic/otx2_devlink.c +++ b/drivers/net/ethernet/marvell/octeontx2/nic/otx2_devlink.c @@ -77,15 +77,7 @@ static const struct devlink_param otx2_dl_params[] = { otx2_dl_mcam_count_validate), }; -static int otx2_devlink_info_get(struct devlink *devlink, - struct devlink_info_req *req, - struct netlink_ext_ack *extack) -{ - return 0; -} - static const struct devlink_ops otx2_devlink_ops = { - .info_get = otx2_devlink_info_get, }; int otx2_register_dl(struct otx2_nic *pfvf)