From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id AEE408D9D for ; Tue, 29 Dec 2015 09:23:49 +0100 (CET) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga102.jf.intel.com with ESMTP; 29 Dec 2015 00:23:48 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,494,1444719600"; d="scan'208";a="882710892" Received: from unknown (HELO dpdk5.sh.intel.com) ([10.239.129.244]) by fmsmga002.fm.intel.com with ESMTP; 29 Dec 2015 00:23:47 -0800 From: Zhihong Wang To: dev@dpdk.org Date: Mon, 28 Dec 2015 20:20:29 -0500 Message-Id: <1451352032-105576-1-git-send-email-zhihong.wang@intel.com> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1451011032-83106-1-git-send-email-zhihong.wang@intel.com> References: <1451011032-83106-1-git-send-email-zhihong.wang@intel.com> Subject: [dpdk-dev] [PATCH v3 0/3] Handle SIGINT and SIGTERM in DPDK examples X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Dec 2015 08:23:50 -0000 This patch handles SIGINT and SIGTERM in testpmd, l2fwd, and l3fwd, make sure all ports are properly stopped and closed. For virtual ports, the stop and close function may deal with resource cleanup, such as socket files unlinking. -------------- Changes in v3: 1. Make sure correct port operations regarding status 2. Small fixes to make the code clearer -------------- Changes in v2: 1. Make sure graceful exit for all running phases 2. Make sure program exits with the right status Zhihong Wang (3): app/test-pmd: Handle SIGINT and SIGTERM in testpmd examples/l2fwd: Handle SIGINT and SIGTERM in l2fwd examples/l3fwd: Handle SIGINT and SIGTERM in l3fwd app/test-pmd/cmdline.c | 20 +++++--- app/test-pmd/testpmd.c | 39 ++++++++++++--- app/test-pmd/testpmd.h | 1 + examples/l2fwd/main.c | 123 +++++++++++++++++++++++++++++++++++++--------- examples/l3fwd/main.c | 129 ++++++++++++++++++++++++++++++++++++++++--------- 5 files changed, 255 insertions(+), 57 deletions(-) -- 2.5.0