Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750997AbdLYGvx convert rfc822-to-8bit (ORCPT ); Mon, 25 Dec 2017 01:51:53 -0500 Received: from mga01.intel.com ([192.55.52.88]:25024 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750744AbdLYGvu (ORCPT ); Mon, 25 Dec 2017 01:51:50 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,453,1508828400"; d="scan'208";a="4667088" From: "Liu, Yi L" To: Xiongwei Song , "kwankhede@nvidia.com" , "alex.williamson@redhat.com" CC: "kvm@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: RE: [PATCH] vfio: mdev: make a couple of functions and structure vfio_mdev_driver static Thread-Topic: [PATCH] vfio: mdev: make a couple of functions and structure vfio_mdev_driver static Thread-Index: AQHTerFbgcvJrrRfXkG2m7Nx3xpI5aNTo+Rg Date: Mon, 25 Dec 2017 06:51:46 +0000 Message-ID: References: <20171221231226.15505-1-sxwjean@gmail.com> In-Reply-To: <20171221231226.15505-1-sxwjean@gmail.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-ctpclassification: CTP_IC x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiN2MwYzU3ZWUtYjNkYi00YWFmLTllNDYtMzIxYTQ0OWQxOGQzIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjIuNS4xOCIsIlRydXN0ZWRMYWJlbEhhc2giOiJuOUIwNnVCYzRieGsweUl2NHZZVjN5aUUrTjBkdEIxZ3k4OXJOK3k1bFo4SFYwelVLaGtcL2w3MjYrNVk3MEkxQiJ9 x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1730 Lines: 51 > Sent: Friday, December 22, 2017 7:12 AM > To: kwankhede@nvidia.com; alex.williamson@redhat.com > Cc: kvm@vger.kernel.org; linux-kernel@vger.kernel.org > Subject: [PATCH] vfio: mdev: make a couple of functions and structure > vfio_mdev_driver static > > The functions vfio_mdev_probe, vfio_mdev_remove and the structure > vfio_mdev_driver are only used in this file, so make them static. > > Clean up sparse warnings: > drivers/vfio/mdev/vfio_mdev.c:114:5: warning: no previous prototype for > 'vfio_mdev_probe' [-Wmissing-prototypes] > drivers/vfio/mdev/vfio_mdev.c:121:6: warning: no previous prototype for > 'vfio_mdev_remove' [-Wmissing-prototypes] > > Signed-off-by: Xiongwei Song > --- > drivers/vfio/mdev/vfio_mdev.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/vfio/mdev/vfio_mdev.c b/drivers/vfio/mdev/vfio_mdev.c index > fa848a701b8b..d230620fe02d 100644 > --- a/drivers/vfio/mdev/vfio_mdev.c > +++ b/drivers/vfio/mdev/vfio_mdev.c > @@ -111,19 +111,19 @@ static const struct vfio_device_ops vfio_mdev_dev_ops = > { > .mmap = vfio_mdev_mmap, > }; > > -int vfio_mdev_probe(struct device *dev) > +static int vfio_mdev_probe(struct device *dev) > { > struct mdev_device *mdev = to_mdev_device(dev); > > return vfio_add_group_dev(dev, &vfio_mdev_dev_ops, mdev); } > > -void vfio_mdev_remove(struct device *dev) > +static void vfio_mdev_remove(struct device *dev) > { > vfio_del_group_dev(dev); > } > > -struct mdev_driver vfio_mdev_driver = { > +static struct mdev_driver vfio_mdev_driver = { > .name = "vfio_mdev", > .probe = vfio_mdev_probe, > .remove = vfio_mdev_remove, > -- > 2.15.1 Reviewed-by: Liu, Yi L