Received: by 2002:a05:7412:d8a:b0:e2:908c:2ebd with SMTP id b10csp1100292rdg; Fri, 13 Oct 2023 10:09:06 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH/xx4C8QsCiE3sW2yP06923YBlO172Pvy8ZGgPs04G7T5s88tG/VFROEMRU+RRdKLSkcNn X-Received: by 2002:a17:902:e811:b0:1b8:8af0:416f with SMTP id u17-20020a170902e81100b001b88af0416fmr35867169plg.1.1697216946114; Fri, 13 Oct 2023 10:09:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697216946; cv=none; d=google.com; s=arc-20160816; b=NzlIKP/VWv87b8c12gY3dOPf4u/06hdeAp+cKt2iO077mai25hYFmQ0eGyc9LhVk3N NFbYgBgIC/SWyUwQFAotMHOROmnyaQ/5Yg34NvdWMVyGBtmMoi8QGATeNcnIpsRAyAN5 fzxPkuEeyYgFy3b+SRZIRYhEJ1wnbqaeQ7w2hojDk6+S+RlUdErk2tVVu3mFthdeDjLM 4oImwRXnEAcBGpUO8HLm8Vfd3ra3G+ADARa82VKnoOYKjqymPxDKKKiEjjnb+HOhf1u4 w1f84pBe90287pzdamTALeM9c9o+xFgX4O4wUju09I4rgPsCQAEQ/cfTK687c6X1UbU9 PhhA== 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=TksTCekXADksDkw6zz27tOiFc5jOxJuDTlx+GNP+MB4=; fh=AByxgCPPHJFcr3Ywbvra8GdCH8cU/fyFb3UIpf51sPU=; b=a6rrs4iGR4SIK6Ha1FRFAMkw089oPieKOAsCla5uNumkg6yW5whn/wf0c7Ey2p8i4P VhqQlh9r/GAdD5b1CdeSJA51yoAFk5Btl2YNw5XSQ40NEnDuM6V/D4h8fu1Gg4zYgHa3 lvjcttkfUVOQPFhGrSyu0uv8Gn6PZ9baV1PRO+4WG2IjV5sp5kG0+JULTlQMgaRocYYm 3lbGbtrNFcLHVWFox71iZOyOywLAFxBYC6Pm0tTu678SgU8e38tR6tLAnWOeifi4DGXT HenPegkGyB7+g8zk+zwBCNJIqGCapBi/WLg8+HsuGWvIbcoMr/du7446Mc1rLcIzh06D zOHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=c+U17X3Y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from howler.vger.email (howler.vger.email. [2620:137:e000::3:4]) by mx.google.com with ESMTPS id m16-20020a170902db1000b001b80ecdcb88si5266651plx.473.2023.10.13.10.09.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Oct 2023 10:09:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) client-ip=2620:137:e000::3:4; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=c+U17X3Y; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:4 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 79FB3833F8CB; Fri, 13 Oct 2023 10:09:03 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231248AbjJMRI6 (ORCPT + 99 others); Fri, 13 Oct 2023 13:08:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44808 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229726AbjJMRIt (ORCPT ); Fri, 13 Oct 2023 13:08:49 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2BCD7C0 for ; Fri, 13 Oct 2023 10:08:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1697216882; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=TksTCekXADksDkw6zz27tOiFc5jOxJuDTlx+GNP+MB4=; b=c+U17X3YHzp6ibhVUeXfN1wAHcdb4ovH1Q1Ayyo8iRLW2FjsWEAvJMqyfGuNBXqdGyMsBP s+UYszHEhhKOZD7rOf84GJg6cfxMfqaHZrXjP3ADq8eDzvLvITgtyUXEFmZ/SoOIgGOlNc FnHlEvjjvpyg03Gctkp76hwhIuKalI4= Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-449-p1fc9ffLPHa4J1LrbnZu_A-1; Fri, 13 Oct 2023 13:07:58 -0400 X-MC-Unique: p1fc9ffLPHa4J1LrbnZu_A-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 24E832800E84; Fri, 13 Oct 2023 17:07:58 +0000 (UTC) Received: from p1.luc.cera.cz (unknown [10.45.225.161]) by smtp.corp.redhat.com (Postfix) with ESMTP id 907BA1C060DF; Fri, 13 Oct 2023 17:07:56 +0000 (UTC) From: Ivan Vecera To: netdev@vger.kernel.org Cc: Jesse Brandeburg , Tony Nguyen , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , linux-kernel@vger.kernel.org, intel-wired-lan@lists.osuosl.org Subject: [PATCH net-next 0/5] i40e: Add basic devlink support Date: Fri, 13 Oct 2023 19:07:50 +0200 Message-ID: <20231013170755.2367410-1-ivecera@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.7 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Fri, 13 Oct 2023 10:09:03 -0700 (PDT) The series adds initial support for devlink to i40e driver. Patch-set overview: Patch 1: Adds initial devlink support (devlink and port registration) Patch 2: Refactors and split i40e_nvm_version_str() Patch 3: Adds support for 'devlink dev info' Patch 4: Refactors existing helper function to read PBA ID Patch 5: Adds 'board.id' to 'devlink dev info' using PBA ID Ivan Vecera (5): i40e: Add initial devlink support i40e: Split and refactor i40e_nvm_version_str() i40e: Add handler for devlink .info_get i40e: Refactor and rename i40e_read_pba_string() i40e: Add PBA as board id info to devlink .info_get drivers/net/ethernet/intel/Kconfig | 1 + drivers/net/ethernet/intel/i40e/Makefile | 3 +- drivers/net/ethernet/intel/i40e/i40e.h | 136 ++++++++--- drivers/net/ethernet/intel/i40e/i40e_common.c | 58 +++-- .../net/ethernet/intel/i40e/i40e_devlink.c | 224 ++++++++++++++++++ .../net/ethernet/intel/i40e/i40e_devlink.h | 18 ++ .../net/ethernet/intel/i40e/i40e_ethtool.c | 4 +- drivers/net/ethernet/intel/i40e/i40e_main.c | 40 +++- .../net/ethernet/intel/i40e/i40e_prototype.h | 3 +- drivers/net/ethernet/intel/i40e/i40e_type.h | 3 + 10 files changed, 414 insertions(+), 76 deletions(-) create mode 100644 drivers/net/ethernet/intel/i40e/i40e_devlink.c create mode 100644 drivers/net/ethernet/intel/i40e/i40e_devlink.h -- 2.41.0