{"id":2235157,"url":"http://patchwork.ozlabs.org/api/1.2/covers/2235157/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/cover/20260508-jmac-gpctest-v1-0-e57e42c87e1e@linaro.org/","project":{"id":14,"url":"http://patchwork.ozlabs.org/api/1.2/projects/14/?format=json","name":"QEMU Development","link_name":"qemu-devel","list_id":"qemu-devel.nongnu.org","list_email":"qemu-devel@nongnu.org","web_url":"","scm_url":"","webscm_url":"","list_archive_url":"","list_archive_url_format":"","commit_url_format":""},"msgid":"<20260508-jmac-gpctest-v1-0-e57e42c87e1e@linaro.org>","list_archive_url":null,"date":"2026-05-08T17:20:11","name":"[0/3] RFC: Testing exceptions in tests/tcg/aarch64","submitter":{"id":92076,"url":"http://patchwork.ozlabs.org/api/1.2/people/92076/?format=json","name":"Jim MacArthur","email":"jim.macarthur@linaro.org"},"mbox":"http://patchwork.ozlabs.org/project/qemu-devel/cover/20260508-jmac-gpctest-v1-0-e57e42c87e1e@linaro.org/mbox/","series":[{"id":503424,"url":"http://patchwork.ozlabs.org/api/1.2/series/503424/?format=json","web_url":"http://patchwork.ozlabs.org/project/qemu-devel/list/?series=503424","date":"2026-05-08T17:20:13","name":"RFC: Testing exceptions in tests/tcg/aarch64","version":1,"mbox":"http://patchwork.ozlabs.org/series/503424/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/covers/2235157/comments/","headers":{"Return-Path":"<qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=linaro.org header.i=@linaro.org header.a=rsa-sha256\n header.s=google header.b=w5o7VbOJ;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=nongnu.org\n (client-ip=209.51.188.17; helo=lists1p.gnu.org;\n envelope-from=qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org;\n receiver=patchwork.ozlabs.org)"],"Received":["from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17])\n\t(using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits))\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4gBwrR1pNxz1yCg\n\tfor <incoming@patchwork.ozlabs.org>; Sat, 09 May 2026 03:21:11 +1000 (AEST)","from localhost ([::1] helo=lists1p.gnu.org)\n\tby lists1p.gnu.org with esmtp (Exim 4.90_1)\n\t(envelope-from <qemu-devel-bounces@nongnu.org>)\n\tid 1wLOsI-0005a9-1M; Fri, 08 May 2026 13:20:30 -0400","from eggs.gnu.org ([2001:470:142:3::10])\n by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)\n (Exim 4.90_1) (envelope-from <jim.macarthur@linaro.org>)\n id 1wLOsC-0005Z7-FZ\n for qemu-devel@nongnu.org; Fri, 08 May 2026 13:20:24 -0400","from mail-wm1-x330.google.com ([2a00:1450:4864:20::330])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <jim.macarthur@linaro.org>)\n id 1wLOs8-0002JD-8x\n for qemu-devel@nongnu.org; Fri, 08 May 2026 13:20:23 -0400","by mail-wm1-x330.google.com with SMTP id\n 5b1f17b1804b1-4891b0786beso15648435e9.1\n for <qemu-devel@nongnu.org>; Fri, 08 May 2026 10:20:16 -0700 (PDT)","from [127.0.1.1] ([2a10:d582:31e:0:e47d:4cf0:1918:bbbd])\n by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-48e6dd2c550sm9516965e9.3.2026.05.08.10.20.14\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Fri, 08 May 2026 10:20:14 -0700 (PDT)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=linaro.org; s=google; t=1778260815; x=1778865615; darn=nongnu.org;\n h=cc:to:content-transfer-encoding:mime-version:message-id:date\n :subject:from:from:to:cc:subject:date:message-id:reply-to;\n bh=doRaxtPQOBaf8x86DjICGD/hSUnx6ZtzP3EUzx6fgfA=;\n b=w5o7VbOJ8FXpJDV3c7LYtNpY91DmwV8GDq1nvtkvF7Zs9ypEbrcdAuJaCEu9ATnjLn\n 1yQG0offhEyr/UKMYFO+H1cBqZsNluQ7mH020C46xDTGwT7BZFsBk3UiMthpps8x8eNN\n 4b4FbFFSn5nFUyPczD3AtPaUUsdn3EXi79OGL0sUWJWbLeo7zWkx0WmaS2L7Do4lK/nw\n jozNUjVOGT4fcsBuhMZIOqQ2Z6zAZZRzfuH4xYpgniPudj05hRVEyCeIHmmraBahhaKZ\n uFD8rhI62VASRTQMj9U67tD5uMdP5XG1dPpRj67covFwo25pwsBz+97RUvxdqHwhO0NW\n N8Uw==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1778260815; x=1778865615;\n h=cc:to:content-transfer-encoding:mime-version:message-id:date\n :subject:from:x-gm-gg:x-gm-message-state:from:to:cc:subject:date\n :message-id:reply-to;\n bh=doRaxtPQOBaf8x86DjICGD/hSUnx6ZtzP3EUzx6fgfA=;\n b=A2/FTaGCqbBR2aTspp4yB73ZwUYFRQYI/aACZ8abBcM6l7iRj2ywuxoxN8bGkZbJlO\n awUGBE3rsXZ0K1AlVhUpUzioRUCedv+aYxewx26173jJvN5VTzTHu0rDgfhdAFP/O47t\n ntx51ShxH5/34Y5rZHBkAJ0kLF/VCEjxXs8PmgiyI6JfYGMWvB6+yqas4UgIkZ6W+vI4\n IwR5l9XRDjom3XWSSAZSR0am8c7ZBU/Y9zr76BjRGB9chCSBK9bMWZqvbhhLgDXVwBg0\n wHvuaoTfpWWUCCYdTmYcio4wP7nyvcs83iBkJWXdWoXHrsx19YH9s7c+DHLBxmzQEjB8\n TUcg==","X-Gm-Message-State":"AOJu0Yxm+vRFapSi/dWegxTfRxJl79bzowtLgqC90Guzo2LbqOiIv2Ro\n g8u1hyMFets8YyXpm8A7maPKa1wDvEabphvpXI52ijmMigP5dklo7qZt1LLNkBDJz5/9h11C20N\n zec5a","X-Gm-Gg":"AeBDieu1RpKiou1yMb8Mz6voR9D0ffmA3mnrs2s9c0bR30sctv52A/shq1XE41MUelb\n mayVULGd38RP7rDsFWGqFymm510KfOMxX3qJ3mDRB8LeO7e0EXAbj8Gwc08ll45WhhY5ws/VCUS\n E/IN+skDqExlU0FGYRmDGORUNFjGpHO9gvBt/j54dBlser/ajqPLX9H7dQI0k4AS9rmmD7W1rsO\n 79NobL1K1miZSzJpRJXmy7q+9/mBJwwfkuUPz03itvLgRPq/0PrE85nbFHNLeYR0gVfyI4fs9sr\n h25CZup/JeSGIVlyi9MmDvFyWpgccrRT2G5Pp0tt9RXYKt82yQzjIIaiOeDlWt4Wj/4iUEE/uid\n N/CrBMVvZx3EeM9WnMj+9BW2STH8qCPmZXoxKMJk5CHwyFZ0Z9Qr0wy9+kPtVWNBnVvxh2G8O7P\n FcFdkZdMjl9kidC+5Xf/AAKI41hbQ=","X-Received":"by 2002:a05:600c:8b08:b0:48a:5501:7995 with SMTP id\n 5b1f17b1804b1-48e51f32ca9mr231887985e9.18.1778260815112;\n Fri, 08 May 2026 10:20:15 -0700 (PDT)","From":"Jim MacArthur <jim.macarthur@linaro.org>","Subject":"[PATCH 0/3] RFC: Testing exceptions in tests/tcg/aarch64","Date":"Fri, 08 May 2026 18:20:11 +0100","Message-Id":"<20260508-jmac-gpctest-v1-0-e57e42c87e1e@linaro.org>","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"7bit","X-B4-Tracking":"v=1; b=H4sIAEsb/mkC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE\n vPSU3UzU4B8JSMDIzMDUwML3azcxGTd9ILkktTiEt1E87REs8RES4NkcwsloJaCotS0zAqwcdG\n xtbUAwDEzOF4AAAA=","To":"qemu-devel@nongnu.org","Cc":"Peter Maydell <peter.maydell@linaro.org>, qemu-arm@nongnu.org,\n Jim MacArthur <jim.macarthur@linaro.org>","X-Mailer":"b4 0.13.0","Received-SPF":"pass client-ip=2a00:1450:4864:20::330;\n envelope-from=jim.macarthur@linaro.org; helo=mail-wm1-x330.google.com","X-Spam_score_int":"-20","X-Spam_score":"-2.1","X-Spam_bar":"--","X-Spam_report":"(-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,\n DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,\n RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,\n SPF_PASS=-0.001 autolearn=ham autolearn_force=no","X-Spam_action":"no action","X-BeenThere":"qemu-devel@nongnu.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"qemu development <qemu-devel.nongnu.org>","List-Unsubscribe":"<https://lists.nongnu.org/mailman/options/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe>","List-Archive":"<https://lists.nongnu.org/archive/html/qemu-devel>","List-Post":"<mailto:qemu-devel@nongnu.org>","List-Help":"<mailto:qemu-devel-request@nongnu.org?subject=help>","List-Subscribe":"<https://lists.nongnu.org/mailman/listinfo/qemu-devel>,\n <mailto:qemu-devel-request@nongnu.org?subject=subscribe>","Errors-To":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org","Sender":"qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org"},"content":"In order to test the granule protection system meaningfully, we need\nto verify that certain memory accesses cause the correct exceptions.\nAFAIK, we do have system tests which boot kernels using GPC, but no\nfiner grained tests for specific GPC behaviour.\n\nSo I've added the following example test of GPC. It uses a new vector\ntable which can replace the one in boot.S with one which will record\nand ignore certain types of exception (data aborts and GPC\nexceptions).\n\nThe test itself (gpc-test.c) is not quite ready for submission yet,\nbut I would like feedback on the mechanism used for verifying\nexceptions. (For example, if we do in fact have an existing way of\ntesting exceptions.)\n\nOnce a mechanism for testing is in place, adding some more features\n(for example FEAT_RME_GPC3) should be relatively easy.\n\nSigned-off-by: Jim MacArthur <jim.macarthur@linaro.org>\n---\nJim MacArthur (3):\n      boot.S: Allocate minimal space for granule protection tables\n      altvec.S: Alternative vector table for aarch64 testing\n      gpc-test.c: Basic test for granule protection check.\n\n tests/tcg/aarch64/Makefile.softmmu-target |   7 +-\n tests/tcg/aarch64/system/altvec.S         | 129 ++++++++++++++++++++++++++++++\n tests/tcg/aarch64/system/boot.S           |  10 +++\n tests/tcg/aarch64/system/gpc-test.c       | 125 +++++++++++++++++++++++++++++\n 4 files changed, 270 insertions(+), 1 deletion(-)\n---\nbase-commit: ee7eb612be8f8886d48c1d0c1f1c65e495138f83\nchange-id: 20260508-jmac-gpctest-a7fa6aa90c78\n\nBest regards,"}