From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:33315) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xc3HY-0001vk-Jz for qemu-devel@nongnu.org; Wed, 08 Oct 2014 22:16:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xc3HS-0005ma-92 for qemu-devel@nongnu.org; Wed, 08 Oct 2014 22:16:44 -0400 Received: from mga11.intel.com ([192.55.52.93]:9940) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xc3HS-0005m8-3h for qemu-devel@nongnu.org; Wed, 08 Oct 2014 22:16:38 -0400 Message-ID: <5435F001.7030403@intel.com> Date: Thu, 09 Oct 2014 10:16:33 +0800 From: "Chen, Tiejun" MIME-Version: 1.0 References: <53FBF5BD.6060104@intel.com> <53FE7E3A.7050907@intel.com> <53FFD752.2040402@intel.com> <20140831085857.GC1514@redhat.com> <5403DEFD.1020704@intel.com> <20140901060506.GA20186@redhat.com> <54042514.6090206@intel.com> <003AAFE53969E14CB1F09B6FD68C3CD478F16D2A@ORSMSX101.amr.corp.intel.com> <54277979.7070408@intel.com> <54279EE3.3050208@intel.com> <20141007072751.GC2424@redhat.com> In-Reply-To: <20141007072751.GC2424@redhat.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Xen-devel] [PATCH 2/2] xen:i386:pc_piix: create isa bridge specific to IGD passthrough List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Michael S. Tsirkin" Cc: "xen-devel@lists.xensource.com" , "Kay, Allen M" , "qemu-devel@nongnu.org" , Konrad Rzeszutek Wilk On 2014/10/7 15:27, Michael S. Tsirkin wrote: > On Sun, Sep 28, 2014 at 01:38:43PM +0800, Chen, Tiejun wrote: >>> **errp) >>> { >>> uint32_t value = 0; >>> XenHostPCIDevice hdev; >>> int r = 0, num; >>> >>> r = xen_host_pci_device_get(&hdev, 0, 0, 0x02, 0); >>> if (!r) { >>> value = hdev.device_id; >>> >>> num = sizeof(xen_igd_combo_id_infos)/sizeof(uint16_t); >> >> Sorry for this one typo: >> >> sizeof(xen_igd_combo_id_infos)/sizeof(xen_igd_combo_id_infos[0]); >> >> Tiejun > > > so don't opencode this, use ARRAY_SIZE. > Yes, I will refine this with ARRAY_SIZE. Thanks Tiejun