From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4E9CEA04A2 for ; Mon, 11 May 2020 15:43:41 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 2E6A51C1AF; Mon, 11 May 2020 15:43:41 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by dpdk.org (Postfix) with ESMTP id 809D41C06A; Mon, 11 May 2020 15:43:37 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id 04BDRL8Z016562; Mon, 11 May 2020 06:43:35 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : content-type : mime-version; s=pfpt0818; bh=ThnORpN7Z8Zz4kOEOvk/jsqpk8c5PqCusZed/HrTRks=; b=YDZguy7XfbHqc4jBJOXlxVMKD2KwMFuSzbWjlIi4TmDHq63jmMClW1n8oclgOlCIFXmo 46wN01lI1iFxK91bFiKjAkvBTSA+Ndyg/brNMIXxHfCu4txLXzo8j3R1DphR/rD7FMPR FlQ+8vHHCGTbBHFfFqBF+47gV3QjBgZg/Sw2mrPvUlITFQCERV9khFQxQlZC7qPkHqgN 9vaTk4BOayXeOhEY/UQS2MiaGj3cJicbTAOQG4ZPmVFJPhfh9fzhwSR7GdsqUNVCT7VU pIQZJwr176ATppL2nMTlrxEtHSEplUgbomQuVTNz7qS6HNpefAEWV2aGPUYVdHJkDuPl Ow== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0a-0016f401.pphosted.com with ESMTP id 30wsvqewqh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Mon, 11 May 2020 06:43:35 -0700 Received: from DC5-EXCH02.marvell.com (10.69.176.39) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 11 May 2020 06:43:33 -0700 Received: from SC-EXCH03.marvell.com (10.93.176.83) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 11 May 2020 06:43:33 -0700 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (104.47.66.41) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1497.2 via Frontend Transport; Mon, 11 May 2020 06:43:32 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RqeT08N6dNPrc/RCYjnQfME3Eo0NZnYCxfY+Oj04sXFW+J+2O4VSFgME+kMgf1+Y0GnhWvP7JgKD3nYg+bbGcLDPFD2b0pMUAwbXR9rOoigbrxCAjJHQmEsRu/0OxqKnJiGaf1m4qBCCBsmwdv4HB8fXvVNbYBiPMacYMzdu9+CElToUvn37qNAum3e3QYz0+rVVCptsMFvM1JH0sNVQVGCUGgqjloqchkqhP7PFpkq3qvUz166ypWIUkKRS+2Ef/aD8yKMLupjNFmBeqAeVc19wsqoSIxX/3109Cq4sYbt110Hui5fU8La2d9YhKJZVYQNZ0VJEDjvnvxUiNvYGEA== 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-SenderADCheck; bh=ThnORpN7Z8Zz4kOEOvk/jsqpk8c5PqCusZed/HrTRks=; b=D+Uj0jndEKnnqhPLKRtYUnq67JazU0cvEH2AhU/l68zk88JEtI5QWgARYNQOabvFh12rq4r8MiSlsD2zRQ1MuWtSbIELHBqfPXrzXUpheK3npE1wW77m64ZUXAHjH0AB75kOrJYImkT5ij9WJx2j/MuQvXbehbXGVM9CYOMiOhujL1a1vR6MAeDHZ+KUaSf8yzu0p+wKE53DS7qSl1VRWQNFlgNuV5HHAiF6gE6F5v0sosr19ZpJAoSP6dvU4iVMoVxfXaV0Q/Mi56HpIR9qAjA5GJHvHPq30Oz2AYfxSY+YdqaVNgrtX202jEo1PM8oY3qCRTQIuFeIzEUzD24JKw== 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=ThnORpN7Z8Zz4kOEOvk/jsqpk8c5PqCusZed/HrTRks=; b=b8JUcfbpow/FCnBdDCzMrb7j16iw/fXwwKza2BPw5tM5fFUd3EDqaGpjrkMoDtrVbTu/bzJbYtrre+UGYQe4nlTQavdaIm/qjdcUCqOGCZqYg2eK4MT2s/8mho9n/GHxC/Nf8PVVuGOKGLCvYlXhowAYlJPaXx8oa8uglrdI4lM= Authentication-Results: networkplumber.org; dkim=none (message not signed) header.d=none;networkplumber.org; dmarc=none action=none header.from=marvell.com; Received: from MN2PR18MB2848.namprd18.prod.outlook.com (2603:10b6:208:38::19) by MN2PR18MB2447.namprd18.prod.outlook.com (2603:10b6:208:100::30) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2979.34; Mon, 11 May 2020 13:43:29 +0000 Received: from MN2PR18MB2848.namprd18.prod.outlook.com ([fe80::a8b1:45c4:b84:9c02]) by MN2PR18MB2848.namprd18.prod.outlook.com ([fe80::a8b1:45c4:b84:9c02%7]) with mapi id 15.20.2979.033; Mon, 11 May 2020 13:43:29 +0000 From: Harman Kalra To: , , CC: , Harman Kalra , Date: Mon, 11 May 2020 19:13:05 +0530 Message-ID: <1589204585-13328-1-git-send-email-hkalra@marvell.com> X-Mailer: git-send-email 2.7.4 Content-Type: text/plain X-ClientProxiedBy: BMXPR01CA0006.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:d::16) To MN2PR18MB2848.namprd18.prod.outlook.com (2603:10b6:208:38::19) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from hkarlara-OptiPlex-3046.marvell.com (115.113.156.2) by BMXPR01CA0006.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:d::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.20.2979.26 via Frontend Transport; Mon, 11 May 2020 13:43:27 +0000 X-Mailer: git-send-email 2.7.4 X-Originating-IP: [115.113.156.2] X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2b242e30-ea13-4cf4-c0b6-08d7f5b149cd X-MS-TrafficTypeDiagnostic: MN2PR18MB2447: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2331; X-Forefront-PRVS: 04004D94E2 X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JSW5NEl+TqO+xlOAHAUz5XaoYmcuOUfbr/CZAbbFiJ8CoZs+M2YpKbc7tBPCVXlMpiOBUy8YOzCYQfV383JDs7pB3v/+y/M1Wo7wi6Ziqblj9W6zYN8o2DsFw9hmzKrJrYkHheSAD3puggqD0QcGMbqsh3Zu//FKjBn7v4DGg86/BMqseH65Pu3VZIzVQgX0o+h40ETU+t7OS56Lc4kRH5W40Yp+qm6tui/KXdbCtskL/Gg3m2CPx9nrttZxExUN8qwFAr1BQ1B/WiOMvQRUiW9bt6xTya1DFa7lq/oF83BXaDcesUAyozx+aQKrMs7sqI4zIi1Q+5IluzPzGJlC3F3SEDAWI9ixDmyWLcKEjaFBY9zVKrjq9ti/bmdcZSPBCjkqeYGyW0HjGLePVorKo9rv9koIh7fLnW02yupZwVo0/bAa/t0c/tp1k+txGWlRHQQESrW0Fpa5SLKLuy39d35cI6qR+GLZ4MMQ14MZDpmhnmpjWmVtfesuaukpKOyK43wblSd1kMqBBvDFhEphEQ== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MN2PR18MB2848.namprd18.prod.outlook.com; PTR:; CAT:NONE; SFTY:; SFS:(4636009)(396003)(366004)(136003)(376002)(346002)(39850400004)(33430700001)(6486002)(16526019)(66476007)(5660300002)(66946007)(66556008)(2616005)(8676002)(956004)(86362001)(7696005)(52116002)(55236004)(478600001)(186003)(4326008)(316002)(6666004)(26005)(2906002)(36756003)(33440700001)(8936002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: K29vFJ7g5cW8xHQksxLnIag/ntF30xvUbY0rpTY4qkic7fkp45CJuU+nQElvmC1PPbnkws9Zq0l81ta1IK2IhX2bPby9RFZ113WX2t5T9jkXSFq80cMt40ADi57bjPk1gE2vSHeeCKnSNOw3lrt+XlJsGC7GrOBYf78K0oVxNks2aPGFwe+7GYpbUn4kz3ZZUWIDj/9ZSvRCAaKqayaEaXsqEr0Wi4oSk96gKIFynQBhXddmlgA6x0gYubmFgeaOHX9P6Di/dkqAlG2nR/SJ/PsCC1ux0O+9YUN33xFNrW2uTeK96hDHef3SKc8Sh1lS3nNDVDA76W1WMKpx5C5wZ4BsdITZnu+7gV+gSeYfgNn3a1jt+OHoPBXsaacajEFu+ykO1Fnx0oVuGsuBZGBfNAJjEh81pGmULeoyFkyLf2UAt5Q5K5QHWXhqUgbnXTUFfH6IUVW2Lo7HOONKCuVsI7vuAebOcGemsL9og6n4JRE= X-MS-Exchange-CrossTenant-Network-Message-Id: 2b242e30-ea13-4cf4-c0b6-08d7f5b149cd X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 May 2020 13:43:29.6959 (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: z54vWV67a4t9mF4LD4WxSJ6IwJEe1ysjw86X6WMvwdH/AwFHlpOOAZJBOh+FoHaJ6b0o47jwP71e3dTKomix4Q== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR18MB2447 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.216, 18.0.676 definitions=2020-05-11_06:2020-05-11, 2020-05-11 signatures=0 Subject: [dpdk-stable] [PATCH] eal: fix epoll fd list rebuild X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" An issue has been observed where epoll file descriptor list rebuilds every time an interrupt/alarm event is received. eal_intr_process_interrupts() should notify pipe fd only if any source is removed from the source list i.e (rv > 0) Fixes: 0c7ce182a760 ("eal: add pending interrupt callback unregister" Cc: stable@dpdk.org Signed-off-by: Harman Kalra --- lib/librte_eal/linux/eal_interrupts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_eal/linux/eal_interrupts.c b/lib/librte_eal/linux/eal_interrupts.c index 16e7a7d51..84eeaa1bc 100644 --- a/lib/librte_eal/linux/eal_interrupts.c +++ b/lib/librte_eal/linux/eal_interrupts.c @@ -1010,7 +1010,7 @@ eal_intr_process_interrupts(struct epoll_event *events, int nfds) } /* notify the pipe fd waited by epoll_wait to rebuild the wait list */ - if (rv >= 0 && write(intr_pipe.writefd, "1", 1) < 0) { + if (rv > 0 && write(intr_pipe.writefd, "1", 1) < 0) { rte_spinlock_unlock(&intr_lock); return -EPIPE; } -- 2.18.0