From patchwork Tue Sep 9 07:31:15 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Auger Eric X-Patchwork-Id: 37040 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f197.google.com (mail-vc0-f197.google.com [209.85.220.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 6BCCC20491 for ; Tue, 9 Sep 2014 07:32:08 +0000 (UTC) Received: by mail-vc0-f197.google.com with SMTP id hy4sf5242017vcb.8 for ; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=rpr2Wkmbf5v+TIxiS93yGj0TKrXqlvHumj2Fd+I9Y94=; b=Y7XQoJJkUZ5EIa4TBtL8o8tw3FYjSAYVL9D7L2op9bHTbVGgHCTi2kAnB1i3trL6ZU m3nI+ORT/D5JrUhYJ2k4BVfi/T9KI7wc6w5MAbhkZZVkO/4FQQ6SLdlX3UcZQJOFGBaq 8ZVmb0mtDJgrtEdHOPIiol7F1IAVfWbL6WqLQmX9QQ9aS9qcQ8WP/SmKQzZU3HAdC0+6 5XcLbfLsD82lFiMmOZ9hwx7TsCD8e/xBPGIzBKxw4+Cj5yjjjs9JmRpZ+3cfXnoOGCoc Wuf1Ro/K6qoXYauhKAL7PqHqIvAFRC2iqt+eNBN4Ulm6rzef4jZzRW8uFyN+lBLYc/cR G5bA== X-Gm-Message-State: ALoCoQkkJCohcCSES+UBM4Qcsqslu/LE9kUmx6y4Matize57mfwI4LyQm9BtOs9dWux6EojLlfMT X-Received: by 10.236.108.172 with SMTP id q32mr21144247yhg.0.1410247928232; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.96.56 with SMTP id j53ls471472qge.28.gmail; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) X-Received: by 10.52.110.202 with SMTP id ic10mr747722vdb.3.1410247928165; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) Received: from mail-vc0-f176.google.com (mail-vc0-f176.google.com [209.85.220.176]) by mx.google.com with ESMTPS id fh1si1892912vcb.46.2014.09.09.00.32.08 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Sep 2014 00:32:08 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.176 as permitted sender) client-ip=209.85.220.176; Received: by mail-vc0-f176.google.com with SMTP id la4so521060vcb.7 for ; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) X-Received: by 10.220.172.8 with SMTP id j8mr13859927vcz.32.1410247928110; Tue, 09 Sep 2014 00:32:08 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.221.45.67 with SMTP id uj3csp244069vcb; Tue, 9 Sep 2014 00:32:07 -0700 (PDT) X-Received: by 10.194.92.244 with SMTP id cp20mr420682wjb.135.1410247927260; Tue, 09 Sep 2014 00:32:07 -0700 (PDT) Received: from mail-wi0-f181.google.com (mail-wi0-f181.google.com [209.85.212.181]) by mx.google.com with ESMTPS id wt7si16114222wjb.115.2014.09.09.00.32.06 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Sep 2014 00:32:07 -0700 (PDT) Received-SPF: pass (google.com: domain of eric.auger@linaro.org designates 209.85.212.181 as permitted sender) client-ip=209.85.212.181; Received: by mail-wi0-f181.google.com with SMTP id e4so3897876wiv.14 for ; Tue, 09 Sep 2014 00:32:06 -0700 (PDT) X-Received: by 10.180.198.50 with SMTP id iz18mr27825934wic.10.1410247926624; Tue, 09 Sep 2014 00:32:06 -0700 (PDT) Received: from midway01-04-00.lavalab ([88.98.47.97]) by mx.google.com with ESMTPSA id s1sm14513743wiw.6.2014.09.09.00.32.05 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 09 Sep 2014 00:32:06 -0700 (PDT) From: Eric Auger To: eric.auger@st.com, christoffer.dall@linaro.org, qemu-devel@nongnu.org, a.rigo@virtualopensystems.com, kim.phillips@freescale.com, marc.zyngier@arm.com, manish.jaggi@caviumnetworks.com, joel.schopp@amd.com, agraf@suse.de, peter.maydell@linaro.org, pbonzini@redhat.com, afaerber@suse.de Cc: eric.auger@linaro.org, kvmarm@lists.cs.columbia.edu, patches@linaro.org, will.deacon@arm.com, Bharat.Bhushan@freescale.com, stuart.yoder@freescale.com, a.motakis@virtualopensystems.com, alex.williamson@redhat.com Subject: [PATCH v6 15/16] VFIO: COMMON: vfio_kvm_device_fd moved in the common header Date: Tue, 9 Sep 2014 08:31:15 +0100 Message-Id: <1410247876-4967-16-git-send-email-eric.auger@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1410247876-4967-1-git-send-email-eric.auger@linaro.org> References: <1410247876-4967-1-git-send-email-eric.auger@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: eric.auger@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.176 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , the device is now used in platform for forwarded IRQ setup Signed-off-by: Eric Auger --- hw/vfio/common.c | 3 ++- include/hw/vfio/vfio-common.h | 5 +++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/hw/vfio/common.c b/hw/vfio/common.c index 252c0b8..466b0e8 100644 --- a/hw/vfio/common.c +++ b/hw/vfio/common.c @@ -44,9 +44,10 @@ struct vfio_as_head vfio_address_spaces = * initialized, this file descriptor is only released on QEMU exit and * we'll re-use it should another vfio device be attached before then. */ -static int vfio_kvm_device_fd = -1; +int vfio_kvm_device_fd = -1; #endif + /* * Common VFIO interrupt disable */ diff --git a/include/hw/vfio/vfio-common.h b/include/hw/vfio/vfio-common.h index 83c7876..0ae0153 100644 --- a/include/hw/vfio/vfio-common.h +++ b/include/hw/vfio/vfio-common.h @@ -41,6 +41,11 @@ #define VFIO_ALLOW_KVM_MSI 1 #define VFIO_ALLOW_KVM_MSIX 1 +#ifdef CONFIG_KVM +extern int vfio_kvm_device_fd; +#endif + + enum { VFIO_DEVICE_TYPE_PCI = 0, VFIO_DEVICE_TYPE_PLATFORM = 1,