From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0F808A0544; Tue, 21 Jun 2022 00:52:53 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A07914069C; Tue, 21 Jun 2022 00:52:52 +0200 (CEST) Received: from mail-pf1-f174.google.com (mail-pf1-f174.google.com [209.85.210.174]) by mails.dpdk.org (Postfix) with ESMTP id 09CAD40151 for ; Tue, 21 Jun 2022 00:52:50 +0200 (CEST) Received: by mail-pf1-f174.google.com with SMTP id w6so4278358pfw.5 for ; Mon, 20 Jun 2022 15:52:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=B+ybPK7DrmMSdvjnCOykj8PRt5/Rzc5xCNfdsjnj+ec=; b=h0ulVBIjmVkjK1bvBKFH2UrBWGNx60YUUYgGBZVqxzGIpbLhj97/RDUb8vM+iLv5PW fyIiuMiqYM+3h3DMuXtlixjAFNsVCJeM1pG0YPvGZXHTpj/7zVkkPnimmPvGA0YAiHHW JO3YdtbHvPKjdR3mXRRXfjV/cL0LQMUarPTerG64qnQ+e5f28wGzIFUoOw97ZP7rnen/ glGpuGVzA/zhClfZJNhbqPvuXBM8BvzsZifvqVD4xBNg4zQd7FuPjIxiBF8VpeJfWXGH i4jiUQu+bwbqIg7AYHRHJ+rqAfFy8o8CFn7VAcvuv8W7NzxzfmZYQ6CyKyKqQ6mo8tZo 4RYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=B+ybPK7DrmMSdvjnCOykj8PRt5/Rzc5xCNfdsjnj+ec=; b=eV++7cjkNhIbGx92fnNOvqMp6cbc8yzhLQ/YVh7qUwqaEx+HrTzKpPcE/h8FIj+ctu TZ1ri2z7R0sXidLhclYCcL/5Y9WuH7DGG9UoJieV2w5YukOVUAICKjI6jivJY47Yc6I3 vtSkv4E/d4/0rO4Unib0mf3QPVPrU/rxNovzEW1bMS2UAbwDoFVvnwY8Qssd66TZq/2S x5hQdazrE17oFsEFbXJeEdeKMqULm96nqrlWeQumexvf+sC2lj2sBbXT2OWEPfzvExDn dX3jgS5IsiIIfW/uyWcECAPLPgBvNKVHs2xXGMLIBTqJkj/Snt/xSfqZyjgAfaTmUgFR NqhQ== X-Gm-Message-State: AJIora8mwtySft4359Qffd+dU25kj7NjQe/UlXoN+B0zJO0mO2S2p6VK QtHl2S2ydeIcQgwbVDuREjoeqkdvJUVwEefm X-Google-Smtp-Source: AGRyM1vTkFxoFuPYBRz9LnH82qJFeGGIqfo11LjZrwNTPUA6AFtzWMtNA2W5iqaC/2c2UeGLdLE4yA== X-Received: by 2002:a65:6d89:0:b0:3fa:5523:440e with SMTP id bc9-20020a656d89000000b003fa5523440emr23761821pgb.318.1655765569964; Mon, 20 Jun 2022 15:52:49 -0700 (PDT) Received: from hermes.local (204-195-112-199.wavecable.com. [204.195.112.199]) by smtp.gmail.com with ESMTPSA id v22-20020aa78096000000b0050dc76281e0sm3740855pff.186.2022.06.20.15.52.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 20 Jun 2022 15:52:49 -0700 (PDT) Date: Mon, 20 Jun 2022 15:52:46 -0700 From: Stephen Hemminger To: Ido Goshen Cc: ferruh.yigit@xilinx.com, dev@dpdk.org Subject: Re: [PATCH v7 2/3] pcap: support MTU set for linux interfaces TX enhancment Message-ID: <20220620155246.243737b7@hermes.local> In-Reply-To: <20220619093034.26891-3-ido@cgstowernetworks.com> References: <20220317174347.110909-1-ido@cgstowernetworks.com> <20220619093034.26891-1-ido@cgstowernetworks.com> <20220619093034.26891-3-ido@cgstowernetworks.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org On Sun, 19 Jun 2022 12:30:33 +0300 Ido Goshen wrote: > Drop only the oversized packets and not its entrie burst > mbuf will be freed and will be counted as oerror > > Signed-off-by: Ido Goshen > --- > drivers/net/pcap/pcap_ethdev.c | 10 ++++++++-- > 1 file changed, 8 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/pcap/pcap_ethdev.c b/drivers/net/pcap/pcap_ethdev.c > index 2221c53051..ff98762058 100644 > --- a/drivers/net/pcap/pcap_ethdev.c > +++ b/drivers/net/pcap/pcap_ethdev.c > @@ -494,8 +494,14 @@ eth_pcap_tx(void *queue, struct rte_mbuf **bufs, uint16_t nb_pkts) > */ > ret = pcap_sendpacket(pcap, > rte_pktmbuf_read(mbuf, 0, len, temp_data), len); > - if (unlikely(ret != 0)) > - break; > + if (unlikely(ret != 0)) { > + if (errno == EMSGSIZE) { Will this show up in tx_errors? > + rte_pktmbuf_free(mbuf); > + continue; > + } else { > + break; > + } else is not needed here. > + } > num_tx++; > tx_bytes += len; > rte_pktmbuf_free(mbuf);