All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Tokarev <mjt@tls.msk.ru>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: KVM list <kvm@vger.kernel.org>
Subject: Re: Q: status of kvm/ subdir in qemu-kvm tarball?
Date: Wed, 23 Feb 2011 16:15:48 +0300	[thread overview]
Message-ID: <4D650884.3090801@msgid.tls.msk.ru> (raw)
In-Reply-To: <4D650479.30609@siemens.com>

23.02.2011 15:58, Jan Kiszka wrote:
> On 2011-02-23 12:42, Michael Tokarev wrote:
[]
>>> - kvm/include (latest kernel headers) *)
>>
>> This directory is always used (in configure)
>> unless -kerneldir is specified - who uses that
>> nowadays?  I dunno.
> 
> It may not be relevant to distros, provided they manage to keep their
> /usr/include/linux stuff in sync with the kernel they ship. But if you
> build qemu-kvm for a kernel (or kvm-kmod) that is more recent than your
> user space headers, this matters.

It only matters if you want to build qemu-kvm for OLDER
kernel without support of some features which are used by
the userspace you're building.  Provided 3 things:

 1) qemu-kvm userspace actually checks a feature before
    using it, and omits some code if the feature isn't
    available.  This means tons of #ifdefs, for a very
    little gain,

 2) kernel interface stays backward-compatible, and

 3) the headers included in qemu-kvm tarball actually
    matches the feature set in the userspace part.

Using more RECENT kernel headers to build userspace which
don't know about the more recent features anyway should
result in exactly the same binary, there's no reason to
use more recent headers.

>>> *) This should really be discussed upstream again: Carry private copy of
>>> kvm headers or rely on distro / kvm-kmod to provide required defines,
>>> types etc.? I'm more and more in favor of option 1.
>>
>> Yes indeed, having current defines of all the features
>> we actually support is a good idea.

That's the key: current features we actually support.
If kernel headers (be them embedded into the userspace
tarball or already installed on the system or headers
from just built kernel.org git tree) define less than
that, we either have tons of #ifdefs or just fail at
build/configure time telling "use more recent headers".
If kernel headers define more than we can understand,
we just ignore the rest...

> Would you like to propose this upstream in form of a patch series (that
> demonstrates its usefulness by dropping tones of #ifdefs)?

..unless I completely missed the point.  Which upstream
you're talking about -- qemu or kernel?  Where the #ifdefs
are, what they're for currently are they really needed?

Does qemu[-kvm] want to stay compatible with older kernels,
or kernel headers?  If yes, how old is old?

/mjt

  reply	other threads:[~2011-02-23 13:15 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-23 11:04 Q: status of kvm/ subdir in qemu-kvm tarball? Michael Tokarev
2011-02-23 11:31 ` Jan Kiszka
2011-02-23 11:42   ` Michael Tokarev
2011-02-23 12:58     ` Jan Kiszka
2011-02-23 13:15       ` Michael Tokarev [this message]
2011-02-23 13:45         ` Jan Kiszka
2011-02-23 14:30           ` Michael Tokarev
2011-02-23 14:57             ` Jan Kiszka
2011-02-27 16:28               ` Avi Kivity
2011-02-27 18:36                 ` Jan Kiszka

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=4D650884.3090801@msgid.tls.msk.ru \
    --to=mjt@tls.msk.ru \
    --cc=jan.kiszka@siemens.com \
    --cc=kvm@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.