mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jan Beulich <jbeulich@suse.com>
To: Jiqian Chen <Jiqian.Chen@amd.com>
Cc: xen-devel@lists.xenproject.org, linux-kernel@vger.kernel.org,
	Juergen Gross <jgross@suse.com>,
	Stefano Stabellini <sstabellini@kernel.org>,
	Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>,
	Marek Marczykowski <marmarek@invisiblethingslab.com>
Subject: Re: [PATCH] xen: Remove config dependency in XEN_PRIVCMD definition
Date: Wed, 9 Oct 2024 09:05:40 +0200	[thread overview]
Message-ID: <73174eb0-380d-4f95-a2c3-097b86fac8db@suse.com> (raw)
In-Reply-To: <20241009062014.407310-1-Jiqian.Chen@amd.com>

On 09.10.2024 08:20, Jiqian Chen wrote:
> Commit 2fae6bb7be32 ("xen/privcmd: Add new syscall to get gsi from dev")
> adds a weak reverse dependency to the config XEN_PRIVCMD definition, its
> purpose is to pass the combination of compilation that CONFIG_XEN_PRIVCMD=y
> and CONFIG_XEN_PCIDEV_BACKEND=m, because in that combination, xen-pciback
> is compiled as a module but xen-privcmd is built-in, so xen-privcmd can't
> find the implementation of pcistub_get_gsi_from_sbdf.
> 
> But that dependency causes xen-privcmd can't be loaded on domU, because
> dependent xen-pciback is always not be loaded successfully on domU.
> 
> To solve above problem and cover original commit's requirement, just remove
> that dependency, because the code "IS_REACHABLE(CONFIG_XEN_PCIDEV_BACKEND)"
> of original commit is enough to meet the requirement.
> 
> Fixes: 2fae6bb7be32 ("xen/privcmd: Add new syscall to get gsi from dev")
> Signed-off-by: Jiqian Chen <Jiqian.Chen@amd.com>

This lacks a Reported-by:.

> --- a/drivers/xen/Kconfig
> +++ b/drivers/xen/Kconfig
> @@ -261,7 +261,6 @@ config XEN_SCSI_BACKEND
>  config XEN_PRIVCMD
>  	tristate "Xen hypercall passthrough driver"
>  	depends on XEN
> -	imply XEN_PCIDEV_BACKEND
>  	default m
>  	help
>  	  The hypercall passthrough driver allows privileged user programs to

The report wasn't about a build problem, but a runtime one. Removing the
dependency here doesn't change anything in the dependency of xen-privcmd
on xen-pciback, as the use of pcistub_get_gsi_from_sbdf() continues to
exist. Consider the case of XEN_PCIDEV_BACKEND=m and XEN_PRIVCMD=m, which
I guess is what Marek is using in his config. Both drivers are available
in such a configuration, yet loading of xen-privcmd then requires to
load xen-pciback first. And that latter load attempt will fail in a DomU.
The two drivers simply may not have any dependency in either direction.

Jan

  reply	other threads:[~2024-10-09  7:05 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-09  6:20 Jiqian Chen
2024-10-09  7:05 ` Jan Beulich [this message]
2024-10-09 22:46   ` Stefano Stabellini
2024-10-10  5:39     ` Jürgen Groß
2024-10-10  7:01       ` Jan Beulich
2024-10-10  7:21         ` Jürgen Groß
2024-10-10  7:07       ` Chen, Jiqian
2024-10-10  7:18         ` Jürgen Groß

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=73174eb0-380d-4f95-a2c3-097b86fac8db@suse.com \
    --to=jbeulich@suse.com \
    --cc=Jiqian.Chen@amd.com \
    --cc=jgross@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marmarek@invisiblethingslab.com \
    --cc=oleksandr_tyshchenko@epam.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.org \
    /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

all inboxes | Powered by JetHome®