From 8b59f26ae48f139c79ee7474d9b7ea3218d68317 Mon Sep 17 00:00:00 2001
From: Roy Tang <rt7380@att.com>
Date: Tue, 5 May 2020 07:51:54 -0700
Subject: [PATCH] Minor fix to neutron sriov agent init script

Change-Id: I618b2974923b298bdd66c79398868f06c963f393
---
 neutron/templates/bin/_neutron-sriov-agent-init.sh.tpl | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/neutron/templates/bin/_neutron-sriov-agent-init.sh.tpl b/neutron/templates/bin/_neutron-sriov-agent-init.sh.tpl
index 885787dec6..0583ea149d 100644
--- a/neutron/templates/bin/_neutron-sriov-agent-init.sh.tpl
+++ b/neutron/templates/bin/_neutron-sriov-agent-init.sh.tpl
@@ -68,11 +68,6 @@ NIC_FIRST_PORT=$(lshw -c network -businfo | awk "/${NIC_BUS%%.*}/ { print \$2; e
 ethtool --set-priv-flags ${NIC_FIRST_PORT} vf-true-promisc-support ${promisc_mode}
 {{- end }}
 
-
-{{- if ( has "besteffort" .Values.conf.sriov_init ) }}
-exit 0
-{{ end }}
-
 {{- if and ( empty .Values.conf.neutron.DEFAULT.host ) ( .Values.pod.use_fqdn.neutron_agent ) }}
 mkdir -p /tmp/pod-shared
 tee > /tmp/pod-shared/neutron-agent.ini << EOF
@@ -80,3 +75,7 @@ tee > /tmp/pod-shared/neutron-agent.ini << EOF
 host = $(hostname --fqdn)
 EOF
 {{- end }}
+
+{{- if ( has "besteffort" .Values.conf.sriov_init ) }}
+exit 0
+{{ end }}