From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lb0-x22a.google.com (mail-lb0-x22a.google.com [IPv6:2a00:1450:4010:c04::22a]) by dpdk.org (Postfix) with ESMTP id 85005156 for ; Tue, 19 Nov 2013 11:34:19 +0100 (CET) Received: by mail-lb0-f170.google.com with SMTP id w7so2180003lbi.29 for ; Tue, 19 Nov 2013 02:35:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=vYC3ZXPZZLVMU0Mkrc57984bT81DsNqHOA7qOTyLzXc=; b=QG3Xb3+EzYRxLS2oBRw5Kooadlz7vAP3gqOLFYHTQ+c95rX5lu7Y0qFJqr7e4iwRIW hnVPS/FhNOIGWHLUvGtLkGghbrQYGLhEFcqH3IYcDGQ4WP6m0YtGJaSf/LZuT3RD+Dem C332fWDn0DDaNbT0lgsI4cPk5eY0adnvhlkKi3Np1OP60YyMnVHRodUvKR4x7vj3Uj9A gscjcDpXqzjhYKgazxRSQ3hbiLMUl/D2C6hNa8IgJuZJAv58P8aGd8NmM+BGb3AdmV5V JP1niYt6UOUp+Jbo5KYRiKllHImC2sPdOK0WwN6ELtx749ove3LJ7GsiTj1rpFwNafLT ee2w== MIME-Version: 1.0 X-Received: by 10.112.168.170 with SMTP id zx10mr17382336lbb.0.1384857316814; Tue, 19 Nov 2013 02:35:16 -0800 (PST) Received: by 10.114.59.130 with HTTP; Tue, 19 Nov 2013 02:35:16 -0800 (PST) Date: Tue, 19 Nov 2013 18:35:16 +0800 Message-ID: From: Jose Gavine Cueto To: "dev@dpdk.org" Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: [dpdk-dev] rte_ring_sc_dequeue returns 0 but sets packet to NULL 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, 19 Nov 2013 10:34:20 -0000 Hi, I am encountering a strange behavior of rte_ring_sc_dequeue, though I'm not yet sure what causes this. I have a code: rc = rte_ring_sc_dequeue(fwdp->rxtx_rings->xmit_ring, &rpackets); At first dequeue, rpackets gets a correct address of an rte_mbuf, however at the second dequeue it returns 0 which is successful but sets the rte_mbuf result to a NULL value. Is this even possible, because its happening in my scenario. Or it could be just there's something wrong with my code. Cheers, Pepe -- To stop learning is like to stop loving.