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 63301A04C2; Fri, 15 Nov 2019 13:31:00 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 46B3E2BA8; Fri, 15 Nov 2019 13:30:59 +0100 (CET) Received: from mail-wm1-f66.google.com (mail-wm1-f66.google.com [209.85.128.66]) by dpdk.org (Postfix) with ESMTP id 960612B86 for ; Fri, 15 Nov 2019 13:30:58 +0100 (CET) Received: by mail-wm1-f66.google.com with SMTP id z26so9468832wmi.4 for ; Fri, 15 Nov 2019 04:30:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nfware-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=E3+WQf6AkRf5EPSczcCaNI1WdMZ5hYlu1KqJj7kzypc=; b=g/ur9Mi4CsOhLbRwYIW5qRkw5zRZ88mJcWy0sETtthNnGsy2iEZK2nke9ZVB1NYX4g e6HL93/ZcYIOw+kTaOqeSZFbnVCw1CSlyhhNcxvzhq+oZC0q/tou/eW3FbmrGvHN40y3 SvZrgOb+V5pNOFKBOpKmNVXnKmMJZeQw5DLKUCssLzhsQgPQRr8exybFuVr2isOIZRyo YvLnQHzjXMquH22RJaCMaZQsGFMthHgAa024B3xqSSMC1OjfDsIblYfVnLZCxTewJF+W 0gQBUW9J5+tu+0O7AzzLaCMlYKfswpjZfJxIDnDSHaXwN8wuU56KqkcAFhuCui5bUNiR 3zpg== 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=E3+WQf6AkRf5EPSczcCaNI1WdMZ5hYlu1KqJj7kzypc=; b=JnET6p015RwW5eFEZmPJ0R0l70xFrugRwXkYuMyMPmt2crrQY3Jw9DbCX3LOcX3Sqf g0abGrCeFvQFc1PyPhiEUZLNab0VFuylxOeg4gDuP6GUlNGhnfapDtvjUTjNM22RreLc /mpRU7e31gy1VJyI0ANKjO3eBn3UcNbe/RbxARAEr7+0tBI9+bOdOALs71GiEkPjUivF pu8hDYCkf8ZZ4Fi5l2ryftGybBEQPptB2rtoeAT34txjBXcMFvdk0nlzCBIFkNHATIyO HaBDaph2TMhUG+DFRfL0H+zzDw52kmUQdme4fJuo7SNrGt/7iMCNaq90Gjy/cOoccsPh YUpA== X-Gm-Message-State: APjAAAXsh5mkacrkTsTUTUqGrrK6cn+nZDkkPwfMVi36Uk2+L116oq2e htwP4PfflM+BHRS73ZU7EtHPJ6VWZTTqLG72tN8r1g== X-Google-Smtp-Source: APXvYqzjScP8Y4KhTgwqxQ+vaYCOBWEw2zAfsy4RekQ2doCvHvmBoqmKVd3S+EuCcEqlzwYm4e91xFtMb6eAKloTGU8= X-Received: by 2002:a1c:1d48:: with SMTP id d69mr13418756wmd.160.1573821058151; Fri, 15 Nov 2019 04:30:58 -0800 (PST) MIME-Version: 1.0 References: <20191115114107.30737-1-michael.pfeiffer@tu-ilmenau.de> In-Reply-To: <20191115114107.30737-1-michael.pfeiffer@tu-ilmenau.de> From: Igor Ryzhov Date: Fri, 15 Nov 2019 15:30:47 +0300 Message-ID: To: Michael Pfeiffer Cc: Ferruh Yigit , dev Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH] kni: reduce interface name size X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Hi Michael, Isn't it better to set it to IFNAMSIZ instead of 16? Best regards, Igot On Fri, Nov 15, 2019 at 2:41 PM Michael Pfeiffer < michael.pfeiffer@tu-ilmenau.de> wrote: > The name in rte_kni_device_info is passed to the kernel, which allows > interface names with at most 16 bytes (IFNAMSIZ). rte_kni_alloc with a > longer name currently trigger a kernel BUG in alloc_netdev_mqs in > net/core/dev.c. Reduce RTE_KNI_NAMESIZE to prevent this situation. > > Signed-off-by: Michael Pfeiffer > --- > lib/librte_eal/linux/eal/include/rte_kni_common.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/librte_eal/linux/eal/include/rte_kni_common.h > b/lib/librte_eal/linux/eal/include/rte_kni_common.h > index 46f75a710..59339271b 100644 > --- a/lib/librte_eal/linux/eal/include/rte_kni_common.h > +++ b/lib/librte_eal/linux/eal/include/rte_kni_common.h > @@ -18,7 +18,7 @@ > /** > * KNI name is part of memzone name. > */ > -#define RTE_KNI_NAMESIZE 32 > +#define RTE_KNI_NAMESIZE 16 > > #define RTE_CACHE_LINE_MIN_SIZE 64 > > -- > 2.20.1 > >