Blame SOURCES/kvm-iscsi-Drop-deprecated-drive-parameter-filename.patch

1bdc94
From 975a41d8556024bed3fafc5118f084adf4cb391e Mon Sep 17 00:00:00 2001
1bdc94
From: Markus Armbruster <armbru@redhat.com>
1bdc94
Date: Mon, 18 Jun 2018 08:43:14 +0200
1bdc94
Subject: [PATCH 07/54] iscsi: Drop deprecated -drive parameter "filename"
1bdc94
1bdc94
RH-Author: Markus Armbruster <armbru@redhat.com>
1bdc94
Message-id: <20180618084330.30009-8-armbru@redhat.com>
1bdc94
Patchwork-id: 80740
1bdc94
O-Subject: [RHEL-7.6 qemu-kvm-rhev PATCH 07/23] iscsi: Drop deprecated -drive parameter "filename"
1bdc94
Bugzilla: 1557995
1bdc94
RH-Acked-by: Max Reitz <mreitz@redhat.com>
1bdc94
RH-Acked-by: Jeffrey Cody <jcody@redhat.com>
1bdc94
RH-Acked-by: Kevin Wolf <kwolf@redhat.com>
1bdc94
1bdc94
Parameter "filename" is deprecated since commit 5c3ad1a6a8f, v2.10.0.
1bdc94
Time to get rid of it.
1bdc94
1bdc94
Signed-off-by: Markus Armbruster <armbru@redhat.com>
1bdc94
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
1bdc94
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
1bdc94
(cherry picked from commit deadbb8ebb5c253da9b8ed02ab51a0fadf60edc7)
1bdc94
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
1bdc94
---
1bdc94
 block/iscsi.c | 23 ++---------------------
1bdc94
 1 file changed, 2 insertions(+), 21 deletions(-)
1bdc94
1bdc94
diff --git a/block/iscsi.c b/block/iscsi.c
1bdc94
index d19ae0e..658462b 100644
1bdc94
--- a/block/iscsi.c
1bdc94
+++ b/block/iscsi.c
1bdc94
@@ -1732,10 +1732,6 @@ static QemuOptsList runtime_opts = {
1bdc94
             .name = "timeout",
1bdc94
             .type = QEMU_OPT_NUMBER,
1bdc94
         },
1bdc94
-        {
1bdc94
-            .name = "filename",
1bdc94
-            .type = QEMU_OPT_STRING,
1bdc94
-        },
1bdc94
         { /* end of list */ }
1bdc94
     },
1bdc94
 };
1bdc94
@@ -1751,27 +1747,12 @@ static int iscsi_open(BlockDriverState *bs, QDict *options, int flags,
1bdc94
     char *initiator_name = NULL;
1bdc94
     QemuOpts *opts;
1bdc94
     Error *local_err = NULL;
1bdc94
-    const char *transport_name, *portal, *target, *filename;
1bdc94
+    const char *transport_name, *portal, *target;
1bdc94
 #if LIBISCSI_API_VERSION >= (20160603)
1bdc94
     enum iscsi_transport_type transport;
1bdc94
 #endif
1bdc94
     int i, ret = 0, timeout = 0, lun;
1bdc94
 
1bdc94
-    /* If we are given a filename, parse the filename, with precedence given to
1bdc94
-     * filename encoded options */
1bdc94
-    filename = qdict_get_try_str(options, "filename");
1bdc94
-    if (filename) {
1bdc94
-        warn_report("'filename' option specified. "
1bdc94
-                    "This is an unsupported option, and may be deprecated "
1bdc94
-                    "in the future");
1bdc94
-        iscsi_parse_filename(filename, options, &local_err);
1bdc94
-        if (local_err) {
1bdc94
-            ret = -EINVAL;
1bdc94
-            error_propagate(errp, local_err);
1bdc94
-            goto exit;
1bdc94
-        }
1bdc94
-    }
1bdc94
-
1bdc94
     opts = qemu_opts_create(&runtime_opts, NULL, 0, &error_abort);
1bdc94
     qemu_opts_absorb_qdict(opts, options, &local_err);
1bdc94
     if (local_err) {
1bdc94
@@ -1989,7 +1970,7 @@ out:
1bdc94
         }
1bdc94
         memset(iscsilun, 0, sizeof(IscsiLun));
1bdc94
     }
1bdc94
-exit:
1bdc94
+
1bdc94
     return ret;
1bdc94
 }
1bdc94
 
1bdc94
-- 
1bdc94
1.8.3.1
1bdc94