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 6497A41C99; Tue, 14 Feb 2023 23:47:51 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 54CE842FAE; Tue, 14 Feb 2023 23:47:51 +0100 (CET) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by mails.dpdk.org (Postfix) with ESMTP id B9EBA42FAA for ; Tue, 14 Feb 2023 23:47:50 +0100 (CET) Received: by mail-pj1-f45.google.com with SMTP id d13-20020a17090ad3cd00b0023127b2d602so225311pjw.2 for ; Tue, 14 Feb 2023 14:47:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=L3aqaeK/W/k2B6TMYwTak/loUQqlYC0thUkEp6I0Mps=; b=5sHUj8NluqTIqQpu1VgKv630NrsV4pLwVJfF3PKitnCdlni7V4SvbApZpbfLKZQB6C CcNaigmNQ0BrhH6knHBtMbyc7cxRlvKxbM56IFSXG2ZG026TJHctyZm3OKCbQTCgmEeI q+SUicoGt7X0j/G3VPjjtsA6um7Fbo9zwj0uKgeZVAp2PdIo9bbI8FpNQS3tqLrf/hz6 bYuN6+tkS/5lq8Mjw7UnljL7Uj2V/u1bOsT59O/PCpWgS0RSe9ngQbloARxO+x4J9Ewa pLUk3bR8EnkU25aWnY4emStIZtNDgBRCMX3MUW6wr+zydKbCkF0deRvwKLWaqMiEr+Ll WePg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=L3aqaeK/W/k2B6TMYwTak/loUQqlYC0thUkEp6I0Mps=; b=OWDebsKvY+lPcv2j4XnNG7pN8SPQq8AgOzhiur1jqLfovHEfLDegeVGr95GOEsog0D /AfSm+xikeKJkpQcRx5LLM4wZWEozNeK0bQApgk1isWxYkZBJcsLDxLni6E47bTSXk5w z4336121aG2LHNWUtSgQETSIkO/HceaOSafZDWhw6jTjQYyOdjAUE+RRgKgr5C/sr7Qf Hl0qm84njWeV5oEdh7+Z9ohuUNew1QmvTwEDYiR627EqHm6pjB8+/3IjZOXD+/naChUM n8oEjPCznckw/2Mrcpa5u8DIo+5hHVYOpJWYb3W1vNZWUKxlykYyHNWhV/FuhDwD+B5h JXpg== X-Gm-Message-State: AO0yUKVdWXYrlbUZ+J2nAX6YJhlhXWgK2i357a4arAWgUvCGZMgbO6J/ MRx6q4dySpQxosC1fHLQEEDwW7T2Gcq/ZsNpd88= X-Google-Smtp-Source: AK7set+n6SAdr7E7x0qf9zVLa/eHMLfZ/oRU0dqnHEmWbECEKzsVn5/U+mPWXfrdAaldAoTFoDfiRw== X-Received: by 2002:a17:903:22cd:b0:19a:aacf:92b6 with SMTP id y13-20020a17090322cd00b0019aaacf92b6mr252621plg.40.1676414869538; Tue, 14 Feb 2023 14:47:49 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id u9-20020a17090341c900b0019607984a5esm10735785ple.95.2023.02.14.14.47.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Feb 2023 14:47:49 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , jiayu.hu@intel.com, Konstantin Ananyev , Mark Kavanagh Subject: [PATCH v6 01/22] gso: don't log message on non TCP/UDP Date: Tue, 14 Feb 2023 14:47:14 -0800 Message-Id: <20230214224735.1404326-2-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.1 In-Reply-To: <20230214224735.1404326-1-stephen@networkplumber.org> References: <20230207204151.1503491-1-stephen@networkplumber.org> <20230214224735.1404326-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 If a large packet is passed into GSO routines of unknown protocol then library would log a message. Better to tell the application instead of logging. Fixes: 119583797b6a ("gso: support TCP/IPv4 GSO") Cc: jiayu.hu@intel.com Signed-off-by: Stephen Hemminger --- lib/gso/rte_gso.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/gso/rte_gso.c b/lib/gso/rte_gso.c index 4b59217c16ee..c8e67c2d4b48 100644 --- a/lib/gso/rte_gso.c +++ b/lib/gso/rte_gso.c @@ -80,9 +80,8 @@ rte_gso_segment(struct rte_mbuf *pkt, ret = gso_udp4_segment(pkt, gso_size, direct_pool, indirect_pool, pkts_out, nb_pkts_out); } else { - /* unsupported packet, skip */ - RTE_LOG(DEBUG, GSO, "Unsupported packet type\n"); - ret = 0; + ret = -ENOTSUP; /* only UDP or TCP allowed */ + } if (ret < 0) { -- 2.39.1