From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 62D63C7618F for ; Mon, 15 Jul 2019 15:39:24 +0000 (UTC) Received: from dpdk.org (dpdk.org [92.243.14.124]) by mail.kernel.org (Postfix) with ESMTP id 1C1452081C for ; Mon, 15 Jul 2019 15:39:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1C1452081C Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=dev-bounces@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id D1B492C18; Mon, 15 Jul 2019 17:39:22 +0200 (CEST) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id 00E152BA8 for ; Mon, 15 Jul 2019 17:39:20 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 Jul 2019 08:39:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.63,493,1557212400"; d="scan'208";a="161116889" Received: from wcpqa1.an.intel.com ([10.123.72.207]) by orsmga008.jf.intel.com with ESMTP; 15 Jul 2019 08:39:19 -0700 From: Erik Gabriel Carrillo To: thomas@monjalon.net Cc: dev@dpdk.org Date: Mon, 15 Jul 2019 10:39:30 -0500 Message-Id: <1563205172-352-1-git-send-email-erik.g.carrillo@intel.com> X-Mailer: git-send-email 1.7.10 Subject: [dpdk-dev] [PATCH 0/2] fix segfault seen with performance-thread example 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" A crash occurs in the examples/performance-thread/l3fwd-thread when it calls into rte_timer_manage() from the LThread library it utilizes. This happens because the application omitted a call to rte_timer_subsystem_init(), which leaves a pointer set to null in the timer library. This pointer is dereferenced in a check for validity of a timer data object, resulting in the segfault. This series fixes the validity check in the timer library, and adds the missing call to rte_timer_subsystem_init in the application. Erik Gabriel Carrillo (2): timer: fix null pointer dereference examples/performance-thread: init timer subsystem examples/performance-thread/l3fwd-thread/main.c | 5 +++++ lib/librte_timer/rte_timer.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) -- 2.6.4