From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id ACF5FA0471 for ; Tue, 13 Aug 2019 06:59:13 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 9D4941BDAE; Tue, 13 Aug 2019 06:59:13 +0200 (CEST) Received: from mail-ot1-f53.google.com (mail-ot1-f53.google.com [209.85.210.53]) by dpdk.org (Postfix) with ESMTP id 45F7F1BDAC for ; Tue, 13 Aug 2019 06:59:12 +0200 (CEST) Received: by mail-ot1-f53.google.com with SMTP id n5so167894814otk.1 for ; Mon, 12 Aug 2019 21:59:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=cMmV+ri3ClFCQS+I77WnVA3YGVUDlakPnX25Li83osc=; b=IWuhZyyX8DLv1E2oqEuRYFsXed01rr9Ekdh/l4f+9D2PHY7QJ6Ho131oIvnGDDiPv2 qiQyIRAmSBvXe0zn7HzNgmR3eqoP+gNeVkLCgQuBzgDU7XgYQ6PqeUdtYeieIXBs1Cj1 aU39zdaOfumT/PTPE674wol61WM3QIbQbe+L7hvKDHyCaK6tsI8MvhPWR+la3VvD+C7o HptjfZH1g64VezeV3xOEPwvx4KozITxGYvj2VVDqThfxT8g571syropuLWcecWXd1YYu b0J4+gfbx+iN1lle18QduLSYw+DxvgZpJExbjC40EzEzdrO+nbEkw/1G/TI4jhCYE4qd Kzrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=cMmV+ri3ClFCQS+I77WnVA3YGVUDlakPnX25Li83osc=; b=IvPD5OQIO9GukafjnRbM69P02Ue2ZuC11IC0JlEEcdJ94R/XPXrYVdpvnucStsw0g5 Vo62CDzVWJjyOxdcW3KaN1Ugz2ILB4i/I2KRes+Q1Nhcr8XlQRNWKP3qYvsrgFUk2vor B8lGkzE/Lz1HICriA3oM7TMKocXTLFUV5wk8ip4P+lJDunH1u0C72L/u1wblLzOqkuOb SDO/BUzvRlvbQoF1z5h1IkCLXxmt7v/VyCHHb0WU7xmu2SOLKzYN3NnW3dEXF7t2D9Xp zBtu/5GUqf6tGcXxRbkca9xpAmWsL/0U69lyKPMWEC4xe3M6vSgPIy+U1d8WX0u2uyNZ +QKA== X-Gm-Message-State: APjAAAXHUKbfzvxIRBNtfGHmpBwECZHXlo14lS3eiK1cAbnowmJkhU4G a9sESyMKs6syiKmd228NOZvh1WcSeXqqMlxK8PE= X-Google-Smtp-Source: APXvYqwHjAeRbqazyHNbhrJdNi2/K23PnPR605r9EiyBuZD1at2VWTWv1f7cwAdSyCawVHwqVeymu9BATPbOm7dcZyo= X-Received: by 2002:a6b:fb0f:: with SMTP id h15mr21674865iog.266.1565672351163; Mon, 12 Aug 2019 21:59:11 -0700 (PDT) MIME-Version: 1.0 References: <20190812202909.00c1eba7@hermes.lan> In-Reply-To: <20190812202909.00c1eba7@hermes.lan> From: Abhijeet Baruah Date: Tue, 13 Aug 2019 10:29:00 +0530 Message-ID: To: Stephen Hemminger Cc: users@dpdk.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] IP Reassembly with more 4 packets crash X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: users-bounces@dpdk.org Sender: "users" I had been making a mistake. My code was of format - if (rte_ipv4_frag_pkt_is_fragmented(ipv4_header)) { rte_mbuf* assembled_msg = rte_ipv4_frag_reassemble_packet(); if (assembled_msg != nullptr) { rte_ip_frag_free_death_row(); } } The rte_ip_frag_free_death_row was NOT getting called when reassembly was failing, as it was in my case of > 4 IP fragments. The fix is to call rte_ip_frag_free_death_row irrespective of reassembly status. On Tue, Aug 13, 2019 at 8:59 AM Stephen Hemminger < stephen@networkplumber.org> wrote: > On Tue, 13 Aug 2019 08:37:09 +0530 > Abhijeet Baruah wrote: > > > Hi, > > > > I have looked at previous mails on this mailing list and also elsewhere > on > > Google and could not find any information related to this. > > > > Whenever I have to reassemble a valid IP packet with more than 4 > fragments, > > I see a crash. Stack trace below. I assume the number 4 comes > > from RTE_LIBRTE_IP_FRAG_MAX_FRAG. > > > > (gdb) bt > > #0 ip_frag_lookup (tbl=tbl@entry=0x7fff7a32ce80, key=key@entry > =0x7ffff6eeee10, > > tms=tms@entry=2602613353715115, free=free@entry=0x7ffff6eeedb8, > > stale=stale@entry=0x7ffff6eeedc0) at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/ip_frag_internal.c:379 > > #1 0x00007ffff7c021f6 in ip_frag_find (tbl=tbl@entry=0x7fff7a32ce80, > > dr=dr@entry=0x7fff7a32c900, key=key@entry=0x7ffff6eeee10, > > tms=2602613353715115) > > at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/ip_frag_internal.c:286 > > #2 0x00007ffff7c00280 in rte_ipv4_frag_reassemble_packet > > (tbl=0x7fff7a32ce80, dr=0x7fff7a32c900, mb=0x7fff8b71b480, tms= > out>, > > ip_hdr=) at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/rte_ipv4_reassembly.c:160 > > > > (gdb) f 0 > > #0 ip_frag_lookup (tbl=tbl@entry=0x7fff7a32ce80, key=key@entry > =0x7ffff6eeee10, > > tms=tms@entry=2602613353715115, free=free@entry=0x7ffff6eeedb8, > > stale=stale@entry=0x7ffff6eeedc0) at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/ip_frag_internal.c:379 > > 379 if (ip_frag_key_cmp(key, &p1[i].key) == 0) > > > > (gdb) f 1 > > #1 0x00007ffff7c021f6 in ip_frag_find (tbl=tbl@entry=0x7fff7a32ce80, > > dr=dr@entry=0x7fff7a32c900, key=key@entry=0x7ffff6eeee10, > > tms=2602613353715115) > > at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/ip_frag_internal.c:286 > > 286 if ((pkt = ip_frag_lookup(tbl, key, tms, &free, &stale)) == NULL) { > > > > (gdb) f 2 > > #2 0x00007ffff7c00280 in rte_ipv4_frag_reassemble_packet > > (tbl=0x7fff7a32ce80, dr=0x7fff7a32c900, mb=0x7fff8b71b480, tms= > out>, > > ip_hdr=) at > > > /usr/src/debug/dpdk-17.11.2-6.fc30.x86_64/lib/librte_ip_frag/rte_ipv4_reassembly.c:160 > > 160 if ((fp = ip_frag_find(tbl, dr, &key, tms)) == NULL) { > > > > Is this a known issue? Are there any workaround? > > > > Regards, > > Abhijeet > > Please try and reproduce with latest DPDK 19.08. >