From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f41.google.com (mail-wm0-f41.google.com [74.125.82.41]) by dpdk.org (Postfix) with ESMTP id 81E708E7B for ; Wed, 25 Nov 2015 01:54:06 +0100 (CET) Received: by wmec201 with SMTP id c201so234221406wme.0 for ; Tue, 24 Nov 2015 16:54:06 -0800 (PST) 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; bh=5JSrhI/SQXsAuc5nf9ili0Lp9R1+9hPWRGzYKl1j7eY=; b=qPOyts8RE5sM4Urf7mdl/lqyWL/8yskrzzv0lmCgCNn6nrDQafx7zaa9rAAA8Su5mx w7G3GHxF7be35wYLeUD3eGNTrw2rrDce+xeV+0FA2r9AvlmfzqiPlD+3A6Scly0Q+fFZ spme1CBviz7p7es8GR2dxlyHzojailsf6FX6OHGVrfPFGMw1YX45BVvm1ohq8HOr1WfG xSHAXgcUTErDnBBKdyD0CVjwqmRKOhKZMsxrl+RyTtshe6ycvpB8PQQiMitN/h8bh9pn TuwYaQJUncYE8t5X3cmmR7Tj8OJP4KQJ9XZVbw184Ujpyz0IkAaUWCyMrKahY3Uov/+X Vnyg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=5JSrhI/SQXsAuc5nf9ili0Lp9R1+9hPWRGzYKl1j7eY=; b=gOeBjfm443qzCD/uzxO77bjrKZ8AcvGN2bmoyDnTYz2hp0Vg9VfNNYHxPP+UnYSb2Y xtTFt8sZB6bVUYDfZh1hPpX64kn6rzs3lV1hswNqvvCVOhqdWhkHPvDwKOXsJ+ID7O4w gmLzALSddqC8oe59COG7sZcNhD9KKhoAZrHTBqUbiXnPtqOsqe3zfkd1xoWIPvFqVahy 11J0c/TfXH0eWUWiF9cN3k5GxPc5E2fxMLe+wKqhLRCMDAmkXgk1DpyfBesqrJzGB5FU 1DdnloHJvWfn+kRPq0oo7CNsyNfqBgFMoR7gq77hsLIjANclMDGk3w8YVSuyv4DrnyPk lgSg== X-Gm-Message-State: ALoCoQn2FynZVoz17o0THTR/AVEA7GLq5AELEDU/1FtChsyotH++F307AdvO1ko6+wW87/f3Gkej X-Received: by 10.28.211.12 with SMTP id k12mr1257458wmg.29.1448412846382; Tue, 24 Nov 2015 16:54:06 -0800 (PST) Received: from localhost.localdomain (136-92-190-109.dsl.ovh.fr. [109.190.92.136]) by smtp.gmail.com with ESMTPSA id he3sm20639627wjc.25.2015.11.24.16.54.05 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 Nov 2015 16:54:05 -0800 (PST) From: Thomas Monjalon To: stephen@networkplumber.org Date: Wed, 25 Nov 2015 01:52:31 +0100 Message-Id: <1448412751-24843-1-git-send-email-thomas.monjalon@6wind.com> X-Mailer: git-send-email 2.5.2 Cc: dev@dpdk.org Subject: [dpdk-dev] [PATCH] sched: remove unused debug functions 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: Wed, 25 Nov 2015 00:54:06 -0000 clang warns about unused functions when debug is enabled. Signed-off-by: Thomas Monjalon --- lib/librte_sched/rte_sched.c | 31 ------------------------------- 1 file changed, 31 deletions(-) diff --git a/lib/librte_sched/rte_sched.c b/lib/librte_sched/rte_sched.c index 9f0b458..d47cfc2 100644 --- a/lib/librte_sched/rte_sched.c +++ b/lib/librte_sched/rte_sched.c @@ -1055,16 +1055,6 @@ rte_sched_port_queue_is_empty(struct rte_sched_port *port, uint32_t qindex) return (queue->qr == queue->qw); } -static inline int -rte_sched_port_queue_is_full(struct rte_sched_port *port, uint32_t qindex) -{ - struct rte_sched_queue *queue = port->queue + qindex; - uint16_t qsize = rte_sched_port_qsize(port, qindex); - uint16_t qlen = queue->qw - queue->qr; - - return (qlen >= qsize); -} - #endif /* RTE_SCHED_DEBUG */ #ifdef RTE_SCHED_COLLECT_STATS @@ -1156,27 +1146,6 @@ rte_sched_port_set_queue_empty_timestamp(struct rte_sched_port *port, uint32_t q #ifdef RTE_SCHED_DEBUG -static inline int -debug_pipe_is_empty(struct rte_sched_port *port, uint32_t pindex) -{ - uint32_t qindex, i; - - qindex = pindex << 4; - - for (i = 0; i < 16; i++) { - uint32_t queue_empty = rte_sched_port_queue_is_empty(port, qindex + i); - uint32_t bmp_bit_clear = (rte_bitmap_get(port->bmp, qindex + i) == 0); - - if (queue_empty != bmp_bit_clear) - rte_panic("Queue status mismatch for queue %u of pipe %u\n", i, pindex); - - if (!queue_empty) - return 0; - } - - return 1; -} - static inline void debug_check_queue_slab(struct rte_sched_port *port, uint32_t bmp_pos, uint64_t bmp_slab) -- 2.5.2