From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41880) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YkBhx-0002od-9r for qemu-devel@nongnu.org; Mon, 20 Apr 2015 09:25:54 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YkBhs-0007SY-Ak for qemu-devel@nongnu.org; Mon, 20 Apr 2015 09:25:53 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34243) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YkBhs-0007SP-39 for qemu-devel@nongnu.org; Mon, 20 Apr 2015 09:25:48 -0400 Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t3KDPkYY016816 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Mon, 20 Apr 2015 09:25:47 -0400 From: Gerd Hoffmann Date: Mon, 20 Apr 2015 15:25:24 +0200 Message-Id: <1429536324-27737-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH] [hack] tseg test List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: pbonzini@redhat.com, lersek@redhat.com, Gerd Hoffmann , "Michael S. Tsirkin" Put some unique content into tseg area when locked down for easy testing. --- hw/pci-host/q35.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c index 7d21399..1b2698f 100644 --- a/hw/pci-host/q35.c +++ b/hw/pci-host/q35.c @@ -200,7 +200,8 @@ static const TypeInfo q35_host_info = { static uint64_t tseg_blackhole_read(void *ptr, hwaddr reg, unsigned size) { - return 0xffffffff; + static const char msg[] = "No access to tseg for you. "; + return msg[reg%sizeof(msg)]; } static void tseg_blackhole_write(void *opaque, hwaddr addr, uint64_t val, @@ -215,8 +216,8 @@ static const MemoryRegionOps tseg_blackhole_ops = { .endianness = DEVICE_NATIVE_ENDIAN, .valid.min_access_size = 1, .valid.max_access_size = 4, - .impl.min_access_size = 4, - .impl.max_access_size = 4, + .impl.min_access_size = 1, + .impl.max_access_size = 1, .endianness = DEVICE_LITTLE_ENDIAN, }; -- 1.8.3.1