From patchwork Mon Apr 24 23:44:53 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Stabellini X-Patchwork-Id: 9697351 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id AD297603F3 for ; Mon, 24 Apr 2017 23:45:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 93524283FB for ; Mon, 24 Apr 2017 23:45:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 84B8728427; Mon, 24 Apr 2017 23:45:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id EA2F7283FB for ; Mon, 24 Apr 2017 23:45:36 +0000 (UTC) Received: from localhost ([::1]:46358 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d2nfj-0003Ng-9Q for patchwork-qemu-devel@patchwork.kernel.org; Mon, 24 Apr 2017 19:45:35 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56688) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d2nfB-0003NK-Ns for qemu-devel@nongnu.org; Mon, 24 Apr 2017 19:45:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d2nf7-0003tr-RC for qemu-devel@nongnu.org; Mon, 24 Apr 2017 19:45:01 -0400 Received: from mail.kernel.org ([198.145.29.136]:52822) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1d2nf7-0003tJ-MZ for qemu-devel@nongnu.org; Mon, 24 Apr 2017 19:44:57 -0400 Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7595520172; Mon, 24 Apr 2017 23:44:55 +0000 (UTC) Received: from [10.149.184.130] (unknown [99.165.194.18]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 36A6920145; Mon, 24 Apr 2017 23:44:54 +0000 (UTC) Date: Mon, 24 Apr 2017 16:44:53 -0700 (PDT) From: Stefano Stabellini X-X-Sender: sstabellini@sstabellini-ThinkPad-X260 To: Peter Maydell In-Reply-To: Message-ID: References: User-Agent: Alpine 2.10 (DEB 1266 2009-07-14) MIME-Version: 1.0 X-Virus-Scanned: ClamAV using ClamSMTP X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 198.145.29.136 Subject: Re: [Qemu-devel] [PULL 0/21] Please pull xen-20170421-tag for 2.10 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stefano Stabellini , Stefan Hajnoczi , QEMU Developers , Greg Kurz , "Aneesh Kumar K.V" , Stefan Hajnoczi , Anthony PERARD , xen-devel@lists.xenproject.org Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP On Mon, 24 Apr 2017, Peter Maydell wrote: > On 24 April 2017 at 22:25, Stefano Stabellini wrote: > > diff --git a/hw/9pfs/xen-9pfs.h b/hw/9pfs/xen-9pfs.h > > new file mode 100644 > > index 0000000..18f0ec0 > > --- /dev/null > > +++ b/hw/9pfs/xen-9pfs.h > > @@ -0,0 +1,14 @@ > > +/* > > + * Xen 9p backend > > + * > > + * Copyright Aporeto 2017 > > + * > > + * Authors: > > + * Stefano Stabellini > > + * > > + */ > > Trivial file, but I prefer it if we have a brief license > statement in every file, just to be clear (it might > accumulate more code later). Sure > > + > > +#include > > +#include "hw/xen/io/ring.h" > > + > > +DEFINE_XEN_FLEX_RING_AND_INTF(xen_9pfs); > > Is it worth a comment to dissuade people from thinking they can > inline the file back into xen-9p-backend.c ? Thanks for the quick review! Here you go: diff --git a/hw/9pfs/xen-9p-backend.c b/hw/9pfs/xen-9p-backend.c index 7e962aa..9c7f41a 100644 --- a/hw/9pfs/xen-9p-backend.c +++ b/hw/9pfs/xen-9p-backend.c @@ -13,12 +13,9 @@ #include "hw/hw.h" #include "hw/9pfs/9p.h" #include "hw/xen/xen_backend.h" -#include "hw/xen/io/ring.h" +#include "hw/9pfs/xen-9pfs.h" #include "qemu/config-file.h" #include "fsdev/qemu-fsdev.h" -#include - -DEFINE_XEN_FLEX_RING_AND_INTF(xen_9pfs); #define VERSIONS "1" #define MAX_RINGS 8 diff --git a/hw/9pfs/xen-9pfs.h b/hw/9pfs/xen-9pfs.h new file mode 100644 index 0000000..6e33d77 --- /dev/null +++ b/hw/9pfs/xen-9pfs.h @@ -0,0 +1,21 @@ +/* + * Xen 9p backend + * + * Copyright Aporeto 2017 + * + * Authors: + * Stefano Stabellini + * + * This work is licensed under the terms of the GNU GPL version 2. + * See the COPYING file in the top-level directory. + * + */ + +#include +#include "hw/xen/io/ring.h" + +/* + * Do not merge into xen-9p-backend.c: clang doesn't allow unused static + * inline functions in c files. + */ +DEFINE_XEN_FLEX_RING_AND_INTF(xen_9pfs);