From patchwork Thu Jan 12 12:14:19 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 91138 Delivered-To: patch@linaro.org Received: by 10.140.20.99 with SMTP id 90csp1589731qgi; Thu, 12 Jan 2017 04:14:53 -0800 (PST) X-Received: by 10.55.19.224 with SMTP id 93mr13789027qkt.198.1484223293645; Thu, 12 Jan 2017 04:14:53 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id q20si5958214qtf.106.2017.01.12.04.14.53; Thu, 12 Jan 2017 04:14:53 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 019CF60843; Thu, 12 Jan 2017 12:14:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 3FA6160682; Thu, 12 Jan 2017 12:14:49 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 18E18606B4; Thu, 12 Jan 2017 12:14:47 +0000 (UTC) Received: from mail-oi0-f41.google.com (mail-oi0-f41.google.com [209.85.218.41]) by lists.linaro.org (Postfix) with ESMTPS id 6DE5F6074E for ; Thu, 12 Jan 2017 12:14:23 +0000 (UTC) Received: by mail-oi0-f41.google.com with SMTP id w204so20500719oiw.0 for ; Thu, 12 Jan 2017 04:14:23 -0800 (PST) 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; bh=r1e5zlD3LASY21K3FwZlfEsUKt0R5oL3MHD2S6OpaPI=; b=PNCp3EL8Fh/vQtB8A+hZmRONZqdQ0/65AAEPIWU7Pq1kIKUFHWNXe7W7aFI2ZXydxu 1f1U31vhBUjNMCiLWB7QaywyDToV7S1mBSM5GlSrU1rxa9c8GHJ2DtObzq1KZIQoVeZF pQVQ0XfRtQ0+ihs+QpGn9g2fwqrdVMH8PdJr1ZIW2wQcrLUinlZttWD4LoWua/v390TY jCFD4hvaa6dax6Hs4TQ9LYW+w2oaofkwS7zSJ05XJWdDMxfM4b6FrCyFaGlbj26tH2uX KgCFY5JsoEtYVUKNqHc2CMLdsBkfoXUIQFJW5js4eO8ZLWQmIo118dtLwWzRNXXRFn4b HBzQ== X-Gm-Message-State: AIkVDXLRpnQ1WeM2GuU0GNBc2WDIN9tlDXLGszPqiIgUteaXfsRZG4l4UKPTNKi6Xvj2xtivWC8= X-Received: by 10.202.189.86 with SMTP id n83mr6822853oif.49.1484223262911; Thu, 12 Jan 2017 04:14:22 -0800 (PST) Received: from localhost.localdomain (cpe-70-121-83-241.austin.res.rr.com. [70.121.83.241]) by smtp.gmail.com with ESMTPSA id z34sm3959499ota.35.2017.01.12.04.14.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Jan 2017 04:14:22 -0800 (PST) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Thu, 12 Jan 2017 06:14:19 -0600 Message-Id: <20170112121419.1529-1-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.9.3 Subject: [lng-odp] [API-NEXT PATCH] linux-generic: packet: remove erroneous assert X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" odp_packet_set_len() is only called from the classifier on paths for which a dummy header may be used. Rather than setting a dummy reference count to validate, it's simpler to just delete the assert. This resolves Bug https://bugs.linaro.org/show_bug.cgi?id=2814 Signed-off-by: Bill Fischofer --- platform/linux-generic/include/odp_packet_internal.h | 2 -- 1 file changed, 2 deletions(-) -- 2.9.3 Reviewed-by: Christophe Milard diff --git a/platform/linux-generic/include/odp_packet_internal.h b/platform/linux-generic/include/odp_packet_internal.h index 607560d..c5dc989 100644 --- a/platform/linux-generic/include/odp_packet_internal.h +++ b/platform/linux-generic/include/odp_packet_internal.h @@ -324,8 +324,6 @@ static inline void packet_ref_count_set(odp_packet_hdr_t *pkt_hdr, uint32_t n) static inline void packet_set_len(odp_packet_hdr_t *pkt_hdr, uint32_t len) { - ODP_ASSERT(packet_ref_count(pkt_hdr) == 1); - pkt_hdr->frame_len = len; pkt_hdr->unshared_len = len; }