From patchwork Wed Jun 18 20:45:45 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nikolay Nikolaev X-Patchwork-Id: 361751 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id E1C2A1400B6 for ; Thu, 19 Jun 2014 06:46:22 +1000 (EST) Received: from localhost ([::1]:60605 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WxMkO-0000ZW-VQ for incoming@patchwork.ozlabs.org; Wed, 18 Jun 2014 16:46:20 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57616) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WxMk3-0000G9-Vx for qemu-devel@nongnu.org; Wed, 18 Jun 2014 16:46:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WxMjx-0002dY-Ux for qemu-devel@nongnu.org; Wed, 18 Jun 2014 16:45:59 -0400 Received: from mail-wi0-f175.google.com ([209.85.212.175]:64917) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WxMjx-0002dR-Od for qemu-devel@nongnu.org; Wed, 18 Jun 2014 16:45:53 -0400 Received: by mail-wi0-f175.google.com with SMTP id r20so8317119wiv.14 for ; Wed, 18 Jun 2014 13:45:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:from:to:cc:date:message-id:user-agent :mime-version:content-type:content-transfer-encoding; bh=MwhGcKyBHmvz22EQeQSCQRoliUFqhO2CQ1ws+tYhNfU=; b=FjDbE83+yvIyTydWbUUK20I1RIpgya3o0gJFjEMXUWrYkbwKxY4PCX623OSfl7HXh8 Cz1aUNHHo0Tt++g1gSWhThZOO4V6j4Ma/c25WBQCbytawCQ5WR0v80Z9tYNavtTjLHgB vUQfE2KQjIJey+rmDanhvViLGnt8Ymr9W07ZuTQavrcGwN3Gu6X7wD4G1Y98gv4Yrw85 X7kIMDIeUPngemj/FzTmCGwjtEMnbss8ln9olNchWnDJ73m/pJ4YDWW33asokGtRB0qM jvg2aDgwX77LuyBP7TYg2Raojcof3aKODvSyqaTu9SZJ8NrpvfRCugdJI1R9TD9zOn7f d9Fg== X-Gm-Message-State: ALoCoQlttcCi87fn0VIj+wcRxs6mbuDzhZyA3coLZP4OOCFTVk9oJH/cygxcoZXjREcKox5c+qiv X-Received: by 10.194.92.244 with SMTP id cp20mr335359wjb.109.1403124352901; Wed, 18 Jun 2014 13:45:52 -0700 (PDT) Received: from [0.0.14.236] ([82.146.27.14]) by mx.google.com with ESMTPSA id ej4sm27432890wib.4.2014.06.18.13.45.51 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 18 Jun 2014 13:45:52 -0700 (PDT) From: Nikolay Nikolaev To: snabb-devel@googlegroups.com, qemu-devel@nongnu.org, mst@redhat.com Date: Wed, 18 Jun 2014 23:45:45 +0300 Message-ID: <20140618204530.16806.54996.stgit@3820> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.85.212.175 Cc: a.motakis@virtualopensystems.com, luke@snabb.co, tech@virtualopensystems.com, n.nikolaev@virtualopensystems.com Subject: [Qemu-devel] [PATCH] net: fix vhost-user mingw compilation X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Make net.o linkage expect net_init_vhost_user only when CONFIG_VHOST_NET is defined. Signed-off-by: Nikolay Nikolaev --- net/net.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/net/net.c b/net/net.c index de76e30..0c30414 100644 --- a/net/net.c +++ b/net/net.c @@ -803,7 +803,9 @@ static int (* const net_client_init_fun[NET_CLIENT_OPTIONS_KIND_MAX])( [NET_CLIENT_OPTIONS_KIND_BRIDGE] = net_init_bridge, #endif [NET_CLIENT_OPTIONS_KIND_HUBPORT] = net_init_hubport, +#ifdef CONFIG_VHOST_NET [NET_CLIENT_OPTIONS_KIND_VHOST_USER] = net_init_vhost_user, +#endif }; @@ -837,7 +839,9 @@ static int net_client_init1(const void *object, int is_netdev, Error **errp) case NET_CLIENT_OPTIONS_KIND_BRIDGE: #endif case NET_CLIENT_OPTIONS_KIND_HUBPORT: +#ifdef CONFIG_VHOST_NET case NET_CLIENT_OPTIONS_KIND_VHOST_USER: +#endif break; default: