From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0111.outbound.protection.outlook.com [104.47.2.111]) by dpdk.org (Postfix) with ESMTP id 758641041 for ; Mon, 10 Sep 2018 17:51:24 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nokia.onmicrosoft.com; s=selector1-nokia-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vy/GJpbVS+hIMAieIkbUVNkcUbyTTWh1Y/uSTH/0LI4=; b=T73nVvKmIITfRmWCfHPgxsx2wfJRRoHYCRHcFspPhPu78PJemAln5f1bkw4OIbtfl2jqWuu48f9Sar1ffC9HTqnxnVvSDKqmsCb2lWaCtq6yrLYZY0RoixHHdBdPn6Vykx61dGn06sFTh3tGr6UZZjqPcSkjMfjzVvEs6crILso= Received: from AM3PR07CA0136.eurprd07.prod.outlook.com (2603:10a6:207:8::22) by AM0PR07MB4193.eurprd07.prod.outlook.com (2603:10a6:208:b8::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1122.13; Mon, 10 Sep 2018 15:51:22 +0000 Received: from VE1EUR03FT052.eop-EUR03.prod.protection.outlook.com (2a01:111:f400:7e09::209) by AM3PR07CA0136.outlook.office365.com (2603:10a6:207:8::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.1143.12 via Frontend Transport; Mon, 10 Sep 2018 15:51:22 +0000 Received-SPF: Pass (protection.outlook.com: domain of nokia.com designates 131.228.2.241 as permitted sender) receiver=protection.outlook.com; client-ip=131.228.2.241; helo=mailrelay.int.nokia.com; Received: from mailrelay.int.nokia.com (131.228.2.241) by VE1EUR03FT052.mail.protection.outlook.com (10.152.19.173) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.20.1143.11 via Frontend Transport; Mon, 10 Sep 2018 15:51:22 +0000 Received: from fihe3nok0735.emea.nsn-net.net (localhost [127.0.0.1]) by fihe3nok0735.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id w8AFohGx009865 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 10 Sep 2018 18:50:43 +0300 Received: from lfs-up-04.localdomain ([10.157.84.234]) by fihe3nok0735.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id w8AFoh6S009862; Mon, 10 Sep 2018 18:50:43 +0300 X-HPESVCS-Source-Ip: 10.157.84.234 Received: by lfs-up-04.localdomain (Postfix, from userid 62146483) id 00B568815; Mon, 10 Sep 2018 18:50:42 +0300 (EEST) From: Julien Meunier To: , CC: Date: Mon, 10 Sep 2018 18:50:35 +0300 Message-ID: <20180910155035.23638-1-julien.meunier@nokia.com> X-Mailer: git-send-email 2.10.2 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:131.228.2.241; IPV:CAL; SCL:-1; CTRY:FI; EFV:NLI; SFV:NSPM; SFS:(10019020)(136003)(376002)(346002)(396003)(39860400002)(2980300002)(438002)(199004)(189003)(336012)(1076002)(1857600001)(316002)(356003)(47776003)(16586007)(110136005)(6666003)(68736007)(22756006)(42186006)(106002)(103686004)(478600001)(8676002)(6346003)(2906002)(26826003)(4326008)(6266002)(186003)(106466001)(36756003)(26005)(126002)(486006)(51416003)(2616005)(86362001)(476003)(44832011)(97736004)(50226002)(5660300001)(8936002)(50466002)(48376002)(14444005)(52956003)(53936002)(81156014)(81166006)(305945005); DIR:OUT; SFP:1102; SCL:1; SRVR:AM0PR07MB4193; H:mailrelay.int.nokia.com; FPR:; SPF:Pass; LANG:en; PTR:InfoDomainNonexistent; A:1; MX:1; X-Microsoft-Exchange-Diagnostics: 1; VE1EUR03FT052; 1:q939bzTnli/qgrdivm1B2R7AKoBrYy+lgib7XiVZaxRJ306CeWwa4aVRxdN/kpg1iZhYv76V2NeTxeZ4LmVl5Sy4fYKhy9WZ0N0iNa7OBZyOnH0v6JIimIyUfvtO1arw MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 665820b3-5218-4a62-3bab-08d6173541e0 X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(4534165)(4627221)(201703031133081)(201702281549075)(5600074)(711020)(4608076)(2017052603328); SRVR:AM0PR07MB4193; X-Microsoft-Exchange-Diagnostics: 1; AM0PR07MB4193; 3:49PEk2ghMrWFP0Bph3bIbUkKmzAMWL3KkJ1UC4VQ4J/Um9QojZW9g9szJLptmTwP6+HOAczWGPA220W19LPf1OwRGlqV50u9KEbhVBg9y9o6EhIvh8Z8Z7Olg03Sq3mHegIvkVC7c/9pmxukIiIwimBESs3SAqVV/lxdv6Ml43H5kxl+FR4lf7uIjjbkUONiZoMruVgdLMY/vJs5DNYgNoqehENypeFNGr/Yn6wDizs9XNN0fYEIQGO81utGfv7RGa1KCS+mhKJ0Q2XmgGycYmimlaP6u4w4e9kx7pl1dQFspAugYDQDPIRRWYIw2HEGn0SqMrRjnbIupgGBTAH2VczojS14nFEijTfDYGp/eNQ=; 25:dp4CaXYkDMq3/bHCVZhp0oynDU1BOW0vs7f1jDH0cRCT3zEJDmIw2yOcMT4hhKvtEUiY6tp3OoI/k+qHkEnjVkOmT/I8fPWJYZ4D/LhlKRaZ5xbI1eW8R5Qau3J1RuvQcB/jpUaIdS0+Jv1g5dPYD2b6t7g9lehNx/Ys8atkH20eBMW5H1Kh4q7VKTotOdvA2SAFe5wE29lqaM3hhwF5amGcgB79Ywxu73y/ShtEi3plOAvXyyg2SCryUai5UBYfWm3pf4mMhX60h1Ht0r2GdOz9j+KTdg2hSNinJH7ymZin1aZ/BaZdgKN6qZa8qe4bqxjkU2YVmR+e2jp5eJMT4Q== X-MS-TrafficTypeDiagnostic: AM0PR07MB4193: X-Microsoft-Exchange-Diagnostics: 1; AM0PR07MB4193; 31:XdfJ7e9Bw7o/qrnRJEjGg6ZAOs8BnWg6IBzWFihk8/hjPXRffSfW2pRNcihrnQVX5Oi6z+bKG6LVOQUOEpmFFb+DuvVp1EQwN8UkB/xYM1tE10aJUgQ5+DW8kOL4T5KmV056IMXtrS/ca4dHf4JH6XWD5K1pML9dNXV7ZGWgggZ2UsZVqVOck5/jzV4VxCdJH95OimwvzSVqyxQ/sdVXpsKV63umSpqNXwrDAstHFVE=; 20:oH4PX5eHSJBDr5+Qb6VLdLwamsQ0PHJGhTw712BHwz+ft7CJCKV1ld8m9Iw2VMw5hs44Bw4JTwQFotFs6eTKlh/StZRqnJIWTxoodxbE7tsJaQzVJtfzXJPbpdNh+F8F9+87DdyJ/Q/o4DLiQRCUdFqA1CyxrrEfy6WIw/yRYhegtCiPWxl0tjL90nGL7vBiZnp/K202zaSwvMS7VQ26E9OMrlQ0uy8K1ZfNblFae6d68Zpm6zD71SkpLpG/EfnLlTTKlujLGbwdrZy57mcGS0loVtQV7BxvPfeZP2D6F6e0UDx6KGCMpYoWbAfv5aelF3nOsMDA8RsBWTnCQUb0x93PLgV2ptYS7bAiSm0wGvNvfJg6iKG79Ro8XMfV5c7VGDUx48yGPxrznDUUxisAmGqEJ3loNhFrB1ZR44R9pGxfCf0B4VU06dHypJispplEihPJX3uZ5wjl/QhdguzEcuJWPTQDRqkfdwNolL8uFY0hn6SeBshDomZ6znWDJl2/s0Fdri0QbDkpG0LuHGd+0g+HcpdIx+quYt+9iV26ZrZZ5NrFc30PsXsCgBoFKMqEEI3IYmFjc8LVti8nZrzMwJxk/PiBG5s89bsh3xluLs8= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(82608151540597)(109105607167333)(195916259791689); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(8121501046)(5005006)(93006095)(93004095)(3231344)(11241501184)(806099)(944501410)(52105095)(3002001)(10201501046)(6055026)(149027)(150027)(6041310)(20161123558120)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699050)(76991033); SRVR:AM0PR07MB4193; BCL:0; PCL:0; RULEID:; SRVR:AM0PR07MB4193; X-Microsoft-Exchange-Diagnostics: 1; AM0PR07MB4193; 4:wBZEXK7Eyc5MXctq9vDsbAk3/e+8T1ah8Bx/wSHPHIBl6Z8biMVOJuXglONJUHixdbjXVHQ9pk+XcIKRptm3Ql7iW6rgZ0CUppmsbkKSrzx64fijqopL1NxUDMSDzkLaI633uZ/0bLiKV7XDJ9enAQup59ZwCouIlmEn57PeFkNkHIG3yO2ED/PY/TDvV8LKa28A1XAqf0qQkv/de3hAvyCJHjX5twkbYP3JMaypGSlKx8SXQnJSHzMXou7h9PcYTa6kGa1VAAlp0YLpSUd5v/UkkDPig8X/8H4hD9m/hoUKHFVx7uye2awtC94xM9QUaB2fboFDhW0vDBfdctHBMq68mjD3QioKNKhCXvFmzI/lCTQzu0Qb0krjvdm12pYg X-Forefront-PRVS: 07915F544A X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM0PR07MB4193; 23:4fYuyVvFTv4lqwLqRtvzXxgJdTAY6coRBM6pEb3di?= =?us-ascii?Q?dO+19fP1hXDK9p4iRi2Zo8+CxAacU8aTvsM9fgdMpbSp9x4nrXMSNfdbEF5C?= =?us-ascii?Q?ZuBRjIdE46KICTW2X0j5VxlX4Dn34x59X7Lu2F+pUfluY392L8nEcF3G1CAs?= =?us-ascii?Q?WhL+Ihzd8J5xWkGBNNkAZwU2yjntebP+Lu6BZ9av8YoRWKlliK6T60obzp/v?= =?us-ascii?Q?bH2rZjacVGGlIpLhLFQKunXY/N4ET+wGgMNbLok5CHx6eDfpLjJXe7rR7DDf?= =?us-ascii?Q?dUB80PPuDN27K3nte5EOTh0gBFT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kUqd5DWXMomB0yfev5d3pQ1sZqd2iYGTjjusJoZdWE1mWHviDtzF8GzBm+wmaTC9/ibvVHQd+PdDmzw34dxhAM5CBm35/lTdeR7Q1bybiD5WPs=; 7:b6fT8pZvnFVg8W6adbucUmw3VC1X++jCn885SwPVA+KF8GI0U5MCXR2YXAq/Wt6ooKcaFCO52RAXdlLCb9sgIBgvTTHj3OQeKLwl3KHiPPzby/dbcdAS6/TYa92Igmz5J4B8l6LlfCP6fRhcyTQ91h5gr6jIqapKu/k1e9VEPLMedblriyez2ZDsEp7nrQq+VQkCEwAed7zFVI5nzuv/gqzGwtTO/R1xVSe3Q53zHK3Y7C4W232z86/jmvQ9PaKW SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: nokia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Sep 2018 15:51:22.3392 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 665820b3-5218-4a62-3bab-08d6173541e0 X-MS-Exchange-CrossTenant-Id: 5d471751-9675-428d-917b-70f44f9630b0 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5d471751-9675-428d-917b-70f44f9630b0; Ip=[131.228.2.241]; Helo=[mailrelay.int.nokia.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR07MB4193 Subject: [dpdk-dev] [PATCH] net/fm10k: add imissed stats X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 10 Sep 2018 15:51:24 -0000 Add support of imissed and q_errors statistics, reported by PCIE_QPRDC register (see datasheet, section 11.27.2.60), which exposes the number of receive packets dropped for a queue. Signed-off-by: Julien Meunier --- drivers/net/fm10k/fm10k_ethdev.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_ethdev.c index 541a49b..a9af6c2 100644 --- a/drivers/net/fm10k/fm10k_ethdev.c +++ b/drivers/net/fm10k/fm10k_ethdev.c @@ -1325,7 +1325,7 @@ fm10k_xstats_get(struct rte_eth_dev *dev, struct rte_eth_xstat *xstats, static int fm10k_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats) { - uint64_t ipackets, opackets, ibytes, obytes; + uint64_t ipackets, opackets, ibytes, obytes, imissed; struct fm10k_hw *hw = FM10K_DEV_PRIVATE_TO_HW(dev->data->dev_private); struct fm10k_hw_stats *hw_stats = @@ -1336,22 +1336,25 @@ fm10k_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *stats) fm10k_update_hw_stats(hw, hw_stats); - ipackets = opackets = ibytes = obytes = 0; + ipackets = opackets = ibytes = obytes = imissed = 0; for (i = 0; (i < RTE_ETHDEV_QUEUE_STAT_CNTRS) && (i < hw->mac.max_queues); ++i) { stats->q_ipackets[i] = hw_stats->q[i].rx_packets.count; stats->q_opackets[i] = hw_stats->q[i].tx_packets.count; stats->q_ibytes[i] = hw_stats->q[i].rx_bytes.count; stats->q_obytes[i] = hw_stats->q[i].tx_bytes.count; + stats->q_errors[i] = hw_stats->q[i].rx_drops.count; ipackets += stats->q_ipackets[i]; opackets += stats->q_opackets[i]; ibytes += stats->q_ibytes[i]; obytes += stats->q_obytes[i]; + imissed += stats->q_errors[i]; } stats->ipackets = ipackets; stats->opackets = opackets; stats->ibytes = ibytes; stats->obytes = obytes; + stats->imissed = imissed; return 0; } -- 2.10.2