From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id D3F6F43802; Wed, 3 Jan 2024 03:26:39 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 59B4B402BC; Wed, 3 Jan 2024 03:26:39 +0100 (CET) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by mails.dpdk.org (Postfix) with ESMTP id 1469B402A3 for ; Wed, 3 Jan 2024 03:26:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1704248798; x=1735784798; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=7A5ml0qrlPu1tKmGOlInAg8PEdop7WE5W6+zIf9tToU=; b=PZFig3pfPK7u8dwZh31M9hYJ3Amo2U4dMXC6HqYCfmLB/yR1if7J2IVD apNAuuHjoATaY6NSDNIX8VKk6DoeMYwKqMsfkSNNamNURhdwPqBLYlpSb ayYmRsPgl7/bhuww6RuHsWpW5pKUAPJT6le4vMKkZMmDO9B9204JeDTrN ZrZJwbOCBqpDn48oOvio6radplWWrdJrLOi+5a+fWV3k4QWDRK0zlcuge WTkMCgaGYKSMSMAkglbp4w2v0QGe+gfbzA7K+1s9pvPq6NNEGZ2G3exDY Zpd/rCSwp4e53VviRHTZpFixVG0UIOmnmV2ik89cnI1Pa618pk5nImVnQ A==; X-IronPort-AV: E=McAfee;i="6600,9927,10941"; a="3787319" X-IronPort-AV: E=Sophos;i="6.04,326,1695711600"; d="scan'208";a="3787319" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Jan 2024 18:26:20 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10941"; a="783371449" X-IronPort-AV: E=Sophos;i="6.04,326,1695711600"; d="scan'208";a="783371449" Received: from orsmsx602.amr.corp.intel.com ([10.22.229.15]) by fmsmga007.fm.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 02 Jan 2024 18:26:19 -0800 Received: from orsmsx610.amr.corp.intel.com (10.22.229.23) by ORSMSX602.amr.corp.intel.com (10.22.229.15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Tue, 2 Jan 2024 18:26:19 -0800 Received: from ORSEDG602.ED.cps.intel.com (10.7.248.7) by orsmsx610.amr.corp.intel.com (10.22.229.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35 via Frontend Transport; Tue, 2 Jan 2024 18:26:19 -0800 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (104.47.59.168) by edgegateway.intel.com (134.134.137.103) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.35; Tue, 2 Jan 2024 18:26:19 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=kjVuLDQGlxzyywGBlWrAA9FwEtsVmcprUBczEFZDpiWh/J2LCVOAbjIoo56yZHU+i8VlXjI+KlU0jS99NNEMu1Vsessnfuc2jVK88QXx4nqJmr1b9N/boRM+EWnqIfHhQkrWcTeQAGdlUKn4OElMHbIVLn2RFA2hPvbh9h5kKw044mAgXR4kRZOBF/ww+I3r4q7zKVNdgcDnIASTdXEdqxmzlkwosrDU2GCD1uP9RB9eDLxT67/N16BJmsIwWUXI93r3alTgWx80GfF3qci1lVzcK5jaQMNE1+dfXMFdXItsZcyybyg81sPDny7po0cwuGQztH1/pw4msNKy8f1ZKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=3H8Skqe9eXzLm4DUe8EiPu1SUVVKo0vroeNe4XujzaY=; b=mOs8EJRJVoFd4ImknpfU3W/tnBVsVWKga/AVETAJP44bmR/xg13r54lDuCt9WH+kOwC4wBDGsCHtLIP2rDCyNJylmTxacrZ7MhwHgyVgi9kCYY+m7Nt73B0xIvcrpM1SSZS+bNXNCySedC0tQ5//XgpjVhqqio0NE6vbLuaDia8sATVrP8rk8yazAROZ1SHKmTca12sE0CFiwFwiuczvTAagRuE5MaeRdZxpBmiVfdP2qUy+rciDcWzuqCnNrd8M68I2xHHZeDi5CUgwGodEs4Vqh2Vlv0A2W7jVMTKpGEZnWDBslKWMoTLxwMBx2gKZ5xv9PfK/kFQez7samv4gPQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Received: from SA1PR11MB6613.namprd11.prod.outlook.com (2603:10b6:806:254::9) by PH7PR11MB6747.namprd11.prod.outlook.com (2603:10b6:510:1b5::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7135.23; Wed, 3 Jan 2024 02:26:17 +0000 Received: from SA1PR11MB6613.namprd11.prod.outlook.com ([fe80::a2fb:a414:62ba:bfbb]) by SA1PR11MB6613.namprd11.prod.outlook.com ([fe80::a2fb:a414:62ba:bfbb%4]) with mapi id 15.20.7159.013; Wed, 3 Jan 2024 02:26:17 +0000 From: "Su, Simei" To: Chuanyu Xue CC: "Xing, Beilei" , "dev@dpdk.org" , "Zhang, Qi Z" , "Lu, Wenzhuo" Subject: RE: [PATCH] net/e1000: support launchtime feature Thread-Topic: [PATCH] net/e1000: support launchtime feature Thread-Index: AQHaMSa05jg+eXAv1UiAlNWb6QLwv7CxppGQgAL+FgCABKkUsIAHjDMAgAaG4oA= Date: Wed, 3 Jan 2024 02:26:17 +0000 Message-ID: References: <20231229212934.98657-1-chuanyu.xue@uconn.edu> In-Reply-To: <20231229212934.98657-1-chuanyu.xue@uconn.edu> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: SA1PR11MB6613:EE_|PH7PR11MB6747:EE_ x-ms-office365-filtering-correlation-id: 822bb360-95f4-4279-008e-08dc0c035d66 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: NlgPyPblRFOIF3ZCZedn920Soqey+eSPs+nzl9Eb8NKdSkFVc8XBLis4sNhKtOqlU0DbXH/QizZkM98hhmEimC0z74ciw5N9COYIRD1CXhGJoSW4Op7dfimtKEkrtTw4rb/JU9/agqgVk5Uf239nIvrZ06Xd3ZPZNEfwA2xU4y/5sYjDyCvWJl+5wfODAzx+O8KKMs9i8kmSFdOzURGl/WsXzicBP8lCzAKUJmOYLXBY44dvJn3DAW+lzsV/X4tS7r+NFcz1H1UTsb3pq0QoGYL1IgMNKHub7iy+GZA02h2dQ1yqVnkAGFb7dtw2/3PHG1sskv2JDfO/nDr0ak3Ewrh/HHj2dXjDSQQCURcUF2bKBDEJCj6Wpqd3cOkyIBfxf2xwv+u7PLpiX00F1vfc4yR8fzOG9ppPyrCmL+8EIHwgYHZ8ejcwlMjWg8GAPfyevJ1PN3n5m1JqXhwDl0JYcD/Sz0kS98g56Yosmi1XEEA8FrFg4ZUZuG6Ps/3kAHy7X+1Up24APp6kgPgcFwfhC/s9FnZXneRS2lUfI91Qxk1qzq/MizNQB1e28MgWLg/KVxovRV6rRGItn2r8ec5QtPR778gXbCny2Q+r7Seq3d/cRCZTsTXzgkdSFS0DTnLi x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SA1PR11MB6613.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230031)(346002)(366004)(136003)(376002)(396003)(39850400004)(230922051799003)(64100799003)(186009)(451199024)(1800799012)(55016003)(83380400001)(107886003)(86362001)(6506007)(38070700009)(82960400001)(33656002)(38100700002)(52536014)(9686003)(7696005)(71200400001)(54906003)(4326008)(53546011)(316002)(5660300002)(66946007)(8936002)(296002)(64756008)(66556008)(8676002)(66446008)(2906002)(66476007)(122000001)(76116006)(6916009)(41300700001)(478600001); DIR:OUT; SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?nq9YhNOTn5iKkOzKzJYLakRQt0SmUbjclH0tQ8JNS+CAFigphJhwFyjOohyM?= =?us-ascii?Q?CSP8FopSap1hPAYvlCMGxsWr/Og6+FQe3AqVivwfEOtRnlyiOVpyIQjaMckb?= =?us-ascii?Q?9dzo9MMVUrETg2Iv4Ad8uBRg2tbX5u9NBA/Yyi0rfak5Vc45WUOjqVto2BVk?= =?us-ascii?Q?VKM1VEcIHBQfb2Cy/Mtb97XdcduXWr677nTLMznwvJvlgmfm0G12QJm29BUH?= =?us-ascii?Q?+qS8DVyJZcYKV9Boz0IztIwWZfl0z2ssJNGbil7bAjkEn/I6t6oVkuWleEIU?= =?us-ascii?Q?QR4EqUMILf9juRlwSwCVqJHR9iM1m0k2vKcHyBDm/vakXPbLw9TYcIeDOL3P?= =?us-ascii?Q?5nH776Aa+Vp/GGf2hTIromxvK6R7Rzj1uv2AlRiNeah4a/P1oIM42Z9zKz6u?= =?us-ascii?Q?wn/Y1kCyeKgxtykD21kh0evbQRNpM5WCmsIl5VTWoXm62IAmOeFIo+EzHlvM?= =?us-ascii?Q?zf2kQS6Eh0HV3GPJjTJxUBcyrg7CuTZ2lHEdNEhX58rtBZia+nPXPfv1pVC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86TpOUB+3z9kHn1J9ys9u6f8RGuD+?= =?us-ascii?Q?rHBXCgHapjHTmK26SD5im6x+eRRgzYqyPlvizEZ1m2rXLRdROyozriZNRg4P?= =?us-ascii?Q?UiNlYx7Uwo4iNgAG+QBK6ijd9wyXhd4OgWNqqesvCJ5PoDh4vUfhKP1KlW9V?= =?us-ascii?Q?KPlxym5fRqOtNh2xx+9q38k+66Wj1RRxCsNhA6jbPvzM/XvCiHnU8kkXruvV?= =?us-ascii?Q?Gf1elRLI86bOF9Z7uDg+61lX+1Xbg0rWpQGeg/XT6AHO?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SA1PR11MB6613.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 822bb360-95f4-4279-008e-08dc0c035d66 X-MS-Exchange-CrossTenant-originalarrivaltime: 03 Jan 2024 02:26:17.0964 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 33tCFjWu3NTZ9ZnDFMd8hQKF9X0BrepwxGzTypOl90g2sHZqpGqEV8HKt/QyO0YUghMfUdweD0o7vqneZwC4Dg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR11MB6747 X-OriginatorOrg: intel.com X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Hi Chuanyu, > -----Original Message----- > From: Chuanyu Xue > Sent: Saturday, December 30, 2023 5:30 AM > To: Su, Simei > Cc: Xing, Beilei ; chuanyu.xue@uconn.edu; > dev@dpdk.org; Zhang, Qi Z ; Lu, Wenzhuo > > Subject: RE: [PATCH] net/e1000: support launchtime feature >=20 > >> > >> >> +static int > >> >> +eth_igb_read_clock(__rte_unused struct rte_eth_dev *dev, uint64_t > >> >> +*clock) { > >> >> + uint64_t systime_cycles; > >> >> + struct e1000_adapter *adapter =3D dev->data->dev_private; > >> >> + > >> >> + systime_cycles =3D igb_read_systime_cyclecounter(dev); > >> >> + uint64_t ns =3D rte_timecounter_update(&adapter->systime_tc, > >> >> systime_cycles); > >> > > >> >Do you also run "ptp timesync" when testing this launchtime feature? > >> > > >> > >> I used `rte_eth_timesync_enable` function during the test. I am not > >> familiar with the `ptp timesync` in DPDK. If you are referring to > >> something else, could you please guide me on how to test it? > > > >Do you use your own application or DPDK application to test this > >launchtime feature, for example, dpdk testpmd? >=20 > Yes, I used my own application to test it. The benefit of launch time fea= ture in > boundable delay and jitter is significant compared with when it is disabl= ed. >=20 > Specifically, my app periodically calls `rte_eth_tx_burst` with > `rte_dynfield_timestamp` field on talker, and compares whether the receiv= ing > time in NIC hardware timestamp on listener is as expected. Talker and lis= tener > are directly connected by a RJ45 cable, both installed with i210 NIC. The > feature works perfect in my test. OK, it sounds good. >=20 > I also tested it with testpmd with `txtimes` config. However it seems the= re is an > issue in testpmd. Specifically the tx_only mode sends packets as fast as > possible, results in an increasing gap between the current time and the > scheduled transmission time. > Based on i210 NIC sheet Sec 7.2.2.2.3, the launch time should be within > (current_time, current time + 0.5 Sec), thus most of tx packets are not > scheduled. > I got the similar test results with dpdk igc driver which already impleme= ted > launch time feature. >=20 > Following is how I try to test with testpmd. Please let me know if I did > something wrong. >=20 > sudo ./dpdk-testpmd -- -i --forward-mode=3Dtxonly >=20 > testpmd> port stop 0 > testpmd> set burst 1 > testpmd> set txtimes 100000000,0 > testpmd> port config 0 tx_offload send_on_timestamp on > testpmd> port start 0 > testpmd> start When testing launch time feature with igc driver, firstly, some code change= made in txonly.c: pkt->ol_flags |=3D RTE_MBUF_F_TX_IEEE1588_TMST; (this flag should be added = to forward PTP packet with hardware Tx timestamp) # ./build/app/dpdk-testpmd -a 0000:81:00.0 -c f -n 4 -- -i --tx-offloads=3D= 0x200000 testpmd> set burst 1 testpmd> set fwd txonly testpmd> set txtimes 1000000,0 testpmd> start On receiver side (with tcpdump): # tcpdump -Q in -ttt -ni ens25f3 --time-stamp-precision=3Dnano -j adapter_u= nsynced -c 32 Thanks, Simei >=20 > > > >> +-----------+---------------+---------------+---------------+---------= ------+---------------+ > >> | 1G | 16880 | 16880 | 16880 | > 16880 > >> | 16880 | > >> +-----------+---------------+---------------+---------------+---------= ------+---------------+ > >> > >> Any suggestions here? Is it supposed to be embedded directly here or > >> left to the application level to compensate? I can fix it accordingly. > > > >I think it can be put here directly just as you do. >=20 > Got it. Will keep this delay compensiation here and revise it in the next= batch > version.