Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757603AbYLEPnl (ORCPT ); Fri, 5 Dec 2008 10:43:41 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754917AbYLEPnc (ORCPT ); Fri, 5 Dec 2008 10:43:32 -0500 Received: from e32.co.us.ibm.com ([32.97.110.150]:54238 "EHLO e32.co.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752431AbYLEPnb (ORCPT ); Fri, 5 Dec 2008 10:43:31 -0500 Message-ID: <49394C1B.2010001@us.ibm.com> Date: Fri, 05 Dec 2008 09:43:23 -0600 From: Anthony Liguori User-Agent: Thunderbird 2.0.0.17 (X11/20080925) MIME-Version: 1.0 To: Mark McLoughlin CC: Jiri Slaby , Michael Tokarev , Rusty Russell , linux-kernel , kvm Subject: Re: [PATCH] virtio: make PCI devices take a virtio_pci module ref References: <1228394671.3732.77.camel@blaa> <49385DB7.4060306@gmail.com> <4938EE0B.8020501@msgid.tls.msk.ru> <493929D2.4070900@gmail.com> <1228488921.3858.25.camel@blaa> In-Reply-To: <1228488921.3858.25.camel@blaa> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1317 Lines: 42 Mark McLoughlin wrote: > On Fri, 2008-12-05 at 14:17 +0100, Jiri Slaby wrote: > > +static void virtio_pci_release_dev(struct device *dev) > +{ > +} > + > /* A PCI device has it's own struct device and so does a virtio device so > * we create a place for the virtio devices to show up in sysfs. I think it > * would make more sense for virtio to not insist on having it's own device. */ > static struct device virtio_pci_root = { > .parent = NULL, > .bus_id = "virtio-pci", > + .release = virtio_pci_release_dev, > }; > Actually, we should be able to delete this virtio_pci_root entirely. The device is a dummy one anyway. Regards, Anthony Liguori > /* Convert a generic virtio device to our structure */ > @@ -328,6 +333,7 @@ static int __devinit virtio_pci_probe(struct pci_dev *pci_dev, > return -ENOMEM; > > vp_dev->vdev.dev.parent = &virtio_pci_root; > + vp_dev->vdev.dev.release = virtio_pci_release_dev; > vp_dev->vdev.config = &virtio_pci_config_ops; > vp_dev->pci_dev = pci_dev; > INIT_LIST_HEAD(&vp_dev->virtqueues); > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/