From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) (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 DDAFA7E101; Sat, 27 Jul 2024 13:00:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.197 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722085218; cv=none; b=Wwzqyvk+QTDUfEtvOrqW5uSj2qxFbJYxz0G0k+XHaSzZFKb2DU/L5UYf/oLFfWCansfF6hXMlDwXZgPYcrVpCMFE+UQUz8bGILl4xo1XhqKl5X0SJjBPp6O094YuJwXS23j54OmgR0NYpTeoiFXLST9/t5ldaP2QtQSOOLWkPnI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1722085218; c=relaxed/simple; bh=47KKAW8Z4/5hyco3FTrmUIFgtVHf+0nvCgShB7JHDBs=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=X2zUxnkOL6lfLMWNNh+t1WfwgVHpyCOrULEQCDOJ2VmECljufeurZ91LOTzGdlGNytMBynUe/VbnfOEYPDYaASZ340xxoPgGYvEo6atkoI/D/zdBy21wUzPN5ge6shzu7R2wm2nOItHfQHWwHUW/FNGnHRK+3yig40leCfRaps0= 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=Aq1nh6jH; arc=none smtp.client-ip=217.70.183.197 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 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="Aq1nh6jH" Received: by mail.gandi.net (Postfix) with ESMTPSA id 5D0DD1C0005; Sat, 27 Jul 2024 13:00:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1722085213; 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=+7sZFvcJjRNHyS+j2zojU/F0BdHWiXiPM8DsgfUSK0s=; b=Aq1nh6jH/8cyaS5PIv1YmeknpQLS0EfUGjYXRrl9hGKdd3bk4p+QslAiWQfKqU2k2RnJk2 yTw79ECxBbCdoO6pp8FNsoJGrYdFZKycqI88/qLPawWeVL5R5//khYedsE34pdJWmOm3Ge kzZgOYFEE9mXSZ3MlauCerubSxL6TnPPAloO8dmU5j8HCvCvAuml02tvWvdnFCZpXGDZuk JZ1PMTcgXlMCkfkWu33lEAr8KYkL5bRnsdZkLInXDUmjiTRR3+VuCcmGcmPdOXjXK4Y2hV hPVFjeuzU0GqurPSC+n8EVxqgYr8qBCBHdr5vI0dDezpsxCckXHYKOXPKhQkmg== Date: Sat, 27 Jul 2024 15:00:09 +0200 From: Kory Maincent To: Jacob Keller Cc: Florian Fainelli , Broadcom internal kernel review list , Andrew Lunn , Heiner Kallweit , Russell King , "David S. Miller" , "Eric Dumazet" , Jakub Kicinski , "Paolo Abeni" , Richard Cochran , "Radu Pirea" , Jay Vosburgh , Andy Gospodarek , Nicolas Ferre , Claudiu Beznea , Willem de Bruijn , Jonathan Corbet , Horatiu Vultur , , Simon Horman , "Vladimir Oltean" , , , , Thomas Petazzoni , , , , Maxime Chevallier , Rahul Rameshbabu , Willem de Bruijn , Shannon Nelson , Alexandra Winter Subject: Re: [PATCH net-next v17 13/14] net: ethtool: Add support for tsconfig command to get/set hwtstamp config Message-ID: <20240727150009.66dcf0ae@kmaincent-XPS-13-7390> In-Reply-To: References: <20240709-feature_ptp_netnext-v17-0-b5317f50df2a@bootlin.com> <20240709-feature_ptp_netnext-v17-13-b5317f50df2a@bootlin.com> Organization: bootlin X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-doc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: kory.maincent@bootlin.com On Wed, 17 Jul 2024 10:43:05 -0700 Jacob Keller wrote: >=20 > > +The legacy configuration is the use of the ioctl(SIOCSHWTSTAMP) with a > > pointer +to a struct ifreq whose ifr_data points to a struct > > hwtstamp_config. +The tx_type and rx_filter are hints to the driver wha= t it > > is expected to do. +If the requested fine-grained filtering for incoming > > packets is not supported, the driver may time stamp more than just the > > requested types of packets. > > =20 >=20 > Does the core automatically handle SIOCSHWTSTAMP and SIOCGHWTSTAMP in > terms of the new API? I'm guessing yes because of the new > .ndo_set_hwtstamp ops? Yes. =20 > > A driver which supports hardware time stamping must support the > > -SIOCSHWTSTAMP ioctl and update the supplied struct hwtstamp_config with > > -the actual values as described in the section on SIOCSHWTSTAMP. It > > -should also support SIOCGHWTSTAMP. > > +ndo_hwtstamp_set NDO or the legacy SIOCSHWTSTAMP ioctl and update the > > +supplied struct hwtstamp_config with the actual values as described in > > +the section on SIOCSHWTSTAMP. It should also support ndo_hwtstamp_get = or > > +the legacy SIOCGHWTSTAMP. =20 >=20 > Can we simply drop the mention of implementing the legacy implementation > on the kernel side? I guess not all existing drivers have converted yet..= .? Yes indeed. In fact, Vlad has already worked on converting all the existing drivers: https://github.com/vladimiroltean/linux/tree/ndo-hwtstamp-v9 I can't find any patch series sent to net next. Vlad what is the status on = this? > I have a similar thought about the other legacy PTP hooks.. it is good > to completely remove the legacy/deprecated implementations as it means > drivers can't be published which don't update to new APIs. That > ultimately just wastes reviewer/maintainer time to point out that it > must be updated to new APIs. Yes but on the userspace side linuxPTP is still using the IOCTLs uAPI that = will become legacy with this series. Maybe it is still a bit early to remove tot= ally their descriptions in the doc? Regards, --=20 K=C3=B6ry Maincent, Bootlin Embedded Linux and kernel engineering https://bootlin.com