Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp5460942ybf; Thu, 5 Mar 2020 01:08:33 -0800 (PST) X-Google-Smtp-Source: ADFU+vsKSyJSXVf1cXL1PUZE9D50/0WB89lnNawuRu3t1LDBG4+Ens853PfVVHQhP/lvM1Tsh6in X-Received: by 2002:aca:4a4e:: with SMTP id x75mr4977115oia.16.1583399312915; Thu, 05 Mar 2020 01:08:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583399312; cv=none; d=google.com; s=arc-20160816; b=C8Xkc9XOh12jdyfC19XluZggPIByD5UQiT24fpDjt1JpryAh0yzOfQcwPjUxaa7fDN zFZgvo7TPteJSqVoM32QW1X1wi91wz69gqrNLxGSLMRSegX5+co+4q7V1CYUbWN8VquO oUOGFVbHlJwSBV+I9Ct86462iR9ooW8kVXP/sqNTZecm/IUl+bBnVf43WmKVMNAJWTnO sxQyHNbFgHLAWpLPzeLDD/iBX6qfWvNuUlRBgO2+Bkl6F/uOG7AqY5cHYrQ9sCm6L3Io 42PZ7xMKktwlugLJ8cGzCsjVYFsIXN/S1nEbXZu4iOpHL40EjF8ywhS0wuX5DBafh26o by5g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:mime-version:user-agent:date:message-id :subject:from:to:dkim-signature; bh=pveQNqjQrDxjxctTRbcArEI0/9cLLRZ+RHHbjAxefrg=; b=WAJik39IJ9QWh1jsy1In+8s/BhMWxrGbhFOaU9EZUh1NMuLnzg0Ql3nuzjn2M6eq9m WJpOEOSuGX5m82/+OXZGu9tWtnfZ+rArzesMGIJt/ri3ML2oFfMvUkZTA2o4RQ/yeYNr 6A3bn3BqdY3HmOsZki5708ADwvDMNHdAzZjplIyQserolb38frFWh3sSxbjmWh+lAPuQ 4v+Phbzk52frzWMr37oAEovyn1t9GkqLEDV1EONwBg2+Pn9Om/n/lIet23opF4PdlEs/ 7OwN/dFEw/3F3TzAZd/o9621jAlYuvUKySQmQ6JCuLUCBwSWDTJH6CB9GiCcGkAxHdpT b1uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Rtmnhz4n; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n1si3290017otf.102.2020.03.05.01.08.08; Thu, 05 Mar 2020 01:08:32 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Rtmnhz4n; spf=pass (google.com: best guess record for domain of linux-wireless-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-wireless-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727002AbgCEJHc (ORCPT + 99 others); Thu, 5 Mar 2020 04:07:32 -0500 Received: from mail-wr1-f44.google.com ([209.85.221.44]:34392 "EHLO mail-wr1-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725897AbgCEJHc (ORCPT ); Thu, 5 Mar 2020 04:07:32 -0500 Received: by mail-wr1-f44.google.com with SMTP id z15so6029794wrl.1 for ; Thu, 05 Mar 2020 01:07:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:from:subject:message-id:date:user-agent:mime-version :content-transfer-encoding:content-language; bh=pveQNqjQrDxjxctTRbcArEI0/9cLLRZ+RHHbjAxefrg=; b=Rtmnhz4nM7wCRYWgwrg9LX3V/n2xMK6NPTNst09JDb3miyVqOdoUt7TLwaY37mP53A jI0zz0OaLai4A8nPkMB0Qz1r/QZeQWANHegF04voHF6f8c+ZvrXWJ8tCxkp6E36wsD/n Lgh5pj4k8+6RiPf1BD4OLwcoSU1cljz57F3Evw11g61eaoeCDwXeCpmQi/acz1er8NiZ dgIcDnwT+HABn/q7jnkzWqWROblmmDg9Rpmjx1xt6a7ftWh8lGzT0zqo8Baku1C36jLk Y2J8bUe3WGbi66S2C1utsJhXuuC4y/YBU9DChgkd2Ym+ZJmBKN8d5mgITJaKX+FU/Bmn YU3w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-transfer-encoding:content-language; bh=pveQNqjQrDxjxctTRbcArEI0/9cLLRZ+RHHbjAxefrg=; b=tTI7pxwmmFhfiPThPKY9JoigCMzcokUcySTmfbUh6tPNNP/6/VyM59TrPfPPppPkvN AhSdu6NYqtF9JYyh4adJN9OAVDODUKzUS92M7F4NdQQtz/uDNj4/x8EjCtsXLz/a6Xjz SUxRghBgjl/4rslRj07dlSTtro/fWW71KbPI2/O9kxWKOAxakfeOvE6TzNZbQ/wbf4NJ 7ryIMoc8IMQHnePB4E2ClIik85xLR1980hUM9k/oTeZ75/BDp+vTg+XJGMu5Pjr4wsF+ ldZHsnhWrYXxlfHIDU0zp9Otm0aiHhfkBbXY3qIULIYiPD/59E0oCpBQYfVKnENZ3WX/ R10Q== X-Gm-Message-State: ANhLgQ2rRGjWIDUrRSSiWt4OQW28xk/crOATk2nxAR0I/kccKnNdB3Pk chtwsAErZxFMcu9nZ3M2C7Y= X-Received: by 2002:adf:b317:: with SMTP id j23mr77835wrd.413.1583399250014; Thu, 05 Mar 2020 01:07:30 -0800 (PST) Received: from [192.168.0.240] (178-117-183-57.access.telenet.be. [178.117.183.57]) by smtp.gmail.com with ESMTPSA id f127sm8639116wma.4.2020.03.05.01.07.28 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 05 Mar 2020 01:07:29 -0800 (PST) To: linux-wireless@vger.kernel.org, linuxwifi@intel.com From: Wei Liu Subject: Precise time synchronization via wifi interface (intel AX201 iwlwifi driver) Message-ID: <032f07e2-2771-619b-52b4-a25c8cd10f86@gmail.com> Date: Thu, 5 Mar 2020 10:07:29 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Hi, I am trying to achieve precise time synchronization via wifi interface. I used intel AX201 card, certified with TimeSync, 802.11v, mc. So I assume it has the capability to do hardware time stamp when running applications like linux ptp (http://linuxptp.sourceforge.net/) and gptp (https://github.com/Avnu/gptp). However I get error that seems to suggest the timestamp mode is not supported. After reading some source code, I discover that the /ptp4l/ application, or /gptp/, or /ethtool/ /-T/ , they all use a system call /ioctl/, which uses ethtool_ops call back to determine whether the hardware can do software/hardware timestamp. However when searching in the driver/net/wireless/iwlwifi directory, I don't see anywhere /ethtool_ops/ is being implemented in the driver. So this most likely is why all user space tools I tried seem to determine the card cannot do hardware and also software (driver level) transmit timestamp. Can someone tell me how I could run ptp like application to fully make use of the Timesync feature of intel card? Some more details below: root@localhost:/debug/tracing# ethtool -i wlp2s0 driver: iwlwifi version: 5.4.6-050406-generic firmware-version: 48.4fa0041f.0 expansion-rom-version: bus-info: 0000:02:00.0 supports-statistics: yes supports-test: no supports-eeprom-access: no supports-register-dump: no supports-priv-flags: no root@localhost:/debug/tracing# ethtool -T wlp2s0 Time stamping parameters for wlp2s0: Capabilities:         software-receive      (SOF_TIMESTAMPING_RX_SOFTWARE)         software-system-clock (SOF_TIMESTAMPING_SOFTWARE) PTP Hardware Clock: none Hardware Transmit Timestamp Modes: none Hardware Receive Filter Modes: none