Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp2076651lqe; Tue, 9 Apr 2024 08:55:55 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX3EvXz1P0wb3rZCAk3Yg23macxxxCuxN8yMfR/TR8TmvVVHOebom2F1RWyP66FYnvzVWOpC7IL2Lsn1CmCvzGeP97r4ctxpMst4y2Jhw== X-Google-Smtp-Source: AGHT+IFmAesbGI1Ro3uPRt0sR2LvpKm8RcRiwV2ZijWIvT1V1In56UGpxAivX8hAHYgIlC7iy4T4 X-Received: by 2002:a05:6358:980c:b0:186:f3f:3252 with SMTP id y12-20020a056358980c00b001860f3f3252mr287758rwa.14.1712678154669; Tue, 09 Apr 2024 08:55:54 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712678154; cv=pass; d=google.com; s=arc-20160816; b=rM89nfKw7t4ABP+KhfeOdhF5aaXu+hcYHweMHxbCSZ34qQWF45JG1wQyPEkfONJCck 9ZvlIlKPocAEDohSVfEBsf/cctN4snFrJaI5QDWySc4JgyUJOUdxuFiiXCeQlJtBrIdM 5mtW0CWDfTdVyEhvkAOZloevMOW2IOSmao7kcZvTZW0vWBfnyBeloZFh6qDjtQqKjdXl 8yMzDu3OSdDMEdwds2yvWMfeOi/NUaRS++7H8oNqjIQHzL8OqCzu4Qz76x29c/iby0Gy GYzvhtXKq/oW52g6UgN3znbjkX1WnLT4QhMLvh/xwvsN8eSpJU+vKUwwotJgjWlG0F53 VODQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=Mfjnd/jmwSmdNqKx68d1jHwlBJ65ByZrCnoxiBN0fyA=; fh=57ylmEJf4L+ab5JW9VDoPKBjQbUSU1WR6XAwF32mgs8=; b=a1DYon8mc7NmXKGuJt90x+ktTNr7xx8O2wpRgKD+tDrn/ttvECbIXSy2wZwC15k98R ch2f55ZIWFFmsrtE/pt+aY1mUhkwSK0a/DIQj1ZI8yNyGBCV+YW+frotI42KMfOVUIfb Qd6z5u2pWz70sj8TUu6ld5ozAn/n3CIYV59m8yHAcb8f0tRzcIL0BoAdEQ6sctgVdYMb Mfm/69tADvcG3d6r/EnHT3Psggj1dx2hzO2SALsjKqSYgRjzBHH2wbPTBYbk8BvMtJiP eoi/8oewMZffjh87JyeKqe3og0LaWu2NqbmWA6QNRK92dFljHrcDAc6P32///GWJMljT RRIg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=lIm6B6F8; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-137165-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-137165-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id m12-20020a63f60c000000b005dc8762dce5si8879123pgh.51.2024.04.09.08.55.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Apr 2024 08:55:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-137165-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=lIm6B6F8; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-137165-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-137165-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 5EBFDB2B621 for ; Tue, 9 Apr 2024 15:07:23 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 45B84137C51; Tue, 9 Apr 2024 15:04:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="lIm6B6F8" Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [217.70.183.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4FFD413329C; Tue, 9 Apr 2024 15:04:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.198 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712675073; cv=none; b=G40PU3nj4Zy//tu6T6ODrqOmRCGRRLTdyLymKqovtOgZ6MSz3oMoKR4xF7OxrKLlNStYp8FkcpgYFwqY2OzHH4Qn6JO23RujxUjL8PFvpLQh6g0C5/HBiH7x1a/HqNSykIWXpq4RXAjeV/w6/027wN1cjSmehZ6hZAL2A1AEptg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712675073; c=relaxed/simple; bh=5rJBQL9W4c23cFyKDiMazSItHw8/Ze0y4gqR4/1+9x8=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=QTc6nVmEWrqHLXtWHvWaWgq5BIZg9AwgXy8ACpq1hQY/FxBzRxlCDMCldZAiFu4vqAfQP1nVr3GyrFvenwlVbWd2RNTp4oIYq69P4NTnzdaoG/bv0y9/QCdUEstnihdxk+8ZkWjQogf0SDN33MRV3R39v0RahnoqMH0n76rUXaM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=lIm6B6F8; arc=none smtp.client-ip=217.70.183.198 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Received: by mail.gandi.net (Postfix) with ESMTPSA id C5A45C0009; Tue, 9 Apr 2024 15:04:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1712675061; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Mfjnd/jmwSmdNqKx68d1jHwlBJ65ByZrCnoxiBN0fyA=; b=lIm6B6F8Uurwx1/NNXbcDwjESQizvBOH4XX/vA1P/edzgE/D0hNDpfcTkPklSijpdqLmeh 5MTydy5DVOzReqM67M+L8dukFY9I17QKgJ65Fc7MCmB4ZZGuhJNNKTU6ta04HCEBzGrkRi lr99SPiXpek2B3zGgYVkDWOJTAsxi8A9gHwC9dYvG+AD+onJufU9+X9EmOTwTdTly5BPpR H5JuuBSIuNCm4Tq/VQKtq/uDnWL3iCPp+xLe1xKdkAN6vAGDQz+bfRXLeYGXVZ49p3Wt9i tma4SwQW2ZnCZZwA3YVHt1DLr92KsCnLIhy2aBSQE0jKl4xh8tZFqd1r00UNLw== From: Kory Maincent Date: Tue, 09 Apr 2024 17:03:53 +0200 Subject: [PATCH net-next v7 03/17] net: pse-pd: Rectify and adapt the naming of admin_cotrol member of struct pse_control_config Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240409-feature_poe-v7-3-11e38efd4dee@bootlin.com> References: <20240409-feature_poe-v7-0-11e38efd4dee@bootlin.com> In-Reply-To: <20240409-feature_poe-v7-0-11e38efd4dee@bootlin.com> To: "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Jonathan Corbet , Luis Chamberlain , Russ Weight , Greg Kroah-Hartman , "Rafael J. Wysocki" , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Oleksij Rempel , Mark Brown , Frank Rowand , Andrew Lunn , Heiner Kallweit , Russell King Cc: Thomas Petazzoni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, devicetree@vger.kernel.org, Dent Project , kernel@pengutronix.de, Maxime Chevallier , Kory Maincent X-Mailer: b4 0.14-dev X-GND-Sasl: kory.maincent@bootlin.com From: Kory Maincent (Dent Project) In commit 18ff0bcda6d1 ("ethtool: add interface to interact with Ethernet Power Equipment"), the 'pse_control_config' structure was introduced, housing a single member labeled 'admin_cotrol' responsible for maintaining the operational state of the PoDL PSE functions. A noticeable typographical error exists in the naming of this field ('cotrol' should be corrected to 'control'), which this commit aims to rectify. Furthermore, with upcoming extensions of this structure to encompass PoE functionalities, the field is being renamed to 'podl_admin_state' to distinctly indicate that this state is tailored specifically for PoDL." Reviewed-by: Oleksij Rempel Reviewed-by: Andrew Lunn Signed-off-by: Kory Maincent --- drivers/net/pse-pd/pse_regulator.c | 8 ++++---- include/linux/pse-pd/pse.h | 4 ++-- net/ethtool/pse-pd.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/net/pse-pd/pse_regulator.c b/drivers/net/pse-pd/pse_regulator.c index e2bf8306ca90..1dedf4de296e 100644 --- a/drivers/net/pse-pd/pse_regulator.c +++ b/drivers/net/pse-pd/pse_regulator.c @@ -31,10 +31,10 @@ pse_reg_ethtool_set_config(struct pse_controller_dev *pcdev, unsigned long id, struct pse_reg_priv *priv = to_pse_reg(pcdev); int ret; - if (priv->admin_state == config->admin_cotrol) + if (priv->admin_state == config->podl_admin_control) return 0; - switch (config->admin_cotrol) { + switch (config->podl_admin_control) { case ETHTOOL_PODL_PSE_ADMIN_STATE_ENABLED: ret = regulator_enable(priv->ps); break; @@ -43,14 +43,14 @@ pse_reg_ethtool_set_config(struct pse_controller_dev *pcdev, unsigned long id, break; default: dev_err(pcdev->dev, "Unknown admin state %i\n", - config->admin_cotrol); + config->podl_admin_control); ret = -ENOTSUPP; } if (ret) return ret; - priv->admin_state = config->admin_cotrol; + priv->admin_state = config->podl_admin_control; return 0; } diff --git a/include/linux/pse-pd/pse.h b/include/linux/pse-pd/pse.h index fb724c65c77b..199cf4ae3cf2 100644 --- a/include/linux/pse-pd/pse.h +++ b/include/linux/pse-pd/pse.h @@ -15,11 +15,11 @@ struct pse_controller_dev; /** * struct pse_control_config - PSE control/channel configuration. * - * @admin_cotrol: set PoDL PSE admin control as described in + * @podl_admin_control: set PoDL PSE admin control as described in * IEEE 802.3-2018 30.15.1.2.1 acPoDLPSEAdminControl */ struct pse_control_config { - enum ethtool_podl_pse_admin_state admin_cotrol; + enum ethtool_podl_pse_admin_state podl_admin_control; }; /** diff --git a/net/ethtool/pse-pd.c b/net/ethtool/pse-pd.c index cc478af77111..aef57a058f0d 100644 --- a/net/ethtool/pse-pd.c +++ b/net/ethtool/pse-pd.c @@ -130,7 +130,7 @@ ethnl_set_pse(struct ethnl_req_info *req_info, struct genl_info *info) struct phy_device *phydev; /* this values are already validated by the ethnl_pse_set_policy */ - config.admin_cotrol = nla_get_u32(tb[ETHTOOL_A_PODL_PSE_ADMIN_CONTROL]); + config.podl_admin_control = nla_get_u32(tb[ETHTOOL_A_PODL_PSE_ADMIN_CONTROL]); phydev = dev->phydev; if (!phydev) { -- 2.34.1