Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/1.1/patches/2230023/?format=api
{ "id": 2230023, "url": "http://patchwork.ozlabs.org/api/1.1/patches/2230023/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260429044752.4176397-45-alistair.francis@wdc.com/", "project": { "id": 14, "url": "http://patchwork.ozlabs.org/api/1.1/projects/14/?format=api", "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": "" }, "msgid": "<20260429044752.4176397-45-alistair.francis@wdc.com>", "date": "2026-04-29T04:47:45", "name": "[PULL,44/51] target/riscv: Use ELEN for Fractional LMUL check", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "3bcbccf8717ff2592526bf3768cc28dda4982bbb", "submitter": { "id": 64571, "url": "http://patchwork.ozlabs.org/api/1.1/people/64571/?format=api", "name": "Alistair Francis", "email": "alistair23@gmail.com" }, "delegate": null, "mbox": "http://patchwork.ozlabs.org/project/qemu-devel/patch/20260429044752.4176397-45-alistair.francis@wdc.com/mbox/", "series": [ { "id": 501983, "url": "http://patchwork.ozlabs.org/api/1.1/series/501983/?format=api", "web_url": "http://patchwork.ozlabs.org/project/qemu-devel/list/?series=501983", "date": "2026-04-29T04:47:05", "name": "[PULL,01/51] hw/riscv/riscv-iommu: Use standard EN_PRI bit for PRI", "version": 1, "mbox": "http://patchwork.ozlabs.org/series/501983/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2230023/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2230023/checks/", "tags": {}, "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=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=iGecLGdi;\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 4g54mC5hPWz1yHv\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 29 Apr 2026 14:57:15 +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 1wHwuD-0001FA-C8; Wed, 29 Apr 2026 00:52:13 -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 <alistair23@gmail.com>)\n id 1wHwtx-0000rD-BG\n for qemu-devel@nongnu.org; Wed, 29 Apr 2026 00:51:57 -0400", "from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531])\n by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)\n (Exim 4.90_1) (envelope-from <alistair23@gmail.com>)\n id 1wHwtu-00015D-Df\n for qemu-devel@nongnu.org; Wed, 29 Apr 2026 00:51:57 -0400", "by mail-pg1-x531.google.com with SMTP id\n 41be03b00d2f7-c79467f124dso4537957a12.2\n for <qemu-devel@nongnu.org>; Tue, 28 Apr 2026 21:51:52 -0700 (PDT)", "from toolbx.alistair23.me ([2403:581e:fdf9:0:6209:4521:6813:45b7])\n by smtp.gmail.com with ESMTPSA id\n d9443c01a7336-2b988772ae8sm7756145ad.7.2026.04.28.21.51.47\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Tue, 28 Apr 2026 21:51:51 -0700 (PDT)" ], "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20251104; t=1777438312; x=1778043112; darn=nongnu.org;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=hCn+ToTOdAoAqsdxgqAQs8i2tRaruwvkYVx+22xQbrs=;\n b=iGecLGdirPNV97WzxUlj4NEpY6HuPagA9ZsflScUIQycr5Dvm5Z1dcCbmw+oYytT+H\n lKIVV/S2HxThjKvd6DUWkoUGECnZhkI8oQd6J+Wb6y6iRufG22RZSYDx7urG9QiGBO+B\n VpDBU1OfmVj87KApr2XWMSeMgW5OJwTL0D89tjyuQZ1oIVS7wnxrPNcOIY/OSiUwoDxi\n +mUnqGm2jvsRxzqYWNo3r+Ej2PnTNc6NaJ5/PVXapZnwlTjat/1oe487MKGkVoGRpsFD\n z0wL5ODov9ZJS5fBNoHFRivNUGJkbu7QXG5Pvp+hFesTeekCZlEtyfnAWQvPZi1t7TBO\n PAEA==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1777438312; x=1778043112;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=hCn+ToTOdAoAqsdxgqAQs8i2tRaruwvkYVx+22xQbrs=;\n b=TR8AbfU+ZaqxYRSNOw+uaSAP6oEYz5TG9dY6yeX4De4TF8azVnc8jS/ESTbSRY18U8\n Eyyd4fw4QbG19Yg8fVFWAmF7z9JSSEWG946tIpNiNoWky7ozXsWMnEIq35Xvj1Z7WRV6\n +PPGumLwKiwe5/TAYBnfqzY8ZxGl0PoZuWJ3GQW92++ZuZakvehdhE05PLRTQJRa6pxZ\n PscAUNw4jTgNFqMKPIljuL8PPEiKf0pcreToVRTrRvvwVWu2eNTOzIL1apYsbyAjZQQS\n RGxBDKAQRlX/7vfxx2nitGYtskzjAd87KFCp7O2XxgWQpXWQeFJ4C2gz22qyVZHwmBWY\n dyZA==", "X-Forwarded-Encrypted": "i=1;\n AFNElJ8Y/9REC3bR+Yn9ed/RrzlbZ8lYDth+EeTroB6bAby08v+E7H6B35S+FRJhZ6OumFHv0zM2M8NZ/aO4@nongnu.org", "X-Gm-Message-State": "AOJu0YytJX6UnXrw6ngFRwi8wt1qcUw+0xybFmTgs9NK/p28S0vQBdXI\n iQDhEd3KRCB2Rm7OtAFlW1EeaikaVy+ruObNwUOjFF/fgquanTjRm00H", "X-Gm-Gg": "AeBDietakipNRp4fLRnKEPzwR2PgPCjHs+JyH8YihaQhyGJW9h8RZXZBo9pf3WLJ1NH\n 8MXmPvEUFRDh1YpI++FvTW8EjGlHTrHM56vaL0HP2Skp7+nGVH5WKZtUZOlFPK0hJ9J7ycTnwQR\n KAjJDWr6Bk1H5QWKblVa0I71SPn+3FjsQFsWNghL9pfI2cwOTWwETi3UnosdcoSWWxF2MFEmUrC\n aQXAdFJylKmUr9k/tWBjFQs78PPcAkKiKPX0NChE8f9hQt+M7fk0M6qugdUr/5OS6IO1REut8Gr\n MJwz7bEFxy6idrCeBJoj+3yO2fWf7XQhASnDTMR9g5TLhTh4SMHe/JslHxX3ZyEdxxHKXYjMBFF\n B+Wq5t8A1X+pEPIHMamjK/ynzt5D7uRJhrRlwOU8sQjjPuYviqiE1HC3tFRvz3x6+L7NxhW3jsk\n OulpN2wIgGZBrUaze0KPfu9TkW0bh1+hCA2jRTPjb0Ezfg8xZ8FWw7", "X-Received": "by 2002:a17:902:e34a:b0:2b0:4579:ae6 with SMTP id\n d9443c01a7336-2b97c4cb993mr45089105ad.38.1777438311922;\n Tue, 28 Apr 2026 21:51:51 -0700 (PDT)", "From": "alistair23@gmail.com", "X-Google-Original-From": "alistair.francis@wdc.com", "To": "palmer@dabbelt.com, liwei1518@gmail.com, daniel.barboza@oss.qualcomm.com,\n zhiwei_liu@linux.alibaba.com, chao.liu.zevorn@gmail.com,\n qemu-riscv@nongnu.org, qemu-devel@nongnu.org", "Cc": "alistair23@gmail.com, Alistair Francis <alistair.francis@wdc.com>,\n qemu-stable@nongnu.org, Max Chou <max.chou@sifive.com>", "Subject": "[PULL 44/51] target/riscv: Use ELEN for Fractional LMUL check", "Date": "Wed, 29 Apr 2026 14:47:45 +1000", "Message-ID": "<20260429044752.4176397-45-alistair.francis@wdc.com>", "X-Mailer": "git-send-email 2.53.0", "In-Reply-To": "<20260429044752.4176397-1-alistair.francis@wdc.com>", "References": "<20260429044752.4176397-1-alistair.francis@wdc.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Received-SPF": "pass client-ip=2607:f8b0:4864:20::531;\n envelope-from=alistair23@gmail.com; helo=mail-pg1-x531.google.com", "X-Spam_score_int": "-17", "X-Spam_score": "-1.8", "X-Spam_bar": "-", "X-Spam_report": "(-1.8 / 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 FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001,\n RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,\n SPF_PASS=-0.001 autolearn=unavailable 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": "From: Alistair Francis <alistair.francis@wdc.com>\n\nThe RISC-V spec states that\n\n\"\"\"\nFor a given supported fractional LMUL setting, implementations\nmust support SEW settings between SEWMIN and LMUL * ELEN, inclusive.\n\"\"\"\n\nWe were previously checking VLEN, instead of ELEN, so let's update to\ncheck ELEN instead of VLEN for fractional scaling.\n\nCc: qemu-stable@nongnu.org\nResolves: https://gitlab.com/qemu-project/qemu/-/work_items/3196\nSigned-off-by: Alistair Francis <alistair.francis@wdc.com>\nReviewed-by: Daniel Henrique Barboza <daniel.barboza@oss.qualcomm.com>\nReviewed-by: LIU Zhiwei <zhiwei_liu@linux.alibaba.com>\nReviewed-by: Chao Liu <chao.liu.zevorn@gmail.com>\nReviewed-by: Max Chou <max.chou@sifive.com>\nMessage-ID: <20260415233740.3027321-5-alistair.francis@wdc.com>\nSigned-off-by: Alistair Francis <alistair.francis@wdc.com>\n---\n target/riscv/vector_helper.c | 9 ++++-----\n 1 file changed, 4 insertions(+), 5 deletions(-)", "diff": "diff --git a/target/riscv/vector_helper.c b/target/riscv/vector_helper.c\nindex 538168efc9..5a3554dd71 100644\n--- a/target/riscv/vector_helper.c\n+++ b/target/riscv/vector_helper.c\n@@ -70,18 +70,17 @@ target_ulong HELPER(vsetvl)(CPURISCVState *env, target_ulong s1,\n bool ill_altfmt = true;\n int xlen = riscv_cpu_xlen(env);\n bool vill = (s2 >> (xlen - 1)) & 0x1;\n- uint16_t vlen = cpu->cfg.vlenb << 3;\n int8_t lmul;\n \n if (vlmul & 4) {\n /*\n * Fractional LMUL, check:\n *\n- * VLEN * LMUL >= SEW\n- * VLEN >> (8 - lmul) >= sew\n- * (vlenb << 3) >> (8 - lmul) >= sew\n+ * ELEN * LMUL >= SEW\n+ * ELEN >> (8 - vlmul) >= sew\n */\n- if (vlmul == 4 || (vlen >> (8 - vlmul)) < sew) {\n+ if (vlmul == 4 ||\n+ (cpu->cfg.elen >> (8 - vlmul)) < sew) {\n vill = true;\n }\n }\n", "prefixes": [ "PULL", "44/51" ] }