From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755512AbbJHJih (ORCPT ); Thu, 8 Oct 2015 05:38:37 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44064 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755171AbbJHJif (ORCPT ); Thu, 8 Oct 2015 05:38:35 -0400 Date: Thu, 8 Oct 2015 12:38:28 +0300 From: "Michael S. Tsirkin" To: Gleb Natapov Cc: Avi Kivity , Alex Williamson , Vlad Zolotarov , Greg KH , linux-kernel@vger.kernel.org, hjk@hansjkoch.de, corbet@lwn.net, bruce.richardson@intel.com, avi@cloudius-systems.com, gleb@cloudius-systems.com, stephen@networkplumber.org, alexander.duyck@gmail.com Subject: Re: [PATCH v3 2/3] uio_pci_generic: add MSI/MSI-X support Message-ID: <20151008121727-mutt-send-email-mst@redhat.com> References: <20151006174648-mutt-send-email-mst@redhat.com> <5613E75E.1040002@scylladb.com> <1444157480.4059.67.camel@redhat.com> <5614C11B.6090601@scylladb.com> <1444235464.4059.169.camel@redhat.com> <56154AB4.1050509@scylladb.com> <20151007230553-mutt-send-email-mst@redhat.com> <20151008041913.GB13818@scylladb.com> <20151008074153.GB19331@redhat.com> <20151008075910.GD11716@scylladb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20151008075910.GD11716@scylladb.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 08, 2015 at 10:59:10AM +0300, Gleb Natapov wrote: > I do not remember this been an issue when uio_generic was accepted > into the kernel. The reason was because it meant to be accessible by root > only. No - because it does not need bus mastering. So it can be used safely with some devices. [mst@robin linux]$ git grep pci_set_master|wc -l 533 [mst@robin linux]$ git grep pci_enable|wc -l 1597 Looks like about 2/3 devices don't need to be bus masters. It's up to admin not to bind it to devices, and that is unfortunate, but manually binding an incorrect driver to a device is generally a hard problem to solve. > > There's also drivers/vfio/virqfd.c which deals > > with sending interrupts over eventfds correctly. > > > As opposite to this patch that deals with them incorrectly? In what way? cleanup on fd close is not handled. -- MST