From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id A1A2CCFA0 for ; Tue, 28 Mar 2017 16:41:15 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=intel.com; i=@intel.com; q=dns/txt; s=intel; t=1490712075; x=1522248075; h=from:to:cc:subject:date:message-id; bh=uJwD9/Dg2oolaOWW7HdaRYOPXDjWVEgkEwf1jQon6MM=; b=p1IX184kIJiFM8ZmC5roaMGGpn9K2UEdBsx1eZTKvp7gS73y0oMBGKc+ O9TE63cPBOE6Xa3l56vejFZEL2NhQw==; Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 Mar 2017 07:41:14 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,236,1486454400"; d="scan'208";a="1128078061" Received: from unknown (HELO localhost.iind.intel.com) ([10.224.122.216]) by fmsmga001.fm.intel.com with ESMTP; 28 Mar 2017 07:41:13 -0700 From: Nikhil Rao To: anatoly.burakov@intel.com Cc: dev@dpdk.org Date: Wed, 29 Mar 2017 04:45:34 +0530 Message-Id: <1490742934-30608-1-git-send-email-nikhil.rao@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [dpdk-dev] [PATCH] vfio: Fix vfio ioctl call to mask INTx X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Mar 2017 14:41:16 -0000 The flags member of irq_set should be ORed with VFIO_IRQ_SET_ACTION_MASK and not VFIO_IRQ_SET_ACTION_UNMASK. The bug was found by code inspection. Fixes: 5c782b3928b8 (\"vfio: interrupts\") Signed-off-by: Nikhil Rao --- lib/librte_eal/linuxapp/eal/eal_interrupts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_eal/linuxapp/eal/eal_interrupts.c b/lib/librte_eal/linuxapp/eal/eal_interrupts.c index 5bb833e..0d7c7c1 100644 --- a/lib/librte_eal/linuxapp/eal/eal_interrupts.c +++ b/lib/librte_eal/linuxapp/eal/eal_interrupts.c @@ -194,7 +194,7 @@ vfio_disable_intx(const struct rte_intr_handle *intr_handle) { irq_set = (struct vfio_irq_set *) irq_set_buf; irq_set->argsz = len; irq_set->count = 1; - irq_set->flags = VFIO_IRQ_SET_DATA_NONE | VFIO_IRQ_SET_ACTION_UNMASK; + irq_set->flags = VFIO_IRQ_SET_DATA_NONE | VFIO_IRQ_SET_ACTION_MASK; irq_set->index = VFIO_PCI_INTX_IRQ_INDEX; irq_set->start = 0; -- 2.7.4