Received: by 2002:a05:7412:b10a:b0:f3:1519:9f41 with SMTP id az10csp2784203rdb; Mon, 4 Dec 2023 07:28:51 -0800 (PST) X-Google-Smtp-Source: AGHT+IG7fYWIrUm4ZyAmpdcEYAdt+pyGvIC41jn6RYldYSJmTM5pw7TGWyw5UeZ8aWU/vhQ4HJtz X-Received: by 2002:a17:90b:4f44:b0:285:fc67:6196 with SMTP id pj4-20020a17090b4f4400b00285fc676196mr3473355pjb.1.1701703731024; Mon, 04 Dec 2023 07:28:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701703731; cv=none; d=google.com; s=arc-20160816; b=yYlYdbos6w+9YLjFZMAwtu0kHSHc+DC3AT3N/hXgCwFT6HUgiaTP2FNzUSwpJF7dPu QZWN6umL3CjPUsV4Gnd/uPac1U2dC/bupbrcrIPM/eAMU4NYmmeHZiqJE+gX0UiBFAsg 0fM0x8VzrLlwZ2jYUsAiGktTuC3DMPiXFLx58v/MayK6dldGH14U/elFetuUNZ2LuyOw GJ7Rm5Ca5URx8GeBXLnTSeWeKBGQU9lhQiD2Bw3XqG3qtu6Bklq+bfqtGU+yu0YRhR2+ YgQp6LSGoGqK2ClSdN+MZyjsSY+Ssfk8z4IV9BEe9u/hvWbeGfchqVcxII4Zdtf04O8G KCrw== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=I0JOcf6jkxhgsas+jU7HoD00NuB8enDjPLTaHOqduD0=; fh=I4Frq8hy2PsYu5XYcvyXIAJ5MhlTZbOy+Hfm+AcLFIk=; b=1BG0czJougPgrL5bN8fPEW7P/1fW7WzHJOGSl+z75YaqHQEhHt5EIFA0SPBkxXpaE/ 7sTzqtepiVVDt0CyKC8/KYQvYadB8MRfaJy+I39inkEzKsqWjA7U87+Ks+CWGpYTEKyp xYHD3soh/zn+/BCNhBRuG1mjAHhJrSt3+qgeTLdby6zvjHThymuO4eiIl4OcQitYBW7j jPuWskTWwEKGGOC8c/BrmaBweDXoR41bNP1W0gWTKt1TQNWddzirJKNjx4fooycfr4ah NY/3kVjIZ8+JEGLinBdaN5Mg4YJHEpYd/fVgoQLDedBXkv54mxdXNB779RRCakmSZDAr r5uw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=WIp3PXXi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id pw5-20020a17090b278500b002839749088dsi4294550pjb.40.2023.12.04.07.28.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Dec 2023 07:28:51 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=WIp3PXXi; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id CCAD080AF813; Mon, 4 Dec 2023 07:28:44 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234119AbjLDP22 (ORCPT + 99 others); Mon, 4 Dec 2023 10:28:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37948 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231328AbjLDP21 (ORCPT ); Mon, 4 Dec 2023 10:28:27 -0500 Received: from relay1-d.mail.gandi.net (relay1-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::221]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8C8F2B0; Mon, 4 Dec 2023 07:28:32 -0800 (PST) Received: by mail.gandi.net (Postfix) with ESMTPSA id 9D4EE240009; Mon, 4 Dec 2023 15:28:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1701703708; 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=I0JOcf6jkxhgsas+jU7HoD00NuB8enDjPLTaHOqduD0=; b=WIp3PXXigOKUmqQlWs81eU0ETi9SOluh1iT/y7P8wqndtOZRUNjGwUuN5PUIFmqWUasfE0 wDXOHIiQ8oms3C9dcNLzivgpnhKlkUkYsYks/IvHI5/ozbvzV39ncvpIDP1pNrBlSjGkto vRzqRUZmXUuQOqx/01B3/fMqOUnPv6gmYdFhQsRm9YxBITcnFc5De9BYSoGxBIrqy5mump YPa+/IF0L7aagdbcXfmCpk9EnY3qdlfgC3nhU6uXt2VOiYKk4nMJz9Mo8MLClM9TcXuMRS 1fDoLiCxEB5vNg21VJFNY1oSDaDpgPDHVguVyrfNDBHIXvtt3RzDh2Qahl0pbQ== Date: Mon, 4 Dec 2023 16:28:25 +0100 From: =?UTF-8?B?S8O2cnk=?= Maincent To: Andrew Lunn Cc: "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 , Thomas Petazzoni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, devicetree@vger.kernel.org, Dent Project Subject: Re: [PATCH net-next v2 4/8] net: ethtool: pse-pd: Expand pse commands with the PSE PoE interface Message-ID: <20231204162825.40e566fe@kmaincent-XPS-13-7390> In-Reply-To: References: <20231201-feature_poe-v2-0-56d8cac607fa@bootlin.com> <20231201-feature_poe-v2-4-56d8cac607fa@bootlin.com> Organization: bootlin X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: kory.maincent@bootlin.com X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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]); Mon, 04 Dec 2023 07:28:45 -0800 (PST) On Sun, 3 Dec 2023 19:45:18 +0100 Andrew Lunn wrote: > > @@ -143,6 +150,43 @@ ethnl_set_pse(struct ethnl_req_info *req_info, str= uct > > genl_info *info) return -EOPNOTSUPP; > > } > > =20 > > + if (!tb[ETHTOOL_A_PODL_PSE_ADMIN_CONTROL] && > > + !tb[ETHTOOL_A_C33_PSE_ADMIN_CONTROL]) > > + return 0; =20 >=20 > -EINVAL? Is there a real use case for not passing either of them? No indeed. > > + > > + if (tb[ETHTOOL_A_PODL_PSE_ADMIN_CONTROL] && > > + !(pse_get_types(phydev->psec) & PSE_PODL)) { > > + NL_SET_ERR_MSG_ATTR(info->extack, > > + tb[ETHTOOL_A_PODL_PSE_ADMIN_CONTROL], > > + "setting PSE PoDL admin control not > > supported"); > > + return -EOPNOTSUPP; > > + } > > + if (tb[ETHTOOL_A_C33_PSE_ADMIN_CONTROL] && > > + !(pse_get_types(phydev->psec) & PSE_C33)) { > > + NL_SET_ERR_MSG_ATTR(info->extack, > > + tb[ETHTOOL_A_C33_PSE_ADMIN_CONTROL], > > + "setting PSE PoE admin control not > > supported"); =20 >=20 > This probably should be C33, not PoE? >=20 > I guess it depends on what the user space tools are using.=20 Yes, I have hesitated on replacing that one. If you prefer c33 in the log, I will change it in next version Regards, --=20 K=C3=B6ry Maincent, Bootlin Embedded Linux and kernel engineering https://bootlin.com