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 B30B3A04F0 for ; Tue, 10 Dec 2019 16:01:20 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id A48171B13C; Tue, 10 Dec 2019 16:01:20 +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 BE7AC1B13C for ; Tue, 10 Dec 2019 16:01:19 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1575990079; 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=uxKqw2gQh+P9EcCcpekQZu3G8uNKpr+GQVunPr5ayFw=; b=T4csRxJHOjL2o7C2aYb8y6jMiRQFbHIZxAc9EcEwIjTIdUxSTv/gwCloF1eY5X58R4C3oU SqXiz4Fy7sVJEaxwJRwnsGXMLSLrJAydnKOMEROAUDM5QABsRkD9kWAtayPwRFcAtU8beM mDa4xHZRtpQHy8h3n8yP5EFowomCFfg= 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-385-q9oG6M7cPHqFB_mGFs0SWg-1; Tue, 10 Dec 2019 10:01:15 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B0616801E76; Tue, 10 Dec 2019 15:01:14 +0000 (UTC) Received: from rh.redhat.com (ovpn-116-64.ams2.redhat.com [10.36.116.64]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9828C5DA76; Tue, 10 Dec 2019 15:01:13 +0000 (UTC) From: Kevin Traynor To: David Hunt Cc: Bruce Richardson , dpdk stable Date: Tue, 10 Dec 2019 14:59:18 +0000 Message-Id: <20191210145937.32755-44-ktraynor@redhat.com> In-Reply-To: <20191210145937.32755-1-ktraynor@redhat.com> References: <20191210145937.32755-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-MC-Unique: q9oG6M7cPHqFB_mGFs0SWg-1 X-Mimecast-Spam-Score: 0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable Subject: [dpdk-stable] patch 'examples/vm_power: fix build without i40e' has been queued to LTS release 18.11.6 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.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/16/19. 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/dc90a9467232103f42= a1fedc9bc788675ae32e27 Thanks. Kevin. --- >From dc90a9467232103f42a1fedc9bc788675ae32e27 Mon Sep 17 00:00:00 2001 From: David Hunt Date: Thu, 24 Oct 2019 15:26:10 +0100 Subject: [PATCH] examples/vm_power: fix build without i40e [ upstream commit e4d028a0fb53809a341f62a39e59f9e13e7c7f59 ] channel_monitor.c was dependent on i40e driver being available. This is only necessary for the TRAFFIC policy, so use #ifdef's to not call these when i40e not available. Fixes: f14791a8126e ("examples/vm_power_mgr: add policy to channels") Signed-off-by: David Hunt Tested-by: Bruce Richardson Acked-by: Bruce Richardson --- examples/vm_power_manager/channel_monitor.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/examples/vm_power_manager/channel_monitor.c b/examples/vm_powe= r_manager/channel_monitor.c index b5b7c6787..1d6d7ec6d 100644 --- a/examples/vm_power_manager/channel_monitor.c +++ b/examples/vm_power_manager/channel_monitor.c @@ -28,5 +28,7 @@ #include #include +#ifdef RTE_LIBRTE_I40E_PMD #include +#endif =20 #include @@ -408,6 +410,10 @@ get_pfid(struct policy *pol) =20 =09=09RTE_ETH_FOREACH_DEV(x) { +#ifdef RTE_LIBRTE_I40E_PMD =09=09=09ret =3D rte_pmd_i40e_query_vfid_by_mac(x, =09=09=09=09(struct ether_addr *)&(pol->pkt.vfid[i])); +#else +=09=09=09ret =3D -ENOTSUP; +#endif =09=09=09if (ret !=3D -EINVAL) { =09=09=09=09pol->port[i] =3D x; @@ -495,8 +501,11 @@ get_pkt_diff(struct policy *pol) =09double rdtsc_curr, rdtsc_diff, diff; =09int x; +#ifdef RTE_LIBRTE_I40E_PMD =09struct rte_eth_stats vf_stats; +#endif =20 =09for (x =3D 0; x < pol->pkt.nb_mac_to_monitor; x++) { =20 +#ifdef RTE_LIBRTE_I40E_PMD =09=09/*Read vsi stats*/ =09=09if (rte_pmd_i40e_get_vf_stats(x, pol->pfid[x], &vf_stats) =3D=3D 0) @@ -504,4 +513,7 @@ get_pkt_diff(struct policy *pol) =09=09else =09=09=09vsi_pkt_count =3D -1; +#else +=09=09vsi_pkt_count =3D -1; +#endif =20 =09=09vsi_pkt_total +=3D vsi_pkt_count; --=20 2.21.0 --- Diff of the applied patch vs upstream commit (please double-check if non-= empty: --- --- -=092019-12-10 14:49:42.026352624 +0000 +++ 0044-examples-vm_power-fix-build-without-i40e.patch=092019-12-10 14:49:= 39.076457320 +0000 @@ -1 +1 @@ -From e4d028a0fb53809a341f62a39e59f9e13e7c7f59 Mon Sep 17 00:00:00 2001 +From dc90a9467232103f42a1fedc9bc788675ae32e27 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit e4d028a0fb53809a341f62a39e59f9e13e7c7f59 ] + @@ -11 +12,0 @@ -Cc: stable@dpdk.org @@ -21 +22 @@ -index 0c73fac55..29e1cb64d 100644 +index b5b7c6787..1d6d7ec6d 100644 @@ -24 +25 @@ -@@ -29,5 +29,7 @@ +@@ -28,5 +28,7 @@ @@ -32 +33 @@ -@@ -437,6 +439,10 @@ get_pfid(struct policy *pol) +@@ -408,6 +410,10 @@ get_pfid(struct policy *pol) @@ -37 +38 @@ - =09=09=09=09(struct rte_ether_addr *)&(pol->pkt.vfid[i])); + =09=09=09=09(struct ether_addr *)&(pol->pkt.vfid[i])); @@ -43 +44 @@ -@@ -532,8 +538,11 @@ get_pkt_diff(struct policy *pol) +@@ -495,8 +501,11 @@ get_pkt_diff(struct policy *pol) @@ -55 +56 @@ -@@ -541,4 +550,7 @@ get_pkt_diff(struct policy *pol) +@@ -504,4 +513,7 @@ get_pkt_diff(struct policy *pol)