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 D9270A0543; Tue, 6 Dec 2022 12:46:51 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AC2A540687; Tue, 6 Dec 2022 12:46:51 +0100 (CET) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by mails.dpdk.org (Postfix) with ESMTP id CDD854021D for ; Tue, 6 Dec 2022 12:46:49 +0100 (CET) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2B63CYJ5012847; Tue, 6 Dec 2022 03:46:49 -0800 Received: from nam12-dm6-obe.outbound.protection.outlook.com (mail-dm6nam12lp2170.outbound.protection.outlook.com [104.47.59.170]) by mx0b-0016f401.pphosted.com (PPS) with ESMTPS id 3m86us9xk2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 06 Dec 2022 03:46:48 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=lLdBXtKLv0yoDmjYgLqb3oKYNVFHL/O/ppGB4rOLOq95w3U0x3uRn2rgXa3XGMAyar0XJAEINH8dAJo9af8oHOcpGLd6rUiSLV5j5N/wiFyORKU5ulFuCtqaYoqoBC7To/PXW96iTJ2B8cfoEXA5yOxPt7HKsYW/RFJEtLBmnS4RymGqB9kbZD8tch+5Xw43wAyVMlGBtoPZA9rg8VcYYaSNIzQIO7p7OUwiYtodlijSfIpD9cN4DRk3z9XOdgfKArS+WGt7gVqO7Yge4d3gr/7iXlVUE2425V6fUeIIE/zymQjSU74JPyCGDO7j/VGhdGEz4e4SVI5IOCWxKZrWaQ== 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=BHvaKJfWpBginIrXcXlkhP9IHsr0zOXHsWN1v4b25P0=; b=iL4xyh268GZgp78w5toDqqvWwHEUAAuoOZ66ZnvtQFNvElMAsP090iAMhmDw4gakf5CTQYlITGaQ0/gpvbxRzMQ3i07QSENAG4cpkSyBDiO55MSpp7ToJry8ekm1c4MMJxtEgw5qlH85m6RTRy/bpfttXMHFBfOVwjlK4QiyZXHYUgkaAqL/uC6+Bv9WmyW8s9enbLDVfk3fs5G+NYT5lcCSmNLR9XxFZs1EU6XQrRFavHOYs9Qz1wJIwJjp8h67XlWii2PSpeB6q74xayYfF4BuJlQxWJz3gX8LNdnXCUFdlLghGGM2phXhHWsfqcqvVITZ9ZHdBd66tzdJYSbl7Q== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector1-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=BHvaKJfWpBginIrXcXlkhP9IHsr0zOXHsWN1v4b25P0=; b=DgjtBF9EoJIIqbjGva4b1jc0gLtbFdjyDYLTdlfxhzlJUKLyjXLJMrqepdv35tDffVdyVLjvUOkMZ/1QoJBn5Expoy2tXKaU9EfAQKjDHQrEEmZbCpgDFn0uwd82ES59NRAElZdcWtWWeig4CSATRcW80+cUerDfVwdqzMTIePQ= Received: from PH0PR18MB5167.namprd18.prod.outlook.com (2603:10b6:510:168::7) by SA0PR18MB3536.namprd18.prod.outlook.com (2603:10b6:806:73::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5880.13; Tue, 6 Dec 2022 11:46:43 +0000 Received: from PH0PR18MB5167.namprd18.prod.outlook.com ([fe80::4cad:7bc7:1d0:4be]) by PH0PR18MB5167.namprd18.prod.outlook.com ([fe80::4cad:7bc7:1d0:4be%3]) with mapi id 15.20.5880.014; Tue, 6 Dec 2022 11:46:43 +0000 From: Amit Prakash Shukla To: "david.marchand@redhat.com" CC: "dev@dpdk.org" , Jerin Jacob Kollanukkaran , "bruce.richardson@intel.com" , "ciara.power@intel.com" , "dmitry.kozliuk@gmail.com" , Anatoly Burakov , Amit Prakash Shukla Subject: RE: [PATCH v7] mem: telemetry support for memseg and element information Thread-Topic: [PATCH v7] mem: telemetry support for memseg and element information Thread-Index: AQHY6HIMw07gtCluZ0ic/8YxH/ekDK5g/2sQ Date: Tue, 6 Dec 2022 11:46:43 +0000 Message-ID: References: <20221025115138.4071745-1-amitprakashs@marvell.com> <20221025130216.4141896-1-amitprakashs@marvell.com> In-Reply-To: <20221025130216.4141896-1-amitprakashs@marvell.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-dg-ref: =?us-ascii?Q?PG1ldGE+PGF0IG5tPSJib2R5LnR4dCIgcD0iYzpcdXNlcnNcYW1pdHByYWth?= =?us-ascii?Q?c2hzXGFwcGRhdGFccm9hbWluZ1wwOWQ4NDliNi0zMmQzLTRhNDAtODVlZS02?= =?us-ascii?Q?Yjg0YmEyOWUzNWJcbXNnc1xtc2ctYTU1MTU3ZDUtNzU1Yi0xMWVkLWI2Y2It?= =?us-ascii?Q?MDBlMDRjY2FkNzJiXGFtZS10ZXN0XGE1NTE1N2Q3LTc1NWItMTFlZC1iNmNi?= =?us-ascii?Q?LTAwZTA0Y2NhZDcyYmJvZHkudHh0IiBzej0iMTcwNzkiIHQ9IjEzMzE0ODAw?= =?us-ascii?Q?ODAwNDU1NjQyNiIgaD0iSFJNWG5hdjcrTTBCUlVqN3dpZW1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ii?Q?ZGdCbEFHd0FiQUJmQUhRQVpRQnlBRzBBYVFCdUFIVUFjd0FBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= =?us-ascii?Q?QUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFBQUFB?= x-dg-reftwo: QUFBQUFBQUFBQUFBQUFBQUFCQUFBQUFBQUFBQUlBQUFBQUFBPT0iLz48L21ldGE+ x-dg-rorf: true x-ms-publictraffictype: Email x-ms-traffictypediagnostic: PH0PR18MB5167:EE_|SA0PR18MB3536:EE_ x-ms-office365-filtering-correlation-id: e588136d-1aee-4292-f941-08dad77f8c0e x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: gCmrSStQh780b99iGaCsCbOiaukGiuVptiOI7hZB8dTG/IDzPAKNBPoamBWVM4wiUnfIyIQZMBxdGkaXUy8KDOB+IR8n1QSO+SgDlTzZ/FOrM5mZTXMcigLv2NP1rYHtaUIAToawL1gXt7Nhb2x6uEQOC0KMMvUsBeO5wdiG8QfHJNYieAfoJgyek/ryjLsKRwjtyenD1H3M+utow6BQIeIrEfvz3rHgskuYHYjRzDdL0AMwdFur9YAczx63JbPblTmhlDnfdpj7jLmfzXQH463u/+27wemA+mLjWFSwjSj1qbUnkJp2M97HgugrPe1YlA9UV5jJWlmZ0Qv60xBXciI2fVr+x0JdPk+tnxtVvbHL7U9CvZtP23GjVzw3UmWvedGM5D1996ntK8/BEoS/QAh7m/uv+o6/D/zegkt6zQDk4N4bM4FQj9dHxafGVTqRWhy9f7wnCjm37h54TfK+Dsf1JODRxv8JLhZG1jicDDqamQIMeTISjHRS2boNz1/idL1bsOPjiECmWb6+gF/8coBddzmWkZRKOK1Pme91ZvKiHmVr9td+SxwA6q87w2TCEVzVoW6qnjW/OGDmY53+/hqMTzOurqAaLo4HhI50xu5PcXxUEvNu4qjwtQ9lNpXzlIAK6M3E+VazS5tLaqVmGxp1hmeC+Z/xOzDGtxn7o8tMU/oubSaaom7dBEUKC/0mtqZ8xXf+StKEech1RK+/Bw== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PH0PR18MB5167.namprd18.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230022)(4636009)(346002)(396003)(39860400002)(366004)(376002)(136003)(451199015)(54906003)(6916009)(316002)(64756008)(66556008)(66946007)(4326008)(76116006)(66476007)(8936002)(66446008)(41300700001)(9686003)(55236004)(186003)(38070700005)(26005)(8676002)(71200400001)(86362001)(2906002)(478600001)(5660300002)(33656002)(52536014)(83380400001)(53546011)(55016003)(30864003)(122000001)(6506007)(7696005)(107886003)(38100700002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?L1f17LWx8MSkyRGDfIDHrX+R0ShshcPa+pdJjEIHsjsnI/xEU+Ny3z8389lL?= =?us-ascii?Q?fTw8WztthVHGgq6dTVaHBw7uzJvZ76Tj2DAhBWkrjOYkU7lbI6Z+BehmZ8KJ?= =?us-ascii?Q?bj5BY9ODesPqtJUqfhYPl+K433RsrP+8hXKoS1L1i3kGTu8qPrh/0C6lfIJI?= =?us-ascii?Q?Uvs2WXY4/Sv/DSdox1hRnY3K/LcHRvryDnrweMoVNrSz4uIxu5WuHzZsVOwd?= =?us-ascii?Q?wUTegfZGrr+glNJwIW0RtlpZJiYg56V/+L/fUHJQAAAfFrGlZ9qEvJdbZUe8?= =?us-ascii?Q?2IOH6jxaFQYZueRYSrCOnvefjCUZIxk8dtG3IvJ3r4Nff+AN4g9N8PTYNIw5?= =?us-ascii?Q?0NQ8rZaH6/4nMo/I+jxnATkdwxH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=?us-ascii?Q?+oM8qty100nkG5httR98T2kU329vbMa5aHKYQAnPRkZOOy+Dj8lcGaUhYD0r?= =?us-ascii?Q?v7N5n6HZqd2Ct41Kfws0a+IIFxfbvjtET/iuPzJ6jyDYvFcxFLR2tljt8p9x?= =?us-ascii?Q?p+gD9ekfiyvgXFLxBSQ3sWgjmMP3PYzym8AI0sYj4jpeH6PEGcPMjps1fMer?= =?us-ascii?Q?gpfAM4lWeFxkPQil6ZtO/jnX9zxW0dkAgAJ56+kmJPSVedh5M0amCd4c43OM?= =?us-ascii?Q?2aWb2yUq/m9kP4F27sv58u23qgR6XGLQbNTI2y4h80V0sIKU7cix5RwzZHdn?= =?us-ascii?Q?XhB9vQK5XKgy8P4EjsDy+yTGA6Wc4bxPxpX7HHgh?= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: marvell.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PH0PR18MB5167.namprd18.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: e588136d-1aee-4292-f941-08dad77f8c0e X-MS-Exchange-CrossTenant-originalarrivaltime: 06 Dec 2022 11:46:43.6487 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: mPSS4SaCinOPsyShqcaW5TYYM9m6OvGnjEy9fc60+GAmL+2eoMR3PmFBzVOLwiYhpaxgPNWqexI5x2K95MDCH4Hli2cIJjp8LoQm8Fvkeoc= X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA0PR18MB3536 X-Proofpoint-GUID: u_OIBAGZxrjjB-IYPrPfkyAAVkZo_xvW X-Proofpoint-ORIG-GUID: u_OIBAGZxrjjB-IYPrPfkyAAVkZo_xvW X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.923,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-12-06_07,2022-12-06_01,2022-06-22_01 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 Ping. > -----Original Message----- > From: Amit Prakash Shukla > Sent: Tuesday, October 25, 2022 6:32 PM > To: Anatoly Burakov > Cc: dev@dpdk.org; Jerin Jacob Kollanukkaran ; > david.marchand@redhat.com; bruce.richardson@intel.com; > ciara.power@intel.com; dmitry.kozliuk@gmail.com; Amit Prakash Shukla > > Subject: [PATCH v7] mem: telemetry support for memseg and element > information >=20 > Changes adds telemetry support to display memory occupancy in memseg > and the information of the elements allocated from a memseg based on > arguments provided by user. This patch adds following endpoints: >=20 > 1. /eal/memseg_lists > The command displays the memseg list from which the memory has been > allocated. > Example: > --> /eal/memseg_lists > {"/eal/memseg_lists": [0, 1]} >=20 > 2. /eal/memseg_list_info, > The command outputs the memsegs, from which the memory is allocated, > for the memseg_list given as input. > Example: > --> /eal/memseg_list_info,0 > {"/eal/memseg_list_info": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, \ 12, 1= 3, 14, 15]} >=20 > 3. /eal/memseg_info,, > The command outputs the memseg information based on the memseg-list > and the memseg-id given as input. > Example: > --> /eal/memseg_info,0,10 > {"/eal/memseg_info": {"Memseg_list_index": 0, \ > "Memseg_index": 10, "Start_addr": "0x101600000", \ > "End_addr": "0x101800000", "Size": 2097152, "Hugepage_size": 2097152, \ > "Socket_id": 0, "flags": 0}} >=20 > --> /eal/memseg_info,0,15 > {"/eal/memseg_info": {"Memseg_list_index": 0, "Memseg_index": 15, \ > "Start_addr": "0x102000000", "End_addr": "0x102200000", \ > "Size": 2097152, "Hugepage_size": 2097152, "Socket_id": 0, "flags": 0}} >=20 > 4. /eal/mem_element_list,,, > The command outputs number of elements in a memseg based on the heap- > id, memseg-list-id and memseg-id given as input. > Example: > --> /eal/mem_element_list,0,0,10 > {"/eal/mem_element_list": {"Element_count": 52}} >=20 > --> /eal/mem_element_list,0,1,15 > {"/eal/mem_element_list": {"Element_count": 52}} >=20 > 5. /eal/mem_element_info,,,, \ > , > The command outputs element information like element start address, end > address, to which memseg it belongs, element state, element size. User ca= n > give a range of elements to be printed. > Example: > --> /eal/mem_element_info,0,0,15,1,2 > {"/eal/mem_element_info": {"element_1": {"msl_id": 0, "ms_id": 15, \ > "memseg_start_addr": "0x102000000", "memseg_end_addr": > "0x102200000", \ > "element_start_addr": "0x102000b00", "element_end_addr": > "0x102003380", \ > "element_size": 10368, "element_state": "Busy"}, "element_2": \ > {"msl_id": 0, "ms_id": 15, "memseg_start_addr": "0x102000000", \ > "memseg_end_addr": "0x102200000", "element_start_addr": > "0x102003380", \ > "element_end_addr": "0x102005c00", "element_size": 10368, \ > "element_state": "Busy"}, "Element_count": 2}} >=20 > Signed-off-by: Amit Prakash Shukla > --- > v2: > - Fixed compilation error related int-to-pointer-cast > - Changes for code review suggestions >=20 > v3: > - Commit message changes > - Renaming end-points > - Changing input parameters to comma-seperated > - Reverting telemetry output buffer size >=20 > v4: > - Patch-2 adds telemetry support to display system memory >=20 > v5: > - Removed command help related changes >=20 > v6: > - Changes for code review suggestions > - Dropped Patch-2 from the series >=20 > v7: > - Fixed compilation error >=20 > lib/eal/common/eal_common_memory.c | 391 > ++++++++++++++++++++++++++++- > 1 file changed, 386 insertions(+), 5 deletions(-) >=20 > diff --git a/lib/eal/common/eal_common_memory.c > b/lib/eal/common/eal_common_memory.c > index 688dc615d7..bce18046ce 100644 > --- a/lib/eal/common/eal_common_memory.c > +++ b/lib/eal/common/eal_common_memory.c > @@ -3,6 +3,7 @@ > */ >=20 > #include > +#include > #include > #include > #include > @@ -26,6 +27,7 @@ > #include "eal_memcfg.h" > #include "eal_options.h" > #include "malloc_heap.h" > +#include "malloc_elem.h" >=20 > /* > * Try to mmap *size bytes in /dev/zero. If it is successful, return the= @@ - > 1113,11 +1115,17 @@ rte_eal_memory_init(void) } >=20 > #ifndef RTE_EXEC_ENV_WINDOWS > -#define EAL_MEMZONE_LIST_REQ "/eal/memzone_list" > -#define EAL_MEMZONE_INFO_REQ "/eal/memzone_info" > -#define EAL_HEAP_LIST_REQ "/eal/heap_list" > -#define EAL_HEAP_INFO_REQ "/eal/heap_info" > -#define ADDR_STR 15 > +#define EAL_MEMZONE_LIST_REQ "/eal/memzone_list" > +#define EAL_MEMZONE_INFO_REQ "/eal/memzone_info" > +#define EAL_HEAP_LIST_REQ "/eal/heap_list" > +#define EAL_HEAP_INFO_REQ "/eal/heap_info" > +#define EAL_MEMSEG_LISTS_REQ "/eal/memseg_lists" > +#define EAL_MEMSEG_LIST_INFO_REQ "/eal/memseg_list_info" > +#define EAL_MEMSEG_INFO_REQ "/eal/memseg_info" > +#define EAL_ELEMENT_LIST_REQ "/eal/mem_element_list" > +#define EAL_ELEMENT_INFO_REQ "/eal/mem_element_info" > +#define ADDR_STR 15 > + >=20 > /* Telemetry callback handler to return heap stats for requested heap id= . */ > static int @@ -1265,6 +1273,362 @@ > handle_eal_memzone_list_request(const char *cmd __rte_unused, > return 0; > } >=20 > +/* n_vals is the number of params to be parsed. */ static int > +parse_params(const char *params, uint32_t *vals, size_t n_vals) { > + char dlim[2] =3D ","; > + char *params_args; > + size_t count =3D 0; > + char *token; > + > + if (vals =3D=3D NULL || params =3D=3D NULL || strlen(params) =3D=3D 0) > + return -1; > + > + /* strtok expects char * and param is const char *. Hence on using > + * params as "const char *" compiler throws warning. > + */ > + params_args =3D strdup(params); > + if (params_args =3D=3D NULL) > + return -1; > + > + token =3D strtok(params_args, dlim); > + while (token && isdigit(*token) && count < n_vals) { > + vals[count++] =3D strtoul(token, NULL, 10); > + token =3D strtok(NULL, dlim); > + } > + > + free(params_args); > + > + if (count < n_vals) > + return -1; > + > + return 0; > +} > + > +static int > +handle_eal_memseg_lists_request(const char *cmd __rte_unused, > + const char *params __rte_unused, > + struct rte_tel_data *d) > +{ > + struct rte_mem_config *mcfg; > + int i; > + > + rte_tel_data_start_array(d, RTE_TEL_INT_VAL); > + > + rte_mcfg_mem_read_lock(); > + mcfg =3D rte_eal_get_configuration()->mem_config; > + > + for (i =3D 0; i < RTE_MAX_MEMSEG_LISTS; i++) { > + struct rte_memseg_list *msl =3D &mcfg->memsegs[i]; > + if (msl->memseg_arr.count =3D=3D 0) > + continue; > + > + rte_tel_data_add_array_int(d, i); > + } > + rte_mcfg_mem_read_unlock(); > + > + return 0; > +} > + > +static int > +handle_eal_memseg_list_info_request(const char *cmd __rte_unused, > + const char *params, struct rte_tel_data *d) > { > + struct rte_mem_config *mcfg; > + struct rte_memseg_list *msl; > + struct rte_fbarray *arr; > + uint32_t ms_list_idx; > + int ms_idx; > + /* size of an array =3D=3D num params to be parsed. */ > + uint32_t vals[1] =3D {0}; > + > + if (parse_params(params, vals, RTE_DIM(vals)) < 0) > + return -1; > + > + ms_list_idx =3D vals[0]; > + if (ms_list_idx >=3D RTE_MAX_MEMSEG_LISTS) > + return -1; > + > + rte_tel_data_start_array(d, RTE_TEL_INT_VAL); > + > + rte_mcfg_mem_read_lock(); > + mcfg =3D rte_eal_get_configuration()->mem_config; > + msl =3D &mcfg->memsegs[ms_list_idx]; > + if (msl->memseg_arr.count =3D=3D 0) > + goto done; > + > + arr =3D &msl->memseg_arr; > + > + ms_idx =3D rte_fbarray_find_next_used(arr, 0); > + while (ms_idx >=3D 0) { > + rte_tel_data_add_array_int(d, ms_idx); > + ms_idx =3D rte_fbarray_find_next_used(arr, ms_idx + 1); > + } > + > +done: > + rte_mcfg_mem_read_unlock(); > + > + return 0; > +} > + > +static int > +handle_eal_memseg_info_request(const char *cmd __rte_unused, > + const char *params, struct rte_tel_data *d) { > + struct rte_mem_config *mcfg; > + uint64_t ms_start_addr, ms_end_addr, ms_size, hugepage_size; > + struct rte_memseg_list *msl; > + const struct rte_memseg *ms; > + struct rte_fbarray *arr; > + char addr[ADDR_STR]; > + uint32_t ms_list_idx =3D 0; > + uint32_t ms_idx =3D 0; > + int32_t ms_socket_id; > + uint32_t ms_flags; > + /* size of an array =3D=3D num params to be parsed. */ > + uint32_t vals[2] =3D {0}; > + > + if (parse_params(params, vals, RTE_DIM(vals)) < 0) > + return -1; > + > + ms_list_idx =3D vals[0]; > + if (ms_list_idx >=3D RTE_MAX_MEMSEG_LISTS) > + return -1; > + > + ms_idx =3D vals[1]; > + > + rte_mcfg_mem_read_lock(); > + > + mcfg =3D rte_eal_get_configuration()->mem_config; > + msl =3D &mcfg->memsegs[ms_list_idx]; > + if (msl->memseg_arr.count =3D=3D 0) { > + rte_mcfg_mem_read_unlock(); > + return -1; > + } > + > + arr =3D &msl->memseg_arr; > + ms =3D rte_fbarray_get(arr, ms_idx); > + if (ms =3D=3D NULL) { > + rte_mcfg_mem_read_unlock(); > + RTE_LOG(DEBUG, EAL, "Error fetching requested > memseg.\n"); > + return -1; > + } > + > + ms_start_addr =3D ms->addr_64; > + ms_end_addr =3D (uint64_t)RTE_PTR_ADD(ms_start_addr, ms->len); > + ms_size =3D ms->len; > + hugepage_size =3D ms->hugepage_sz; > + ms_socket_id =3D ms->socket_id; > + ms_flags =3D ms->flags; > + > + rte_mcfg_mem_read_unlock(); > + > + rte_tel_data_start_dict(d); > + rte_tel_data_add_dict_int(d, "Memseg_list_index", ms_list_idx); > + rte_tel_data_add_dict_int(d, "Memseg_index", ms_idx); > + snprintf(addr, ADDR_STR, "0x%"PRIx64, ms_start_addr); > + rte_tel_data_add_dict_string(d, "Start_addr", addr); > + snprintf(addr, ADDR_STR, "0x%"PRIx64, ms_end_addr); > + rte_tel_data_add_dict_string(d, "End_addr", addr); > + rte_tel_data_add_dict_u64(d, "Size", ms_size); > + rte_tel_data_add_dict_u64(d, "Hugepage_size", hugepage_size); > + rte_tel_data_add_dict_int(d, "Socket_id", ms_socket_id); > + rte_tel_data_add_dict_int(d, "flags", ms_flags); > + > + return 0; > +} > + > +static int > +handle_eal_element_list_request(const char *cmd __rte_unused, > + const char *params, struct rte_tel_data *d) { > + struct rte_mem_config *mcfg; > + struct rte_memseg_list *msl; > + const struct rte_memseg *ms; > + struct malloc_elem *elem; > + struct malloc_heap *heap; > + uint64_t ms_start_addr, ms_end_addr; > + uint64_t elem_start_addr, elem_end_addr; > + uint32_t ms_list_idx =3D 0; > + uint32_t heap_id =3D 0; > + uint32_t ms_idx =3D 0; > + int elem_count =3D 0; > + /* size of an array =3D=3D num params to be parsed. */ > + uint32_t vals[3] =3D {0}; > + > + if (parse_params(params, vals, RTE_DIM(vals)) < 0) > + return -1; > + > + heap_id =3D vals[0]; > + if (heap_id >=3D RTE_MAX_HEAPS) > + return -1; > + > + ms_list_idx =3D vals[1]; > + if (ms_list_idx >=3D RTE_MAX_MEMSEG_LISTS) > + return -1; > + > + ms_idx =3D vals[2]; > + > + rte_mcfg_mem_read_lock(); > + > + mcfg =3D rte_eal_get_configuration()->mem_config; > + msl =3D &mcfg->memsegs[ms_list_idx]; > + ms =3D rte_fbarray_get(&msl->memseg_arr, ms_idx); > + if (ms =3D=3D NULL) { > + rte_mcfg_mem_read_unlock(); > + RTE_LOG(DEBUG, EAL, "Error fetching requested > memseg.\n"); > + return -1; > + } > + > + ms_start_addr =3D ms->addr_64; > + ms_end_addr =3D (uint64_t)RTE_PTR_ADD(ms_start_addr, ms->len); > + rte_mcfg_mem_read_unlock(); > + > + rte_tel_data_start_dict(d); > + > + heap =3D &mcfg->malloc_heaps[heap_id]; > + rte_spinlock_lock(&heap->lock); > + > + elem =3D heap->first; > + while (elem) { > + elem_start_addr =3D (uint64_t)elem; > + elem_end_addr =3D > + (uint64_t)RTE_PTR_ADD(elem_start_addr, elem- > >size); > + > + if ((uint64_t)elem_start_addr >=3D ms_start_addr && > + (uint64_t)elem_end_addr <=3D ms_end_addr) > + elem_count++; > + elem =3D elem->next; > + } > + > + rte_spinlock_unlock(&heap->lock); > + > + rte_tel_data_add_dict_int(d, "Element_count", elem_count); > + > + return 0; > +} > + > +static int > +handle_eal_element_info_request(const char *cmd __rte_unused, > + const char *params, struct rte_tel_data *d) { > + struct rte_mem_config *mcfg; > + struct rte_memseg_list *msl; > + const struct rte_memseg *ms; > + struct malloc_elem *elem; > + struct malloc_heap *heap; > + struct rte_tel_data *c; > + uint64_t ms_start_addr, ms_end_addr; > + uint64_t elem_start_addr, elem_end_addr; > + uint32_t ms_list_idx =3D 0; > + uint32_t heap_id =3D 0; > + uint32_t ms_idx =3D 0; > + uint32_t start_elem =3D 0, end_elem =3D 0; > + uint32_t count =3D 0, elem_count =3D 0; > + char str[ADDR_STR]; > + /* size of an array =3D=3D num params to be parsed. */ > + uint32_t vals[5] =3D {0}; > + > + if (parse_params(params, vals, RTE_DIM(vals)) < 0) > + return -1; > + > + heap_id =3D vals[0]; > + if (heap_id >=3D RTE_MAX_HEAPS) > + return -1; > + > + ms_list_idx =3D vals[1]; > + if (ms_list_idx >=3D RTE_MAX_MEMSEG_LISTS) > + return -1; > + > + ms_idx =3D vals[2]; > + start_elem =3D vals[3]; > + end_elem =3D vals[4]; > + > + if (end_elem < start_elem) > + return -1; > + > + rte_mcfg_mem_read_lock(); > + > + mcfg =3D rte_eal_get_configuration()->mem_config; > + msl =3D &mcfg->memsegs[ms_list_idx]; > + ms =3D rte_fbarray_get(&msl->memseg_arr, ms_idx); > + if (ms =3D=3D NULL) { > + rte_mcfg_mem_read_unlock(); > + RTE_LOG(DEBUG, EAL, "Error fetching requested > memseg.\n"); > + return -1; > + } > + > + ms_start_addr =3D ms->addr_64; > + ms_end_addr =3D (uint64_t)RTE_PTR_ADD(ms_start_addr, ms->len); > + > + rte_mcfg_mem_read_unlock(); > + > + rte_tel_data_start_dict(d); > + > + heap =3D &mcfg->malloc_heaps[heap_id]; > + rte_spinlock_lock(&heap->lock); > + > + elem =3D heap->first; > + while (elem) { > + elem_start_addr =3D (uint64_t)elem; > + elem_end_addr =3D > + (uint64_t)RTE_PTR_ADD(elem_start_addr, elem- > >size); > + > + if (elem_start_addr < ms_start_addr || > + elem_end_addr > ms_end_addr) { > + elem =3D elem->next; > + continue; > + } > + > + if (count < start_elem) { > + elem =3D elem->next; > + count++; > + continue; > + } > + > + c =3D rte_tel_data_alloc(); > + if (c =3D=3D NULL) > + break; > + > + rte_tel_data_start_dict(c); > + rte_tel_data_add_dict_int(c, "msl_id", ms_list_idx); > + rte_tel_data_add_dict_int(c, "ms_id", ms_idx); > + snprintf(str, ADDR_STR, "0x%"PRIx64, ms_start_addr); > + rte_tel_data_add_dict_string(c, "memseg_start_addr", str); > + snprintf(str, ADDR_STR, "0x%"PRIx64, ms_end_addr); > + rte_tel_data_add_dict_string(c, "memseg_end_addr", str); > + snprintf(str, ADDR_STR, "0x%"PRIx64, elem_start_addr); > + rte_tel_data_add_dict_string(c, "element_start_addr", str); > + snprintf(str, ADDR_STR, "0x%"PRIx64, elem_end_addr); > + rte_tel_data_add_dict_string(c, "element_end_addr", str); > + rte_tel_data_add_dict_int(c, "element_size", elem->size); > + snprintf(str, ADDR_STR, "%s", elem->state =3D=3D 0 ? "Free" : > + elem->state =3D=3D 1 ? "Busy" : elem->state =3D=3D 2 ? > + "Pad" : "Error"); > + rte_tel_data_add_dict_string(c, "element_state", str); > + > + snprintf(str, ADDR_STR, "%s_%u", "element", count); > + if (rte_tel_data_add_dict_container(d, str, c, 0) !=3D 0) { > + rte_tel_data_free(c); > + break; > + } > + > + elem_count++; > + count++; > + if (count > end_elem) > + break; > + > + elem =3D elem->next; > + } > + > + rte_spinlock_unlock(&heap->lock); > + > + rte_tel_data_add_dict_int(d, "Element_count", elem_count); > + > + return 0; > +} > + > RTE_INIT(memory_telemetry) > { > rte_telemetry_register_cmd( > @@ -1279,5 +1643,22 @@ RTE_INIT(memory_telemetry) > rte_telemetry_register_cmd( > EAL_HEAP_INFO_REQ, > handle_eal_heap_info_request, > "Returns malloc heap stats. Parameters: int > heap_id"); > + rte_telemetry_register_cmd( > + EAL_MEMSEG_LISTS_REQ, > + handle_eal_memseg_lists_request, > + "Returns array of memseg list IDs. Takes no > parameters"); > + rte_telemetry_register_cmd( > + EAL_MEMSEG_LIST_INFO_REQ, > + handle_eal_memseg_list_info_request, > + "Returns memseg list info. Parameters: int > memseg_list_id"); > + rte_telemetry_register_cmd( > + EAL_MEMSEG_INFO_REQ, > handle_eal_memseg_info_request, > + "Returns memseg info. Parameter: int > memseg_list_id,int memseg_id"); > + rte_telemetry_register_cmd(EAL_ELEMENT_LIST_REQ, > + handle_eal_element_list_request, > + "Returns array of heap element IDs. Parameters: int > heap_id, int memseg_list_id, int memseg_id"); > + rte_telemetry_register_cmd(EAL_ELEMENT_INFO_REQ, > + handle_eal_element_info_request, > + "Returns element info. Parameters: int heap_id, int > memseg_list_id, > +int memseg_id, int start_elem_id, int end_elem_id"); > } > #endif > -- > 2.25.1