From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com [74.125.82.67]) by dpdk.org (Postfix) with ESMTP id 03F477289 for ; Thu, 29 Mar 2018 23:24:20 +0200 (CEST) Received: by mail-wm0-f67.google.com with SMTP id f125so13884342wme.4 for ; Thu, 29 Mar 2018 14:24:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=28DRsv+QYAFHOkQRiCRQvubzBQLopqiLihNLEKJfEhQ=; b=G+lYVRNl0f+qbBt3d1/XV7vhOIfTdmPlJhiQF4LNHeBUDact1bMS2dblNIWX4VK9PO oV7cVi5g1kHjqXENfyUYG62ZcgWsxwRrK9UmJzLlO4YmVEbsTzI4DRRkyephhaOc1iYv xDa2czRculNEwB8ymBp/PW1F8wLkthx4pCy1YezgNlVw2byjFMkfB8AtomZ+UhAutokt ghFM5RC38x+gF/u9LFarK0rtu7hMyJ9mJZ5Oa7pkWh5GnZ80Jcx0HFgh36O3g5fx+kiK zwxtV+l9geipvwZxIuV8MQ4gAyigrpyOhRjApLEaeiK0vtMZxSr69ChBKuXKVrnCN+Ia Ct6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=28DRsv+QYAFHOkQRiCRQvubzBQLopqiLihNLEKJfEhQ=; b=dAiFnexpFlBhbHXUmCdKsETEOEC1ViyqHwf+mfJmoTgcIEfkCzDTe1sboe3bOyibQQ kSfYpCAOheaNw8MvC+9BzW6vgxrgoSec0SO/ct8GksfKl4pLbFAhdauMOmmvuPcrQV8F p3DPLyGKFaVe0k/idH/60jP55KUmpuctK9UqVwU51gLQoU4sK4leugQzEFrIZS9bsqkb uqVvUs904pBC1RqODs66dnX6NXRE1HXsef1vMaGHUXSSodBWx39cXnN/wq+2O+jIRMIK EajUlfiSRno2YTdQQ7+qyTDa7w/ASq7EYmnSv01LPSeWEVc0u+yfr2tKg4fPF30mx4kd Lutg== X-Gm-Message-State: ALQs6tB4Yy4Mbb01U9OUBqlZp9+4CeBz8u1YFZ1PUnYKHyLoKdrEebkB Rsrz78044te4PBJJXrxyfKa5+737 X-Google-Smtp-Source: AIpwx49y749qKUpVez97GOKkUYNZHw3XGrInHYdzvnMBWB/XKT7+yh0A6qHYq0qGWFs4sIVVBVTCNA== X-Received: by 10.28.63.2 with SMTP id m2mr383905wma.158.1522358659359; Thu, 29 Mar 2018 14:24:19 -0700 (PDT) Received: from bidouze.dev.6wind.com. (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id m35sm11907457wrm.59.2018.03.29.14.24.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Mar 2018 14:24:18 -0700 (PDT) From: Gaetan Rivet To: dev@dpdk.org Cc: Gaetan Rivet Date: Thu, 29 Mar 2018 23:23:29 +0200 Message-Id: X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: Subject: [dpdk-dev] [PATCH v4 05/20] eal/class: register destructor 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: Thu, 29 Mar 2018 21:24:21 -0000 Signed-off-by: Gaetan Rivet --- lib/librte_eal/common/include/rte_class.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/librte_eal/common/include/rte_class.h b/lib/librte_eal/common/include/rte_class.h index b5e550a34..e8176f5e1 100644 --- a/lib/librte_eal/common/include/rte_class.h +++ b/lib/librte_eal/common/include/rte_class.h @@ -112,6 +112,11 @@ static void classinitfn_ ##nm(void) \ {\ (cls).name = RTE_STR(nm);\ rte_class_register(&cls); \ +} \ +RTE_FINI_PRIO(classfinifn_ ##nm, CLASS); \ +static void classfinifn_ ##nm(void) \ +{ \ + rte_class_unregister(&cls); \ } #ifdef __cplusplus -- 2.11.0