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 7F306A0561 for ; Thu, 27 Feb 2020 18:39:06 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 78ECF2C02; Thu, 27 Feb 2020 18:39:06 +0100 (CET) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by dpdk.org (Postfix) with ESMTP id A12172C02 for ; Thu, 27 Feb 2020 18:39:05 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1582825145; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=HqPYUEX/8Mzbl2M5AfNTlFqEQuT7HUa7UysZ6HY/IDY=; b=hbRBb459TJCTejfcKrDVmoXqmL3qNCavuFtBPNApLRYJpa6sbl2HwJuBQM911i8GysQWYI AxwmhajmUqxstBor+Uk00+hWn+mHHJJzgq8kMNFNoJDbLLKmQlN9grFlWUeQIEf83VZVm3 F5uefI+XO8ZZOs9GrUtBzvM8jwyuRj0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-157-EBJEnb6UN3aYCCVrh0w87A-1; Thu, 27 Feb 2020 12:39:01 -0500 X-MC-Unique: EBJEnb6UN3aYCCVrh0w87A-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C72C1107ACCA; Thu, 27 Feb 2020 17:38:59 +0000 (UTC) Received: from rh.redhat.com (unknown [10.33.36.123]) by smtp.corp.redhat.com (Postfix) with ESMTP id 121108AC42; Thu, 27 Feb 2020 17:38:54 +0000 (UTC) From: Kevin Traynor To: Itsuro Oda Cc: Maxime Coquelin , dpdk stable Date: Thu, 27 Feb 2020 17:37:59 +0000 Message-Id: <20200227173807.28004-8-ktraynor@redhat.com> In-Reply-To: <20200227173807.28004-1-ktraynor@redhat.com> References: <20200227173807.28004-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Subject: [dpdk-stable] patch 'net/vhost: allocate interface name from heap' has been queued to LTS release 18.11.7 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" Hi, FYI, your patch has been queued to LTS release 18.11.7 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 03/02/20. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasi= ng (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/kevintraynor/dpdk-stable-queue This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable-queue/commit/68a347bf099a80eb7e= 4e4ddc756c6e8d89440f02 Thanks. Kevin. --- >From 68a347bf099a80eb7e4e4ddc756c6e8d89440f02 Mon Sep 17 00:00:00 2001 From: Itsuro Oda Date: Thu, 6 Feb 2020 10:39:33 +0900 Subject: [PATCH] net/vhost: allocate interface name from heap [ upstream commit e045e858444349323cb02e0951cd977d4a0edd0d ] This patch allocates iface_name of pmd_internal from heap in order to be able to refer from secondary processes. Fixes: 4852aa8f6e21 ("drivers/net: enable hotplug on secondary process") Signed-off-by: Itsuro Oda Reviewed-by: Maxime Coquelin --- drivers/net/vhost/rte_eth_vhost.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/net/vhost/rte_eth_vhost.c b/drivers/net/vhost/rte_eth_= vhost.c index 47d0102e0e..45e9d5cae4 100644 --- a/drivers/net/vhost/rte_eth_vhost.c +++ b/drivers/net/vhost/rte_eth_vhost.c @@ -1006,5 +1006,5 @@ eth_dev_close(struct rte_eth_dev *dev) =20 =09free(internal->dev_name); -=09free(internal->iface_name); +=09rte_free(internal->iface_name); =09rte_free(internal); =20 @@ -1247,7 +1247,9 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, cha= r *iface_name, =09if (internal->dev_name =3D=3D NULL) =09=09goto error; -=09internal->iface_name =3D strdup(iface_name); +=09internal->iface_name =3D rte_malloc_socket(name, strlen(iface_name) + 1= , +=09=09=09=09=09=09 0, numa_node); =09if (internal->iface_name =3D=3D NULL) =09=09goto error; +=09strcpy(internal->iface_name, iface_name); =20 =09list->eth_dev =3D eth_dev; @@ -1291,5 +1293,5 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, cha= r *iface_name, error: =09if (internal) { -=09=09free(internal->iface_name); +=09=09rte_free(internal->iface_name); =09=09free(internal->dev_name); =09} --=20 2.21.1 --- Diff of the applied patch vs upstream commit (please double-check if non-= empty: --- --- -=092020-02-27 17:26:24.144104345 +0000 +++ 0008-net-vhost-allocate-interface-name-from-heap.patch=092020-02-27 17:= 26:23.643831243 +0000 @@ -1 +1 @@ -From e045e858444349323cb02e0951cd977d4a0edd0d Mon Sep 17 00:00:00 2001 +From 68a347bf099a80eb7e4e4ddc756c6e8d89440f02 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit e045e858444349323cb02e0951cd977d4a0edd0d ] + @@ -10 +11,0 @@ -Cc: stable@dpdk.org @@ -19 +20 @@ -index a63588986f..cea2ead2da 100644 +index 47d0102e0e..45e9d5cae4 100644 @@ -22 +23 @@ -@@ -1010,5 +1010,5 @@ eth_dev_close(struct rte_eth_dev *dev) +@@ -1006,5 +1006,5 @@ eth_dev_close(struct rte_eth_dev *dev) @@ -29 +30 @@ -@@ -1257,7 +1257,9 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, ch= ar *iface_name, +@@ -1247,7 +1247,9 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, ch= ar *iface_name, @@ -40 +41 @@ -@@ -1307,5 +1309,5 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, ch= ar *iface_name, +@@ -1291,5 +1293,5 @@ eth_dev_vhost_create(struct rte_vdev_device *dev, ch= ar *iface_name,