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 53CEA4386B; Tue, 9 Jan 2024 03:19:18 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D672C40298; Tue, 9 Jan 2024 03:19:17 +0100 (CET) Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by mails.dpdk.org (Postfix) with ESMTP id 1C1044021F for ; Tue, 9 Jan 2024 03:19:15 +0100 (CET) Received: from mail.maildlp.com (unknown [172.19.162.254]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4T8F396ZnWz1Q7Qf; Tue, 9 Jan 2024 10:18:29 +0800 (CST) Received: from kwepemd100004.china.huawei.com (unknown [7.221.188.31]) by mail.maildlp.com (Postfix) with ESMTPS id 7BA7B18001C; Tue, 9 Jan 2024 10:19:12 +0800 (CST) Received: from [10.67.121.175] (10.67.121.175) by kwepemd100004.china.huawei.com (7.221.188.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.2.1258.28; Tue, 9 Jan 2024 10:19:11 +0800 Message-ID: <359de0d6-90c4-aaea-f186-574d04a31c2a@huawei.com> Date: Tue, 9 Jan 2024 10:19:10 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [PATCH] ethdev: add dump regs for telemetry To: Ferruh Yigit , , Thomas Monjalon , Andrew Rybchenko , Bruce Richardson CC: , , References: <20231214015650.3738578-1-haijie1@huawei.com> <8632690b-5e85-43fb-9121-a8910074726d@amd.com> From: Jie Hai In-Reply-To: <8632690b-5e85-43fb-9121-a8910074726d@amd.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.67.121.175] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To kwepemd100004.china.huawei.com (7.221.188.31) 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 On 2023/12/14 20:49, Ferruh Yigit wrote: > On 12/14/2023 1:56 AM, Jie Hai wrote: >> The ethdev library now registers a telemetry command for >> dump regs. >> >> An example usage is shown below: >> --> /ethdev/regs,test >> { >> "/ethdev/regs": { >> "regs_offset": 0, >> "regs_length": 3192, >> "regs_width": 4, >> "device_version": "0x1080f00", >> "regs_file": "port_0_regs_test" >> } >> } > > Above code writes register data to a file. > > I am not sure about this kind of usage of telemetry command, that it > cause data to be written to a file. > > My understanding is, telemetry usage is based on what telemetry client > receives. > What do you think just keep the 'reg_info' fields excluding data to the > file? > > .Hi, Ferruh I tried to write all register information to telemetry data, but gave up because some drivers had too many registers (eg.ixgbe) to carry. Therefore, the writing data to file approach is selected. When we query a register, the register content is the key. The information such as the width and length is only auxiliary information. If the register data cannot be obtained, the auxiliary information is optional. So I don't think register data should be removed. In my opinion, writing a file is a more appropriate way to do it. I wonder if there's a better way. Best regards, Thanks