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 696FFA00D7 for ; Fri, 1 Nov 2019 10:04:23 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 375891DFEC; Fri, 1 Nov 2019 10:04:23 +0100 (CET) Received: from mail-pf1-f194.google.com (mail-pf1-f194.google.com [209.85.210.194]) by dpdk.org (Postfix) with ESMTP id 0AAAE1D440; Fri, 1 Nov 2019 10:04:20 +0100 (CET) Received: by mail-pf1-f194.google.com with SMTP id c13so6624109pfp.5; Fri, 01 Nov 2019 02:04:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=lUTUwUK72KZVfcFFwIopZgSSrfOLUHARyDC9EJVIOms=; b=nhyRDnhNPqKZv+VQnUX8OUfXX1d5gcz/PwxkzxQmNCUQnloX5A8S/geH9d0g0dTK+1 zoaHPQalx/pGjLZpQGRUetggZLoNHmMf4PekKDnUhNqWHJX0amjbCUASYt/RJSjooTVy I2MSDS7VqaPWGEKGKeofyPW6qvqd9i09X3p1q+Kf/HMbjZjdGuECOULkYui3+Ts/AhwQ sRUOI7lK+Kpw7nA4FVYYEQWHo7mtU2cgYdaQhA+52+IAp1F1jcXqXswJCqPLq+UopQHV iDkvrNj16M0jQA+/5AY9g23cfPncGlsCY7eh2MgcKPae/YvdS2dui84IYYiwOOhvEpCI kIRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=lUTUwUK72KZVfcFFwIopZgSSrfOLUHARyDC9EJVIOms=; b=Wv8zqrXkZy8tyqHT6Aaxedz4UeFBZjQlwwpFIuc5VP9u25qLTuJEUaSm188xxzy7Vt 58AettkHTCKNCimG208fQBgYs+Q3RTXcleyb/ibSNik64U/Z0Ix2LLLWmmXCq0jtZPwc SGSxNe8q3cQcLFJUB49BgsB/nlTWf2o5xZh/fIdxjQRgtTsBC3eJ/Z33jO5YxPbsLmr2 5D7/oVS0eaWhX9Jf0KOpghnXXoyRVfrMZQEjqJIemY8UDF97JFag8s1yXWLTed0i0NGe eiV52U9Dc1UGBqDAe6wwZJvt/2LMMVoOJWn8fj+JcB4EZROCj8FaiJhfjOHGohS6gwoe FnsQ== X-Gm-Message-State: APjAAAVfKVlbI7cgvrovH/6Wus3FORAyPlNlvr3143QZfl0nwu/If8uh nzgHPAh5MS1wVY6+Xu8sT1Q= X-Google-Smtp-Source: APXvYqz9/QuBHioSTuWxyUDJilVBrwrMrnOMWRVSVID+FseByI3mGApEYV4xpQgT8ViuwB5nhdD7xA== X-Received: by 2002:a17:90a:c244:: with SMTP id d4mr13853028pjx.117.1572599059118; Fri, 01 Nov 2019 02:04:19 -0700 (PDT) Received: from localhost.localdomain ([192.47.164.146]) by smtp.gmail.com with ESMTPSA id s2sm5527426pgi.47.2019.11.01.02.04.17 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 01 Nov 2019 02:04:18 -0700 (PDT) From: yasufum.o@gmail.com To: anatoly.burakov@intel.com, david.marchand@redhat.com, konstantin.ananyev@intel.com Cc: dev@dpdk.org, stable@dpdk.org, yasufum.o@gmail.com Date: Fri, 1 Nov 2019 18:04:12 +0900 Message-Id: <20191101090413.17997-1-yasufum.o@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190724082031.45546-1-yasufum.o@gmail.com> References: <20190724082031.45546-1-yasufum.o@gmail.com> Subject: [dpdk-stable] [PATCH v6 0/1] fbarray: fix duplicated fbarray file in secondary X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" From: Yasufumi Ogawa In secondary_msl_create_walk(), it creates a file for fbarrays with its PID for reserving unique name among secondary processes. However, it does not work if several secondaries run as app containers because each of containerized secondary has PID 1, and failed to reserve unique name other than first one. To reserve unique name in each of containers, use hostname in addition to PID. --- v2: * fix typo in commit message v3: * add fclose() after if getting hostname with fscan() is failed v4: * Increase the size of proc_id to 33 and add boundary in calling fscan() v5: * revise title to reflect the issue * use gethostname() instead of getting from `etc/hostname` * use HOST_NAME_MAX for size of string for hostname v6: * change to use hostname and pid to cover both of host and container cases * change RTE_FBARRAY_NAME_LEN to NAME_MAX to reserve enough size for filename --- Yasufumi Ogawa (1): fbarray: fix duplicated fbarray file in secondary lib/librte_eal/common/include/rte_fbarray.h | 2 +- lib/librte_eal/linux/eal/eal_memalloc.c | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) -- 2.17.1