Received: from eggs.gnu.org ([2001:4830:134:3::10]:33192) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bzwA9-0003gc-Jw for qemu-devel@nongnu.org; Thu, 27 Oct 2016 21:40:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bzwA8-00045S-6x for qemu-devel@nongnu.org; Thu, 27 Oct 2016 21:40:53 -0400 From: David Gibson Date: Fri, 28 Oct 2016 12:37:56 +1100 Message-Id: <1477618694-21019-56-git-send-email-david@gibson.dropbear.id.au> In-Reply-To: <1477618694-21019-1-git-send-email-david@gibson.dropbear.id.au> References: <1477618694-21019-1-git-send-email-david@gibson.dropbear.id.au> Subject: [Qemu-devel] [PULL 55/73] tests: Adjust tco-test to use qpci_legacy_iomap() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: peter.maydell@linaro.org Cc: agraf@suse.de, clg@kaod.org, thuth@redhat.com, lvivier@redhat.com, aik@ozlabs.ru, mark.cave-ayland@ilande.co.uk, mdroth@linux.vnet.ibm.com, bharata@linux.vnet.ibm.com, qemu-ppc@nongnu.org, qemu-devel@nongnu.org, David Gibson Avoid tco-test making assumptions about the internal format of the address tokens passed to PCI IO accessors, by using the new qpci_legacy_iomap() function. Signed-off-by: David Gibson Reviewed-by: Laurent Vivier Reviewed-by: Greg Kurz --- tests/tco-test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/tco-test.c b/tests/tco-test.c index 0d201b1..129577d 100644 --- a/tests/tco-test.c +++ b/tests/tco-test.c @@ -70,7 +70,7 @@ static void test_init(TestData *d) /* set Root Complex BAR */ qpci_config_writel(d->dev, ICH9_LPC_RCBA, RCBA_BASE_ADDR | 0x1); - d->tco_io_base = (void *)((uintptr_t)PM_IO_BASE_ADDR + 0x60); + d->tco_io_base = qpci_legacy_iomap(d->dev, PM_IO_BASE_ADDR + 0x60); } static void stop_tco(const TestData *d) -- 2.7.4