From: "Michael S. Tsirkin" <mst@redhat.com>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Philippe Ombredanne <pombredanne@nexb.com>,
Thomas Gleixner <tglx@linutronix.de>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] virtio_balloon: fix build regression
Date: Wed, 8 Nov 2017 17:24:30 +0200 [thread overview]
Message-ID: <20171108172156-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <20171108120740.3137853-1-arnd@arndb.de>
On Wed, Nov 08, 2017 at 01:07:10PM +0100, Arnd Bergmann wrote:
> The new balloon_page_push/balloon_page_pop helpers got added
> inside of an #ifdef, causing a build failure when CONFIG_BALLOON_COMPACTION
> is disabled:
>
> drivers/virtio/virtio_balloon.c: In function 'fill_balloon':
> drivers/virtio/virtio_balloon.c:164:3: error: implicit declaration of function 'balloon_page_push'
>
> This adds another empty stub function for the case that
> CONFIG_BALLOON_COMPACTION is disabled.
>
> Fixes: f09517b35de8 ("virtio_balloon: fix deadlock on OOM")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> I couldn't easily figure out whether the new functions were indeed
> intended to be only used when BALLOON_COMPACTION is enabled, or
> whether they should always be there. In case I picked the wrong
> one of the two, the answer would obviously be to move the
> definitions outside of the #ifdef, or into a different file.
Hmm no, I think we actually need these to work.
I'll fix it up, thanks for the report.
> ---
> include/linux/balloon_compaction.h | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/include/linux/balloon_compaction.h b/include/linux/balloon_compaction.h
> index 36734ff07213..730b962fd572 100644
> --- a/include/linux/balloon_compaction.h
> +++ b/include/linux/balloon_compaction.h
> @@ -223,6 +223,15 @@ static inline int balloon_page_migrate(struct page *newpage,
> return 0;
> }
>
> +static inline void balloon_page_push(struct list_head *pages, struct page *page)
> +{
> +}
> +
> +static inline struct page *balloon_page_pop(struct list_head *pages)
> +{
> + return NULL;
> +}
> +
> static inline gfp_t balloon_mapping_gfp_mask(void)
> {
> return GFP_HIGHUSER;
> --
> 2.9.0
prev parent reply other threads:[~2017-11-08 15:24 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-11-08 12:07 [PATCH] virtio_balloon: fix build regression Arnd Bergmann
2017-11-08 15:24 ` Michael S. Tsirkin [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:
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=20171108172156-mutt-send-email-mst@kernel.org \
--to=mst@redhat.com \
--cc=arnd@arndb.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pombredanne@nexb.com \
--cc=tglx@linutronix.de \
/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.