From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752242AbcEKOuG (ORCPT ); Wed, 11 May 2016 10:50:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47192 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751512AbcEKOuF (ORCPT ); Wed, 11 May 2016 10:50:05 -0400 Subject: Re: [PATCH 0/2] irqbypass/kvm: Silence registration errors To: Alex Williamson , kvm@vger.kernel.org References: <20160505174733.9576.61083.stgit@gimli.home> Cc: feng.wu@intel.com, linux-kernel@vger.kernel.org, eric.auger@linaro.org From: Paolo Bonzini Message-ID: <57334697.4060408@redhat.com> Date: Wed, 11 May 2016 16:49:59 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.1 MIME-Version: 1.0 In-Reply-To: <20160505174733.9576.61083.stgit@gimli.home> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Wed, 11 May 2016 14:50:04 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 05/05/2016 19:58, Alex Williamson wrote: > Currently an AMD system using vfio-pci/kvm will issue a dev_info() for > every MSI/X vector registered because kvm_x86_ops does not support a > bypass mechanism except on Intel and the add_producer callback returns > an errno for that. This is meaningless, unintended, and confuses > users. We could simply have KVM's add_producer callback return 0 if > there's no bypass mechanism, but then why are we registering as an IRQ > bypass consumer in the first place? We also don't necessarily want to > simply remove the dev_info/pr_info on registration failure because > then we have no warning if something does actually go wrong. So > instead, let's conditionalize IRQ bypass registration on whether we > have any support for it, and to keep the de-registration path clean > and fill an unintended gap, let's ignore deregistration of NULL tokens > and prevent registration of the same. NULL isn't a good, unique > cookie anyway. Tested on AMD and non-PI Intel. Thanks, > > Alex Thanks, applying these patches to kvm/queue. Paolo