archive mirror
 help / color / mirror / Atom feed
From: Rusty Russell <>
To: Kent Overstreet <>
Cc: "Michael S. Tsirkin" <>,,
Subject: Re: [PATCH] virtio-blk: Fix kconfig option
Date: Fri, 07 Sep 2012 12:27:18 +0930	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Kent Overstreet <> writes:
> On Fri, Sep 07, 2012 at 09:10:25AM +0930, Rusty Russell wrote:
>> Kent Overstreet <> writes:
>> > On Thu, Sep 06, 2012 at 12:49:56PM +0300, Michael S. Tsirkin wrote:
>> >> On Thu, Sep 06, 2012 at 02:25:12AM -0700, Kent Overstreet wrote:
>> >> > Do you not understand the difference between depends an selects?
>> >> > Or did you not read my original mail?
>> Now you're getting insulting.
> Yes, but at least I'm not being intentionally obtuse.

Insulting again.  Wow.

It took me this long to understand your complaint.  Perhaps I'm stupid.
Or perhaps you are terrible at explaining yourself, and it is only
through our patient and heroic efforts that we can comprehend you at

> Think about it from the user's pov. They check what VIRTIO_BLK depends
> on - just VIRTIO.
> So they try to figure out how to flip on VIRTIO, or what VIRTIO even is.
> See how that last step might be problematic? CONFIG_VIRTIO is not
> exposed! It doesn't even seem to control anything!
> Go back to your example. Checking the dependencies for E1000 would tell
> you the user needs to flip on CONFIG_PCI. Done. Easy.

Actually, it depends on NET_VENDOR_INTEL which depends on CONFIG_PCI,
but yes, it's discoverable.

So your actual complaint is that:
1) CONFIG_VIRTIO is misleadingly documented both in comment and name.
2) It's not discoverable, since it's only selected via other things.

> And, if that is what you're doing with CONFIG_VIRTIO (I'm still not
> sure) the comment at the top of drivers/virtio/Kconfig is _wrong_:

As grep would show you, it's selected by LGUEST, S390_GUEST, RPMSG,
VIRTIO_PCI and VIRTIO_MMIO (VIRTIO_BALLOON is a cut & paste bug, already
patched by MST).

We could change every virtio device to depend on (CONFIG_LGUEST |
CONFIG_VIRTIO_MMIO), which is more discoverable but uglier.  How's this

From: Rusty Russell <>
Subject: virtio: add help to CONFIG_VIRTIO option.

Trying to enable a virtio driver (eg CONFIG_VIRTIO_BLK) is painful
because it depends on CONFIG_VIRTIO.  CONFIG_VIRTIO doesn't tell you
how to turn it on (it's selected from anything which provides a virtio

This patch at least adds some documentation, visible in menuconfig, as
a hint.

Reported-by: Kent Overstreet <>
Signed-off-by: Rusty Russell <>

diff --git a/drivers/virtio/Kconfig b/drivers/virtio/Kconfig
--- a/drivers/virtio/Kconfig
+++ b/drivers/virtio/Kconfig
@@ -1,8 +1,10 @@
-# Virtio always gets selected by whoever wants it.
 config VIRTIO
+	---help---
+	  This option is selected by any driver which implements the virtio
-# Similarly the virtio ring implementation.
 	depends on VIRTIO

      reply	other threads:[~2012-09-07  3:30 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-03  4:41 [PATCH] virtio-blk: Fix kconfig option Kent Overstreet
2012-09-03  4:46 ` Kent Overstreet
2012-09-04  6:23 ` Rusty Russell
2012-09-04 23:12   ` Kent Overstreet
2012-09-05  4:22   ` Asias He
2012-09-05  5:48     ` Michael S. Tsirkin
2012-09-05  5:54       ` Asias He
2012-09-05  6:04         ` Michael S. Tsirkin
2012-09-05  6:12   ` Michael S. Tsirkin
2012-09-06  1:46     ` Rusty Russell
2012-09-06  7:41   ` Kent Overstreet
2012-09-06  8:44     ` Michael S. Tsirkin
2012-09-06  9:25       ` Kent Overstreet
2012-09-06  9:49         ` Michael S. Tsirkin
2012-09-06 10:02           ` Kent Overstreet
2012-09-06 10:18             ` Michael S. Tsirkin
2012-09-06 10:31               ` Kent Overstreet
2012-09-06 11:09                 ` Michael S. Tsirkin
2012-09-06 23:40             ` Rusty Russell
2012-09-07  0:25               ` Kent Overstreet
2012-09-07  2:57                 ` Rusty Russell [this message]

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:

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

  git send-email \ \ \ \ \ \ \

* 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).