qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: qemu-devel@nongnu.org
Cc: "Daniel P. Berrangé" <berrange@redhat.com>,
	"Marc-André Lureau" <marcandre.lureau@redhat.com>,
	"Philippe Mathieu-Daudé" <philmd@linaro.org>,
	qemu-block@nongnu.org, "Fam Zheng" <fam@euphon.net>,
	"Murilo Opsfelder Araujo" <muriloo@linux.ibm.com>,
	"Paolo Bonzini" <pbonzini@redhat.com>,
	"Thomas Huth" <thuth@redhat.com>
Subject: [PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config() impl
Date: Mon,  5 Jun 2023 19:41:46 +0200	[thread overview]
Message-ID: <20230605174146.87440-3-philmd@linaro.org> (raw)
In-Reply-To: <20230605174146.87440-1-philmd@linaro.org>

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



  parent reply	other threads:[~2023-06-05 17:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-05 17:41 [PATCH 0/2] scsi/qemu-pr-helper: Drop 'old' lib and use default config helpers Philippe Mathieu-Daudé
2023-06-05 17:41 ` [PATCH 1/2] scsi/qemu-pr-helper: Drop support for 'old' libmultipath API Philippe Mathieu-Daudé
2023-06-05 17:41 ` Philippe Mathieu-Daudé [this message]
2023-06-05 17:52   ` [PATCH 2/2] scsi/qemu-pr-helper: Use defaults [get/set]_multipath_config() impl Paolo Bonzini
2023-06-05 17:43 ` [PATCH 0/2] scsi/qemu-pr-helper: Drop 'old' lib and use default config helpers Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230605174146.87440-3-philmd@linaro.org \
    --to=philmd@linaro.org \
    --cc=berrange@redhat.com \
    --cc=fam@euphon.net \
    --cc=marcandre.lureau@redhat.com \
    --cc=muriloo@linux.ibm.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).