From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp3.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 18032D6DDF7 for ; Fri, 15 Nov 2024 12:38:28 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp3.osuosl.org (Postfix) with ESMTP id 32CF960875; Fri, 15 Nov 2024 12:38:27 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp3.osuosl.org ([127.0.0.1]) by localhost (smtp3.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id f5fi7u3bpb5U; Fri, 15 Nov 2024 12:38:25 +0000 (UTC) X-Comment: SPF check N/A for local connections - client-ip=140.211.166.142; helo=lists1.osuosl.org; envelope-from=intel-wired-lan-bounces@osuosl.org; receiver= DKIM-Filter: OpenDKIM Filter v2.11.0 smtp3.osuosl.org 95B3560836 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osuosl.org; s=default; t=1731674305; bh=S7qgfrRLINtmDz7DwpEPIMAyVu4yHld0Yj99jSXZo6c=; h=Date:From:To:Cc:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=2hO5aNrq3UwyxRGOHbd/hRQf3kln0x9KS66d8W+6Sn1T/rSgktD6XX3iQAiKmlZFO P2BJsuTz+Z4dGgTpHua1Xob7hUwzCNBdiKEEG+NB51i+M9D3zmhnmbeXpYOyPdNYVU zpDGncbxpbwHmHybXKiZMbeJ9tZnSclHjCudM7hyJW2xKzuY5IRhkBKtDu13HX0pyQ oIL9HAnXzHmciuqKCPQmdeGwnwB0kRNco69Vg8sBqDRlliEF3D8tIHmer0p69rhLOR yTYFT8XzpB/+c7YgJmKLZpk49eUsMY0lOn8+H3OJPvWV8DZshVsT5YaVj89E2nkong QG+hECemnbtpg== Received: from lists1.osuosl.org (lists1.osuosl.org [140.211.166.142]) by smtp3.osuosl.org (Postfix) with ESMTP id 95B3560836; Fri, 15 Nov 2024 12:38:25 +0000 (UTC) Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) by lists1.osuosl.org (Postfix) with ESMTP id 7BEDE27EB for ; Fri, 15 Nov 2024 12:38:24 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id 5C06D40188 for ; Fri, 15 Nov 2024 12:38:24 +0000 (UTC) X-Virus-Scanned: amavis at osuosl.org Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 8TrGKsJmHX02 for ; Fri, 15 Nov 2024 12:38:23 +0000 (UTC) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=139.178.84.217; helo=dfw.source.kernel.org; envelope-from=horms@kernel.org; receiver= DMARC-Filter: OpenDMARC Filter v1.4.2 smtp4.osuosl.org 7E0A540177 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp4.osuosl.org 7E0A540177 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by smtp4.osuosl.org (Postfix) with ESMTPS id 7E0A540177 for ; Fri, 15 Nov 2024 12:38:23 +0000 (UTC) Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 265615C569D; Fri, 15 Nov 2024 12:37:38 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id BF5E4C4CECF; Fri, 15 Nov 2024 12:38:20 +0000 (UTC) Date: Fri, 15 Nov 2024 12:38:18 +0000 From: Simon Horman To: Milena Olech Cc: intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org, anthony.l.nguyen@intel.com, przemyslaw.kitszel@intel.com, Alexander Lobakin Message-ID: <20241115123818.GM1062410@kernel.org> References: <20241113154616.2493297-1-milena.olech@intel.com> <20241113154616.2493297-2-milena.olech@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20241113154616.2493297-2-milena.olech@intel.com> X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1731674302; bh=wF9ZmkatT4npVqnDubQ5KfN4GgDfZfCVqUvTI3bcGlI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=hQ9uF404Rb8Fe30AtvBpJe7uvw0z8coYGXcY38WXEKq0/eGiOARc953oLR3/8efZJ XcI/BNaKhMSuK8FMO1zJXlzny7p9QSyQAe97b4DESuAiPamlBqQ5adnKwPu5TSBeAm 3VrDJbyPDzdS8k1GQZ57TfUJPaBTals0e5xIRX2xVFDlfq+8yM9xE5TZ4IlAly4myV l6Kc7xA3l8s0o3NeFwSRKkCgR3ZrXile4sA0cC6qUNqrKJQshdZk2pK6BKChtbJ2ot O1DpRzvuATqR4BqaLZ8NIwa6xom+fLLy6hmlH0fEQD1VlETF21FNCMYbXi+cCSFB+r BD7l9G3fBrH2A== X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Mailman-Original-Authentication-Results: smtp4.osuosl.org; dkim=pass (2048-bit key, unprotected) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20201202 header.b=hQ9uF404 Subject: Re: [Intel-wired-lan] [PATCH iwl-net 01/10] idpf: initial PTP support X-BeenThere: intel-wired-lan@osuosl.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Intel Wired Ethernet Linux Kernel Driver Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-wired-lan-bounces@osuosl.org Sender: "Intel-wired-lan" On Wed, Nov 13, 2024 at 04:46:09PM +0100, Milena Olech wrote: > PTP feature is supported if the VIRTCHNL2_CAP_PTP is negotiated during the > capabilities recognition. Initial PTP support includes PTP initialization > and registration of the clock. > > Reviewed-by: Alexander Lobakin > Signed-off-by: Milena Olech ... > diff --git a/drivers/net/ethernet/intel/idpf/idpf_ptp.h b/drivers/net/ethernet/intel/idpf/idpf_ptp.h > new file mode 100644 > index 000000000000..cb19988ca60f > --- /dev/null > +++ b/drivers/net/ethernet/intel/idpf/idpf_ptp.h > @@ -0,0 +1,32 @@ > +/* SPDX-License-Identifier: GPL-2.0-only */ > +/* Copyright (C) 2024 Intel Corporation */ > + > +#ifndef _IDPF_PTP_H > +#define _IDPF_PTP_H > + > +#include > + > +/** > + * struct idpf_ptp - PTP parameters > + * @info: structure defining PTP hardware capabilities > + * @clock: pointer to registered PTP clock device > + * @adapter: back pointer to the adapter > + */ > +struct idpf_ptp { > + struct ptp_clock_info info; > + struct ptp_clock *clock; > + struct idpf_adapter *adapter; > +}; > + > +#if IS_ENABLED(CONFIG_PTP_1588_CLOCK) > +int idpf_ptp_init(struct idpf_adapter *adapter); > +void idpf_ptp_release(struct idpf_adapter *adapter); > +#else /* CONFIG_PTP_1588_CLOCK */ > +static inline int idpf_ptp_init(struct idpf_adapter *adpater) nit: adapter > +{ > + return 0; > +} > + > +static inline void idpf_ptp_release(struct idpf_adapter *adpater) { } Ditto > +#endif /* CONFIG_PTP_1588_CLOCK */ > +#endif /* _IDPF_PTP_H */ ...