qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config


From: Philippe Mathieu-Daudé
Subject: [PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config() impl
Date: Mon, 5 Jun 2023 19:41:46 +0200

Commit b3f1c8c413 ("qemu-pr-helper: use new libmultipath API")
declared the two [get/set]_multipath_config() functions to
satisfy the 'new' API. The library already provides an internal
implementation for these helpers, exposed as weak symbols.
Since our implementation doesn't provide much, we can default
to the internal implementation.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
 scsi/qemu-pr-helper.c | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/scsi/qemu-pr-helper.c b/scsi/qemu-pr-helper.c
index ae44a816e1..4d64e6b53c 100644
--- a/scsi/qemu-pr-helper.c
+++ b/scsi/qemu-pr-helper.c
@@ -261,26 +261,14 @@ static void dm_init(void)
 
 /* Variables required by libmultipath and libmpathpersist.  */
 QEMU_BUILD_BUG_ON(PR_HELPER_DATA_SIZE > MPATH_MAX_PARAM_LEN);
-static struct config *multipath_conf;
 unsigned mpath_mx_alloc_len = PR_HELPER_DATA_SIZE;
 int logsink;
 struct udev *udev;
 
-extern struct config *get_multipath_config(void);
-struct config *get_multipath_config(void)
-{
-    return multipath_conf;
-}
-
-extern void put_multipath_config(struct config *conf);
-void put_multipath_config(struct config *conf)
-{
-}
-
 static void multipath_pr_init(void)
 {
     udev = udev_new();
-    multipath_conf = mpath_lib_init();
+    mpath_lib_init();
 }
 
 static int is_mpath(int fd)
-- 
2.38.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]