From patchwork Fri Dec 29 21:22:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758789 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670579wrw; Fri, 29 Dec 2023 13:24:34 -0800 (PST) X-Google-Smtp-Source: AGHT+IHG8OGOCnFvkK5PYgez/OAgEXifa3bZ2mHfv8zCVARrel3A885lE0/6QFU93zWcKStLnLNm X-Received: by 2002:a05:6808:2383:b0:3bb:761c:b285 with SMTP id bp3-20020a056808238300b003bb761cb285mr15236499oib.31.1703885074018; Fri, 29 Dec 2023 13:24:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885073; cv=none; d=google.com; s=arc-20160816; b=ZlfedBw+JfYjicXvHwRWVobtC+caM/4FXs/hLY8/pq3eCEhkoV2gmrJGL9OIGtDmMu qU2woDFw6A4kWDvXT5TODwsy8E7HvnrgvHrePS7OznzphKptws/zXO65tL4sjH0nxZLM 1pYUMKeWf191EjjDJVh99fWJwjgynw6uZXvb5V4SHBDOr5R5P2jJNKSGhPuZima6/KlS uv94Aa0dJvVs/FxI3CsfFOiOmNKRHt1EQyHcip58dB6LCS450vhFQNQTBekT9KW+Sond G7QX1DUMU/Vs6sGiOW2GwCFJpif24+KZa/FjZNsvCNF+qVceXsInbBH52Zt5ptnTstdw 6W3g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=1TEKLSsQIWfhjFxdaJnF+IoMYCW7TwDJB1ogBSn9TY8=; fh=dNfoUO7Nc2JDxXG2d8JvM7yFdAIO7QjfCreESjF9xd0=; b=bLjMyA3RzTRRN6tUaP5pqg8GT/GQhcW/OynUdjuCS1Oz9PU81UgMWfjgm/QGufRPQf zny7D/YX+UroEugkAG39KAD//vcZBUI/X7v7Y5nUifkym1nvxuXnkp8NXxgaVANhvUaq 0e1bIeA0B+RkI9Yt5ehrF1TvHk8aMc4OATCbl6tXt+RBAhnFJ0JNyUp9XinosTyECebx JfZ8j/dZhvhvJE5Qu9gRcQmN1JnZzqy8aGbzhIgOtMpwbS9as3r0BQnAikW7AN9e/kFO yzK5IvULyMj4K+SFRg/JG5v+KFt6DibgTZzXIdqmjFre4ZPe7AKaof/WExRASsdgZw4T 62ZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cQSOWbEh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 15-20020ac8590f000000b004254a95906bsi19695464qty.332.2023.12.29.13.24.33 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:24:33 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=cQSOWbEh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKKn-0006pr-1D; Fri, 29 Dec 2023 16:24:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKKl-0006pK-Qa for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:23:59 -0500 Received: from mail-il1-x12c.google.com ([2607:f8b0:4864:20::12c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKj-0005ko-VD for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:23:59 -0500 Received: by mail-il1-x12c.google.com with SMTP id e9e14a558f8ab-3600dc78bc0so14534985ab.2 for ; Fri, 29 Dec 2023 13:23:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885037; x=1704489837; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=1TEKLSsQIWfhjFxdaJnF+IoMYCW7TwDJB1ogBSn9TY8=; b=cQSOWbEhy8yLsndyVmdHi2E1P9DIMbzczCjXKOOLSJu3JZkUucV7g7fvwmqKx2XQp3 oVSDNksuxqUDLBoDYukr0fE2OOZtw7ia4rG/c7qbdeZFmhinbCic7CSRSnWQAqhNd1Bf pc1JTwd7MmpxURLtj9vMjAB/V17jXgn8usNyrs2/Nka+i5QWl3qwd8vOf0SYbfFV+/Hf WVnojAJ+2Vi1EPl5M0GDHBaaSCSa3Cz8b0uhycnDjA2c+bi/6TNgYq6F29Pghenw0nIw lPQoRd5BpE9VL3p7EcwspIZOVPLnjhKMnJkaoLTg8BP4nGkCNi6+/qNDJkDcaWkGcz2P JbvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885037; x=1704489837; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1TEKLSsQIWfhjFxdaJnF+IoMYCW7TwDJB1ogBSn9TY8=; b=D+zrFjKR0tTQgwfKvyX6kEo7zztKvuLgspQ8JX5+BUOE740mXIPefDbwqIplZ304TN xbBBBNai/WFtjmvTA446g5SLzSOuXBAJVdLHjKeaQO7oo8aXQ9F+pvTDUX4JfuVKeIex tUNmDTDPRhfgOTbFIImIjZGOr9mk65Em31kP+OH9kBIjIRpeSpFrldlq4yT2fGkQwdFP gvpkUMwXi07+B5bnER+wYKkYIqf3YHC4o0F+Np8uszfN99g2e1OZB2VSh1SVpuugGAuc ZJZkp4ixYSl+vuPLotMS+tyPs6xJ/FvaiXCO1JJw8jYOXjMS67t/fuOIMhyW8LHt5y0/ MNEw== X-Gm-Message-State: AOJu0Yyj4AP+7vXf8oKldSWbZn0n+FjWIhKBp08MS5XFS//RmNiZG/xp TRN7w52oRnyC8y8prNB21LmFWBI36H34ilYuncb5Kvsl5vCG8A== X-Received: by 2002:a92:c241:0:b0:35f:af09:23d1 with SMTP id k1-20020a92c241000000b0035faf0923d1mr17263374ilo.28.1703885036856; Fri, 29 Dec 2023 13:23:56 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.23.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:23:56 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Juan Quintela Subject: [PULL 01/71] migration: Make VMStateDescription.subsections const Date: Sat, 30 Dec 2023 08:22:36 +1100 Message-Id: <20231229212346.147149-2-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::12c; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x12c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Allow the array of pointers to itself be const. Propagate this through the copies of this field. Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Juan Quintela Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-2-richard.henderson@linaro.org> --- include/migration/vmstate.h | 2 +- migration/savevm.c | 12 ++++++------ migration/vmstate.c | 14 ++++++++------ 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/include/migration/vmstate.h b/include/migration/vmstate.h index 9821918631..294d2d8486 100644 --- a/include/migration/vmstate.h +++ b/include/migration/vmstate.h @@ -209,7 +209,7 @@ struct VMStateDescription { bool (*dev_unplug_pending)(void *opaque); const VMStateField *fields; - const VMStateDescription **subsections; + const VMStateDescription * const *subsections; }; extern const VMStateInfo vmstate_info_bool; diff --git a/migration/savevm.c b/migration/savevm.c index 1b9ab7b8ee..eab62330b6 100644 --- a/migration/savevm.c +++ b/migration/savevm.c @@ -551,11 +551,11 @@ static void dump_vmstate_vmsf(FILE *out_file, const VMStateField *field, } static void dump_vmstate_vmss(FILE *out_file, - const VMStateDescription **subsection, + const VMStateDescription *subsection, int indent) { - if (*subsection != NULL) { - dump_vmstate_vmsd(out_file, *subsection, indent, true); + if (subsection != NULL) { + dump_vmstate_vmsd(out_file, subsection, indent, true); } } @@ -597,7 +597,7 @@ static void dump_vmstate_vmsd(FILE *out_file, fprintf(out_file, "\n%*s]", indent, ""); } if (vmsd->subsections != NULL) { - const VMStateDescription **subsection = vmsd->subsections; + const VMStateDescription * const *subsection = vmsd->subsections; bool first; fprintf(out_file, ",\n%*s\"Subsections\": [\n", indent, ""); @@ -606,7 +606,7 @@ static void dump_vmstate_vmsd(FILE *out_file, if (!first) { fprintf(out_file, ",\n"); } - dump_vmstate_vmss(out_file, subsection, indent + 2); + dump_vmstate_vmss(out_file, *subsection, indent + 2); subsection++; first = false; } @@ -831,7 +831,7 @@ void unregister_savevm(VMStateIf *obj, const char *idstr, void *opaque) static void vmstate_check(const VMStateDescription *vmsd) { const VMStateField *field = vmsd->fields; - const VMStateDescription **subsection = vmsd->subsections; + const VMStateDescription * const *subsection = vmsd->subsections; if (field) { while (field->name) { diff --git a/migration/vmstate.c b/migration/vmstate.c index b7723a4187..ef26f26ccd 100644 --- a/migration/vmstate.c +++ b/migration/vmstate.c @@ -452,13 +452,15 @@ int vmstate_save_state_v(QEMUFile *f, const VMStateDescription *vmsd, } static const VMStateDescription * -vmstate_get_subsection(const VMStateDescription **sub, char *idstr) +vmstate_get_subsection(const VMStateDescription * const *sub, + const char *idstr) { - while (sub && *sub) { - if (strcmp(idstr, (*sub)->name) == 0) { - return *sub; + if (sub) { + for (const VMStateDescription *s = *sub; s ; s = *++sub) { + if (strcmp(idstr, s->name) == 0) { + return s; + } } - sub++; } return NULL; } @@ -517,7 +519,7 @@ static int vmstate_subsection_load(QEMUFile *f, const VMStateDescription *vmsd, static int vmstate_subsection_save(QEMUFile *f, const VMStateDescription *vmsd, void *opaque, JSONWriter *vmdesc) { - const VMStateDescription **sub = vmsd->subsections; + const VMStateDescription * const *sub = vmsd->subsections; bool vmdesc_has_subsections = false; int ret = 0; From patchwork Fri Dec 29 21:22:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758791 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670688wrw; Fri, 29 Dec 2023 13:24:59 -0800 (PST) X-Google-Smtp-Source: AGHT+IF0P0D4e7pPLsDe/5POmmr9+xN6bWfBM1qf9+jFWH9dceRS5h70wSUk9BwJ3Hc6aucgEkqk X-Received: by 2002:ac8:5ad0:0:b0:425:4043:18c7 with SMTP id d16-20020ac85ad0000000b00425404318c7mr15159114qtd.122.1703885098904; Fri, 29 Dec 2023 13:24:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885098; cv=none; d=google.com; s=arc-20160816; b=wYiCMo/J1eEDoIL8vxXMEZ6eHLvcx8lWDUNuf9C/iPATjxYR+hw/016eSI8DQJ3LYA CpZOwd+w55NDNmHGLM2WeWK2x1jzqUiJnNgwAzpfNte0dKr12P1Qg+RLe2kvG3terBJX TV2qZIATVOiNRURQZz//j0om6QssZub47kBv53bTlaRCCpIdKtbc9Y2IR59FPWGwf50h d2ONfNGXL9B6EkYUkRZ2faEwWK5km5HyCxY6UGSWlEXSfBBkpKq5Y8Hpbl8w01x6dRrQ IbhXfB2qaZc/mDyd/BvDu6qTg4d/rrCMwH0KZJOuW6igywMWQ0hH+hzLdBAT3LHb9QN9 JRhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=8xm0Gl7UGEHRLA0hiMBXMip7qQxs5CW2t5gzkb/woyg=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=I9Be0Lszs5OWbUxoLqBstRYnHXhOao2KIIsNlRrJfYS+smTliMYkR8nKKhi+zvuINF LVcCVyASZRSZUHQGA04uMjQja0tAA7RdyucOzxJIABZVG/SXBVmW9K097TZEOG1ml/K9 ifLFrUUSvXamy9IgjdWaGycv1kpC2URjbMsqJ8hfyvWnOyRrVy902cV5LjpXU8D27awJ eY1C2xtAHzm1ZiAAp+/BzhCNuTO1pmW1Dmi+miEgp57P7kvgFe5MQAO6RwVa7T2NoLAY lyZYJNWJfDPvgHXKk/vo9GGcZW5U78o/LJUECYvra97N7aacsGiuhMvIEepB7tFFbqgD PY/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vbI7nT1y; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d13-20020ac85d8d000000b0042548ac376fsi19775319qtx.718.2023.12.29.13.24.58 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:24:58 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vbI7nT1y; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKKq-0006qG-1s; Fri, 29 Dec 2023 16:24:04 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKKo-0006q7-JH for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:02 -0500 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKm-0005oP-Gr for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:02 -0500 Received: by mail-ot1-x330.google.com with SMTP id 46e09a7af769-6dbf0561f8bso2632160a34.1 for ; Fri, 29 Dec 2023 13:24:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885039; x=1704489839; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8xm0Gl7UGEHRLA0hiMBXMip7qQxs5CW2t5gzkb/woyg=; b=vbI7nT1ybEJmmiRO0piLdjC+//Jz4jLXfe4l8qn565JdECdcPUWXAugu6K9QZQeCnx 5/cfSt4471F2R726ZZPudTmpTh8eul3QI34CXB0drGUwLEqteZdJAi2z/H8Qt7wIo0EL vK45TI3r3ubch1G/K4RlIzY1CwtMtMyyoaTpCdDLfiF4wfP260ePXTbpywhzZghSgaXR ZotRNbtG375qTaweWyuQo7JPSgvOmDsmsB34t0zUfdR4o3augMogBw/sS3kKcslW9tRb LvaNGnnZu4v+3zYs6SWy/Hm3954zlT/zFbeoKIyVOCyXdlcRWgjbq68Q6EQpTIlyqmgc ZtFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885039; x=1704489839; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8xm0Gl7UGEHRLA0hiMBXMip7qQxs5CW2t5gzkb/woyg=; b=ENVQXG1Z3l0wshBBrpiVovf1iQ6Xd6E2mUHxMcP5PPpzVS/jZ+3aUoahhsbl86ndgL R6Y82dsKN8APB9hLEztRRqQi3SJdLjFhzWzEuMj7I9JO2X9/cZroQMJxgkw+F8b32BHT Gvb5HyUK8NQKBTsmSogyIRZv7jHGzFJ9n+I7KPzNOWYG4oaHsieIyQE22zpmss+hpmq4 KQWSLnCSPJBgoHDRT6A68xcHmxocRKjqYaQ/vp6N1SGiQlww4nVfd1moeyp8IxDltFmr NvEakAEsvoy1nEf5Oh8r6nsh+2nrglFQv1L2QFTk8l76aEsKAg81DMhOT2HcPIgJZ3v3 QDuA== X-Gm-Message-State: AOJu0Yxqxz7eFxos6L6RTvcP45Vr4l8kUh+sp+NQ6OJ0gA08WABzCtKm fX4+IyjFlQ+NbwVSjQBc3diSvwmhwMK2OisToFGoHmtgLSN/8A== X-Received: by 2002:a05:6830:a41:b0:6db:dc52:385a with SMTP id g1-20020a0568300a4100b006dbdc52385amr7231916otu.19.1703885039123; Fri, 29 Dec 2023 13:23:59 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.23.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:23:58 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 02/71] target/arm: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:37 +1100 Message-Id: <20231229212346.147149-3-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::330; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-3-richard.henderson@linaro.org> --- target/arm/machine.c | 54 ++++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/target/arm/machine.c b/target/arm/machine.c index 9e20b41189..542be14bec 100644 --- a/target/arm/machine.c +++ b/target/arm/machine.c @@ -49,7 +49,7 @@ static const VMStateDescription vmstate_vfp = { .version_id = 3, .minimum_version_id = 3, .needed = vfp_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* For compatibility, store Qn out of Zn here. */ VMSTATE_UINT64_SUB_ARRAY(env.vfp.zregs[0].d, ARMCPU, 0, 2), VMSTATE_UINT64_SUB_ARRAY(env.vfp.zregs[1].d, ARMCPU, 0, 2), @@ -115,7 +115,7 @@ static const VMStateDescription vmstate_iwmmxt = { .version_id = 1, .minimum_version_id = 1, .needed = iwmmxt_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.iwmmxt.regs, ARMCPU, 16), VMSTATE_UINT32_ARRAY(env.iwmmxt.cregs, ARMCPU, 16), VMSTATE_END_OF_LIST() @@ -140,7 +140,7 @@ static const VMStateDescription vmstate_zreg_hi_reg = { .name = "cpu/sve/zreg_hi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_SUB_ARRAY(d, ARMVectorReg, 2, ARM_MAX_VQ - 2), VMSTATE_END_OF_LIST() } @@ -150,7 +150,7 @@ static const VMStateDescription vmstate_preg_reg = { .name = "cpu/sve/preg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(p, ARMPredicateReg, 2 * ARM_MAX_VQ / 8), VMSTATE_END_OF_LIST() } @@ -161,7 +161,7 @@ static const VMStateDescription vmstate_sve = { .version_id = 1, .minimum_version_id = 1, .needed = sve_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(env.vfp.zregs, ARMCPU, 32, 0, vmstate_zreg_hi_reg, ARMVectorReg), VMSTATE_STRUCT_ARRAY(env.vfp.pregs, ARMCPU, 17, 0, @@ -174,7 +174,7 @@ static const VMStateDescription vmstate_vreg = { .name = "vreg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(d, ARMVectorReg, ARM_MAX_VQ * 2), VMSTATE_END_OF_LIST() } @@ -196,7 +196,7 @@ static const VMStateDescription vmstate_za = { .version_id = 1, .minimum_version_id = 1, .needed = za_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(env.zarray, ARMCPU, ARM_MAX_VQ * 16, 0, vmstate_vreg, ARMVectorReg), VMSTATE_END_OF_LIST() @@ -217,7 +217,7 @@ static const VMStateDescription vmstate_serror = { .version_id = 1, .minimum_version_id = 1, .needed = serror_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(env.serror.pending, ARMCPU), VMSTATE_UINT8(env.serror.has_esr, ARMCPU), VMSTATE_UINT64(env.serror.esr, ARMCPU), @@ -235,7 +235,7 @@ static const VMStateDescription vmstate_irq_line_state = { .version_id = 1, .minimum_version_id = 1, .needed = irq_line_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.irq_line_state, ARMCPU), VMSTATE_END_OF_LIST() } @@ -254,7 +254,7 @@ static const VMStateDescription vmstate_m_faultmask_primask = { .version_id = 1, .minimum_version_id = 1, .needed = m_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.faultmask[M_REG_NS], ARMCPU), VMSTATE_UINT32(env.v7m.primask[M_REG_NS], ARMCPU), VMSTATE_END_OF_LIST() @@ -289,7 +289,7 @@ static const VMStateDescription vmstate_m_csselr = { .version_id = 1, .minimum_version_id = 1, .needed = m_csselr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(env.v7m.csselr, ARMCPU, M_REG_NUM_BANKS), VMSTATE_VALIDATE("CSSELR is valid", csselr_vmstate_validate), VMSTATE_END_OF_LIST() @@ -301,7 +301,7 @@ static const VMStateDescription vmstate_m_scr = { .version_id = 1, .minimum_version_id = 1, .needed = m_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.scr[M_REG_NS], ARMCPU), VMSTATE_END_OF_LIST() } @@ -312,7 +312,7 @@ static const VMStateDescription vmstate_m_other_sp = { .version_id = 1, .minimum_version_id = 1, .needed = m_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.other_sp, ARMCPU), VMSTATE_END_OF_LIST() } @@ -331,7 +331,7 @@ static const VMStateDescription vmstate_m_v8m = { .version_id = 1, .minimum_version_id = 1, .needed = m_v8m_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(env.v7m.msplim, ARMCPU, M_REG_NUM_BANKS), VMSTATE_UINT32_ARRAY(env.v7m.psplim, ARMCPU, M_REG_NUM_BANKS), VMSTATE_END_OF_LIST() @@ -343,7 +343,7 @@ static const VMStateDescription vmstate_m_fp = { .version_id = 1, .minimum_version_id = 1, .needed = vfp_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(env.v7m.fpcar, ARMCPU, M_REG_NUM_BANKS), VMSTATE_UINT32_ARRAY(env.v7m.fpccr, ARMCPU, M_REG_NUM_BANKS), VMSTATE_UINT32_ARRAY(env.v7m.fpdscr, ARMCPU, M_REG_NUM_BANKS), @@ -365,7 +365,7 @@ static const VMStateDescription vmstate_m_mve = { .version_id = 1, .minimum_version_id = 1, .needed = mve_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.vpr, ARMCPU), VMSTATE_UINT32(env.v7m.ltpsize, ARMCPU), VMSTATE_END_OF_LIST() @@ -377,7 +377,7 @@ static const VMStateDescription vmstate_m = { .version_id = 4, .minimum_version_id = 4, .needed = m_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.vecbase[M_REG_NS], ARMCPU), VMSTATE_UINT32(env.v7m.basepri[M_REG_NS], ARMCPU), VMSTATE_UINT32(env.v7m.control[M_REG_NS], ARMCPU), @@ -391,7 +391,7 @@ static const VMStateDescription vmstate_m = { VMSTATE_INT32(env.v7m.exception, ARMCPU), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_m_faultmask_primask, &vmstate_m_csselr, &vmstate_m_scr, @@ -416,7 +416,7 @@ static const VMStateDescription vmstate_thumb2ee = { .version_id = 1, .minimum_version_id = 1, .needed = thumb2ee_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.teecr, ARMCPU), VMSTATE_UINT32(env.teehbr, ARMCPU), VMSTATE_END_OF_LIST() @@ -445,7 +445,7 @@ static const VMStateDescription vmstate_pmsav7 = { .version_id = 1, .minimum_version_id = 1, .needed = pmsav7_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(env.pmsav7.drbar, ARMCPU, pmsav7_dregion, 0, vmstate_info_uint32, uint32_t), VMSTATE_VARRAY_UINT32(env.pmsav7.drsr, ARMCPU, pmsav7_dregion, 0, @@ -474,7 +474,7 @@ static const VMStateDescription vmstate_pmsav7_rnr = { .version_id = 1, .minimum_version_id = 1, .needed = pmsav7_rnr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.pmsav7.rnr[M_REG_NS], ARMCPU), VMSTATE_END_OF_LIST() } @@ -504,7 +504,7 @@ static const VMStateDescription vmstate_pmsav8r = { .version_id = 1, .minimum_version_id = 1, .needed = pmsav8r_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(env.pmsav8.hprbar, ARMCPU, pmsav8r_hdregion, 0, vmstate_info_uint32, uint32_t), VMSTATE_VARRAY_UINT32(env.pmsav8.hprlar, ARMCPU, @@ -518,7 +518,7 @@ static const VMStateDescription vmstate_pmsav8 = { .version_id = 1, .minimum_version_id = 1, .needed = pmsav8_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(env.pmsav8.rbar[M_REG_NS], ARMCPU, pmsav7_dregion, 0, vmstate_info_uint32, uint32_t), VMSTATE_VARRAY_UINT32(env.pmsav8.rlar[M_REG_NS], ARMCPU, pmsav7_dregion, @@ -527,7 +527,7 @@ static const VMStateDescription vmstate_pmsav8 = { VMSTATE_UINT32(env.pmsav8.mair1[M_REG_NS], ARMCPU), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_pmsav8r, NULL } @@ -560,7 +560,7 @@ static const VMStateDescription vmstate_m_security = { .version_id = 1, .minimum_version_id = 1, .needed = m_security_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.v7m.secure, ARMCPU), VMSTATE_UINT32(env.v7m.other_ss_msp, ARMCPU), VMSTATE_UINT32(env.v7m.other_ss_psp, ARMCPU), @@ -888,7 +888,7 @@ const VMStateDescription vmstate_arm_cpu = { .post_save = cpu_post_save, .pre_load = cpu_pre_load, .post_load = cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(env.regs, ARMCPU, 16), VMSTATE_UINT64_ARRAY(env.xregs, ARMCPU, 32), VMSTATE_UINT64(env.pc, ARMCPU), @@ -937,7 +937,7 @@ const VMStateDescription vmstate_arm_cpu = { }, VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_vfp, &vmstate_iwmmxt, &vmstate_m, From patchwork Fri Dec 29 21:22:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758819 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671672wrw; Fri, 29 Dec 2023 13:28:57 -0800 (PST) X-Google-Smtp-Source: AGHT+IHhn/UvIIkF1LR3Wp1Dcd5IlcCOuT7BmzekcsVW4M5sRlAejctUDOx3DSUXR5UE7A/3Uo6c X-Received: by 2002:a05:622a:210:b0:428:c2e:11f6 with SMTP id b16-20020a05622a021000b004280c2e11f6mr900345qtx.12.1703885337340; Fri, 29 Dec 2023 13:28:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885337; cv=none; d=google.com; s=arc-20160816; b=VYscUvKNTfRTHJSZvcasje1zGV91Iukt9WL1yiis+nGoWfXezIfipxHcAo+ThQL+Hk Tlqar9QPYL54YquPKwZTzTxKDw1bhb/7miqkBWzM2dqTb/YGqEqB/SqJkLriFe4eSpOU B6YbSdcRlofqXDCCKVI4qJg+RLHuz0y1ewXov1Z70zvAV8Pr17wHQdAMKBcKrGEyXkMJ mZ2nuRwIVQn0wyCHadQEevrM2teICIYUM1zi3afkbdNOxSWNg68pZhC0EwVoP3rXt3c1 HqFyLKjBFicNtZSl96IgAGfHG0Ky7xJZNVCpmnUIA2GNjiLRrqlf05bbo7XwdqPoFM0x nmQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=gT4WX0PoL92afkyPoSUzD3XqpdNjfk+jVfvP3kUng1I=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=LalEKkmUqPZjlfVGOF/JaxeBI+MF8INY4jHBAdlzhFQnCx3ic5rMO6DH3vcQwL3lk+ po9i4o2dB+bTy71W58MVpQ7CYZ7F8KGRGbDA3BytSBScPAt7IVJNNJYDsgOaA8FwN2Gw tcbuBuVjdqa0Y/kIxTLxkU759gg7n8ooU4Y2No3iw8hkrqb0uNsQc9RODTnPbosHkR7k ISzxGIUW5qZVFEzxT6zHtb5Uqlo584MUhL0cH3zfIfJSH8g5FbJ1y+iti5UVdqhNarhO WKVyqJsygjOiR3OkPi41GlDonz/EHp+bDbMvzl/XAGjBvdqY9iu1+ksdH+Qel9yLsCSz MWPg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Kis/vHPo"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y13-20020a05622a164d00b00427759a44a8si19715203qtj.452.2023.12.29.13.28.57 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:57 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Kis/vHPo"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKKr-0006qy-Hz; Fri, 29 Dec 2023 16:24:05 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKKq-0006qK-9Z for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:04 -0500 Received: from mail-il1-x12d.google.com ([2607:f8b0:4864:20::12d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKo-0005uT-Tk for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:04 -0500 Received: by mail-il1-x12d.google.com with SMTP id e9e14a558f8ab-35fea35c432so47816355ab.0 for ; Fri, 29 Dec 2023 13:24:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885041; x=1704489841; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=gT4WX0PoL92afkyPoSUzD3XqpdNjfk+jVfvP3kUng1I=; b=Kis/vHPo+GYe7FN/5zdb9g+TVWCseXjdHFFa6N0tLutCiJ+3BDzOiNrJkkAJpjRexH p7fcbGCfTOPYB/tUa0/fVN9E//ZL1xYrcX7wXEy8FwGZqwJt1OrmQs+y5ZIRp1EipkeU dciuGnvD1avfPDdzXI37RPlT1sSg0igwyaUSpFXgCe2zvvWifTT7FceJ2eWg+gD2a5V+ F1PmGGspdskWZKM8AZiv9rsy5UXxwOmAa6C+1Vevqlwhw7253fDUoyx8Oo73KNm0sZM7 a4pmmS31IBSPOiycRW6JQr0ns+Pt+PQwUmaMitRo4pBZTUt6CigvtbJja2M4q45IxzXy tmow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885041; x=1704489841; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gT4WX0PoL92afkyPoSUzD3XqpdNjfk+jVfvP3kUng1I=; b=eHDcE9hjw67xTywY/ai9X96O9XIKtNbc4vTz4l4fH4ZDvZlOy8BmQe1VcnvDg88RSy 5dO3beRAyd9QxeNUHWE5CeeWXlKi8bHEeB2AzcYkekCuWLRJwtmBjCEZALmAM6dygZSR X7YiaMm2PTACwFMkJ8u8qGWGpXMH5WqYoeAmG3TLipcpf/8wOuI1yUjBxLGkhhURniI/ y6/YleJgaHXIVI6rF0Tv/VfWDxsGwSlJoKfWJm0tcBuwPWzJIt1RTcvqjOup6r1+BKkM p9iorz7zGgP/mCz41pl4B208Y32ArsBwU/w8+u6rg3xUu1Cy+lMb/lsbl9cBWqi29biy EIhQ== X-Gm-Message-State: AOJu0YyH8rL9pbnIiEDMAEmHwbk7+Uo5W0qizGZtAi386NG5wSlXobZM 5sG8Au6zR0mgn44q6QTbAgI3a1uXYLQ24kZLvUQtRB/LfmApxg== X-Received: by 2002:a92:c267:0:b0:35d:a84e:f729 with SMTP id h7-20020a92c267000000b0035da84ef729mr20321997ild.63.1703885041637; Fri, 29 Dec 2023 13:24:01 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.23.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:01 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 03/71] target/arm: Constify hvf/hvf.c Date: Sat, 30 Dec 2023 08:22:38 +1100 Message-Id: <20231229212346.147149-4-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::12d; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x12d.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-4-richard.henderson@linaro.org> --- target/arm/hvf/hvf.c | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/target/arm/hvf/hvf.c b/target/arm/hvf/hvf.c index 757e13b0f9..203d88f80b 100644 --- a/target/arm/hvf/hvf.c +++ b/target/arm/hvf/hvf.c @@ -36,7 +36,7 @@ #define MDSCR_EL1_SS_SHIFT 0 #define MDSCR_EL1_MDE_SHIFT 15 -static uint16_t dbgbcr_regs[] = { +static const uint16_t dbgbcr_regs[] = { HV_SYS_REG_DBGBCR0_EL1, HV_SYS_REG_DBGBCR1_EL1, HV_SYS_REG_DBGBCR2_EL1, @@ -54,7 +54,8 @@ static uint16_t dbgbcr_regs[] = { HV_SYS_REG_DBGBCR14_EL1, HV_SYS_REG_DBGBCR15_EL1, }; -static uint16_t dbgbvr_regs[] = { + +static const uint16_t dbgbvr_regs[] = { HV_SYS_REG_DBGBVR0_EL1, HV_SYS_REG_DBGBVR1_EL1, HV_SYS_REG_DBGBVR2_EL1, @@ -72,7 +73,8 @@ static uint16_t dbgbvr_regs[] = { HV_SYS_REG_DBGBVR14_EL1, HV_SYS_REG_DBGBVR15_EL1, }; -static uint16_t dbgwcr_regs[] = { + +static const uint16_t dbgwcr_regs[] = { HV_SYS_REG_DBGWCR0_EL1, HV_SYS_REG_DBGWCR1_EL1, HV_SYS_REG_DBGWCR2_EL1, @@ -90,7 +92,8 @@ static uint16_t dbgwcr_regs[] = { HV_SYS_REG_DBGWCR14_EL1, HV_SYS_REG_DBGWCR15_EL1, }; -static uint16_t dbgwvr_regs[] = { + +static const uint16_t dbgwvr_regs[] = { HV_SYS_REG_DBGWVR0_EL1, HV_SYS_REG_DBGWVR1_EL1, HV_SYS_REG_DBGWVR2_EL1, @@ -2010,7 +2013,7 @@ static const VMStateDescription vmstate_hvf_vtimer = { .name = "hvf-vtimer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(vtimer_val, HVFVTimer), VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:22:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758794 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670870wrw; Fri, 29 Dec 2023 13:25:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IHBzEP3dhepL/L9amGnn6C2f/8u2NnlOgM3gSn6QkRHy+uSWw8h7CuNSoWiJ4of5DOzhqZN X-Received: by 2002:a05:6214:e47:b0:67f:e29:d4f4 with SMTP id o7-20020a0562140e4700b0067f0e29d4f4mr13245724qvc.14.1703885144766; Fri, 29 Dec 2023 13:25:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885144; cv=none; d=google.com; s=arc-20160816; b=Qlae+9TvQIhK0fIw0fzcU0UpcTaV22CFLw3RT1q3huZHSm9d7pdvwoJsOhkXNaQtcT VjFwFmkXLLOGb3VtVes8Hvfr6ZNmsEslAGqCSRFeyHd1pkykPYjPcBMySyQrgBIGQkrT 8kW0UNw8Fl/9lMRKS13eWF1XsVwWoWu2iszgoaJQVKU18p3TSGR438bUgakPOWjZdHTe vHaVg7DTj2SmhDRIOaBK/rfxdkIW+fXWNwV1zXrU15MTnjjJyqsELnsAmgvCDejkd2yD V9tKRU59w4E9Rm+b1A00DHiXzbJjk45aaD5E2rSsjjqCTjP7sPNtHDRfKoQQrOyIyhLP 54uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Te0syHdSvAn6waobc73q7nKB4LmwnyEhA4q5YcHJ4/8=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=RlUZAzK/fDHrXwYJoSgshUjmAUBHX4Vtxn3AObqejkB+IEvcMDCJHc1yTThXG4TyfB hSRu+5ZkSRsMDvyeKNvxFy8o0lZ0aLM3XkEzhb6KKvvkDe8aKVw6Hua7PDS/Sj47q9ON tspJ2MKpI+DXSa4C6ohtRLegkq4Pv/OxxaqwpXs6y5y9aHAQG0QAKaIkuupWOpdK9I9w fGJXoaZnz+dz1tKOCRUIT4efMslsE7lRNKBEA1294JqHmydKsTJMZfd67jAGshV6TRlV tSPHNKtw4TLfwmc0M53eVOJnm9saN/WpPv6g7PYETWnjDdvGaX9uI0OveGJNksUASEIo WRyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aD8hvsou; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id d27-20020a0cb2db000000b0067f70fc7fcdsi19380712qvf.405.2023.12.29.13.25.44 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:44 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aD8hvsou; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKL2-0006sD-Bn; Fri, 29 Dec 2023 16:24:18 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKKx-0006ra-Cu for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:12 -0500 Received: from mail-pl1-x631.google.com ([2607:f8b0:4864:20::631]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKr-0005xb-JX for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:11 -0500 Received: by mail-pl1-x631.google.com with SMTP id d9443c01a7336-1d427518d52so36463235ad.0 for ; Fri, 29 Dec 2023 13:24:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885044; x=1704489844; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Te0syHdSvAn6waobc73q7nKB4LmwnyEhA4q5YcHJ4/8=; b=aD8hvsouABLKVV6O/R2AKm5vkOgfkF8Li1w2M6ljeRx5JKirpvohG7Yhe9N1I1WxjT iTOGqM+2ivWxwimsPyOz03knSRMSEtiVqKq8aEVz7Cbb1V4lqt8kybbpczQ4Qi8SN+TA 05GOf+jDE5SvYT+PMgNnCxCZPYLH5TlOYw9yy91camh6OgqARiNNd+ig+jH6T7LUtQAm RZ/+BkLr/gAO3IhxQ7pxVIEbBlPW7YZy1TeHcvDvg2NzoL84te/w+q0GXbk6t16hVls8 ZnAb3xXAp/u8sp4a5+osdzoBJUm9SZlV1QpGh++moYwRWDp/4ZvoITfrTPL8IG5lkE3T 1ymg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885044; x=1704489844; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Te0syHdSvAn6waobc73q7nKB4LmwnyEhA4q5YcHJ4/8=; b=C2QnB+9BFCwVXDjuLiwBmJ58JtkbMJKQUZOGnN37Hls0luGwbNCPHVpGrG6/2RIMzT oCZTvwVsLullpbq9vZSquuwNmtScaP0ExoflKNBsD6UllS2AFqqWI0TNkO9LOj0iM3Wr Z0H9EqNNPQ7GOC5S+DgFQc6O75XMSettVZkf00EiMhVy2zHVTyDkuPY6PiRACAAMVTgB +CQXTQvORWPy9ZK9I5FNaWHi1eVGYgKo2pn5njTiFfVWaQgqKcwPd9Oxq2jAF+iwxj9t jqzg1MQ1MxSAJ0e3ZEB8ni5AcqeuYs4kzVhrcRU7qxb6voiRYZND4Qls6dc93/0HyNBQ ojBA== X-Gm-Message-State: AOJu0YwNIql8mlT0ldv89aesSbOQSGybofW7N4xtaVzN+IUQIqD1zOlE L4pYqr2LVUjpCiaT0lRuK0Jj1sBfAT/tPsA3EEzsFsPbcA/HHA== X-Received: by 2002:a17:902:74c4:b0:1d3:bceb:ba62 with SMTP id f4-20020a17090274c400b001d3bcebba62mr15614893plt.45.1703885043950; Fri, 29 Dec 2023 13:24:03 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:03 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 04/71] target/alpha: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:39 +1100 Message-Id: <20231229212346.147149-5-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::631; envelope-from=richard.henderson@linaro.org; helo=mail-pl1-x631.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-5-richard.henderson@linaro.org> --- target/alpha/machine.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target/alpha/machine.c b/target/alpha/machine.c index 2b7c8148ff..f09834f635 100644 --- a/target/alpha/machine.c +++ b/target/alpha/machine.c @@ -24,7 +24,7 @@ static const VMStateInfo vmstate_fpcr = { .put = put_fpcr, }; -static VMStateField vmstate_env_fields[] = { +static const VMStateField vmstate_env_fields[] = { VMSTATE_UINTTL_ARRAY(ir, CPUAlphaState, 31), VMSTATE_UINTTL_ARRAY(fir, CPUAlphaState, 31), /* Save the architecture value of the fpcr, not the internally @@ -73,7 +73,7 @@ static const VMStateDescription vmstate_env = { .fields = vmstate_env_fields, }; -static VMStateField vmstate_cpu_fields[] = { +static const VMStateField vmstate_cpu_fields[] = { VMSTATE_CPU(), VMSTATE_STRUCT(env, AlphaCPU, 1, vmstate_env, CPUAlphaState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:22:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758810 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671485wrw; Fri, 29 Dec 2023 13:28:05 -0800 (PST) X-Google-Smtp-Source: AGHT+IHlCLD73rkKJ5sm9oTcU5ZUeaN8JyCLMF4c+6n88ExPYiSSSHQBDiq6JTmWJ0qcXbBc+EUF X-Received: by 2002:a05:6214:2d02:b0:67f:bb8c:87e2 with SMTP id mz2-20020a0562142d0200b0067fbb8c87e2mr11834129qvb.46.1703885285349; Fri, 29 Dec 2023 13:28:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885285; cv=none; d=google.com; s=arc-20160816; b=fGY/OPQvhqs4A+PBmu3DSdumvMo1YXYJW5JCDh4lFf0qtxkpmNnD/TfOCAnYPw4bly GhdJVxRUrXqzGR3p8BG5nuNillb9ICw/hrRB3OSrJ9zCGKQ9U7ZPggsZTPD7IjpGQ2lQ GaEgU3n+dm/D0EOXWHD1VKzzx9/YRG5qnM3em6BApTUQfEb8TXvB1udOjoqObbSCDMUo nYbq1NwgwEEQC37kRGQLs1I8qbWmEcMbBVCkweWWYJn9st3RfVquu2RtTnC0RWv0ePWu wufMFfjJZ6RL1slkIoRqUuRsTmOL3ofRaQTW8a9FcGTbFIaRkwlb6BIJoEPW7YcRhdt1 ocbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=nyDvxTucZvevaETcjw9mADYnujp4cVpiY3zTBw5hjb4=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=xu+BDVkKk5xYP3pHme5GFa5x8KjROL7uorpNAD9TFMwNhBRHoLImdy2prOZGSKijbx AjYYpx6qCzRwonLN4eyuCJH9E/QwNBg15jO8xJf/mqtMGgBPsA/gPdhrcGfpjJhDe1p7 GyunLq53pMn6sGLRmWmozL62YymcU4huRzhcJrLPvLVPAy4QtaTGHiiL56XtPPVfw18e LDghw0jbjM0pWESQcJhYkvnkDkOGGkq/b6a8ApZqemWbrbcee7N30KhuzxyOvEtZuwBj QXf2FuJ7MjvbjnUm+HO0jvOO3a8JYs2hpyrWIun6tsn9E2GMcoAteh6APSQy2ciYWDgY sj9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZoCG+U07; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id p18-20020a05622a13d200b0042612900969si20125521qtk.591.2023.12.29.13.28.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:05 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZoCG+U07; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKL0-0006s8-GD; Fri, 29 Dec 2023 16:24:14 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKKv-0006rC-Au for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:10 -0500 Received: from mail-pg1-x52f.google.com ([2607:f8b0:4864:20::52f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKt-00063m-Pp for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:09 -0500 Received: by mail-pg1-x52f.google.com with SMTP id 41be03b00d2f7-5bdbe2de25fso5598121a12.3 for ; Fri, 29 Dec 2023 13:24:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885046; x=1704489846; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=nyDvxTucZvevaETcjw9mADYnujp4cVpiY3zTBw5hjb4=; b=ZoCG+U075binTMh1vSNKOUHcZQtIT1CwnyLr3n1qPiDAJ2UWPP8O7f0FP+dy18Xz2V VIgb+jHp6oN3HvjZFlBg+KYlMUb1n3sbdFWVsoWLleJ8h8+j52EahEPZ2R3h0QEMZgZC bc8t2lPki3S0Xw2UIeJX+pjxy906iMqp3gcRaDzWjubXZJxhTjpaXgSIin2HFe9ERZgo sFM6rsqrl8wljFkNWRmqIkyBVIfn749vjH5NoN0puDAlhog5KdQoAHmG4/7Z10itphdn U7/I9dzSQrJxQx2t8/valMt1ugOeRMEtIxZo+FWA7n5TeGSmqvjm5dB4nc69hQLbKZYb PTFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885046; x=1704489846; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=nyDvxTucZvevaETcjw9mADYnujp4cVpiY3zTBw5hjb4=; b=IQPi+N+9C1r6tMgdwvSK6JTwn5x2YrryCyXk6/aIyjtDP/dnyIjxODkRwgHfNuYjTJ PJDNEehsJmcT52PVokZd8XXrZyYtAN8Y6ikiTG+xREGscgHCzlbYQHR5Jt9goWq2jbUa BkRVMQupSYRcIQ75H7IMYSF6f9OVORH9rmVDzGaoVJxPaFP4p6zNI2oS2tW8AhtaZpuo O9QXMgB03zeAMVNx0lbgd1WghK0nl9BIP21EpWhR0cSl3BtFTpYjSxEvUUUgWAB8i1X/ A0g1pyh/jsHYng94RfaLtIjSnDWoAnkTjUTz66/A/3OjheFjsMWg0thEQgixV/bEPYdb 5g1Q== X-Gm-Message-State: AOJu0Yy9eEkjFvEagPnYhK3TM0gxC/2s/s2Ds5+ysoHjPu5ycccKryC5 bn+CVm5rA+6tIeKOMj9GiG12qirwTP4uo9MewJSZpgmHRIUB0w== X-Received: by 2002:a05:6a20:5518:b0:18d:64a:e125 with SMTP id ko24-20020a056a20551800b0018d064ae125mr12740578pzb.31.1703885046375; Fri, 29 Dec 2023 13:24:06 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:05 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 05/71] target/avr: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:40 +1100 Message-Id: <20231229212346.147149-6-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52f; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52f.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-6-richard.henderson@linaro.org> --- target/avr/machine.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/avr/machine.c b/target/avr/machine.c index 16f7a3e031..4402862fb9 100644 --- a/target/avr/machine.c +++ b/target/avr/machine.c @@ -100,7 +100,7 @@ const VMStateDescription vms_avr_cpu = { .name = "cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.pc_w, AVRCPU), VMSTATE_UINT32(env.sp, AVRCPU), VMSTATE_UINT32(env.skip, AVRCPU), From patchwork Fri Dec 29 21:22:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758801 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670960wrw; Fri, 29 Dec 2023 13:26:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IGuAsdxKuYFKEGGUxcWIIGOQGWK2ssnnwOy+iqALEERSXuYL+woP5BtoqhepDI4gTKtycoR X-Received: by 2002:a05:622a:50e:b0:427:95fa:5a40 with SMTP id l14-20020a05622a050e00b0042795fa5a40mr18130481qtx.124.1703885163674; Fri, 29 Dec 2023 13:26:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885163; cv=none; d=google.com; s=arc-20160816; b=ZfDYLkX/I3grImYUUMe4i4Tao+sIhEa4a1vM+2O9n5KIoXoRTlKEyPXNK/guTmwLv8 V8ipybknWbD3k3Vb1AdO7SqEsl1VUpaIAMeQLUoOhoVQRoj5MFI/jCsj7ZrFBgJSrZcE uxdWmcqtAALRFNC7TohLnUTtILXWrG470FZWjyc+NLPot8DNbx+O0oFf/2/v92Eqizae 8QAvYcFA6Zxl+Mjl4Tk97cZ23ddG0nXUsM7f+w438h1TqYrAAGFtvkqojRZCpSdAQYIr DqdsXZ4+1vItDJRQ6Fub/sAnvptOm6XXWLQ/VxqHIeChbWohF1CGO2oQ31tNA5zq1AiX Hfig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=0BYi4NVrnMs7H/Gj4Nqxzy7vtCBJeOHIeFvnPCuOWVk=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=eYBfE3ziByeWuU31sqW8ZjgCqzPCmD56NG5v47RW4LTZ2+eqSy67LfAnmMUDSyMrnx OzFBN/7JUKiQZ5Nv/Xbh+JynkzeDOQYuTrVqw5RboM0iwX1rouallW0RgiJHDfW7xNgq /chUUsS17yojzp1zmHMyuJgkChyIiNO/Y7Pknjsr9V2UMP+Fb5vo8hxJ591YdAzq9N3u iPyntTwEmXCGmdnZ911GOdhXR9sGISAPrvPqg5gv705xfTYKCRy8pvmDpYcm6jC9oN3d d0zomgrwlVA6jLIJWYfwCR88VHyNUUGtWfNMtJuTi+5WMV0MBKOrxDr5HngsLvaIiVIn TrbA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=lwygizme; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id fg5-20020a05622a580500b00427fa8c8799si4689164qtb.660.2023.12.29.13.26.03 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:26:03 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=lwygizme; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKL8-0006vf-I8; Fri, 29 Dec 2023 16:24:23 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL0-0006sC-Lf for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:16 -0500 Received: from mail-pg1-x52c.google.com ([2607:f8b0:4864:20::52c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKx-0006DL-QG for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:13 -0500 Received: by mail-pg1-x52c.google.com with SMTP id 41be03b00d2f7-5bdb0be3591so5597123a12.2 for ; Fri, 29 Dec 2023 13:24:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885049; x=1704489849; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=0BYi4NVrnMs7H/Gj4Nqxzy7vtCBJeOHIeFvnPCuOWVk=; b=lwygizmehueCII5/ENz3EqXOWkNrg4oVrc3BQfCUKWzzSDE8axGNnvHTvbq7ldunQs LUVU7h4PP+CaUgGxNhXWySis4v6aAvI7BNUdew4i2nT7d1R4E8NHhCq9zG66Iop7Ofzf UEeCKu2z24pp36hdXSQKhA7IINx/wiQq2L0FE0YYmCkVzyt3L834cEJp+dLbWXmyWmj2 qlOUiLxm8dP8Im9xNaazUvGFtBDLs3ZP2hD/drunjnEujto6Y9c5FBzPoSiQbno09JxA mq3KxXNau1G71SYVvfHQ7PNOn6kKkVeT+5rs8JCXWeKwTg+6Ynk347lkeCy37OiJX/lb HmkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885049; x=1704489849; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=0BYi4NVrnMs7H/Gj4Nqxzy7vtCBJeOHIeFvnPCuOWVk=; b=HkotdTLE3gsWHlmyWEs/aSPmmfyNvpqYOmg2dBrVoGVi8+vazJeTp+EWsppFh4MjN2 RNhTqWzkCBa9t6hKHp89qBaGu1HOrOkzKgFhpYSj+5b48CX6sGk96fPBXJ8vBia74R0y 9Mkm+xI8BAifabD9lxolxkTUkchjEFmKyx/87Uw9adZozIvMs2Jq/MXJ1Cmnd7ljf91Z KtikaOPu/FqqKR0IXpctJyQ4DB4yySC4R/+yRabuPAZaK22MVOudWLmLj/+pfp0I5x3Z K4QuyiNqUjpq4//7F0eXbFzYWeIrylhK7tKFykVDC4FY/Ar8lAocIfar3izD/SAH5WWa nEfg== X-Gm-Message-State: AOJu0YwT/P4qkzowkTUdg8zFUJCZDddwX6+dFm0KgMAUaZzdFftq2CWe qle7/Dqbi5V1V5XY4P9UaXlHehSYCZ6KHRJ9+Ih5kguSc/CFFw== X-Received: by 2002:a05:6a21:8185:b0:195:573:ce4f with SMTP id pd5-20020a056a21818500b001950573ce4fmr15107252pzb.20.1703885048800; Fri, 29 Dec 2023 13:24:08 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:08 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 06/71] target/cris: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:41 +1100 Message-Id: <20231229212346.147149-7-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52c; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-7-richard.henderson@linaro.org> --- target/cris/machine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target/cris/machine.c b/target/cris/machine.c index f370f33486..7b9bde872a 100644 --- a/target/cris/machine.c +++ b/target/cris/machine.c @@ -26,7 +26,7 @@ static const VMStateDescription vmstate_tlbset = { .name = "cpu/tlbset", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(lo, TLBSet), VMSTATE_UINT32(hi, TLBSet), VMSTATE_END_OF_LIST() @@ -37,7 +37,7 @@ static const VMStateDescription vmstate_cris_env = { .name = "env", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, CPUCRISState, 16), VMSTATE_UINT32_ARRAY(pregs, CPUCRISState, 16), VMSTATE_UINT32(pc, CPUCRISState), @@ -85,7 +85,7 @@ const VMStateDescription vmstate_cris_cpu = { .name = "cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CPU(), VMSTATE_STRUCT(env, CRISCPU, 1, vmstate_cris_env, CPUCRISState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:22:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758824 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671860wrw; Fri, 29 Dec 2023 13:29:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IEX6LgRGlpb3ExCoRfNfJFzdfgMICBnbjWUcgk82EYpjHEVnw2vLNV2pLsMvypGDh7dtbhe X-Received: by 2002:a05:622a:114:b0:425:4042:f44f with SMTP id u20-20020a05622a011400b004254042f44fmr16891850qtw.51.1703885385073; Fri, 29 Dec 2023 13:29:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885385; cv=none; d=google.com; s=arc-20160816; b=UMXW/l6LbEVIKrrpEl1Beqt7jVeTUPfDp6jW5OrYnyBRUM8CrwkzkUo0relActvL12 opnUVu/ReG5VbQedv1Z+9otQ7EIQHQHfvrSjgZI+BtPjhBYEz4IpwuKrDEZ6CQ79ZG+P 2YEpgpPbIcf7E24CbLvUhqjFthZRNmQDl1ixej3Rk4bd0sasrXyrYu5MS4lKp36KaCM2 VdxnqrHSSkApeJT6RFvitbpPKdYxTk+iJTJXuuBbHvzA8pha+W5/6S1ib4UapGstBKgl L+03ohBWc/4QV+4igB3mjuj0CXqqxrsVgMAVRarkEC7SSBENRKYW9cd+EavFy4yBMz3Z Nu/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Qey0fjhrVWPpPqjaLWiAWIvGaxQY0g0jcM6s2r3zWX0=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=DvIBvXOIucO9lvaSMPe6rPjpCvA/jlBZQwkYuQ8rLKXvfSkJsHieLwBsJe3gw5qTN/ 0cIuXCcoomPM9lKwizXay3FkwnnlpA/F+rz75FcCM75CWep+n7A8qPwklCfWTC/5YUBv 3q+AQVnAheoeLbaN4821Ml71HsUzZTRpG7DIeRa+qeDyAobkNGClIqAK6U1t5eV88MyF A7c86uD0k+yWlPW8iCM6UEdhAGDP5LcYxO7/5adAAeXxzfk+UF34BONe+oQ+9z/yvcWT x+gnD0mnqUTKbEVZuRFAQcMpKyGnX13woj+NmwL1qxGDH8T+yiT62e9pr1DDJB5ndtez 0yiA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Gjl1j3+Z; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b17-20020a05622a021100b00427eeefbed4si6228443qtx.467.2023.12.29.13.29.44 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:45 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Gjl1j3+Z; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLA-0006vt-6F; Fri, 29 Dec 2023 16:24:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL2-0006t0-HZ for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:18 -0500 Received: from mail-pg1-x530.google.com ([2607:f8b0:4864:20::530]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKKy-0006J4-K6 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:14 -0500 Received: by mail-pg1-x530.google.com with SMTP id 41be03b00d2f7-5ce74ea4bf2so353316a12.0 for ; Fri, 29 Dec 2023 13:24:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885051; x=1704489851; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Qey0fjhrVWPpPqjaLWiAWIvGaxQY0g0jcM6s2r3zWX0=; b=Gjl1j3+Zu+BpkYS5vXp7qvAYJ0f0PZOQxiNO98CW0qm74qs6LjR05WtwIGLFvSN0Dt 2X7PTrq6Ddtabzqydz2CQ3rVkybC1jRPgwEDZeoIem5aU36O6MrXvJ7Hi1kgRQfZ3yMX VryxzfAje8U6d1xeC6oe9+HgTTXG/kAVuw5mwzFnttuZX4u4X1SMhzfXwxjZ2rBVSwai gznxlYt1WnEu5YuJ6lN3AieKE1aSmmpnv9FXHlTU5FxcOPMDTySSvjfxDn05RUCIJTwU kf7DB1Tq5U989CwBcoPuDKHHARpLmgGf91OcqZaaaszyi7tSsu8C0pDkrxT0VQH6r5Fo lKog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885051; x=1704489851; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Qey0fjhrVWPpPqjaLWiAWIvGaxQY0g0jcM6s2r3zWX0=; b=X9PR/P+DZvHdNJIBj4AdzohsAb5UjqXDySei1PUnKAfgBxbwdTJpHfH6b9O5D3ICpL GO/Vqci62OvQZxQrjqNA5qveo0Rw+atov42JiVfJgj+9R10xIYrlFa8qTkAI3EqD8wLF D8s8dgpL67RV/2SnCxhWmzE9DoDnP9p3oJHPLCTSko6lP0KiUUu4fub6ds8GiTJUhg9D sLO2NfEOHoPdNcitVgs9zLkYZ1nmnt06yd2+oXNoUULtBt6YufWLw+kyACOI8M/vRNF8 pg33ldMQBvIc5PS0d7ihK+564WP4mdQOfSKs/Vclm5UN/NfVtTL5oT3mfTDUfmQjLObz OmTQ== X-Gm-Message-State: AOJu0YyDOAkNU7apZAoV+5E3GciM68Z5DG26+X+c2zP/BJBg5KFUxi9c lqWW1sddYXoI/BuUoZbRzd0a0Zi+kcSN97qCMotn90vX+OmK/A== X-Received: by 2002:a05:6a20:9390:b0:196:a796:4a58 with SMTP id x16-20020a056a20939000b00196a7964a58mr328595pzh.32.1703885051028; Fri, 29 Dec 2023 13:24:11 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.09 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:10 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 07/71] target/hppa: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:42 +1100 Message-Id: <20231229212346.147149-8-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::530; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x530.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-8-richard.henderson@linaro.org> --- target/hppa/machine.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/hppa/machine.c b/target/hppa/machine.c index 15cbc5e6d0..211bfcf640 100644 --- a/target/hppa/machine.c +++ b/target/hppa/machine.c @@ -201,7 +201,7 @@ static const VMStateField vmstate_env_fields[] = { VMSTATE_END_OF_LIST() }; -static const VMStateDescription *vmstate_env_subsections[] = { +static const VMStateDescription * const vmstate_env_subsections[] = { &vmstate_tlb, NULL }; From patchwork Fri Dec 29 21:22:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758807 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671273wrw; Fri, 29 Dec 2023 13:27:17 -0800 (PST) X-Google-Smtp-Source: AGHT+IEe/vjTEJEAckcxLDmTIj9eJ6OpqrSh9SjkKh1SlSHgq2pxAoVEWh5UnM+iR8aUTkTQ+gP1 X-Received: by 2002:a05:6808:1242:b0:3bb:db16:af8d with SMTP id o2-20020a056808124200b003bbdb16af8dmr2952088oiv.59.1703885237289; Fri, 29 Dec 2023 13:27:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885237; cv=none; d=google.com; s=arc-20160816; b=HBF3JKMqgM7O9lVbYPfflaQKQJIjpJ3Tew0VGtR82TI0r3wJ6SZ4z3KqjbUDVbvtpf L0gpZQYYHaMKTfzYDkMLoIi3efIwrirpCRSFdFpWev7J+43vQqpIHW2U3KXF1xJu2Q0a Wa3Wm6hDf1EhSz8w5uIftJ6uyvYDve6tLTfiBAip/RXmkPP61qVzwNwtEEdSIBEG1/OC UiQ99cgxp4AMHrN2g0ThGgLe0KxDqk9PSlxbg/dGgzcpNc7MykT/RH7Cavn62iH45JzP SjeyAmg3E6wvvhIEif7/6Y1c/FU9i0y1PxDC7RccWwNMDdabtUIOsqNF9YnkAGCJU0HJ PFIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=kFO7RAJUqXH71mzo/s8NnyQP9pZH+bYMV+IP41+DcOk=; fh=GstYAhRjUP+ivyXSmazQSCet1zGHWK0juBUWG85sowQ=; b=NackEoLoMMXeCrFQCL4xi3MGx9A+S2hfFIz2WbefS/D6UX07Sjo1BPthJ73a7wgmbf fjaWRjY/3q2jcMgjjRTG7QxAClyB8waGXoqc2E4DH9YhwTFgI5wOkcvETHs8qXArFMCR W0MvDoS0BfCsHKLlwD9Gb9c7F7ImMMh3h2VMRLBe095MNhlKHs/mIlVeL3AbDfww7skQ APJcSkOYKX6S5LCHRriNeqyn6K7PjiI+e4v0XSksWgo6ZgXcGs713k8CszUrWSX6vZr5 Be8Ci4rG8/BHObjAsq9iEftZ8YuPy8taPY5/3SpXyW+x2zwH3tV5q823gYtUA8MIVWAc TkEQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=M4ezPhHg; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id h18-20020ac87d52000000b00427e0d5801esi9055918qtb.807.2023.12.29.13.27.17 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:17 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=M4ezPhHg; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLA-0006vy-PZ; Fri, 29 Dec 2023 16:24:24 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL5-0006ue-5S for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:20 -0500 Received: from mail-oa1-x33.google.com ([2001:4860:4864:20::33]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKL2-0006PK-9Q for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:18 -0500 Received: by mail-oa1-x33.google.com with SMTP id 586e51a60fabf-204301f2934so5196657fac.1 for ; Fri, 29 Dec 2023 13:24:14 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885053; x=1704489853; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=kFO7RAJUqXH71mzo/s8NnyQP9pZH+bYMV+IP41+DcOk=; b=M4ezPhHgPtlAbAfuFXoPaKHVzVOVlqdimRrKH65y2o5Lrdmic/EL8PhuE+Ped2Hdl/ 0uHOiwGX+TS5sEqtGLBozq/uakAvyjfnOxljB8gdgbgBY3x4U2+RULq3FapFxx209UQj wJo5atA6n5QAjjU/GnhXILz6hs68aas+57tC0RwC4dfu2jgZZLNoY1pmoqiDNPF3eNLH 4CulStzktgTjWfEjz9QB9zO1go8B0Exd49cOfT0rCYO36eQ4Ax4Ph8soBv5kY1W0u6nr lLyrS6v7vcLaifdLVtsJnOo5dfTNxmMcM/MfB5/hznAjWl4WI+hcaq619dx6praqAfXG hJfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885053; x=1704489853; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kFO7RAJUqXH71mzo/s8NnyQP9pZH+bYMV+IP41+DcOk=; b=AWr2GHu7AwToDW6DMEpuftOu+d7lambsXaYtPSqcW1amL2FgJj3ml+yPcwvvZEPTF8 Hp5WoG6fj6eAtvZtEsGqT2BxpUnQSQWUtuMdSFu4yNAAJTTxx9pERfEwAIs9JXJkrwEJ kWA56MRi4ye8nm1vUdx+CThIPZmeTk73ebkbk7yHneG5PUKw3lG6U06qtLG4Mq4ZaBFP m22Hzz0p23rkrfMXtETepEHZreg3XV1cYhcVaG2nSKsQ5YqT8fKwQrmHF7A006yFBfkc CVvja0oOe+2McTlQoxrNjPzmS0VBtNPbVLPhrO+6jkLqKGZWE1lRAjsNBZZr7JTQ0AJ8 mbGg== X-Gm-Message-State: AOJu0YzSVBUlfn8shl3MbYotai3N39tp3HH1qPIAuAvfEftq2uBWVCsG B190yhczn/xZ00JyHyy7tfECPl0b58Hq0oGXlW1iVhgD9/+OKw== X-Received: by 2002:a05:6870:178e:b0:204:6d0a:577b with SMTP id r14-20020a056870178e00b002046d0a577bmr11903266oae.21.1703885053562; Fri, 29 Dec 2023 13:24:13 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:13 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Zhao Liu Subject: [PULL 08/71] target/i386: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:43 +1100 Message-Id: <20231229212346.147149-9-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::33; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x33.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Reviewed-by: Zhao Liu Message-Id: <20231221031652.119827-9-richard.henderson@linaro.org> --- target/i386/machine.c | 128 +++++++++++++++++++++--------------------- 1 file changed, 64 insertions(+), 64 deletions(-) diff --git a/target/i386/machine.c b/target/i386/machine.c index a1041ef828..c3ae320814 100644 --- a/target/i386/machine.c +++ b/target/i386/machine.c @@ -18,7 +18,7 @@ static const VMStateDescription vmstate_segment = { .name = "segment", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(selector, SegmentCache), VMSTATE_UINTTL(base, SegmentCache), VMSTATE_UINT32(limit, SegmentCache), @@ -43,7 +43,7 @@ static const VMStateDescription vmstate_xmm_reg = { .name = "xmm_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ZMM_Q(0), ZMMReg), VMSTATE_UINT64(ZMM_Q(1), ZMMReg), VMSTATE_END_OF_LIST() @@ -59,7 +59,7 @@ static const VMStateDescription vmstate_ymmh_reg = { .name = "ymmh_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ZMM_Q(2), ZMMReg), VMSTATE_UINT64(ZMM_Q(3), ZMMReg), VMSTATE_END_OF_LIST() @@ -74,7 +74,7 @@ static const VMStateDescription vmstate_zmmh_reg = { .name = "zmmh_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ZMM_Q(4), ZMMReg), VMSTATE_UINT64(ZMM_Q(5), ZMMReg), VMSTATE_UINT64(ZMM_Q(6), ZMMReg), @@ -92,7 +92,7 @@ static const VMStateDescription vmstate_hi16_zmm_reg = { .name = "hi16_zmm_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ZMM_Q(0), ZMMReg), VMSTATE_UINT64(ZMM_Q(1), ZMMReg), VMSTATE_UINT64(ZMM_Q(2), ZMMReg), @@ -114,7 +114,7 @@ static const VMStateDescription vmstate_bnd_regs = { .name = "bnd_regs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(lb, BNDReg), VMSTATE_UINT64(ub, BNDReg), VMSTATE_END_OF_LIST() @@ -128,7 +128,7 @@ static const VMStateDescription vmstate_mtrr_var = { .name = "mtrr_var", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(base, MTRRVar), VMSTATE_UINT64(mask, MTRRVar), VMSTATE_END_OF_LIST() @@ -142,7 +142,7 @@ static const VMStateDescription vmstate_lbr_records_var = { .name = "lbr_records_var", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(from, LBREntry), VMSTATE_UINT64(to, LBREntry), VMSTATE_UINT64(info, LBREntry), @@ -201,7 +201,7 @@ static const VMStateDescription vmstate_fpreg_tmp = { .name = "fpreg_tmp", .post_load = fpreg_post_load, .pre_save = fpreg_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tmp_mant, x86_FPReg_tmp), VMSTATE_UINT16(tmp_exp, x86_FPReg_tmp), VMSTATE_END_OF_LIST() @@ -210,7 +210,7 @@ static const VMStateDescription vmstate_fpreg_tmp = { static const VMStateDescription vmstate_fpreg = { .name = "fpreg", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP(FPReg, x86_FPReg_tmp, vmstate_fpreg_tmp), VMSTATE_END_OF_LIST() } @@ -453,7 +453,7 @@ static const VMStateDescription vmstate_exception_info = { .version_id = 1, .minimum_version_id = 1, .needed = exception_info_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(env.exception_pending, X86CPU), VMSTATE_UINT8(env.exception_injected, X86CPU), VMSTATE_UINT8(env.exception_has_payload, X86CPU), @@ -475,7 +475,7 @@ static const VMStateDescription vmstate_steal_time_msr = { .version_id = 1, .minimum_version_id = 1, .needed = steal_time_msr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.steal_time_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -486,7 +486,7 @@ static const VMStateDescription vmstate_async_pf_msr = { .version_id = 1, .minimum_version_id = 1, .needed = async_pf_msr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.async_pf_en_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -497,7 +497,7 @@ static const VMStateDescription vmstate_async_pf_int_msr = { .version_id = 1, .minimum_version_id = 1, .needed = async_pf_int_msr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.async_pf_int_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -508,7 +508,7 @@ static const VMStateDescription vmstate_pv_eoi_msr = { .version_id = 1, .minimum_version_id = 1, .needed = pv_eoi_msr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.pv_eoi_en_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -519,7 +519,7 @@ static const VMStateDescription vmstate_poll_control_msr = { .version_id = 1, .minimum_version_id = 1, .needed = poll_control_msr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.poll_control_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -538,7 +538,7 @@ static const VMStateDescription vmstate_fpop_ip_dp = { .version_id = 1, .minimum_version_id = 1, .needed = fpop_ip_dp_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(env.fpop, X86CPU), VMSTATE_UINT64(env.fpip, X86CPU), VMSTATE_UINT64(env.fpdp, X86CPU), @@ -559,7 +559,7 @@ static const VMStateDescription vmstate_msr_tsc_adjust = { .version_id = 1, .minimum_version_id = 1, .needed = tsc_adjust_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.tsc_adjust, X86CPU), VMSTATE_END_OF_LIST() } @@ -578,7 +578,7 @@ static const VMStateDescription vmstate_msr_smi_count = { .version_id = 1, .minimum_version_id = 1, .needed = msr_smi_count_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_smi_count, X86CPU), VMSTATE_END_OF_LIST() } @@ -597,7 +597,7 @@ static const VMStateDescription vmstate_msr_tscdeadline = { .version_id = 1, .minimum_version_id = 1, .needed = tscdeadline_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.tsc_deadline, X86CPU), VMSTATE_END_OF_LIST() } @@ -624,7 +624,7 @@ static const VMStateDescription vmstate_msr_ia32_misc_enable = { .version_id = 1, .minimum_version_id = 1, .needed = misc_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_ia32_misc_enable, X86CPU), VMSTATE_END_OF_LIST() } @@ -635,7 +635,7 @@ static const VMStateDescription vmstate_msr_ia32_feature_control = { .version_id = 1, .minimum_version_id = 1, .needed = feature_control_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_ia32_feature_control, X86CPU), VMSTATE_END_OF_LIST() } @@ -670,7 +670,7 @@ static const VMStateDescription vmstate_msr_architectural_pmu = { .version_id = 1, .minimum_version_id = 1, .needed = pmu_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_fixed_ctr_ctrl, X86CPU), VMSTATE_UINT64(env.msr_global_ctrl, X86CPU), VMSTATE_UINT64(env.msr_global_status, X86CPU), @@ -706,7 +706,7 @@ static const VMStateDescription vmstate_mpx = { .version_id = 1, .minimum_version_id = 1, .needed = mpx_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BND_REGS(env.bnd_regs, X86CPU, 4), VMSTATE_UINT64(env.bndcs_regs.cfgu, X86CPU), VMSTATE_UINT64(env.bndcs_regs.sts, X86CPU), @@ -728,7 +728,7 @@ static const VMStateDescription vmstate_msr_hyperv_hypercall = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_hypercall_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_guest_os_id, X86CPU), VMSTATE_UINT64(env.msr_hv_hypercall, X86CPU), VMSTATE_END_OF_LIST() @@ -748,7 +748,7 @@ static const VMStateDescription vmstate_msr_hyperv_vapic = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_vapic_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_vapic, X86CPU), VMSTATE_END_OF_LIST() } @@ -767,7 +767,7 @@ static const VMStateDescription vmstate_msr_hyperv_time = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_time_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_tsc, X86CPU), VMSTATE_END_OF_LIST() } @@ -792,7 +792,7 @@ static const VMStateDescription vmstate_msr_hyperv_crash = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_crash_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.msr_hv_crash_params, X86CPU, HV_CRASH_PARAMS), VMSTATE_END_OF_LIST() } @@ -815,7 +815,7 @@ static const VMStateDescription vmstate_msr_hyperv_runtime = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_runtime_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_runtime, X86CPU), VMSTATE_END_OF_LIST() } @@ -855,7 +855,7 @@ static const VMStateDescription vmstate_msr_hyperv_synic = { .minimum_version_id = 1, .needed = hyperv_synic_enable_needed, .post_load = hyperv_synic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_synic_control, X86CPU), VMSTATE_UINT64(env.msr_hv_synic_evt_page, X86CPU), VMSTATE_UINT64(env.msr_hv_synic_msg_page, X86CPU), @@ -883,7 +883,7 @@ static const VMStateDescription vmstate_msr_hyperv_stimer = { .version_id = 1, .minimum_version_id = 1, .needed = hyperv_stimer_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.msr_hv_stimer_config, X86CPU, HV_STIMER_COUNT), VMSTATE_UINT64_ARRAY(env.msr_hv_stimer_count, X86CPU, HV_STIMER_COUNT), @@ -926,7 +926,7 @@ static const VMStateDescription vmstate_msr_hyperv_reenlightenment = { .minimum_version_id = 1, .needed = hyperv_reenlightenment_enable_needed, .post_load = hyperv_reenlightenment_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_hv_reenlightenment_control, X86CPU), VMSTATE_UINT64(env.msr_hv_tsc_emulation_control, X86CPU), VMSTATE_UINT64(env.msr_hv_tsc_emulation_status, X86CPU), @@ -970,7 +970,7 @@ static const VMStateDescription vmstate_avx512 = { .version_id = 1, .minimum_version_id = 1, .needed = avx512_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.opmask_regs, X86CPU, NB_OPMASK_REGS), VMSTATE_ZMMH_REGS_VARS(env.xmm_regs, X86CPU, 0), #ifdef TARGET_X86_64 @@ -993,7 +993,7 @@ static const VMStateDescription vmstate_xss = { .version_id = 1, .minimum_version_id = 1, .needed = xss_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.xss, X86CPU), VMSTATE_END_OF_LIST() } @@ -1012,7 +1012,7 @@ static const VMStateDescription vmstate_umwait = { .version_id = 1, .minimum_version_id = 1, .needed = umwait_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.umwait, X86CPU), VMSTATE_END_OF_LIST() } @@ -1031,7 +1031,7 @@ static const VMStateDescription vmstate_pkru = { .version_id = 1, .minimum_version_id = 1, .needed = pkru_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32(env.pkru, X86CPU), VMSTATE_END_OF_LIST() } @@ -1050,7 +1050,7 @@ static const VMStateDescription vmstate_pkrs = { .version_id = 1, .minimum_version_id = 1, .needed = pkrs_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32(env.pkrs, X86CPU), VMSTATE_END_OF_LIST() } @@ -1070,7 +1070,7 @@ static const VMStateDescription vmstate_tsc_khz = { .version_id = 1, .minimum_version_id = 1, .needed = tsc_khz_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(env.tsc_khz, X86CPU), VMSTATE_END_OF_LIST() } @@ -1090,7 +1090,7 @@ static const VMStateDescription vmstate_vmx_vmcs12 = { .version_id = 1, .minimum_version_id = 1, .needed = vmx_vmcs12_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(data.vmx[0].vmcs12, struct kvm_nested_state, KVM_STATE_NESTED_VMX_VMCS_SIZE), @@ -1110,7 +1110,7 @@ static const VMStateDescription vmstate_vmx_shadow_vmcs12 = { .version_id = 1, .minimum_version_id = 1, .needed = vmx_shadow_vmcs12_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(data.vmx[0].shadow_vmcs12, struct kvm_nested_state, KVM_STATE_NESTED_VMX_VMCS_SIZE), @@ -1131,13 +1131,13 @@ static const VMStateDescription vmstate_vmx_nested_state = { .version_id = 1, .minimum_version_id = 1, .needed = vmx_nested_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_U64(hdr.vmx.vmxon_pa, struct kvm_nested_state), VMSTATE_U64(hdr.vmx.vmcs12_pa, struct kvm_nested_state), VMSTATE_U16(hdr.vmx.smm.flags, struct kvm_nested_state), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_vmx_vmcs12, &vmstate_vmx_shadow_vmcs12, NULL, @@ -1162,7 +1162,7 @@ static const VMStateDescription vmstate_svm_nested_state = { .version_id = 1, .minimum_version_id = 1, .needed = svm_nested_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_U64(hdr.svm.vmcb_pa, struct kvm_nested_state), VMSTATE_UINT8_ARRAY(data.svm[0].vmcb12, struct kvm_nested_state, @@ -1232,13 +1232,13 @@ static const VMStateDescription vmstate_kvm_nested_state = { .name = "cpu/kvm_nested_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_U16(flags, struct kvm_nested_state), VMSTATE_U16(format, struct kvm_nested_state), VMSTATE_U32(size, struct kvm_nested_state), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_vmx_nested_state, &vmstate_svm_nested_state, NULL @@ -1251,7 +1251,7 @@ static const VMStateDescription vmstate_nested_state = { .minimum_version_id = 1, .needed = nested_state_needed, .post_load = nested_state_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER(env.nested_state, X86CPU, vmstate_kvm_nested_state, struct kvm_nested_state), @@ -1269,7 +1269,7 @@ static const VMStateDescription vmstate_xen_vcpu = { .version_id = 1, .minimum_version_id = 1, .needed = xen_vcpu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.xen_vcpu_info_gpa, X86CPU), VMSTATE_UINT64(env.xen_vcpu_info_default_gpa, X86CPU), VMSTATE_UINT64(env.xen_vcpu_time_info_gpa, X86CPU), @@ -1295,7 +1295,7 @@ static const VMStateDescription vmstate_mcg_ext_ctl = { .version_id = 1, .minimum_version_id = 1, .needed = mcg_ext_ctl_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.mcg_ext_ctl, X86CPU), VMSTATE_END_OF_LIST() } @@ -1314,7 +1314,7 @@ static const VMStateDescription vmstate_spec_ctrl = { .version_id = 1, .minimum_version_id = 1, .needed = spec_ctrl_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT64(env.spec_ctrl, X86CPU), VMSTATE_END_OF_LIST() } @@ -1334,7 +1334,7 @@ static const VMStateDescription amd_tsc_scale_msr_ctrl = { .version_id = 1, .minimum_version_id = 1, .needed = amd_tsc_scale_msr_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT64(env.amd_tsc_scale_msr, X86CPU), VMSTATE_END_OF_LIST() } @@ -1367,7 +1367,7 @@ static const VMStateDescription vmstate_msr_intel_pt = { .version_id = 1, .minimum_version_id = 1, .needed = intel_pt_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_rtit_ctrl, X86CPU), VMSTATE_UINT64(env.msr_rtit_status, X86CPU), VMSTATE_UINT64(env.msr_rtit_output_base, X86CPU), @@ -1391,7 +1391,7 @@ static const VMStateDescription vmstate_msr_virt_ssbd = { .version_id = 1, .minimum_version_id = 1, .needed = virt_ssbd_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT64(env.virt_ssbd, X86CPU), VMSTATE_END_OF_LIST() } @@ -1410,7 +1410,7 @@ static const VMStateDescription vmstate_svm_npt = { .version_id = 1, .minimum_version_id = 1, .needed = svm_npt_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT64(env.nested_cr3, X86CPU), VMSTATE_UINT32(env.nested_pg_mode, X86CPU), VMSTATE_END_OF_LIST() @@ -1430,7 +1430,7 @@ static const VMStateDescription vmstate_svm_guest = { .version_id = 1, .minimum_version_id = 1, .needed = svm_guest_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32(env.int_ctl, X86CPU), VMSTATE_END_OF_LIST() } @@ -1450,7 +1450,7 @@ static const VMStateDescription vmstate_efer32 = { .version_id = 1, .minimum_version_id = 1, .needed = intel_efer32_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.efer, X86CPU), VMSTATE_END_OF_LIST() } @@ -1470,7 +1470,7 @@ static const VMStateDescription vmstate_msr_tsx_ctrl = { .version_id = 1, .minimum_version_id = 1, .needed = msr_tsx_ctrl_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.tsx_ctrl, X86CPU), VMSTATE_END_OF_LIST() } @@ -1489,7 +1489,7 @@ static const VMStateDescription vmstate_msr_intel_sgx = { .version_id = 1, .minimum_version_id = 1, .needed = intel_sgx_msrs_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.msr_ia32_sgxlepubkeyhash, X86CPU, 4), VMSTATE_END_OF_LIST() } @@ -1517,7 +1517,7 @@ static const VMStateDescription vmstate_pdptrs = { .minimum_version_id = 1, .needed = pdptrs_needed, .post_load = pdptrs_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.pdptrs, X86CPU, 4), VMSTATE_END_OF_LIST() } @@ -1536,7 +1536,7 @@ static const VMStateDescription vmstate_msr_xfd = { .version_id = 1, .minimum_version_id = 1, .needed = xfd_msrs_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_xfd, X86CPU), VMSTATE_UINT64(env.msr_xfd_err, X86CPU), VMSTATE_END_OF_LIST() @@ -1557,7 +1557,7 @@ static const VMStateDescription vmstate_amx_xtile = { .version_id = 1, .minimum_version_id = 1, .needed = amx_xtile_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(env.xtilecfg, X86CPU, 64), VMSTATE_UINT8_ARRAY(env.xtiledata, X86CPU, 8192), VMSTATE_END_OF_LIST() @@ -1578,7 +1578,7 @@ static const VMStateDescription vmstate_arch_lbr = { .version_id = 1, .minimum_version_id = 1, .needed = arch_lbr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.msr_lbr_ctl, X86CPU), VMSTATE_UINT64(env.msr_lbr_depth, X86CPU), VMSTATE_LBR_VARS(env.lbr_records, X86CPU, ARCH_LBR_NR_ENTRIES, 1), @@ -1599,7 +1599,7 @@ static const VMStateDescription vmstate_triple_fault = { .version_id = 1, .minimum_version_id = 1, .needed = triple_fault_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(env.triple_fault_pending, X86CPU), VMSTATE_END_OF_LIST() } @@ -1611,7 +1611,7 @@ const VMStateDescription vmstate_x86_cpu = { .minimum_version_id = 11, .pre_save = cpu_pre_save, .post_load = cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.regs, X86CPU, CPU_NB_REGS), VMSTATE_UINTTL(env.eip, X86CPU), VMSTATE_UINTTL(env.eflags, X86CPU), @@ -1699,7 +1699,7 @@ const VMStateDescription vmstate_x86_cpu = { VMSTATE_END_OF_LIST() /* The above list is not sorted /wrt version numbers, watch out! */ }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_exception_info, &vmstate_async_pf_msr, &vmstate_async_pf_int_msr, From patchwork Fri Dec 29 21:22:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758792 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670739wrw; Fri, 29 Dec 2023 13:25:14 -0800 (PST) X-Google-Smtp-Source: AGHT+IE9gen+Q5oMCdDl2M1PN0eftbHO4dDAX6QII0uREI7JIOAORe5Rxg99GLXg4uCpFXjwouNf X-Received: by 2002:a05:620a:205a:b0:781:539f:2846 with SMTP id d26-20020a05620a205a00b00781539f2846mr6827027qka.14.1703885114272; Fri, 29 Dec 2023 13:25:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885114; cv=none; d=google.com; s=arc-20160816; b=FwoqZ/VPLbvE/9S2QzY6JWGaKr+MfDHkf2FoOc7rBsGoTH7oxPpiGn2x9gMoUwSTdF ZpgrQO0JOpnTwRPvmbJi5XGZYDC3sWKNOpfm6ENpU42t4vsdJEDbaID8w/DGVBCQjmuG I7v0I28rYuSyXslJX5SgihKKLUR7HqLAOWwjLiyUyEVttzaf4E+mnwx+YKPenWpt6HVG pI+cD2cuMra8ls+wRCbzN629j0ugYzLlheUG5MeNq5SQrukH+dJeEx38KkTWTcQ4V8cg PUMvuiPDvn7T1fvv7EdmeN1fArSFKViqM4SCBd3lA2l+ZR01xc7eIvl2RhHJqRB9mP3o 5fqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=QMN6P6UkRFuIZLQOv+2lhjHpbohYNcYTosCGWfaizOs=; fh=KXT8skN7RFTc7N6YjUNlSMSjM9WXZW43UAg6bOEDSoc=; b=z4VdwMVnLOMOJCYVPxTNqyFDTqCU8xT/4Y0t6WpyKWf7qPtN47E4e2FiN/G8kUBut4 2CuBtwr5trbgHNs09EiummBxUtfQpCEQMKmcYPlg7h1Zs/r7nB1DfNBPEMSPB7dcBY1a 7WTaDsHwZC4tf7TkQJOurhedtd0IxUxGHoQswxnvh9CGbosqU+kyoKHKrEkwziV9Lxb9 9m7xBqyEAoLaUtQLajDSbXTXzHmrhbR+15wZ9SeXEAG0L/Qzm4a7bRYC47E9rKaq62ZV dyXUE6dSPEt4HVg6t0N7NpgBxlcHxU0VkHbbjK+UXlKk6gr6C3mV2owglBqDYeTKSZ1B hSNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="EM82f/IF"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i19-20020a05620a145300b007815c65c8basi6954510qkl.62.2023.12.29.13.25.14 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:14 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="EM82f/IF"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKL9-0006vl-Ub; Fri, 29 Dec 2023 16:24:23 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL4-0006uc-NF for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:20 -0500 Received: from mail-il1-x12c.google.com ([2607:f8b0:4864:20::12c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKL3-0006S4-4q for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:18 -0500 Received: by mail-il1-x12c.google.com with SMTP id e9e14a558f8ab-35feb61c91fso23479935ab.3 for ; Fri, 29 Dec 2023 13:24:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885056; x=1704489856; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=QMN6P6UkRFuIZLQOv+2lhjHpbohYNcYTosCGWfaizOs=; b=EM82f/IF+VKt9AtJpaKTCtbk3iVh1sb9Vkeei8WC8Q1Gw6XFHEjKFgVaC4SQl2mNfg oKtWKqvrhNz29oh01VKt11hr0g2S9hvrzRKcXeZaTy5t0V4o+axrzjE/paOHxaTFHQbA 6l8123nVCzqMggKXbZ+rTRZQndXnW37muX+BXloJc7Dq8YJAlWLEc2TPiKmPBULs1AqQ bWyteaVU1dlYcZA/lv/fC8UngqvR5hVWD1IEcp/Lwq9a/c43KGHdWCj2DzzbmWBJkQFC m0kvwkVVVoOiEIeaE6ECMVOUS06hRKd1Abgig3DKBA4Jx6dwXXD1NcwD6vBBQhYuznvv eAWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885056; x=1704489856; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=QMN6P6UkRFuIZLQOv+2lhjHpbohYNcYTosCGWfaizOs=; b=jcLzr9Ii2ASEwABV3YbR3QOe8m5aiHFKCfr3fYgNQUzn3dnYQ/SnGQfgb96SoXHtOr qkgiuJGqRjIiAHwnLmOKxBo9a99gZ591U/6872r7/WLkGhjIbjZGPZVz9slnLr9jj0XS 9fkUZRKkVPUvfJ3hdSyMvRV1BUBPL/xTNRpkphZAX2NMpIQ7Azjres3cdrfzlcxIe0M9 zDQPswHiWYtu3fDQ30w4qCOUD7ywSFwoOkQai62Nl7T28Bv8R7zofXy/KhhTvIvc03PP l41/Y0o/N0lpcapPB9xHYdmrlNotZ8b/E1g6VPi7/TYDQV3g/b+/swmRiifCN5YaGOr6 WErw== X-Gm-Message-State: AOJu0YwFiftScJSWpv6JhocynnJMws2sOjpWzDFxDEozcb/mT1CX6uq6 +OSZ1ALER+BvjIfncnBA0UJqjEb6FhSQDGJDySip7nhekLf9JQ== X-Received: by 2002:a05:6e02:1545:b0:35f:e71f:4c63 with SMTP id j5-20020a056e02154500b0035fe71f4c63mr9872127ilu.100.1703885056119; Fri, 29 Dec 2023 13:24:16 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:15 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Song Gao Subject: [PULL 09/71] target/loongarch: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:44 +1100 Message-Id: <20231229212346.147149-10-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::12c; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x12c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Reviewed-by: Song Gao Message-Id: <20231221031652.119827-10-richard.henderson@linaro.org> --- target/loongarch/machine.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/target/loongarch/machine.c b/target/loongarch/machine.c index 1c4e01d076..c7029fb9b4 100644 --- a/target/loongarch/machine.c +++ b/target/loongarch/machine.c @@ -14,7 +14,7 @@ static const VMStateDescription vmstate_fpu_reg = { .name = "fpu_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(UD(0), VReg), VMSTATE_END_OF_LIST() } @@ -36,7 +36,7 @@ static const VMStateDescription vmstate_fpu = { .version_id = 1, .minimum_version_id = 1, .needed = fpu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FPU_REGS(env.fpr, LoongArchCPU, 0), VMSTATE_UINT32(env.fcsr0, LoongArchCPU), VMSTATE_BOOL_ARRAY(env.cf, LoongArchCPU, 8), @@ -48,7 +48,7 @@ static const VMStateDescription vmstate_lsxh_reg = { .name = "lsxh_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(UD(1), VReg), VMSTATE_END_OF_LIST() } @@ -70,7 +70,7 @@ static const VMStateDescription vmstate_lsx = { .version_id = 1, .minimum_version_id = 1, .needed = lsx_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_LSXH_REGS(env.fpr, LoongArchCPU, 0), VMSTATE_END_OF_LIST() }, @@ -80,7 +80,7 @@ static const VMStateDescription vmstate_lasxh_reg = { .name = "lasxh_reg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(UD(2), VReg), VMSTATE_UINT64(UD(3), VReg), VMSTATE_END_OF_LIST() @@ -103,7 +103,7 @@ static const VMStateDescription vmstate_lasx = { .version_id = 1, .minimum_version_id = 1, .needed = lasx_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_LASXH_REGS(env.fpr, LoongArchCPU, 0), VMSTATE_END_OF_LIST() }, @@ -114,7 +114,7 @@ const VMStateDescription vmstate_tlb = { .name = "cpu/tlb", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tlb_misc, LoongArchTLB), VMSTATE_UINT64(tlb_entry0, LoongArchTLB), VMSTATE_UINT64(tlb_entry1, LoongArchTLB), @@ -127,7 +127,7 @@ const VMStateDescription vmstate_loongarch_cpu = { .name = "cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.gpr, LoongArchCPU, 32), VMSTATE_UINTTL(env.pc, LoongArchCPU), @@ -193,7 +193,7 @@ const VMStateDescription vmstate_loongarch_cpu = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fpu, &vmstate_lsx, &vmstate_lasx, From patchwork Fri Dec 29 21:22:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758827 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672061wrw; Fri, 29 Dec 2023 13:30:28 -0800 (PST) X-Google-Smtp-Source: AGHT+IGc2Ao0WjVdhz7Nrj5zjz7ntzpNJLt9RYotmPZqFqIXHSik4tT102r/bv/7yvoHfbiWEi+G X-Received: by 2002:a05:620a:394a:b0:77e:fba3:9d30 with SMTP id qs10-20020a05620a394a00b0077efba39d30mr16315401qkn.148.1703885428011; Fri, 29 Dec 2023 13:30:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885427; cv=none; d=google.com; s=arc-20160816; b=Zsd4OAxuhGS+Xiem42vQZtMjjR20p0+ClxZR5ux8qGZNn83jEsUW1uVzm+bdmHl7RM VlaaULN40F6OCdZu+7fSCqcQ8TtAv6VLfGCunLJkYeBbnWz3lSKrhEwDnmg+FSl9XImI S2QRbaqcpNGCdFt8JRxXY4SwbN3LvbosjB80eyqYwpxIaFl13hzEGsEzEQwGHzY+4qXP EKWoy7GH7ZWgMrAAzwyF1rI9RGZ9X80NpR384Y5vhaIyP3eg1LqAmLfCB+uLcyc4n4ge uMm4bGuFv5ZT0vwEpd1orPBxu6k2owGm/O2ImMd81mycZH08yGsUvcOZYJYLiTx7ZD/5 mxzg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=WQ7Vx56bKbymYuLyooz5UOtSKpXbnXiz4KIzxIin+2g=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=Hr6r+aCPk25PeKWADJKAyunNZKKEkjkEFBoJvaHoz49G2cjx5EYY/dTzhb/nGTixKA yjUNBkhutxgG8g5JKdepHN4ZdDkbTXUWcpg7mS4iutjlBB+deY9i/Xfo4FKLI/0qF1kQ /MSav+lIKwxXCuLD3tE962vAg73isDUjeekMXK4FDPFI3FNdyqs8pFMNHqnwBBjDEqKr n5WDe67/CbCVj2FhcOiK04W92S4iPgFFwqUGzfTa0jm2ElPs/T8iK2NJ0q090LauH5pG x8jg3N1jf2a9z2ZZLvfJaX1CKCcftraTAEUFtsqgrUI6MsbDZnNcqbE+IDgqcxZvxSMJ 41Qg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ce9pOGec; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id bl39-20020a05620a1aa700b007815baa09e2si7831270qkb.59.2023.12.29.13.30.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:27 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ce9pOGec; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLD-0006xG-JQ; Fri, 29 Dec 2023 16:24:27 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL7-0006vI-5H for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:21 -0500 Received: from mail-pg1-x52d.google.com ([2607:f8b0:4864:20::52d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKL5-0006Vz-HL for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:20 -0500 Received: by mail-pg1-x52d.google.com with SMTP id 41be03b00d2f7-5bdb0be3591so5597163a12.2 for ; Fri, 29 Dec 2023 13:24:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885058; x=1704489858; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=WQ7Vx56bKbymYuLyooz5UOtSKpXbnXiz4KIzxIin+2g=; b=Ce9pOGectX4uZP2xhKzF/Q1ZuN3hrS4Kc6PjyccrImdoxFPXvRtZDP9w4lEsT6h6vq vKfDwRsF6cNJ5oEjOv/Q7NNXKs1nMYViOrSwR+DcrhP3NU6w9VIcAc4PWiy5g3KvU6VS H3VLOldGDJdnDHDh5OlBd5gIB3X970svWH9KeFWoPm0lr6L/OXupc5EgtlCSAXv/gGQB 6aNt0J6JuAmHJr+HQTJdYy9JZ8yozyRWyIZiACOWP8p2WVfdLcKz1tJIbxxsWJ/q1D6v SuxfRSxasggwko/2IGkj1WkJHjzn+23kC160Dj3oxMQTGI5hqiLhHY7OzvN1C8hZOEDk hLjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885058; x=1704489858; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=WQ7Vx56bKbymYuLyooz5UOtSKpXbnXiz4KIzxIin+2g=; b=JAanHisFT5uq+LwVIVelbR039NY3QsRBoP+fSOt2Dm8GdYfIsr02C2lmZxJg2tbKIA xI0KTNi28xOY2HsQmtme5vI2zsmAtg7OFkoW9iz7Yri9E6caXfIIKdwg0FgcQxs1lkc6 22vO+PHU1hNOLAT8GIC7KSt4q0N/bssw/QpVxSeszqA4xI1UDp67sJc3b9lyn/2UNH4L k4eIQ6fQ5Nj2kVh61t3B0igmLu51R2VML1soce7G4WHrQXjxP6lE3iZaW3rwx6FNHIfV 4Lzbt7Xvl3c4XgC8K80VHwPv4NbZ0NUEMbFw+72Zy2GK937SVEwxfktRPcNkRk7X7F+8 VQyg== X-Gm-Message-State: AOJu0YyCROSZXRkQsP7xXVfxwfjoB8YEE38fH9tJBwiMBB0WbxT/3rF/ eDwescKa7RFadyrYAU0ruGrS3vll/FvTZmw6/X/caZAsSu7leQ== X-Received: by 2002:a05:6a20:9708:b0:189:c46d:9790 with SMTP id hr8-20020a056a20970800b00189c46d9790mr12328790pzc.30.1703885058156; Fri, 29 Dec 2023 13:24:18 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:17 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 10/71] target/m68k: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:45 +1100 Message-Id: <20231229212346.147149-11-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52d; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52d.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-11-richard.henderson@linaro.org> --- target/m68k/cpu.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/target/m68k/cpu.c b/target/m68k/cpu.c index 11c7e0a790..43b1bde21c 100644 --- a/target/m68k/cpu.c +++ b/target/m68k/cpu.c @@ -381,7 +381,7 @@ static const VMStateDescription vmstate_freg_tmp = { .name = "freg_tmp", .post_load = freg_post_load, .pre_save = freg_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tmp_mant, m68k_FPReg_tmp), VMSTATE_UINT16(tmp_exp, m68k_FPReg_tmp), VMSTATE_END_OF_LIST() @@ -390,7 +390,7 @@ static const VMStateDescription vmstate_freg_tmp = { static const VMStateDescription vmstate_freg = { .name = "freg", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP(FPReg, m68k_FPReg_tmp, vmstate_freg_tmp), VMSTATE_END_OF_LIST() } @@ -411,7 +411,7 @@ const VMStateDescription vmmstate_fpu = { .minimum_version_id = 1, .needed = fpu_needed, .post_load = fpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.fpcr, M68kCPU), VMSTATE_UINT32(env.fpsr, M68kCPU), VMSTATE_STRUCT_ARRAY(env.fregs, M68kCPU, 8, 0, vmstate_freg, FPReg), @@ -432,7 +432,7 @@ const VMStateDescription vmstate_cf_spregs = { .version_id = 1, .minimum_version_id = 1, .needed = cf_spregs_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.macc, M68kCPU, 4), VMSTATE_UINT32(env.macsr, M68kCPU), VMSTATE_UINT32(env.mac_mask, M68kCPU), @@ -454,7 +454,7 @@ const VMStateDescription vmstate_68040_mmu = { .version_id = 1, .minimum_version_id = 1, .needed = cpu_68040_mmu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.mmu.ar, M68kCPU), VMSTATE_UINT32(env.mmu.ssw, M68kCPU), VMSTATE_UINT16(env.mmu.tcr, M68kCPU), @@ -479,7 +479,7 @@ const VMStateDescription vmstate_68040_spregs = { .version_id = 1, .minimum_version_id = 1, .needed = cpu_68040_spregs_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(env.vbr, M68kCPU), VMSTATE_UINT32(env.cacr, M68kCPU), VMSTATE_UINT32(env.sfc, M68kCPU), @@ -492,7 +492,7 @@ static const VMStateDescription vmstate_m68k_cpu = { .name = "cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(env.dregs, M68kCPU, 8), VMSTATE_UINT32_ARRAY(env.aregs, M68kCPU, 8), VMSTATE_UINT32(env.pc, M68kCPU), @@ -509,7 +509,7 @@ static const VMStateDescription vmstate_m68k_cpu = { VMSTATE_INT32(env.pending_level, M68kCPU), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmmstate_fpu, &vmstate_cf_spregs, &vmstate_68040_mmu, From patchwork Fri Dec 29 21:22:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758799 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670937wrw; Fri, 29 Dec 2023 13:25:57 -0800 (PST) X-Google-Smtp-Source: AGHT+IHVGIHBVbYlqeZU9T+Pq9wu3nzaeKVQ675W2OwYKZdvT0PWJEtZHkNLSHe3/kXOheEM9vvQ X-Received: by 2002:a05:6808:2204:b0:3bb:6d95:8b28 with SMTP id bd4-20020a056808220400b003bb6d958b28mr14078537oib.46.1703885156762; Fri, 29 Dec 2023 13:25:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885156; cv=none; d=google.com; s=arc-20160816; b=xgoZHoUJceEHXk35o0s/HpZQWreSHd7zGm8fTd/cdkQ9fkeQrk6vz6BgW/kSQVCjul 0jS1M2cbq+VpGBtQf2PkRQnSV9SxI9o5U2GfjtpWtZGD9xVINtHsGs44eoTXxQCykhQp QQ4XqQNnxKaLyqBQeC240oN1bmX4vcZEIN8bquLmWJp2FSETrFd2hgirjkBUXY+mnEXi 2x/kCMBp/ZSC+nCqZD9XtS76+IwIGDIi5oLGT58eUEELc9aFmL8UPcXMTrAJWBJeY+0r xJ51YvUGpOIiE5jfjbKkLLW5qe8vd4mvxhCCGDTGEJOsxgzUVmeoxlmCvPaGUP6fb2sE 4tFg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=JdUJ+a9jwe6jFr1Vp2r8iUErAThFUW3vNQyu0k8ot3I=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=S6BuXGFtPWMUfRbO0d7Fidjn10dhgIsNopLAcz5P7D+C2p4sZ5eIks7VN8U6YOK3ik EA9Mivt5w8ROToCQ035VHb9tn/fah/JD+c7PB9IGPitDhF3Ww2WqB7GODw4JVW9Twzsp D4YkTPoPt9cEdQ5uxPZL+kPgBqnoUEnn06dISdD8JVhCy7laZjkb86K4DnmJDaw37pO3 d7lwANHNgPxSJ9O3KsXWW5pBJj0nrFNdVRV1/aeObEgaMaZn2kEyXUEmfFkicNpkWxpJ cs3cpglY1ciMqvh4JLQ0xvO00iX7Uh8Gkn+5Oav2Pc/d0gVqGJJEb9afs+4xGK9TO1aP gr0A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=k+oPniaq; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g12-20020ac8580c000000b00427fbce211asi3985489qtg.773.2023.12.29.13.25.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:56 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=k+oPniaq; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLC-0006x3-TM; Fri, 29 Dec 2023 16:24:26 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKL9-0006vm-5y for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:23 -0500 Received: from mail-oi1-x22d.google.com ([2607:f8b0:4864:20::22d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKL7-0006Xt-NL for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:22 -0500 Received: by mail-oi1-x22d.google.com with SMTP id 5614622812f47-3bbc755167fso2038386b6e.0 for ; Fri, 29 Dec 2023 13:24:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885060; x=1704489860; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=JdUJ+a9jwe6jFr1Vp2r8iUErAThFUW3vNQyu0k8ot3I=; b=k+oPniaqny+ovl0t0D3tuVhQZJvJ8Gwz+A06oejlma7zjNtFnHY4lqZe+QiJdbWiBZ nRlO+Y3sqPx4T0Pws/53kiWtPeuG1pEu6SD5ql5tE7pTAfxAHD6qw/ylZlQ3N4hWmlA0 WK2bIYaV6nshAabFZvD+hdhjhm8TWDtc/xeN25wXb+KeuTA94LXWmeUyH9uUqWOLTwnM AHtDBbQon6i93IW6QMVtHUFE4r+H0K2/6vLqCWnzGMpml9NgPGk719cvk1Xf7fGhxcm+ IOcPYavsSA4FPilRlVT5S/a+x/W8HBDPQFoEXdoSBPv3Jxij5hyYcvCnmGVT1SF/3GkF UkKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885060; x=1704489860; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=JdUJ+a9jwe6jFr1Vp2r8iUErAThFUW3vNQyu0k8ot3I=; b=rO7H9KZo1679tDyM4K2Ig87cn5E2xO7TB+cqDYIXhj82V56WPRITrIKIUfwk9n9o0v f5546pUGVQSlscUOoOACRt2HioV15y6GRP9E7My6846pXtuGW+9wza6ElbgloiF+odNn 3Mx6ACb241XvTqmR/MF4FKPhVXP08cQ+BMvyLzn/qEiDInR1upu55qNLCcd8NjiJBOb7 b1K3FJQtIeZhP/KbPyulwZwFOgIrdPkS7Bo6LKzZkw5+msP/Yf9QU1NmxeGzWHlRye9s QiNW7OEfaTuP3Ge2IgL0UXuNCvIi56gylvYtdmP33gq+11dvZu0EY6pUxjsS/n4Uwiyr puBQ== X-Gm-Message-State: AOJu0YwQIm1eyZUXsaYuWq7JXxHUtFtv4YvkDxfOj1gN5y+AUCEcQYv2 MqDy4SPjLWCrfYJx/7AIM2cNY4Hhxy+vlMOpp6F/c6ePoneG1A== X-Received: by 2002:a05:6870:b620:b0:204:1df1:8c85 with SMTP id cm32-20020a056870b62000b002041df18c85mr13654332oab.94.1703885060568; Fri, 29 Dec 2023 13:24:20 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:19 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 11/71] target/microblaze: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:46 +1100 Message-Id: <20231229212346.147149-12-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::22d; envelope-from=richard.henderson@linaro.org; helo=mail-oi1-x22d.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-12-richard.henderson@linaro.org> --- target/microblaze/machine.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target/microblaze/machine.c b/target/microblaze/machine.c index d24def3992..51705e4f5c 100644 --- a/target/microblaze/machine.c +++ b/target/microblaze/machine.c @@ -22,7 +22,7 @@ #include "migration/cpu.h" -static VMStateField vmstate_mmu_fields[] = { +static const VMStateField vmstate_mmu_fields[] = { VMSTATE_UINT64_2DARRAY(rams, MicroBlazeMMU, 2, TLB_ENTRIES), VMSTATE_UINT8_ARRAY(tids, MicroBlazeMMU, TLB_ENTRIES), VMSTATE_UINT32_ARRAY(regs, MicroBlazeMMU, 3), @@ -60,7 +60,7 @@ static const VMStateInfo vmstate_msr = { .put = put_msr, }; -static VMStateField vmstate_env_fields[] = { +static const VMStateField vmstate_env_fields[] = { VMSTATE_UINT32_ARRAY(regs, CPUMBState, 32), VMSTATE_UINT32(pc, CPUMBState), @@ -92,7 +92,7 @@ static const VMStateDescription vmstate_env = { .fields = vmstate_env_fields, }; -static VMStateField vmstate_cpu_fields[] = { +static const VMStateField vmstate_cpu_fields[] = { VMSTATE_CPU(), VMSTATE_STRUCT(env, MicroBlazeCPU, 1, vmstate_env, CPUMBState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:22:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758798 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670938wrw; Fri, 29 Dec 2023 13:25:57 -0800 (PST) X-Google-Smtp-Source: AGHT+IH7OrpKK86cj/hU25MrEOrNctRvwKjHtXRuHt2eAbZ7PhylicsSLdzWbswx4gaV7jQMRmIR X-Received: by 2002:a05:622a:607:b0:425:4043:764b with SMTP id z7-20020a05622a060700b004254043764bmr16105264qta.115.1703885156466; Fri, 29 Dec 2023 13:25:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885156; cv=none; d=google.com; s=arc-20160816; b=YGd/SiqLheGP524Yx4xmoYeAnSzwJVoz68kSotpPdHcWq53UYbvF3jK5E3FmZYfQDa 1S2Id2V2cDKLY7PiZQ43ziV0XPkd94wWr1hf4pDdywSEF+0gsPL8Tf86LigXb+iEg2Lt QCBcKQUtSLG9vE1QRIxZrosssnE2CCZjDnNhLq5yVH5i420wl/GypT1zYSyjGQiJel1O jM2ReWNRc3PYvgpDSV3cAhnYiYbctIbQJCCMbnd75zmsgCQGm/mxPpRkqsnD1qQkf7Tj t3+XiXK2vuT4Tb03+BJT6m9NNn49XSqCf0Lb3mMxIACzatjr4WjCJnkculbRXC2hyW5r eO/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=mm4+MbG9/Lxz7kczYlcLTiw7gqQVGMuSdlqX7t/TGnQ=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=n1oxkIu90WL0lAPjWsM96Gh80E9j59g4WNwgqqKWoeW1ywcrEopQ5Q0Hmd5cYhmS9R 9tpGEx9lok0iRb39AfdbUTVuFzdOIrq1JhjCja6s9zLzDSdRignSTDC9Mm0jFRmL/6JH uvKlIyASs7gNumPhKcO4waHD9CDcXZNRvyhDob9HmV8PujNhWb8TaSh7rBoA5tnxXsGq 4pjAD+nAbPURCZY9OwTB9Nf5RbU+aMqInXO5GQhvzxzIZFRj2eNFhspTvE53HooP7Xg5 4D+oXqqtkANYtH8HEmYI2qXO0vMwgizRr3bTEo+v5HmqxXX12KV7Ql76hm7lv3QECiC7 5g8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=UGSxTEN8; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id n3-20020a05622a11c300b0042786aecb91si20021851qtk.251.2023.12.29.13.25.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:56 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=UGSxTEN8; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLF-0006y0-Gv; Fri, 29 Dec 2023 16:24:29 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLD-0006xD-Hh for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:27 -0500 Received: from mail-oa1-x35.google.com ([2001:4860:4864:20::35]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLA-0006dC-Nz for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:27 -0500 Received: by mail-oa1-x35.google.com with SMTP id 586e51a60fabf-2044d093b3fso4451643fac.3 for ; Fri, 29 Dec 2023 13:24:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885063; x=1704489863; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=mm4+MbG9/Lxz7kczYlcLTiw7gqQVGMuSdlqX7t/TGnQ=; b=UGSxTEN8rzWp5WTSvqkVDkwVFtSSR6UIqoZOc5E7BsjNp8WKzBluKNEXm/GaHp/Shg 2tibF1H3u+IIMTVGrRohUMnP04Z8BrkRMZDew1q5GmjtdmTVOlgTCFPqrWmxjZQSunYC 9TIwcRc9H1Ir5AYdigF1nQrfu55YoctYQC86Jd+TIJnbGNOYaxxYkzwR+zxcd6vLn/4g zcGdPvdGz8mktA5D24lkyIZRtIve1RyaDofppkRjlZzXw+bO//wyr5vYh7VBZbDfAgDr 0VFSqy4VUqZVuJ8cr7gLCpagSZs8FIJYAjSg7QcnLOOUiiMP8FdJXDUWPR+7AtseO4b+ +5uA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885063; x=1704489863; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mm4+MbG9/Lxz7kczYlcLTiw7gqQVGMuSdlqX7t/TGnQ=; b=bQyLAzYp1DfPEmf4AHe6VXE6O9zb9GnTrDbsjlkMIsRCGU7drkyC0cVFzgBX6LdYEb Ifd8K1Q/z+2lxhMwxWpHRnqfPrTdjbgmgubJFnLNRMRnw97yVUiDu69HjyQw3zZJwD1x Gu7Vj4DS3C36/YTJDESKPr2fs1QCZ7eDBSjzUgVLcxyF8kodU5lRzP7OKxQCrT49DEPA T+JP0/YkwAfmxNGiH9mJisCwTb2cAW3e0R0LSJafw1sDNqlYfjHTUCy1iYvcu0fKkLw6 sslUuuAmL1R5Z/TQyAgRaQr4t7ehykHxomx1E/bcrFHVIjS1YHO1uj/jmRxiasjdXjr/ blqg== X-Gm-Message-State: AOJu0YwOmm7jDXQQOPCTj5+e7cAMOkL2AUnXum5TFJIKK2YdoL1KLvL4 ghCFb9LEbaDpIslsnbW4g1vjWK9gRVgWNm2N+ThigQQhZQ+agw== X-Received: by 2002:a05:6870:238f:b0:203:a48b:6ad4 with SMTP id e15-20020a056870238f00b00203a48b6ad4mr15710572oap.93.1703885062984; Fri, 29 Dec 2023 13:24:22 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:22 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 12/71] target/mips: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:47 +1100 Message-Id: <20231229212346.147149-13-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::35; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x35.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-13-richard.henderson@linaro.org> --- target/mips/sysemu/machine.c | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/target/mips/sysemu/machine.c b/target/mips/sysemu/machine.c index 80d37f9c2f..218f4c3a67 100644 --- a/target/mips/sysemu/machine.c +++ b/target/mips/sysemu/machine.c @@ -44,7 +44,7 @@ static int put_fpr(QEMUFile *f, void *pv, size_t size, return 0; } -const VMStateInfo vmstate_info_fpr = { +static const VMStateInfo vmstate_info_fpr = { .name = "fpr", .get = get_fpr, .put = put_fpr, @@ -56,21 +56,21 @@ const VMStateInfo vmstate_info_fpr = { #define VMSTATE_FPR_ARRAY(_f, _s, _n) \ VMSTATE_FPR_ARRAY_V(_f, _s, _n, 0) -static VMStateField vmstate_fpu_fields[] = { +static const VMStateField vmstate_fpu_fields[] = { VMSTATE_FPR_ARRAY(fpr, CPUMIPSFPUContext, 32), VMSTATE_UINT32(fcr0, CPUMIPSFPUContext), VMSTATE_UINT32(fcr31, CPUMIPSFPUContext), VMSTATE_END_OF_LIST() }; -const VMStateDescription vmstate_fpu = { +static const VMStateDescription vmstate_fpu = { .name = "cpu/fpu", .version_id = 1, .minimum_version_id = 1, .fields = vmstate_fpu_fields }; -const VMStateDescription vmstate_inactive_fpu = { +static const VMStateDescription vmstate_inactive_fpu = { .name = "cpu/inactive_fpu", .version_id = 1, .minimum_version_id = 1, @@ -79,7 +79,7 @@ const VMStateDescription vmstate_inactive_fpu = { /* TC state */ -static VMStateField vmstate_tc_fields[] = { +static const VMStateField vmstate_tc_fields[] = { VMSTATE_UINTTL_ARRAY(gpr, TCState, 32), #if defined(TARGET_MIPS64) VMSTATE_UINT64_ARRAY(gpr_hi, TCState, 32), @@ -103,14 +103,14 @@ static VMStateField vmstate_tc_fields[] = { VMSTATE_END_OF_LIST() }; -const VMStateDescription vmstate_tc = { +static const VMStateDescription vmstate_tc = { .name = "cpu/tc", .version_id = 2, .minimum_version_id = 2, .fields = vmstate_tc_fields }; -const VMStateDescription vmstate_inactive_tc = { +static const VMStateDescription vmstate_inactive_tc = { .name = "cpu/inactive_tc", .version_id = 2, .minimum_version_id = 2, @@ -119,11 +119,11 @@ const VMStateDescription vmstate_inactive_tc = { /* MVP state */ -const VMStateDescription vmstate_mvp = { +static const VMStateDescription vmstate_mvp = { .name = "cpu/mvp", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(CP0_MVPControl, CPUMIPSMVPContext), VMSTATE_INT32(CP0_MVPConf0, CPUMIPSMVPContext), VMSTATE_INT32(CP0_MVPConf1, CPUMIPSMVPContext), @@ -190,7 +190,7 @@ static int put_tlb(QEMUFile *f, void *pv, size_t size, return 0; } -const VMStateInfo vmstate_info_tlb = { +static const VMStateInfo vmstate_info_tlb = { .name = "tlb_entry", .get = get_tlb, .put = put_tlb, @@ -202,11 +202,11 @@ const VMStateInfo vmstate_info_tlb = { #define VMSTATE_TLB_ARRAY(_f, _s, _n) \ VMSTATE_TLB_ARRAY_V(_f, _s, _n, 0) -const VMStateDescription vmstate_tlb = { +static const VMStateDescription vmstate_tlb = { .name = "cpu/tlb", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(nb_tlb, CPUMIPSTLBContext), VMSTATE_UINT32(tlb_in_use, CPUMIPSTLBContext), VMSTATE_TLB_ARRAY(mmu.r4k.tlb, CPUMIPSTLBContext, MIPS_TLB_MAX), @@ -221,7 +221,7 @@ const VMStateDescription vmstate_mips_cpu = { .version_id = 21, .minimum_version_id = 21, .post_load = cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Active TC */ VMSTATE_STRUCT(env.active_tc, MIPSCPU, 1, vmstate_tc, TCState), From patchwork Fri Dec 29 21:22:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758795 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670880wrw; Fri, 29 Dec 2023 13:25:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IGeaCf0B4Xdv1iMNQefMNTJ9MlMXcgqwmWm6x6+ZlFPXchCTAOzZl90hbE3wMMWINq8J560 X-Received: by 2002:ac8:7dc1:0:b0:425:8cea:eba1 with SMTP id c1-20020ac87dc1000000b004258ceaeba1mr20448037qte.80.1703885145963; Fri, 29 Dec 2023 13:25:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885145; cv=none; d=google.com; s=arc-20160816; b=cLqYg0V2ypTrLN2jzzOOL+dk8ZncS9eyCh/Ry6IkeVV9DK11RQ6oo/9JwkYPKcvyph 8HopaXEBVyGfgdqaPHIebgSouS2YQHWhen1TO2jXGSOxN+2V1ZP7kZIpRANYjf7ck1sQ PH7VYxQ8NPQ4anBF0aUdQgYRLAnWIK4pkQsvs3xC80xngHFw7ViI88ARGusPFFeS8lMu +hqA3DVn1Hh9vP8b1lbZz0ntMKkyIk3OKekzklx9KXwFhYnbBF1S6XXx0M9eYxmwdxCb ty995PfbiJevoNCLqUnnYjzY7BThJLHCGNhAk/Q4NM/J973s3XjReUfS4ARns2tLnpd7 HVmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=D1wtmagA20UyDQGh/RhpJV+m3qRJC3+9KhhosTNeN7E=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=0/pHSvKHQsDhwmYcNYCx4swBPMkQXw5sgFrQ3fwwx9yhxcp8xcodB2196AzRSmKdbY GkIsa19EaLhgJVWoo9RvXACHD8ULYaWc1Eh3FhEH3nNI5JB+r5kPM+/EQSfp+iR1LIR+ Xgnxt9GXTIqs+l5tK0vOuGka6qoNGzYe4kbvJrcNkgiLJre3Ny5j/UIkLJ1Y6KmW8XtP 1Espb0sRaauEQQMrjTzVEvuBBX+DNJz3j4L65eHKc54oZh+Yt7CiErBQTCtFWxfZSVBl 7x9jqBjGiwkAJH+KyNbtgiOyvwOk4PFzVRjboI1UYYrw9C/cT8EfZwULH/LygCSVDqAe XKUw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PPxxqXkb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i8-20020ac85c08000000b004280e3fcbe8si500032qti.123.2023.12.29.13.25.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:45 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=PPxxqXkb; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLF-0006xz-HE; Fri, 29 Dec 2023 16:24:29 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLE-0006xo-An for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:28 -0500 Received: from mail-ot1-x32a.google.com ([2607:f8b0:4864:20::32a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLC-0006de-Rw for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:28 -0500 Received: by mail-ot1-x32a.google.com with SMTP id 46e09a7af769-6dc02ab3cc9so1977064a34.3 for ; Fri, 29 Dec 2023 13:24:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885065; x=1704489865; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=D1wtmagA20UyDQGh/RhpJV+m3qRJC3+9KhhosTNeN7E=; b=PPxxqXkbIqfCNQ0ji9JmuN5itT9f5q1QVh1EOWls28yz/qQiH0WsAdjIoICaTYMD19 LqUsnM6quF+Z3jpGGcreJz43nzS+UVmTdBx4T9FuohZ46cXddVFv7voLgz102rP6UPUw y3JD2PbGAa3RALuH2sIASauhrZK7etEHbD9B7BRXHG8mf4KvmbJ7MdcHk+CVFMWyKXok 8zaU5cC8nRsnkIwJ1zTPEY2ReY67Am5zX037mzy0p51J6/Q650T3DpJbYQK+rV6mjF6i N0dxamnGwjAQbye6hOJnX/0h1G8BKFsu+oWKNn0CUqVAdawnxfCo+3d84m8oi7YLGqZz t0kA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885065; x=1704489865; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=D1wtmagA20UyDQGh/RhpJV+m3qRJC3+9KhhosTNeN7E=; b=LgHO6RBIg0dE97gWyx+ozGYcxQHsfxS5lvx1t9zllR58gGJfOvi9ONzsDH+cWfMx15 Mq4Ts4U/tGzdxYlhUFcpSglh9P1Y9tVQWsVCYsZ0YDECoQFTkdjh87cjMJdTMpB4CbvR QORC/avbTq90JuoK6ZIe6rHuzx0OU/46jaHSCQG4Yo1rNDdxBlrIRkopBak2P1kFcRxz CTN8DDZjntz911izoP/su035q/GsAGq8VsyN8z7ilsp8dmGODUAQ7mxDfyhlEATFw3as 9fde/5n9XUpaT30Y/RBTZ2/E3IqGEcu6VpqNTCm9rVlEEyCsS4yWF/lpxfaQo2XnJ2OI AvKQ== X-Gm-Message-State: AOJu0YzNf4U6NzDit/lf7tNiCY1nhQdISzpu3Nr8Y77/jJ+iVueUJ/jZ t+v1uyo5PwpDrzKXOh1SgvzN3vcQPOVBYPmPy1EgVU3h21QjLQ== X-Received: by 2002:a9d:7c88:0:b0:6d8:74e2:c09a with SMTP id q8-20020a9d7c88000000b006d874e2c09amr11349202otn.76.1703885064991; Fri, 29 Dec 2023 13:24:24 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:24 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 13/71] target/openrisc: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:48 +1100 Message-Id: <20231229212346.147149-14-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::32a; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x32a.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-14-richard.henderson@linaro.org> --- target/openrisc/machine.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target/openrisc/machine.c b/target/openrisc/machine.c index b7d7388640..3574e571cb 100644 --- a/target/openrisc/machine.c +++ b/target/openrisc/machine.c @@ -25,7 +25,7 @@ static const VMStateDescription vmstate_tlb_entry = { .name = "tlb_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(mr, OpenRISCTLBEntry), VMSTATE_UINTTL(tr, OpenRISCTLBEntry), VMSTATE_END_OF_LIST() @@ -36,7 +36,7 @@ static const VMStateDescription vmstate_cpu_tlb = { .name = "cpu_tlb", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(itlb, CPUOpenRISCTLBContext, TLB_SIZE, 0, vmstate_tlb_entry, OpenRISCTLBEntry), VMSTATE_STRUCT_ARRAY(dtlb, CPUOpenRISCTLBContext, TLB_SIZE, 0, @@ -71,7 +71,7 @@ static const VMStateDescription vmstate_env = { .name = "env", .version_id = 6, .minimum_version_id = 6, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_2DARRAY(shadow_gpr, CPUOpenRISCState, 16, 32), VMSTATE_UINTTL(pc, CPUOpenRISCState), VMSTATE_UINTTL(ppc, CPUOpenRISCState), @@ -135,7 +135,7 @@ const VMStateDescription vmstate_openrisc_cpu = { .version_id = 1, .minimum_version_id = 1, .post_load = cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CPU(), VMSTATE_STRUCT(env, OpenRISCCPU, 1, vmstate_env, CPUOpenRISCState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:22:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758809 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671453wrw; Fri, 29 Dec 2023 13:27:59 -0800 (PST) X-Google-Smtp-Source: AGHT+IE0JphjOixzUODaex2EU3+65ElFDJoV3fMJ3wiSfXPYYgLBNf72MRcr1gRlmlOuTGPwd4Cq X-Received: by 2002:a05:620a:2296:b0:77e:fba3:58ce with SMTP id o22-20020a05620a229600b0077efba358cemr13073178qkh.95.1703885279683; Fri, 29 Dec 2023 13:27:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885279; cv=none; d=google.com; s=arc-20160816; b=GPzFwJEnhWd70TcQ1v5FKzo7sBQl2V5rsuirIrwuEyd3TyG9au/57InFO/RQh2f6zY fo0Qo0ygersBQc/T6/93AKtzrVaWSeNLcJOgpNO2mL5ADJNYI7CTKzYLJfSdQ9DrkduJ H3BxryMLDSZHqKNEz4yRqEACAeeJ64YRg/jok43PdKcdENdes/K0+6egTI6UGWUxzKY2 8Qu4ESBy+N5CAHco8s6Tj/0Eir8BLmk+TWZrsYcI5ODCtzZc1YpP3vQ+2QFRUHD5DFCO jPyd7BbD1iZa780ava3mn5DgRZEPHHchsl0yhagdy9FQaxjXecbMDdY2UYCF1puUefiT AC5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=NbLag/EB+bHmmgZuugtXh6y657JKbfbzieGWYM5hvCY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=wLHOHfmYa8Ho46QFD/Ws8X1m4/nsoCb/CktEeZgijlBJeLqOeONqjL8rtJIZMfvboc 0AiB9a2hb9LbOhCKR/Jz6F1uacj4a0VtLQZb+cYJdxIQqoT7ZJyOL8ywQ6zlkcE2kSoR cre9rI/chchPJdyZdQeTmRwqEZOu9KdVf1teQkj2m8Yg8ope0Iz6EQDXpZSvW05xjITz iXubm2wZu/L1OJU3IgpGmWoJQ2nmcteQXOgv35vbqex1ui7p9/4SCdnH2ZVhIIzSyIYz gvTUJ8BOp/qQSJoFM2KTv5s+/rs7OGJ0AlvZBqrhKNtwYvlsEDpt8YmabroDHGGpk7lm 9qJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oAYTO0+p; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w10-20020a05620a444a00b0077effc13fa3si21297157qkp.158.2023.12.29.13.27.59 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:59 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oAYTO0+p; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLI-0006z2-B9; Fri, 29 Dec 2023 16:24:32 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLG-0006yJ-Cy for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:30 -0500 Received: from mail-io1-xd33.google.com ([2607:f8b0:4864:20::d33]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLE-0006e4-Fj for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:30 -0500 Received: by mail-io1-xd33.google.com with SMTP id ca18e2360f4ac-7ba737ee9b5so505928539f.0 for ; Fri, 29 Dec 2023 13:24:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885067; x=1704489867; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=NbLag/EB+bHmmgZuugtXh6y657JKbfbzieGWYM5hvCY=; b=oAYTO0+p3TOe6m9RMQJmhu13PywPs5SuS9/xbOlKKoS81DLoiiJD8aEqQgYiuGqYu8 +/BBtz6fTjacWVD2jl7iK3MPFnk/kNPUsUKICL/+oS13d8R1SApS/DBxLqToZ3+3qPFL ZEG+sN7Gq9u9JLARWIkNlAHB2lOtScXCLiPGOsbYlrTozaPymhaV7IN4m7qAR0MZqMY3 cBPra/h9SixPMazwVa23pRBaZZ01OMHLY5m/chn2tGuD7Rd4halPF95zJjI/FUNFx3aN v3UgfUMZcV2xGVNGMCsQ6hgWNvNiO5lI70FeXaxpISu4PoIgxzmTF4y6he1HbDwzbnLt /tRg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885067; x=1704489867; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=NbLag/EB+bHmmgZuugtXh6y657JKbfbzieGWYM5hvCY=; b=en/jJhbU6BHyKehXMwmAb9H6OxfNTNDGzdc0TS/VVzDrOxlaoHrS9lk6EL2GxVs+Gn uCcDcC2FiD1JzdQg0iRTTBQbu8yW6KPCwnVtcni7O9y6KoWjvzRPMbBto4vOXshIGGyv QsHluRUUJouI8yqNxNt334l7nCjyXG1iECxmQHx0krKwcI3998Z2HDqd3KrUoJFw2Pj9 r/D5j9clPazJSU1spJobD0SQCeylPUny2rpg6XAcYp2P2iv7fH9h3eizrOAHj0YIEYIG 5fC+BNhX/Wdt8uCrBYmKQcsDt2xge42KNNn+6kQdSvJ65MqKRUmT8Ec5pzKK13Q3gpbO pNfw== X-Gm-Message-State: AOJu0YxqxSLqvHufL3rIzldTuH1uTpwZwXn3TtJsle68sCuvKt4EwXkc m3jf3ulq5k/448MaaoamzFlPYNuKeNKUhx/WsioMh8TeyZb0qA== X-Received: by 2002:a05:6e02:2408:b0:35d:5995:7992 with SMTP id bs8-20020a056e02240800b0035d59957992mr22555504ilb.44.1703885067229; Fri, 29 Dec 2023 13:24:27 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.25 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:26 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 14/71] target/ppc: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:49 +1100 Message-Id: <20231229212346.147149-15-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::d33; envelope-from=richard.henderson@linaro.org; helo=mail-io1-xd33.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-15-richard.henderson@linaro.org> --- target/ppc/machine.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/target/ppc/machine.c b/target/ppc/machine.c index 68cbdffecd..203fe28e01 100644 --- a/target/ppc/machine.c +++ b/target/ppc/machine.c @@ -351,7 +351,7 @@ static const VMStateDescription vmstate_fpu = { .version_id = 1, .minimum_version_id = 1, .needed = fpu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FPR_ARRAY(env.vsr, PowerPCCPU, 32), VMSTATE_UINTTL(env.fpscr, PowerPCCPU), VMSTATE_END_OF_LIST() @@ -392,7 +392,7 @@ static const VMStateDescription vmstate_altivec = { .version_id = 1, .minimum_version_id = 1, .needed = altivec_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_AVR_ARRAY(env.vsr, PowerPCCPU, 32), /* * Save the architecture value of the vscr, not the internally @@ -425,7 +425,7 @@ static const VMStateDescription vmstate_vsx = { .version_id = 1, .minimum_version_id = 1, .needed = vsx_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VSR_ARRAY(env.vsr, PowerPCCPU, 32), VMSTATE_END_OF_LIST() }, @@ -445,7 +445,7 @@ static const VMStateDescription vmstate_tm = { .version_id = 1, .minimum_version_id = 1, .needed = tm_needed, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINTTL_ARRAY(env.tm_gpr, PowerPCCPU, 32), VMSTATE_AVR_ARRAY(env.tm_vsr, PowerPCCPU, 64), VMSTATE_UINT64(env.tm_cr, PowerPCCPU), @@ -479,7 +479,7 @@ static const VMStateDescription vmstate_sr = { .version_id = 1, .minimum_version_id = 1, .needed = sr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.sr, PowerPCCPU, 32), VMSTATE_END_OF_LIST() }, @@ -553,7 +553,7 @@ static const VMStateDescription vmstate_slb = { .minimum_version_id = 1, .needed = slb_needed, .post_load = slb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_TEST(mig_slb_nr, PowerPCCPU, cpu_pre_3_0_migration), VMSTATE_SLB_ARRAY(env.slb, PowerPCCPU, MAX_SLB_ENTRIES), VMSTATE_END_OF_LIST() @@ -565,7 +565,7 @@ static const VMStateDescription vmstate_tlb6xx_entry = { .name = "cpu/tlb6xx_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(pte0, ppc6xx_tlb_t), VMSTATE_UINTTL(pte1, ppc6xx_tlb_t), VMSTATE_UINTTL(EPN, ppc6xx_tlb_t), @@ -586,7 +586,7 @@ static const VMStateDescription vmstate_tlb6xx = { .version_id = 1, .minimum_version_id = 1, .needed = tlb6xx_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(env.nb_tlb, PowerPCCPU, NULL), VMSTATE_STRUCT_VARRAY_POINTER_INT32(env.tlb.tlb6, PowerPCCPU, env.nb_tlb, @@ -601,7 +601,7 @@ static const VMStateDescription vmstate_tlbemb_entry = { .name = "cpu/tlbemb_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(RPN, ppcemb_tlb_t), VMSTATE_UINTTL(EPN, ppcemb_tlb_t), VMSTATE_UINTTL(PID, ppcemb_tlb_t), @@ -625,7 +625,7 @@ static const VMStateDescription vmstate_tlbemb = { .version_id = 1, .minimum_version_id = 1, .needed = tlbemb_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(env.nb_tlb, PowerPCCPU, NULL), VMSTATE_STRUCT_VARRAY_POINTER_INT32(env.tlb.tlbe, PowerPCCPU, env.nb_tlb, @@ -639,7 +639,7 @@ static const VMStateDescription vmstate_tlbmas_entry = { .name = "cpu/tlbmas_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(mas8, ppcmas_tlb_t), VMSTATE_UINT32(mas1, ppcmas_tlb_t), VMSTATE_UINT64(mas2, ppcmas_tlb_t), @@ -661,7 +661,7 @@ static const VMStateDescription vmstate_tlbmas = { .version_id = 1, .minimum_version_id = 1, .needed = tlbmas_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(env.nb_tlb, PowerPCCPU, NULL), VMSTATE_STRUCT_VARRAY_POINTER_INT32(env.tlb.tlbm, PowerPCCPU, env.nb_tlb, @@ -684,7 +684,7 @@ static const VMStateDescription vmstate_compat = { .version_id = 1, .minimum_version_id = 1, .needed = compat_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(compat_pvr, PowerPCCPU), VMSTATE_END_OF_LIST() } @@ -700,7 +700,7 @@ static const VMStateDescription vmstate_reservation = { .version_id = 1, .minimum_version_id = 1, .needed = reservation_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(env.reserve_addr, PowerPCCPU), VMSTATE_UINTTL(env.reserve_length, PowerPCCPU), VMSTATE_UINTTL(env.reserve_val, PowerPCCPU), @@ -717,7 +717,7 @@ const VMStateDescription vmstate_ppc_cpu = { .minimum_version_id = 5, .pre_save = cpu_pre_save, .post_load = cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UNUSED(sizeof(target_ulong)), /* was _EQUAL(env.spr[SPR_PVR]) */ /* User mode architected state */ @@ -748,7 +748,7 @@ const VMStateDescription vmstate_ppc_cpu = { VMSTATE_UINT32_TEST(mig_nb_BATs, PowerPCCPU, cpu_pre_2_8_migration), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fpu, &vmstate_altivec, &vmstate_vsx, From patchwork Fri Dec 29 21:22:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758800 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670956wrw; Fri, 29 Dec 2023 13:26:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IHp/JRg9gV714V2uO+Qa+a6+21s40mcTNrTHHwIdMvVLoWI2q93h1lwWawo5TdLWU1gDKZb X-Received: by 2002:a05:620a:6285:b0:781:610d:585e with SMTP id ov5-20020a05620a628500b00781610d585emr4519187qkn.113.1703885162989; Fri, 29 Dec 2023 13:26:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885162; cv=none; d=google.com; s=arc-20160816; b=pa7nzfMPM2QyUY+P4joHcwHRXzMP/piPPuPvjPLU7ktsHpNyyLDpOFV4D/25+aqlI5 kAXY00O3Xsk0dVum6TI6rtqxyArqUgBsj1MRyPWB61QHDIuEFx8s2pKQD8GXIo3jBO7l +DqjP2KdWmYvzBzf3DgBEZpZ5h71HQSAEP6i62Dlm0oxKRfygVG2R8WeRbkLvPU+pZjs uXIdLk5fdZVp2nbLvEZFtjg8M50MaGO/oc0Flqc8KYFFQNWLF/gDcKKr6BKjCqh9KmKH HcQq+0lYN8riUrQBp/XSGdqhCzXXDHg3to5vcvsmrzHVXzS620B8JzpydN3LBXIoScwc m8iQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=GagVqcPQHuKFmUNCXS0XsIJu0ULMlIKav1OQs/IsaFA=; fh=OD2lp1dfJFstOGLpXnIzbHomhWx3nF/XGvY6bQVU7c8=; b=Tv/RKO1lmmNjnLg80I6Q75ZAqK/4EFMOvItaWjHnvmQuYxs6zcI5kIVJxzV7/+D7TO uLYq2peDRurSspvZXLIIarORXpGGcesk1ro7UG8E3S+II7iuCKI+sP1I0E4El6baTeDF ny3Q1AkWRkI4JvmwazS41gJPXi+OaT85Iz+sY7A3EEJoesNfpbahym9FbXdiwAuf89IO 2bRgaYwiXz5XOVl5glJXC8ilBkXHUIJ/06XFCuD7k5XUTtWzO8oj99cOk0WNljDOJ4xa kyp0iBH+T7xO5bW07qlSg9c9QbsMb+Dw+hHvr/iT9GwtbO5hjQXwvSE1thIxnToLzPkF YrBg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V31xoIAT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g14-20020a05620a108e00b0077f5759e06bsi18697049qkk.781.2023.12.29.13.26.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:26:02 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=V31xoIAT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLK-000713-6E; Fri, 29 Dec 2023 16:24:34 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLI-0006z3-R2 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:32 -0500 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLH-0006gH-1D for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:32 -0500 Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-6d9e62ff056so2711576b3a.1 for ; Fri, 29 Dec 2023 13:24:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885070; x=1704489870; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=GagVqcPQHuKFmUNCXS0XsIJu0ULMlIKav1OQs/IsaFA=; b=V31xoIATCLbG1LdDwdi0xOYOug0PZZKqzSnfw65WCkxwif/10NTCiPNuFKHBW08dwa fdQE8hIIUFXZrSuNQJZUQgQzgE0q0xUaOW6Q+Us5HOdDFWk9S36zvuX2STo5eidomcGJ /qF/cu1DCvRnLdva0lcAvzOIHiBsNlczq30gsrFS5G4aT5+U+SXvSvVyzT6hrWmtDbq6 JX0rXslF1A6sHtRSfXmOB6j2y1e9QUxHBTwvFu25abmpJayTC5rLVnMNJD4iKIxWD9Qk /oj2i2iYzErd2NNin5eH1/RJ3Bq6KJ7tb+K87z6BDhI3J9g0iyASvx/MIhtTcUylp2GR tboQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885070; x=1704489870; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GagVqcPQHuKFmUNCXS0XsIJu0ULMlIKav1OQs/IsaFA=; b=P8JfL3ZJSTbTSnuzpZbTmNb7GIsgBe6dzqUjw1ZEXlY2IXM26G+CkU8dZt6fjujtFe RtgbJC4x1hYYgg1gVPujPaZyhyVx/ypG54tptQNoVlMeBSWRTqAeLRAQVtEehCgUElex uT/bCR7iE55l8KRRUZIPkr32Cbk9vasOSPOxHiR2wQ9IBpuuhDCMXp7wr4DjNZ/h5i41 Hz//bjxQjB/6OcfnTR2CIQeHOL2xbRHV0DsU+1fm3bfv4/s+iu7E7wYmCstvImNL9TRQ KmdM0WuRXqj6SX39tigeTEvXKvma+9P0DIn+0RjOrB+50wvMwQ5Xr6Aib5zGG5/UfrvU JUyA== X-Gm-Message-State: AOJu0YyrktRPzl7N9Egqpw3fgo6Knky0DrccpYfyT9WeovEhGNBSGa2/ qXTpT5yGMMXJGjx+WBE3KQQYyDMQE+D2fy5DSNU42YRKTVZ8LQ== X-Received: by 2002:a05:6a21:1a0:b0:195:dad0:7185 with SMTP id le32-20020a056a2101a000b00195dad07185mr8403380pzb.96.1703885069735; Fri, 29 Dec 2023 13:24:29 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:29 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Alistair Francis Subject: [PULL 15/71] target/riscv: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:50 +1100 Message-Id: <20231229212346.147149-16-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::436; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x436.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Acked-by: Alistair Francis Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-16-richard.henderson@linaro.org> --- target/riscv/machine.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/target/riscv/machine.c b/target/riscv/machine.c index fdde243e04..72fe2374dc 100644 --- a/target/riscv/machine.c +++ b/target/riscv/machine.c @@ -49,7 +49,7 @@ static const VMStateDescription vmstate_pmp_entry = { .name = "cpu/pmp/entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(addr_reg, pmp_entry_t), VMSTATE_UINT8(cfg_reg, pmp_entry_t), VMSTATE_END_OF_LIST() @@ -62,7 +62,7 @@ static const VMStateDescription vmstate_pmp = { .minimum_version_id = 1, .needed = pmp_needed, .post_load = pmp_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(env.pmp_state.pmp, RISCVCPU, MAX_RISCV_PMPS, 0, vmstate_pmp_entry, pmp_entry_t), VMSTATE_END_OF_LIST() @@ -82,7 +82,7 @@ static const VMStateDescription vmstate_hyper = { .version_id = 3, .minimum_version_id = 3, .needed = hyper_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(env.hstatus, RISCVCPU), VMSTATE_UINTTL(env.hedeleg, RISCVCPU), VMSTATE_UINT64(env.hideleg, RISCVCPU), @@ -138,7 +138,7 @@ static const VMStateDescription vmstate_vector = { .version_id = 2, .minimum_version_id = 2, .needed = vector_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.vreg, RISCVCPU, 32 * RV_VLEN_MAX / 64), VMSTATE_UINTTL(env.vxrm, RISCVCPU), VMSTATE_UINTTL(env.vxsat, RISCVCPU), @@ -163,7 +163,7 @@ static const VMStateDescription vmstate_pointermasking = { .version_id = 1, .minimum_version_id = 1, .needed = pointermasking_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(env.mmte, RISCVCPU), VMSTATE_UINTTL(env.mpmmask, RISCVCPU), VMSTATE_UINTTL(env.mpmbase, RISCVCPU), @@ -189,7 +189,7 @@ static const VMStateDescription vmstate_rv128 = { .version_id = 1, .minimum_version_id = 1, .needed = rv128_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.gprh, RISCVCPU, 32), VMSTATE_UINT64(env.mscratchh, RISCVCPU), VMSTATE_UINT64(env.sscratchh, RISCVCPU), @@ -218,7 +218,7 @@ static const VMStateDescription vmstate_kvmtimer = { .minimum_version_id = 1, .needed = kvmtimer_needed, .post_load = cpu_kvmtimer_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.kvm_timer_time, RISCVCPU), VMSTATE_UINT64(env.kvm_timer_compare, RISCVCPU), VMSTATE_UINT64(env.kvm_timer_state, RISCVCPU), @@ -252,7 +252,7 @@ static const VMStateDescription vmstate_debug = { .minimum_version_id = 2, .needed = debug_needed, .post_load = debug_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(env.trigger_cur, RISCVCPU), VMSTATE_UINTTL_ARRAY(env.tdata1, RISCVCPU, RV_MAX_TRIGGERS), VMSTATE_UINTTL_ARRAY(env.tdata2, RISCVCPU, RV_MAX_TRIGGERS), @@ -283,7 +283,7 @@ static const VMStateDescription vmstate_smstateen = { .version_id = 1, .minimum_version_id = 1, .needed = smstateen_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.mstateen, RISCVCPU, 4), VMSTATE_UINT64_ARRAY(env.hstateen, RISCVCPU, 4), VMSTATE_UINT64_ARRAY(env.sstateen, RISCVCPU, 4), @@ -304,7 +304,7 @@ static const VMStateDescription vmstate_envcfg = { .version_id = 1, .minimum_version_id = 1, .needed = envcfg_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.menvcfg, RISCVCPU), VMSTATE_UINTTL(env.senvcfg, RISCVCPU), VMSTATE_UINT64(env.henvcfg, RISCVCPU), @@ -324,7 +324,7 @@ static const VMStateDescription vmstate_pmu_ctr_state = { .version_id = 1, .minimum_version_id = 1, .needed = pmu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(mhpmcounter_val, PMUCTRState), VMSTATE_UINTTL(mhpmcounterh_val, PMUCTRState), VMSTATE_UINTTL(mhpmcounter_prev, PMUCTRState), @@ -346,7 +346,7 @@ static const VMStateDescription vmstate_jvt = { .version_id = 1, .minimum_version_id = 1, .needed = jvt_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL(env.jvt, RISCVCPU), VMSTATE_END_OF_LIST() } @@ -357,7 +357,7 @@ const VMStateDescription vmstate_riscv_cpu = { .version_id = 9, .minimum_version_id = 9, .post_load = riscv_cpu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.gpr, RISCVCPU, 32), VMSTATE_UINT64_ARRAY(env.fpr, RISCVCPU, 32), VMSTATE_UINT8_ARRAY(env.miprio, RISCVCPU, 64), @@ -411,7 +411,7 @@ const VMStateDescription vmstate_riscv_cpu = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_pmp, &vmstate_hyper, &vmstate_vector, From patchwork Fri Dec 29 21:22:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758803 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671225wrw; Fri, 29 Dec 2023 13:27:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IHfCePM5rRPd/bCksZhRU8iwRMGbSiuVMFb8UTsnrxjdL1HatmdPnhfkt8SYm7R61dRULCA X-Received: by 2002:a05:6808:338b:b0:3bb:c774:563c with SMTP id ce11-20020a056808338b00b003bbc774563cmr4425769oib.61.1703885227288; Fri, 29 Dec 2023 13:27:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885227; cv=none; d=google.com; s=arc-20160816; b=kC3o7r6zJichAUD6k/4aLr5td3Gs5gG/86La1obPVTGC6InNLABtxsCPOI4aFEChp6 nAIX3SN8UxqwTM6Aa390TIw/g9Eyaj+AwJA/qfVXO+YpThdsFxUyY+cC7l3ZAiX/L7KF 6reuP+LGUZAz31aYuQ9G2WxK80MqKzODxd22hdgKUxZgkDyEdX0pGI6QQrbv3B+JMAmE WlObGeuy99Ks0u17IdiY56NEYkQJN4QJPr/clK9RJhXsYIsDjIUlBzqWMD561b6gaY8+ JsFbzBuNXaV6IZIvXFj4x/qENF1rIMEZk0wT6iRHJCngqiSWKBoecvFt/ltbnUV56usC q3Jw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=CWWqpcyXTMz7Xz2FP1em44VzN8AMs3WMuNzELPAxUXs=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=R2dZQg9eLHXyifz6z+iDkA9gdhj8gd+FtuCH8rti1lgFS6djXkc2NAQ9GrAPAXYlBC NK3hLNGRUo5VgG2yOtBl1L47s32JY6NEsq2YLD2f8MzlhcY8O9uiI9ENvG6aMiCMe/wo ci/dGxB7w7WjW4U1ewvscC4pDCAOs/vyIcedUhaB+d0uJXC/E+YV367Vsix/SSp4ksKz wuvmrYWCX/dtg5llr32imkb1we4rJqA692ruYHokRq5piRldeQYOaA6E6d2a0Eu8A+Wi EW+PLSZsN8to/MMZb+4F2w1NpHaNgkeORBCkgXUcOy+gvSMR7cYvQbioWWhkcUC5dPHF vYLA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nuRG0sEL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c7-20020a0ce147000000b0067f623d7750si17888538qvl.468.2023.12.29.13.27.07 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:07 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=nuRG0sEL; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLN-00076L-QZ; Fri, 29 Dec 2023 16:24:37 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLL-00075R-Mm for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:35 -0500 Received: from mail-pg1-x52f.google.com ([2607:f8b0:4864:20::52f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLJ-0006iY-1R for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:35 -0500 Received: by mail-pg1-x52f.google.com with SMTP id 41be03b00d2f7-5cdfed46372so4075063a12.3 for ; Fri, 29 Dec 2023 13:24:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885072; x=1704489872; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=CWWqpcyXTMz7Xz2FP1em44VzN8AMs3WMuNzELPAxUXs=; b=nuRG0sELlKyURlE6DWlxfWPCVx8KKKiYVtnSrMUmCKixunW197g2CP+c+PYjKx7zU+ tVVvtizm85Klny6nGxwxq1VYv221etCvncxc77mEqjBZZZhNBYur0oOY/kwtzKxYVYPV Rgzi0mshwyzaCZ0gOSh3vsACZR6HZych+w6KRD0vg2zopbqEuTvtiEXiB3ngvQ04UZlJ jMO6zvMkih0L2nL/OrEE1YLemHNEYkWL0dA0JdRJ+3KYqp1ZdXjVVIGlz2ZjS2laqqX4 SqJkegta1o+YJtzqFdZwLkpXuNaU+pV3qpID9GR70rLp5QyZngqiQlr+O87WPfAotvPE ht/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885072; x=1704489872; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CWWqpcyXTMz7Xz2FP1em44VzN8AMs3WMuNzELPAxUXs=; b=Dfypk8F7DZcwGA44/iRfvSHibz41U3DZRMhX/svOki1RLInZO+anAJhzwQrQTfGNZ8 JS9a8fbxip59lLIMH5GHQIRMlerpihj5aQFkh6gD88jZq5UwW+tHiUw1z/9NiwReEqAe TjtTkQ0I817axWBZt4rzTDyHZqOVvxWcuINEGTar33WQ4La+m7ahiKP+vJFidTpJG55U SSIRPODRk6G3nF2W+ZV5eGfbWvNloto8v8iht++lBWZq3WGyocVS9xzaAo+8CA34JokB 6fzKqVCo5/lzfCJjwQC85wJ54ccG7v1CTiN8g129HLmEK68c1hmozxEELoDV+sEe4Gg0 g8Wg== X-Gm-Message-State: AOJu0YxI6iGE2DL4Kje9tNbtii0RI9NWSXq3FCNoRd9Lo7NcdcYL1h2Z ptdaLkIMmVJ+/vB+nse3a03Gvor0/Vfm6bw76hnQXbQL3FT/eg== X-Received: by 2002:a05:6a20:6311:b0:18c:2d7:c4b0 with SMTP id h17-20020a056a20631100b0018c02d7c4b0mr11389742pzf.4.1703885071718; Fri, 29 Dec 2023 13:24:31 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:31 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 16/71] target/s390x: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:51 +1100 Message-Id: <20231229212346.147149-17-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52f; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52f.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-17-richard.henderson@linaro.org> --- target/s390x/machine.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/target/s390x/machine.c b/target/s390x/machine.c index 37a076858c..a125ebcc2f 100644 --- a/target/s390x/machine.c +++ b/target/s390x/machine.c @@ -66,7 +66,7 @@ static const VMStateDescription vmstate_fpu = { .version_id = 1, .minimum_version_id = 1, .needed = fpu_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.vregs[0][0], S390CPU), VMSTATE_UINT64(env.vregs[1][0], S390CPU), VMSTATE_UINT64(env.vregs[2][0], S390CPU), @@ -98,7 +98,7 @@ static const VMStateDescription vmstate_vregs = { .version_id = 1, .minimum_version_id = 1, .needed = vregs_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* vregs[0][0] -> vregs[15][0] and fregs are overlays */ VMSTATE_UINT64(env.vregs[16][0], S390CPU), VMSTATE_UINT64(env.vregs[17][0], S390CPU), @@ -157,12 +157,12 @@ static bool riccb_needed(void *opaque) return s390_has_feat(S390_FEAT_RUNTIME_INSTRUMENTATION); } -const VMStateDescription vmstate_riccb = { +static const VMStateDescription vmstate_riccb = { .name = "cpu/riccb", .version_id = 1, .minimum_version_id = 1, .needed = riccb_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(env.riccb, S390CPU, 64), VMSTATE_END_OF_LIST() } @@ -174,12 +174,12 @@ static bool exval_needed(void *opaque) return cpu->env.ex_value != 0; } -const VMStateDescription vmstate_exval = { +static const VMStateDescription vmstate_exval = { .name = "cpu/exval", .version_id = 1, .minimum_version_id = 1, .needed = exval_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.ex_value, S390CPU), VMSTATE_END_OF_LIST() } @@ -190,12 +190,12 @@ static bool gscb_needed(void *opaque) return s390_has_feat(S390_FEAT_GUARDED_STORAGE); } -const VMStateDescription vmstate_gscb = { +static const VMStateDescription vmstate_gscb = { .name = "cpu/gscb", .version_id = 1, .minimum_version_id = 1, .needed = gscb_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.gscb, S390CPU, 4), VMSTATE_END_OF_LIST() } @@ -206,12 +206,12 @@ static bool bpbc_needed(void *opaque) return s390_has_feat(S390_FEAT_BPB); } -const VMStateDescription vmstate_bpbc = { +static const VMStateDescription vmstate_bpbc = { .name = "cpu/bpbc", .version_id = 1, .minimum_version_id = 1, .needed = bpbc_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(env.bpbc, S390CPU), VMSTATE_END_OF_LIST() } @@ -222,12 +222,12 @@ static bool etoken_needed(void *opaque) return s390_has_feat(S390_FEAT_ETOKEN); } -const VMStateDescription vmstate_etoken = { +static const VMStateDescription vmstate_etoken = { .name = "cpu/etoken", .version_id = 1, .minimum_version_id = 1, .needed = etoken_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.etoken, S390CPU), VMSTATE_UINT64(env.etoken_extension, S390CPU), VMSTATE_END_OF_LIST() @@ -239,12 +239,12 @@ static bool diag318_needed(void *opaque) return s390_has_feat(S390_FEAT_DIAG_318); } -const VMStateDescription vmstate_diag318 = { +static const VMStateDescription vmstate_diag318 = { .name = "cpu/diag318", .version_id = 1, .minimum_version_id = 1, .needed = diag318_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(env.diag318_info, S390CPU), VMSTATE_END_OF_LIST() } @@ -256,7 +256,7 @@ const VMStateDescription vmstate_s390_cpu = { .pre_save = cpu_pre_save, .version_id = 4, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_ARRAY(env.regs, S390CPU, 16), VMSTATE_UINT64(env.psw.mask, S390CPU), VMSTATE_UINT64(env.psw.addr, S390CPU), @@ -278,7 +278,7 @@ const VMStateDescription vmstate_s390_cpu = { irqstate_saved_size), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fpu, &vmstate_vregs, &vmstate_riccb, From patchwork Fri Dec 29 21:22:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758814 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671557wrw; Fri, 29 Dec 2023 13:28:20 -0800 (PST) X-Google-Smtp-Source: AGHT+IEg1i5+W67rLfAOHtvY0Fh2gyKUm2TLM8e8IC/AByB5LGtC/tdYfe5jvJvmP+5cehGDIk8k X-Received: by 2002:a05:620a:44d3:b0:781:5f72:f962 with SMTP id y19-20020a05620a44d300b007815f72f962mr5001895qkp.131.1703885299659; Fri, 29 Dec 2023 13:28:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885299; cv=none; d=google.com; s=arc-20160816; b=qreX4HsCe3iaqGrpEEBQ3kjr/OcQF7WCejOkj7wpYnFnE72xEmf3Y4QhHfMWHOc8GK +O5Xm8crOpT1q899q12PxzpZPeC0IHY/+h5JTK5r8g7LhYWdj2UHOWoMscJtlhb2q8em UGagstAhiFoDFYGvDaG2+PIDyC0Ga4KxRGG11a2QWPvR5TIx+VJ4SGIeHwVs3lFrXwwJ 9b2QoMCS3ZWWfmM0weeaWS27+FfURfVI3VFJeKm67WjTWE6u03BEmttguHcyob7M1sNe j5zCCgXGrI3vGgesPfGazl5Pwsts9/7qvA7Ok6WdP+NdEFzyDl/pkePTdIT9H6ws/1ui 5mRg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=LI81JsuIm1ZNENuf49HeeV43cGqA8WHtNsvGxM/VR4U=; fh=rYI8DiHAAFX3O5g969KmOAQ7d45Sb8OxQX1+DywGDk4=; b=huL+nmaYJ956IE8qTPb30wEAXfNt5ic3p1VhXKd5Arl+9v9IlhYLcOeWbyawMhdhBE TSdyhXOFloESNgTYZY055qVDsvN056PW8hFdkr9OhOQAYGCxSbyQ+nKdvdsHe+/Qbktz A6hVCU4QkosF84RPYqy4dMp2SNWvZi9fyuhdM9LqoTbL5gAoAUQeUCE3xnbOsmVnn2Ax OmDajJNT5fHwQvDh2ewS2+dHVjAZfBQLBbaEYztq3pl/27+tQ1Eb1+8zceGBNMd3X8Vy daJYUGWPpMqWsvOGm30WTY0OTlzmnfZKMVrxP8vTW006QjX0xKY/+tcsG8gwRoejr/MF qsWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zUPAC5o0; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g14-20020a05620a108e00b0077f5759e06bsi18700735qkk.781.2023.12.29.13.28.19 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:19 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zUPAC5o0; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLP-0007B0-Vf; Fri, 29 Dec 2023 16:24:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLO-000793-S5 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:38 -0500 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLM-0006kS-BE for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:38 -0500 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-6d9f94b9186so2214424b3a.0 for ; Fri, 29 Dec 2023 13:24:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885074; x=1704489874; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LI81JsuIm1ZNENuf49HeeV43cGqA8WHtNsvGxM/VR4U=; b=zUPAC5o0o9tpb7WMrXxdhEzriw2DjTnvElApjqwG9LurOfJc2LPwhD2yfj7pm1y8nf 4/u9sqEa1/cBfrBMmFzjOHDOlSlAAcXPvOdp/hI1puNRvAHuN9LOgRGlFI6twpA0Akpz n1FMePHc5ZNjuXGwNFgnQDyhDhI6Vw+8dR36YQZoRKWmfKNNr+jIaIehAiI1zm/PTXjM 989B+L5HvTCDLpkUbNBEVMONzQwYG+Bw+4YwydNa7c+fTtK7g4v/vfj4UCYMmhvQihIC UHF/OF6n0rIAPJjcDti2XNEWx9+Be2vvbJdunu0YmbgU0JGPgi7lgQARGYggfGnZtAZG 5Pqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885074; x=1704489874; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LI81JsuIm1ZNENuf49HeeV43cGqA8WHtNsvGxM/VR4U=; b=WwWN+GrIOYN/8ZcQvys7K/H+n10C9w+nyGL1pL3vTxZ6XLYFJW/y9Vmt0ba9DK11mQ CltVdOySy7XEmsV5DcOwZCuEBh2lNQct+XHwbcaSKVwsU7gYgo1GuqLfLI1CI8x644WE 5FDMJInw/5Ywz2uO1nymruwL/BfcgmWF6LA4aF5NTIrooi1I/A45at2UJzeLYtfCRXL5 l8i0fQtN2yjm+AzLP+ak9zVwj2p7Mwo/60UkUVMbOvmB3nscv+I3EOATQddgLkRtAdfV w8qlnsueVbwg7SyqhjKrE7UBywSkwb8jLkeCSM9bHAJ+cIUqfVEm6GOb11T9UCGzB78M 9p0w== X-Gm-Message-State: AOJu0YyvQWR6myXa4vyauc9NF4DHpqC/fT4G7P2568NXOI4e9yO4zkze DNLUKkSLLqNU9R7UnH5rDS/gfxN32xQMKFnxWfBpoyOxdJzgJw== X-Received: by 2002:aa7:8b48:0:b0:6d9:8f6f:6b7e with SMTP id i8-20020aa78b48000000b006d98f6f6b7emr11500576pfd.56.1703885074032; Fri, 29 Dec 2023 13:24:34 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:33 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Mark Cave-Ayland Subject: [PULL 17/71] target/sparc: Constify VMState in machine.c Date: Sat, 30 Dec 2023 08:22:52 +1100 Message-Id: <20231229212346.147149-18-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::434; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x434.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Mark Cave-Ayland Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-18-richard.henderson@linaro.org> --- target/sparc/machine.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/target/sparc/machine.c b/target/sparc/machine.c index 44dfc07014..2b5686c330 100644 --- a/target/sparc/machine.c +++ b/target/sparc/machine.c @@ -10,7 +10,7 @@ static const VMStateDescription vmstate_cpu_timer = { .name = "cpu_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(frequency, CPUTimer), VMSTATE_UINT32(disabled, CPUTimer), VMSTATE_UINT64(disabled_mask, CPUTimer), @@ -29,7 +29,7 @@ static const VMStateDescription vmstate_trap_state = { .name = "trap_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tpc, trap_state), VMSTATE_UINT64(tnpc, trap_state), VMSTATE_UINT64(tstate, trap_state), @@ -42,7 +42,7 @@ static const VMStateDescription vmstate_tlb_entry = { .name = "tlb_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tag, SparcTLBEntry), VMSTATE_UINT64(tte, SparcTLBEntry), VMSTATE_END_OF_LIST() @@ -147,7 +147,7 @@ const VMStateDescription vmstate_sparc_cpu = { .version_id = SPARC_VMSTATE_VER, .minimum_version_id = SPARC_VMSTATE_VER, .pre_save = cpu_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINTTL_ARRAY(env.gregs, SPARCCPU, 8), VMSTATE_UINT32(env.nwindows, SPARCCPU), VMSTATE_VARRAY_MULTIPLY(env.regbase, SPARCCPU, env.nwindows, 16, From patchwork Fri Dec 29 21:22:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758817 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671572wrw; Fri, 29 Dec 2023 13:28:24 -0800 (PST) X-Google-Smtp-Source: AGHT+IF9hAHEg9nlG6QoFmM/7IRAPraQfdHQQGmXbswBaThj0rqgd2Fu64fwLCkiMUqJnvWekfNn X-Received: by 2002:a05:622a:48a:b0:427:851a:ddfa with SMTP id p10-20020a05622a048a00b00427851addfamr16974748qtx.20.1703885304432; Fri, 29 Dec 2023 13:28:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885304; cv=none; d=google.com; s=arc-20160816; b=0r7g/EHm84sfNUL49N/rBVKnsJ6Q20+nUVxo5cvw6nwG+YNmtW78dkhkN+pPPd6cOO 3eW1zEzG+tDXaAo3rWrsDYwpg3px+NVr5ztSL2okO47P3mY0WpmbjBsJuiR6Wg34YYAg 47IcKyA3NbWsM2aqjkFL0f6NJsck9UEVJZm/m1HY2BsjC46hYNxSzBnXumP6wxjr8RtE OZfhgSKYQuegKBGfAj3h0A3jDeSBxFxrZr0eQKnckc4oJUX/DkUl1qmOym7XvBqnu3ig dAf9RYCCtAWkpYuUhEqJiwafznQBxdof/ILBpolxnaTzqeWShS8WuAKaWmkV1lGtqJqU QmNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=+rc1PcOkeKg5VLZFzRGj/U/rtJvZF1IpsUq8e3b5Odc=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=sx6he+VDURjRLv6WndWMYXArDHNWzuGES1dFae6rR3VJ7LpWzlMRWom6rk4b7PfMq/ GF2hFkhW0t2k77E0ORSxOJ7WcQGDVbN0K0UfhBmOB3/Q1bpWcykZlDdcBmi9nE6JYHJO W6VhlfbZlqaQcgNHy4s63hEBABulzQ0WiriwBdVQ1XjLrdfmr7H+tbgp5H8e8NtNgK1i udzDPnzTc95xNdxBlNVvdhU7yBXCxJE2YQNPr04iJKpPJE1KreIzSNiOTrZzfyFyg60P LP6lfHsQOeALxT8pQs7B9vB6hj9DIDR31AcDcnqQ8n/+2gWZ0B0kzokAv7lypVM0A8yd 8jXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=YTHjwYSI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id s9-20020a05622a178900b00417b8ceb616si19938411qtk.403.2023.12.29.13.28.24 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:24 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=YTHjwYSI; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLR-0007Cg-Ja; Fri, 29 Dec 2023 16:24:41 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLQ-0007BQ-HB for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:40 -0500 Received: from mail-pf1-x42f.google.com ([2607:f8b0:4864:20::42f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLN-0006lC-Ud for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:40 -0500 Received: by mail-pf1-x42f.google.com with SMTP id d2e1a72fcca58-6da16ec9be4so1554417b3a.1 for ; Fri, 29 Dec 2023 13:24:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885076; x=1704489876; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=+rc1PcOkeKg5VLZFzRGj/U/rtJvZF1IpsUq8e3b5Odc=; b=YTHjwYSIAT07go967rSyNjx+vynDZXgp4BM7o+YHvwwYPytxI3+P3KOcU0CY70vKj+ tpCxk3XVlfVjgbJHKLf9cxDdNRncoaBpW+9R3I/fYtx8/lju645n/DIFUW4jIwSQytrV eIMYvGQe5N/G5FYgkQAmNHbzFuhP6P/xWE/FWYX1A+HfNV6M5Iy3S2DroucJ3Sgz1Jzk yVBbRp6uVSESXzjE7Zs7fso43gK3Pl099dpYu1o8COcET+vSY/eAhGIvdjFAHNIFBUxH k6ZmQ9AKSoYEjmeafg0Z037WEvDRtvMqWjx57mDz1YgjOOUHcot2cJV+VadmLc5a4Ok/ wfoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885076; x=1704489876; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+rc1PcOkeKg5VLZFzRGj/U/rtJvZF1IpsUq8e3b5Odc=; b=NsRIhhcPRCqwoeVHjAM2De49WL42DAA29FRtm7Aw7LuKa6zg5AsF6k2hlw798XBbJb uPLuHXaMOfNbTbdnRb7Gik+sv2E3QeQCLQ0U3XNsaFptP83Kmouk6f3SjOsYr96iDAOg kuxfBanqipF5+f4T5d8mC3/6IgSXnOYwZrdqFTtMZq+p1Ix9foqSepRDWj99D7vFNjGr f4UnXNSAe0NI9LozttPq0n03vcrprLCHP2bYw0nd9p36KECJS/4ZUI/PhArOaffFUmtH 2+OrHuaKWU+qlA0VaNYq/I1/ofKNXx3U+jk7DDm1H7ZGDr6q31R8IKHl5lpMNV+e8mKq cT9g== X-Gm-Message-State: AOJu0YzPyaTHcssXzIxONUeW77lNgPw7OLkplDj1X4Sh7bliE2UNQKo0 jQdIBRFENP+2FIsiQmONsndh7VMKrVZGTWma1btnn+qahDsL7Q== X-Received: by 2002:aa7:8c42:0:b0:6d9:ac6f:20b4 with SMTP id e2-20020aa78c42000000b006d9ac6f20b4mr8949565pfd.42.1703885076371; Fri, 29 Dec 2023 13:24:36 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:36 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 18/71] hw/arm: Constify VMState Date: Sat, 30 Dec 2023 08:22:53 +1100 Message-Id: <20231229212346.147149-19-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42f; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42f.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-19-richard.henderson@linaro.org> --- hw/arm/armsse.c | 2 +- hw/arm/armv7m.c | 2 +- hw/arm/highbank.c | 2 +- hw/arm/integratorcp.c | 6 +++--- hw/arm/musicpal.c | 14 +++++++------- hw/arm/pxa2xx.c | 18 +++++++++--------- hw/arm/pxa2xx_gpio.c | 2 +- hw/arm/pxa2xx_pic.c | 2 +- hw/arm/smmuv3.c | 8 ++++---- hw/arm/spitz.c | 8 ++++---- hw/arm/stellaris.c | 6 +++--- hw/arm/strongarm.c | 12 ++++++------ hw/arm/versatilepb.c | 2 +- hw/arm/virt-acpi-build.c | 2 +- hw/arm/z2.c | 4 ++-- 15 files changed, 45 insertions(+), 45 deletions(-) diff --git a/hw/arm/armsse.c b/hw/arm/armsse.c index 31acbf7347..02b4f6596f 100644 --- a/hw/arm/armsse.c +++ b/hw/arm/armsse.c @@ -1677,7 +1677,7 @@ static const VMStateDescription armsse_vmstate = { .name = "iotkit", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(mainclk, ARMSSE), VMSTATE_CLOCK(s32kclk, ARMSSE), VMSTATE_UINT32(nsccfg, ARMSSE), diff --git a/hw/arm/armv7m.c b/hw/arm/armv7m.c index d10abb36a8..375a40962f 100644 --- a/hw/arm/armv7m.c +++ b/hw/arm/armv7m.c @@ -559,7 +559,7 @@ static const VMStateDescription vmstate_armv7m = { .name = "armv7m", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(refclk, ARMv7MState), VMSTATE_CLOCK(cpuclk, ARMv7MState), VMSTATE_END_OF_LIST() diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c index f12aacea6b..c21e18d08f 100644 --- a/hw/arm/highbank.c +++ b/hw/arm/highbank.c @@ -112,7 +112,7 @@ static const VMStateDescription vmstate_highbank_regs = { .name = "highbank-regs", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, HighbankRegsState, NUM_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/arm/integratorcp.c b/hw/arm/integratorcp.c index d176e9af7e..e602ca5e14 100644 --- a/hw/arm/integratorcp.c +++ b/hw/arm/integratorcp.c @@ -63,7 +63,7 @@ static const VMStateDescription vmstate_integratorcm = { .name = "integratorcm", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cm_osc, IntegratorCMState), VMSTATE_UINT32(cm_ctrl, IntegratorCMState), VMSTATE_UINT32(cm_lock, IntegratorCMState), @@ -346,7 +346,7 @@ static const VMStateDescription vmstate_icp_pic = { .name = "icp_pic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, icp_pic_state), VMSTATE_UINT32(irq_enabled, icp_pic_state), VMSTATE_UINT32(fiq_enabled, icp_pic_state), @@ -488,7 +488,7 @@ static const VMStateDescription vmstate_icp_control = { .name = "icp_control", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(intreg_state, ICPCtrlRegsState), VMSTATE_END_OF_LIST() } diff --git a/hw/arm/musicpal.c b/hw/arm/musicpal.c index 9703bfb97f..3200c9f68a 100644 --- a/hw/arm/musicpal.c +++ b/hw/arm/musicpal.c @@ -275,7 +275,7 @@ static const VMStateDescription musicpal_lcd_vmsd = { .name = "musicpal_lcd", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(brightness, musicpal_lcd_state), VMSTATE_UINT32(mode, musicpal_lcd_state), VMSTATE_UINT32(irqctrl, musicpal_lcd_state), @@ -400,7 +400,7 @@ static const VMStateDescription mv88w8618_pic_vmsd = { .name = "mv88w8618_pic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, mv88w8618_pic_state), VMSTATE_UINT32(enabled, mv88w8618_pic_state), VMSTATE_END_OF_LIST() @@ -583,7 +583,7 @@ static const VMStateDescription mv88w8618_timer_vmsd = { .name = "timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(ptimer, mv88w8618_timer_state), VMSTATE_UINT32(limit, mv88w8618_timer_state), VMSTATE_END_OF_LIST() @@ -594,7 +594,7 @@ static const VMStateDescription mv88w8618_pit_vmsd = { .name = "mv88w8618_pit", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(timer, mv88w8618_pit_state, 4, 1, mv88w8618_timer_vmsd, mv88w8618_timer_state), VMSTATE_END_OF_LIST() @@ -681,7 +681,7 @@ static const VMStateDescription mv88w8618_flashcfg_vmsd = { .name = "mv88w8618_flashcfg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cfgr0, mv88w8618_flashcfg_state), VMSTATE_END_OF_LIST() } @@ -1015,7 +1015,7 @@ static const VMStateDescription musicpal_gpio_vmsd = { .name = "musicpal_gpio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(lcd_brightness, musicpal_gpio_state), VMSTATE_UINT32(out_state, musicpal_gpio_state), VMSTATE_UINT32(in_state, musicpal_gpio_state), @@ -1174,7 +1174,7 @@ static const VMStateDescription musicpal_key_vmsd = { .name = "musicpal_key", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(kbd_extended, musicpal_key_state), VMSTATE_UINT32(pressed_keys, musicpal_key_state), VMSTATE_END_OF_LIST() diff --git a/hw/arm/pxa2xx.c b/hw/arm/pxa2xx.c index f0bf407e66..6b2e54473b 100644 --- a/hw/arm/pxa2xx.c +++ b/hw/arm/pxa2xx.c @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_pxa2xx_pm = { .name = "pxa2xx_pm", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(pm_regs, PXA2xxState, 0x40), VMSTATE_END_OF_LIST() } @@ -238,7 +238,7 @@ static const VMStateDescription vmstate_pxa2xx_cm = { .name = "pxa2xx_cm", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(cm_regs, PXA2xxState, 4), VMSTATE_UINT32(clkcfg, PXA2xxState), VMSTATE_UINT32(pmnc, PXA2xxState), @@ -465,7 +465,7 @@ static const VMStateDescription vmstate_pxa2xx_mm = { .name = "pxa2xx_mm", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(mm_regs, PXA2xxState, 0x1a), VMSTATE_END_OF_LIST() } @@ -510,7 +510,7 @@ static const VMStateDescription vmstate_pxa2xx_ssp = { .name = "pxa2xx-ssp", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(enable, PXA2xxSSPState), VMSTATE_UINT32_ARRAY(sscr, PXA2xxSSPState, 2), VMSTATE_UINT32(sspsp, PXA2xxSSPState), @@ -1200,7 +1200,7 @@ static const VMStateDescription vmstate_pxa2xx_rtc_regs = { .minimum_version_id = 0, .pre_save = pxa2xx_rtc_pre_save, .post_load = pxa2xx_rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(rttr, PXA2xxRTCState), VMSTATE_UINT32(rtsr, PXA2xxRTCState), VMSTATE_UINT32(rtar, PXA2xxRTCState), @@ -1464,7 +1464,7 @@ static const VMStateDescription vmstate_pxa2xx_i2c_slave = { .name = "pxa2xx_i2c_slave", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(parent_obj, PXA2xxI2CSlaveState), VMSTATE_END_OF_LIST() } @@ -1474,7 +1474,7 @@ static const VMStateDescription vmstate_pxa2xx_i2c = { .name = "pxa2xx_i2c", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(control, PXA2xxI2CState), VMSTATE_UINT16(status, PXA2xxI2CState), VMSTATE_UINT8(ibmr, PXA2xxI2CState), @@ -1728,7 +1728,7 @@ static const VMStateDescription vmstate_pxa2xx_i2s = { .name = "pxa2xx_i2s", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(control, PXA2xxI2SState, 2), VMSTATE_UINT32(status, PXA2xxI2SState), VMSTATE_UINT32(mask, PXA2xxI2SState), @@ -2027,7 +2027,7 @@ static const VMStateDescription pxa2xx_fir_vmsd = { .name = "pxa2xx-fir", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(enable, PXA2xxFIrState), VMSTATE_UINT8_ARRAY(control, PXA2xxFIrState, 3), VMSTATE_UINT8_ARRAY(status, PXA2xxFIrState, 2), diff --git a/hw/arm/pxa2xx_gpio.c b/hw/arm/pxa2xx_gpio.c index c8db5e8e2b..41dca036fb 100644 --- a/hw/arm/pxa2xx_gpio.c +++ b/hw/arm/pxa2xx_gpio.c @@ -320,7 +320,7 @@ static const VMStateDescription vmstate_pxa2xx_gpio_regs = { .name = "pxa2xx-gpio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(ilevel, PXA2xxGPIOInfo, PXA2XX_GPIO_BANKS), VMSTATE_UINT32_ARRAY(olevel, PXA2xxGPIOInfo, PXA2XX_GPIO_BANKS), VMSTATE_UINT32_ARRAY(dir, PXA2xxGPIOInfo, PXA2XX_GPIO_BANKS), diff --git a/hw/arm/pxa2xx_pic.c b/hw/arm/pxa2xx_pic.c index 1373a0d275..f54546cd4d 100644 --- a/hw/arm/pxa2xx_pic.c +++ b/hw/arm/pxa2xx_pic.c @@ -316,7 +316,7 @@ static const VMStateDescription vmstate_pxa2xx_pic_regs = { .version_id = 0, .minimum_version_id = 0, .post_load = pxa2xx_pic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(int_enabled, PXA2xxPICState, 2), VMSTATE_UINT32_ARRAY(int_pending, PXA2xxPICState, 2), VMSTATE_UINT32_ARRAY(is_fiq, PXA2xxPICState, 2), diff --git a/hw/arm/smmuv3.c b/hw/arm/smmuv3.c index c3871ae067..68eeef3e1d 100644 --- a/hw/arm/smmuv3.c +++ b/hw/arm/smmuv3.c @@ -1768,7 +1768,7 @@ static const VMStateDescription vmstate_smmuv3_queue = { .name = "smmuv3_queue", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(base, SMMUQueue), VMSTATE_UINT32(prod, SMMUQueue), VMSTATE_UINT32(cons, SMMUQueue), @@ -1790,7 +1790,7 @@ static const VMStateDescription vmstate_gbpa = { .version_id = 1, .minimum_version_id = 1, .needed = smmuv3_gbpa_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(gbpa, SMMUv3State), VMSTATE_END_OF_LIST() } @@ -1801,7 +1801,7 @@ static const VMStateDescription vmstate_smmuv3 = { .version_id = 1, .minimum_version_id = 1, .priority = MIG_PRI_IOMMU, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(features, SMMUv3State), VMSTATE_UINT8(sid_size, SMMUv3State), VMSTATE_UINT8(sid_split, SMMUv3State), @@ -1826,7 +1826,7 @@ static const VMStateDescription vmstate_smmuv3 = { VMSTATE_END_OF_LIST(), }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_gbpa, NULL } diff --git a/hw/arm/spitz.c b/hw/arm/spitz.c index cc268c6ac0..1d680b61e2 100644 --- a/hw/arm/spitz.c +++ b/hw/arm/spitz.c @@ -1143,7 +1143,7 @@ static const VMStateDescription vmstate_sl_nand_info = { .name = "sl-nand", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(ctl, SLNANDState), VMSTATE_STRUCT(ecc, SLNANDState, 0, vmstate_ecc_state, ECCState), VMSTATE_END_OF_LIST(), @@ -1180,7 +1180,7 @@ static const VMStateDescription vmstate_spitz_kbd = { .version_id = 1, .minimum_version_id = 0, .post_load = spitz_keyboard_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(sense_state, SpitzKeyboardState), VMSTATE_UINT16(strobe_state, SpitzKeyboardState), VMSTATE_UNUSED_TEST(is_version_0, 5), @@ -1208,7 +1208,7 @@ static const VMStateDescription vmstate_corgi_ssp_regs = { .name = "corgi-ssp", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SSI_PERIPHERAL(ssidev, CorgiSSPState), VMSTATE_UINT32_ARRAY(enable, CorgiSSPState, 3), VMSTATE_END_OF_LIST(), @@ -1236,7 +1236,7 @@ static const VMStateDescription vmstate_spitz_lcdtg_regs = { .name = "spitz-lcdtg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SSI_PERIPHERAL(ssidev, SpitzLCDTG), VMSTATE_UINT32(bl_intensity, SpitzLCDTG), VMSTATE_UINT32(bl_power, SpitzLCDTG), diff --git a/hw/arm/stellaris.c b/hw/arm/stellaris.c index dd90f686bf..729a8bf569 100644 --- a/hw/arm/stellaris.c +++ b/hw/arm/stellaris.c @@ -419,7 +419,7 @@ static const VMStateDescription vmstate_stellaris_sys = { .version_id = 2, .minimum_version_id = 1, .post_load = stellaris_sys_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pborctl, ssys_state), VMSTATE_UINT32(ldopctl, ssys_state), VMSTATE_UINT32(int_mask, ssys_state), @@ -631,7 +631,7 @@ static const VMStateDescription vmstate_stellaris_i2c = { .name = "stellaris_i2c", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(msa, stellaris_i2c_state), VMSTATE_UINT32(mcs, stellaris_i2c_state), VMSTATE_UINT32(mdr, stellaris_i2c_state), @@ -901,7 +901,7 @@ static const VMStateDescription vmstate_stellaris_adc = { .name = "stellaris_adc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(actss, StellarisADCState), VMSTATE_UINT32(ris, StellarisADCState), VMSTATE_UINT32(im, StellarisADCState), diff --git a/hw/arm/strongarm.c b/hw/arm/strongarm.c index cc73145053..fef3638aca 100644 --- a/hw/arm/strongarm.c +++ b/hw/arm/strongarm.c @@ -211,7 +211,7 @@ static const VMStateDescription vmstate_strongarm_pic_regs = { .version_id = 0, .minimum_version_id = 0, .post_load = strongarm_pic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pending, StrongARMPICState), VMSTATE_UINT32(enabled, StrongARMPICState), VMSTATE_UINT32(is_fiq, StrongARMPICState), @@ -439,7 +439,7 @@ static const VMStateDescription vmstate_strongarm_rtc_regs = { .minimum_version_id = 0, .pre_save = strongarm_rtc_pre_save, .post_load = strongarm_rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(rttr, StrongARMRTCState), VMSTATE_UINT32(rtsr, StrongARMRTCState), VMSTATE_UINT32(rtar, StrongARMRTCState), @@ -677,7 +677,7 @@ static const VMStateDescription vmstate_strongarm_gpio_regs = { .name = "strongarm-gpio", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ilevel, StrongARMGPIOInfo), VMSTATE_UINT32(olevel, StrongARMGPIOInfo), VMSTATE_UINT32(dir, StrongARMGPIOInfo), @@ -846,7 +846,7 @@ static const VMStateDescription vmstate_strongarm_ppc_regs = { .name = "strongarm-ppc", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ilevel, StrongARMPPCInfo), VMSTATE_UINT32(olevel, StrongARMPPCInfo), VMSTATE_UINT32(dir, StrongARMPPCInfo), @@ -1300,7 +1300,7 @@ static const VMStateDescription vmstate_strongarm_uart_regs = { .version_id = 0, .minimum_version_id = 0, .post_load = strongarm_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(utcr0, StrongARMUARTState), VMSTATE_UINT16(brd, StrongARMUARTState), VMSTATE_UINT8(utcr3, StrongARMUARTState), @@ -1558,7 +1558,7 @@ static const VMStateDescription vmstate_strongarm_ssp_regs = { .version_id = 0, .minimum_version_id = 0, .post_load = strongarm_ssp_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16_ARRAY(sscr, StrongARMSSPState, 2), VMSTATE_UINT16(sssr, StrongARMSSPState), VMSTATE_UINT16_ARRAY(rx_fifo, StrongARMSSPState, 8), diff --git a/hw/arm/versatilepb.c b/hw/arm/versatilepb.c index 2f22dc890f..4b2257787b 100644 --- a/hw/arm/versatilepb.c +++ b/hw/arm/versatilepb.c @@ -52,7 +52,7 @@ static const VMStateDescription vmstate_vpb_sic = { .name = "versatilepb_sic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, vpb_sic_state), VMSTATE_UINT32(mask, vpb_sic_state), VMSTATE_UINT32(pic_enable, vpb_sic_state), diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index 8bc35a483c..5e7cf6c6b3 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -1100,7 +1100,7 @@ static const VMStateDescription vmstate_virt_acpi_build = { .name = "virt_acpi_build", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(patched, AcpiBuildState), VMSTATE_END_OF_LIST() }, diff --git a/hw/arm/z2.c b/hw/arm/z2.c index d9a08fa67b..83741a4909 100644 --- a/hw/arm/z2.c +++ b/hw/arm/z2.c @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_zipit_lcd_state = { .name = "zipit-lcd", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SSI_PERIPHERAL(ssidev, ZipitLCD), VMSTATE_INT32(selected, ZipitLCD), VMSTATE_INT32(enabled, ZipitLCD), @@ -274,7 +274,7 @@ static const VMStateDescription vmstate_aer915_state = { .name = "aer915", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(len, AER915State), VMSTATE_BUFFER(buf, AER915State), VMSTATE_END_OF_LIST(), From patchwork Fri Dec 29 21:22:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758806 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671274wrw; Fri, 29 Dec 2023 13:27:17 -0800 (PST) X-Google-Smtp-Source: AGHT+IFi1sqrVP+TgBTjRNEq8dBl6W9Mezwj/9Wspa3r1AXjIqEuGxC7j5nSOjsRNKyTgH0/5BjL X-Received: by 2002:a05:620a:8501:b0:781:711e:5529 with SMTP id pe1-20020a05620a850100b00781711e5529mr2902067qkn.78.1703885237520; Fri, 29 Dec 2023 13:27:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885237; cv=none; d=google.com; s=arc-20160816; b=TO3O3f8QvNc8DSMgyqDhIdgOBOxZugKQjQCA9/NB2eqS8QpgoPyOG9gIyuUYycnxG/ PjCdRFPi2a/zStu0CwKkHFLSdDZ2T1ylFBtt8I71+H7nibKP1oiwp+rgDGLfGEa4/5Ln Akyob2ingXM/7eUAeRHHAq1CrokBL7Nzhn/M60YX9lvilUNOOhgbG8lLdmR9VHAaX63u YrcOBd6LcO6dCp0h18bZ21EVlJA0nXKd+7xGAmUjBM82wJooT0fX3txoE3q0N7n8KVMN KNV9OAomvKUsFuIP8jVLGfGcoBQBeUS8pMhINR9UdLb1m+42xXmmpafqa0pUwb9v9/9l eSrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Qxy3UL4B8AxC1Jq+djISZlpE1zvXiAaDiE1NgzJw8Vw=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=h4evmAZLBJPAHHTodFtALrt5+vBaySznzEAF2nVgYk6s9k7Ni1dLZv5//4mpjH1Q1z V1mArytXpfjXqF32q+U8eY34OuEKIcITZ3GNl551hOF5J42xzOW2RrfwHMpVx7sG9z/L Cb5YfhW721ENwAudm4GVN2CBTl0ZfnfWbsGc04vPSgpNgd0zoX7/YrCtaSnj2VDy0mPN rfPDTwLHOK3TAXNcsc1UiiR0ABfA6mXoq4VKT6zW580EQzS732dYAGiEARJuDC0J8FhY mLicHkFd/E9udhOo8tmOoKeE7Q39eyqNAqtAlOzdugM9I+g0dqKo5tWDxT1DB9T/9jdK TX7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pwbKDwAv; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x7-20020a05620a258700b007817145f9a5si4865606qko.411.2023.12.29.13.27.17 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:17 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pwbKDwAv; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLS-0007DU-J9; Fri, 29 Dec 2023 16:24:42 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLR-0007CY-DG for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:41 -0500 Received: from mail-il1-x134.google.com ([2607:f8b0:4864:20::134]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLP-0006nt-OE for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:41 -0500 Received: by mail-il1-x134.google.com with SMTP id e9e14a558f8ab-35fe8a4b311so26505195ab.1 for ; Fri, 29 Dec 2023 13:24:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885078; x=1704489878; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Qxy3UL4B8AxC1Jq+djISZlpE1zvXiAaDiE1NgzJw8Vw=; b=pwbKDwAv09IDReFS3A3qDFioLgTbBEq1aeWA08NHlPGGL5JKW/7lyx0hXyfAcvtY0c qnr1Vh2PIbrKhq0YHexMIFX/BmEdYftDB7prcWMxfXwFtXC9g8dhxABMjdQSCgbWLrJl jAuQt+0ijF/rc6VXBS4kzr/XvTlDcUV9/SufNSYKPYc+/102k9RhbNDliwGqrk1pCKa1 QZYHt9+MEDSHLkdSNijIA5qYY4VYbsDiT5GA7r3G+s6EDwYcg+Lg9dvSI/NBdVjz4qAp uv/lmIlS04tJofQx3zcIXsAy36YjPCfzuEEREIQ3FAM4+dzcyWK0nN77aSMAlVMHGurx TJWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885078; x=1704489878; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Qxy3UL4B8AxC1Jq+djISZlpE1zvXiAaDiE1NgzJw8Vw=; b=P1wrelpaChFhqn7p0McHS6rzvevm4EYR+/kJsy85qBocKiSzXSqJu6fnyOoKH5S7T3 IqpWEmp+ijvNXEmGgQI/wu3KYauNceOh05+Xdi3F+CQ/NOhDCU0MXVf6Xf+qofEREuDK r3uCKRPAu5uuVIVPbFTpWSrEBIkmpUoXVPfqsJuWgCpCauSevEP7XGe2/QFBjBGnYvgv QgQshdLBEhd8a0OXSic2tPmwO7iaLan4ZfHBoy6yBgTF3wY4/6aIkY5Gf84YXhYqyqwL NRux05QJycf6HQOT7oYu7y9uBCiBwX7Y8242hMTu4syc583JwfrucK0uLRK3C/9DmigR wZ7g== X-Gm-Message-State: AOJu0YwCW26z3S1kFghZ0gJEypuC2ymNbpRbI6Ut1tJevUUyzpVrtBEW xIu3iKIDVk9GUK255BgA0ux77jCBnhTipcWsjh3bfnrDoEsPWQ== X-Received: by 2002:a05:6e02:3004:b0:360:35f:55e8 with SMTP id bd4-20020a056e02300400b00360035f55e8mr10202260ilb.53.1703885078694; Fri, 29 Dec 2023 13:24:38 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:38 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 19/71] hw/core: Constify VMState Date: Sat, 30 Dec 2023 08:22:54 +1100 Message-Id: <20231229212346.147149-20-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::134; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x134.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-20-richard.henderson@linaro.org> --- hw/core/clock-vmstate.c | 6 +++--- hw/core/or-irq.c | 6 +++--- hw/core/ptimer.c | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/hw/core/clock-vmstate.c b/hw/core/clock-vmstate.c index 7eccb6d4ea..e831fc596f 100644 --- a/hw/core/clock-vmstate.c +++ b/hw/core/clock-vmstate.c @@ -41,7 +41,7 @@ const VMStateDescription vmstate_muldiv = { .version_id = 1, .minimum_version_id = 1, .needed = muldiv_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(multiplier, Clock), VMSTATE_UINT32(divider, Clock), VMSTATE_END_OF_LIST() @@ -53,11 +53,11 @@ const VMStateDescription vmstate_clock = { .version_id = 0, .minimum_version_id = 0, .pre_load = clock_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(period, Clock), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_muldiv, NULL }, diff --git a/hw/core/or-irq.c b/hw/core/or-irq.c index 1df4bc05a7..13907df026 100644 --- a/hw/core/or-irq.c +++ b/hw/core/or-irq.c @@ -94,7 +94,7 @@ static const VMStateDescription vmstate_or_irq_extras = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_extras_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT16_UNSAFE(levels, OrIRQState, num_lines, 0, vmstate_info_bool, bool), VMSTATE_END_OF_LIST(), @@ -105,11 +105,11 @@ static const VMStateDescription vmstate_or_irq = { .name = TYPE_OR_IRQ, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL_SUB_ARRAY(levels, OrIRQState, 0, OLD_MAX_OR_LINES), VMSTATE_END_OF_LIST(), }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_or_irq_extras, NULL }, diff --git a/hw/core/ptimer.c b/hw/core/ptimer.c index e03165febf..b1517592c6 100644 --- a/hw/core/ptimer.c +++ b/hw/core/ptimer.c @@ -441,7 +441,7 @@ const VMStateDescription vmstate_ptimer = { .name = "ptimer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(enabled, ptimer_state), VMSTATE_UINT64(limit, ptimer_state), VMSTATE_UINT64(delta, ptimer_state), From patchwork Fri Dec 29 21:22:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758812 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671511wrw; Fri, 29 Dec 2023 13:28:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IEf1ZNF/D/33oG9+c/hFR77wdvCAhxXSuUe8CP6miIi8AsJyASObABSiPLlKEjYL4Jz9wCT X-Received: by 2002:a05:620a:1918:b0:77e:fba3:a220 with SMTP id bj24-20020a05620a191800b0077efba3a220mr16922120qkb.122.1703885291044; Fri, 29 Dec 2023 13:28:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885291; cv=none; d=google.com; s=arc-20160816; b=frgBLT6deYs2e62kpe76RTWXVlWz/KJjEchFUfQdHK7tlEwPwXFzveS5aICiO2HuaO KsE6j04HRXiUG/a1v1RBqUXn8AEukrEYTeAnVdo8ZM/XiUgFeCSTb1q8gQa89whOYSZm Q9gvGO8k5FJuGRkzdw7sS4APae0iUNHbv7qraNuKSDF6W8ZAH4Td+UgmRR8mm7gNhQ3D 8TLDM/3nTIykYOp00hhVqyCHFukJYT8z0m0EvtfTNijQSeCSeq9vH7waC5DHxlCGIYdb m5Hc0bpXNXndRNI5XVGvcVo1rfUgEFmpJ1YaascmGodMe9ZtHbFhrQIrT+2cMDTHoJ6b DFNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=OWhbEXkC1GW/Vbr9cJeB8yQeDQQ2N/bSYDuiieojzSA=; fh=4a/xJBKFPbIePV7C4z+fxJKuek+JkHMUL6iUyRF9HeQ=; b=XFwTVAq73xlzU/Mpgn3FPiXzXyp19rnP7Tx6IXH7ASlWRkDyzXkwvB+Kv41W2mcseg W4w23+7agQnuzhjWPxHgTLGczEwLNydC0DPHi7THh4jc2VFQ+Ri60AOnAMd7+Ge5uqP7 7EOGSKbNOJIlQp4CEfwzntARnomAwes4yU2zo1JlPxuPhsLhcWPuVHECrdcuJVaxILEG jHneEz4zQPuE0thI50IzDhvnfZ9GfruvxL6oEuiTaygI7hPElWa3aAN9+cqtnbiy6/Qm uppvEpcpYAU+hPe6x/0249dTstyAU6V3v4VKx/oSI6gOBH5WSmBrZEaVTRbAx0F3RGO2 FZdw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gJzjfvA1; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id 2-20020a05620a048200b00781575a8695si8159308qkr.667.2023.12.29.13.28.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:11 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gJzjfvA1; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLV-0007FC-Eq; Fri, 29 Dec 2023 16:24:45 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLU-0007Dz-3s for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:44 -0500 Received: from mail-il1-x131.google.com ([2607:f8b0:4864:20::131]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLS-0006od-NC for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:43 -0500 Received: by mail-il1-x131.google.com with SMTP id e9e14a558f8ab-35fb0dcec7aso32580055ab.3 for ; Fri, 29 Dec 2023 13:24:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885081; x=1704489881; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=OWhbEXkC1GW/Vbr9cJeB8yQeDQQ2N/bSYDuiieojzSA=; b=gJzjfvA1zfd9yIyRawgE8LKFCdXIcoilf/eF8aDnO+ii3UrQqh4rWmIF6ZO2ZE7myF m3sScsI6WS7+fo8IgcCioJLcxnxD9Y34nuB+aCXsA2WW9/lf9E4DCxHZr4rkrKBSQC0l /aTbZCgzaeASbl4HdgIv2NM2p2h8agJSSr9YUtiaA6nIBKCDek7l8OarmYJ+vwX5GU55 MV6bd7kuVIBeKJg3XEkUp6AxsjIVNAKFVovdsjuZCWPz/oW/lQocys1dAW6sYvMQQrjI hPbeJDTAwSMrNuEunSxigwTplYzkRn3xmO34eYXZSRdtPmv4Xvoy/iCQMJNXlnu10Qti gmmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885081; x=1704489881; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OWhbEXkC1GW/Vbr9cJeB8yQeDQQ2N/bSYDuiieojzSA=; b=oC4BItvuE3xAxN+oyYlT5BzPL0jBOF1lpdamQDDzxUKvlsV+CuLOpd0W4K85ov/4GC eUfCR+gsCL0u4M93p4EhVEmbP8THZi8vFguJaP6K6/Zxam8rHqJX5FXv2t/iu8RJjEgL zTG310YvHOvq5NkBRt7RuPWJ+FrExoV45V7lEcFq8FdbHL4eX5NMCYLAKomi1TDGEmPq X38hRHaAysenPz2TAOJ1WP7o1TgZz0zF6ciQWjJTcOFk2rflkyj33pmfe5wRtzWDqe2r RKa6ZnZ71xfDpPAmFUHl0CbUZo/Fp2ZkkOJE9fSpP0iiQMlixZpeyw4Y5qW/RfVNAcT9 eJeg== X-Gm-Message-State: AOJu0YzDvQ2egLqDMmgqXFofrQG//bBH5ZGu8S98IgOCd1q6icoOW7oR Zo6t0DMhMNqdOsdkeOqSf1EIUfT1s32QNQbzXleuIMnM2C0UdA== X-Received: by 2002:a05:6e02:144d:b0:35f:e83e:88ae with SMTP id p13-20020a056e02144d00b0035fe83e88aemr17087448ilo.21.1703885081554; Fri, 29 Dec 2023 13:24:41 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:41 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Greg Kurz , Christian Schoenebeck Subject: [PULL 20/71] hw/9pfs: Constify VMState Date: Sat, 30 Dec 2023 08:22:55 +1100 Message-Id: <20231229212346.147149-21-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::131; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x131.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Acked-by: Greg Kurz Acked-by: Christian Schoenebeck Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-21-richard.henderson@linaro.org> --- hw/9pfs/virtio-9p-device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/9pfs/virtio-9p-device.c b/hw/9pfs/virtio-9p-device.c index 5f522e68e9..efa41cfd73 100644 --- a/hw/9pfs/virtio-9p-device.c +++ b/hw/9pfs/virtio-9p-device.c @@ -237,7 +237,7 @@ static const VMStateDescription vmstate_virtio_9p = { .name = "virtio-9p", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:22:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758826 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671925wrw; Fri, 29 Dec 2023 13:30:01 -0800 (PST) X-Google-Smtp-Source: AGHT+IHTRZT7nW+xZ4tCxmt9zz+GWYFUxSNurKcncog5yajssOd524K45sfXAuf2WVjY3hjlefww X-Received: by 2002:a05:622a:2c9:b0:425:8a27:4bee with SMTP id a9-20020a05622a02c900b004258a274beemr20145810qtx.79.1703885401393; Fri, 29 Dec 2023 13:30:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885401; cv=none; d=google.com; s=arc-20160816; b=j9nacjZZgT2IeKl467pPUatowUY+ORWIXAVu+zeBmhT0QcttIqqfpQIs9G+kYSnEbd R2Cx3KBAyjiNXtqixWE7rhjc+1xap4vEvGJHghGk5oq3YR1X0nYXJK5qVfFjJ1HxgtIu HnV1FqK0EMJmnBa0IYETP43mDneFzx4/25lonAYD9sxjRyAq4bpNiRAa/GxCaeGLNoLi /UsDtgeTbJHawpTVC/XF8SUladr1Kw9s9aULYJ0NCPUVlfGsWQvDIyq+VXRkgLGpLGJq 82eVTR40c741Cl7N2jYCXxph1xfDja6swiNyMqLNUsjRSp+cqyLtJZeAx9saiwMJKxmE gSqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=DOvF0AY7fePCXN1tebEvp8pAm4Tzy5l1IurRZ4G7S50=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=SKPbM1SFY138Rj5+JPiQmRj4PJZxUBLxkizMBtZrRAwzKfA790AJkossiK53cHLEpO 2iL//H0rZXWkucIhVKCV0qP61n5/FkDiYPgDOgBstgdBDIiDLhCguS8IHrbI/5LccyTi PfgPC+iu27sl2IJQCscM5Nzg70z8esJl8zUYMyWgvAAkW3pTrfmisB7oRGGHeXhB3fJr /419Yek0249Wvm6inJd5I3EQwcldhwvo2Q/kKzKCJN7ztjQlLPYogbW9putK8ktNJzpa gkwRB5MZhqInyQHw93wxzLyXk+P53oU0jj0cp4xinDsFayBv9jEX7CcQKAOaPEw74ZdZ mRJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eWAN8nYn; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t11-20020a05622a180b00b00427f73f2645si4435449qtc.659.2023.12.29.13.30.01 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:01 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=eWAN8nYn; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLY-0007My-M9; Fri, 29 Dec 2023 16:24:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLX-0007KG-ME for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:47 -0500 Received: from mail-oa1-x33.google.com ([2001:4860:4864:20::33]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLV-0006wW-Im for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:47 -0500 Received: by mail-oa1-x33.google.com with SMTP id 586e51a60fabf-204fdd685fdso1195753fac.2 for ; Fri, 29 Dec 2023 13:24:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885084; x=1704489884; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=DOvF0AY7fePCXN1tebEvp8pAm4Tzy5l1IurRZ4G7S50=; b=eWAN8nYnA20J0T9XM41axANm8UuSAMqF/qdNqRPSgIZEmojg2X1nToKaOL2o2cXLK5 162LqkSJxcYk/Lbk2yJLRYZt//rMobDKVTN8Fe3qeUjSeXQNoWLM8BhlrfqfWMBAik/B pAWPDtD+x38HvZeeoNM87gwkmOsd9Hon3AGMe4FrYH4YHZu0/AcecfWPlY0lgIs7cdhX UvfpksQGtok26SxXx6dCuvwxKMVhe/xO5G98U2odMADQLtbse2iKi2vZ327g73h8jvxh +bslHfa8vaFFWfLRR4+h+ExXqYRAeiW6pJQSLRF21xlmBBqbH83HLSAotzUamzhVBW9c x6lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885084; x=1704489884; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=DOvF0AY7fePCXN1tebEvp8pAm4Tzy5l1IurRZ4G7S50=; b=IZSOssp8L+IETWMZ5saCTlamj+uHyZRUhoDENC617RJ+5kZtIPSBqFHWIkmOM5Rbh5 +bxXpp4yzi54gq+DkQH0AhAd9OwCZPnE0O2oMoRXwve2uIqYRQTnDXRYCBleKggKwCfJ C7ZOCGp6TTsZPKn+dx0CZkFKiP2L47Y1aICBSU3gGhW5+MDUPQ741YRotH4bW7Bho2Ta rDTfje+u6nWkvAT/wRL8JPI0/zGzDHjUonbtwzvmAho8g5nRgFFFOuBjzKzYjBemkCrI FLlpAJywpHuDxSamlQUgljfMGnJOVpx0rK9HNWN8Yqt860E4ci62fAr20dKP3O92wpob fSQw== X-Gm-Message-State: AOJu0YyVRScj/mNakeHP0iKQgx6hjhMSfpglHI5NWRcdsyG5Yga8deTJ 5+QjTQurNKkatzwR7/NCjuHAySR+Ogvab4HelUyJFmoXS+McAg== X-Received: by 2002:a05:6870:c0cf:b0:1fb:75c:3ff0 with SMTP id e15-20020a056870c0cf00b001fb075c3ff0mr14672724oad.80.1703885084153; Fri, 29 Dec 2023 13:24:44 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.41 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:43 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 21/71] hw/acpi: Constify VMState Date: Sat, 30 Dec 2023 08:22:56 +1100 Message-Id: <20231229212346.147149-22-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::33; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x33.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-22-richard.henderson@linaro.org> --- hw/acpi/cpu.c | 4 ++-- hw/acpi/erst.c | 2 +- hw/acpi/generic_event_device.c | 12 ++++++------ hw/acpi/ich9.c | 12 ++++++------ hw/acpi/ich9_tco.c | 2 +- hw/acpi/memory_hotplug.c | 4 ++-- hw/acpi/pcihp.c | 2 +- hw/acpi/piix4.c | 12 ++++++------ hw/acpi/vmgenid.c | 2 +- 9 files changed, 26 insertions(+), 26 deletions(-) diff --git a/hw/acpi/cpu.c b/hw/acpi/cpu.c index 011d2c6c2d..2d81c1e790 100644 --- a/hw/acpi/cpu.c +++ b/hw/acpi/cpu.c @@ -297,7 +297,7 @@ static const VMStateDescription vmstate_cpuhp_sts = { .name = "CPU hotplug device state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(is_inserting, AcpiCpuStatus), VMSTATE_BOOL(is_removing, AcpiCpuStatus), VMSTATE_UINT32(ost_event, AcpiCpuStatus), @@ -310,7 +310,7 @@ const VMStateDescription vmstate_cpu_hotplug = { .name = "CPU hotplug state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(selector, CPUHotplugState), VMSTATE_UINT8(command, CPUHotplugState), VMSTATE_STRUCT_VARRAY_POINTER_UINT32(devs, CPUHotplugState, dev_count, diff --git a/hw/acpi/erst.c b/hw/acpi/erst.c index ba751dc60e..b2f1b13630 100644 --- a/hw/acpi/erst.c +++ b/hw/acpi/erst.c @@ -932,7 +932,7 @@ static const VMStateDescription erst_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = erst_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(operation, ERSTDeviceState), VMSTATE_UINT8(busy_status, ERSTDeviceState), VMSTATE_UINT8(command_status, ERSTDeviceState), diff --git a/hw/acpi/generic_event_device.c b/hw/acpi/generic_event_device.c index a3d31631fe..2d6e91b124 100644 --- a/hw/acpi/generic_event_device.c +++ b/hw/acpi/generic_event_device.c @@ -312,7 +312,7 @@ static const VMStateDescription vmstate_memhp_state = { .name = "acpi-ged/memhp", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_MEMORY_HOTPLUG(memhp_state, AcpiGedState), VMSTATE_END_OF_LIST() } @@ -322,7 +322,7 @@ static const VMStateDescription vmstate_ged_state = { .name = "acpi-ged-state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(sel, GEDState), VMSTATE_END_OF_LIST() } @@ -332,7 +332,7 @@ static const VMStateDescription vmstate_ghes = { .name = "acpi-ghes", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ghes_addr_le, AcpiGhesState), VMSTATE_END_OF_LIST() }, @@ -349,7 +349,7 @@ static const VMStateDescription vmstate_ghes_state = { .version_id = 1, .minimum_version_id = 1, .needed = ghes_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ghes_state, AcpiGedState, 1, vmstate_ghes, AcpiGhesState), VMSTATE_END_OF_LIST() @@ -360,11 +360,11 @@ static const VMStateDescription vmstate_acpi_ged = { .name = "acpi-ged", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ged_state, AcpiGedState, 1, vmstate_ged_state, GEDState), VMSTATE_END_OF_LIST(), }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_memhp_state, &vmstate_ghes_state, NULL diff --git a/hw/acpi/ich9.c b/hw/acpi/ich9.c index 25e2c7243e..573d032e8e 100644 --- a/hw/acpi/ich9.c +++ b/hw/acpi/ich9.c @@ -164,7 +164,7 @@ static const VMStateDescription vmstate_memhp_state = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_test_use_memhp, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_MEMORY_HOTPLUG(acpi_memory_hotplug, ICH9LPCPMRegs), VMSTATE_END_OF_LIST() } @@ -181,7 +181,7 @@ static const VMStateDescription vmstate_tco_io_state = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_test_use_tco, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(tco_regs, ICH9LPCPMRegs, 1, vmstate_tco_io_sts, TCOIORegs), VMSTATE_END_OF_LIST() @@ -208,7 +208,7 @@ static const VMStateDescription vmstate_cpuhp_state = { .minimum_version_id = 1, .needed = vmstate_test_use_cpuhp, .pre_load = vmstate_cpuhp_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CPU_HOTPLUG(cpuhp_state, ICH9LPCPMRegs), VMSTATE_END_OF_LIST() } @@ -226,7 +226,7 @@ static const VMStateDescription vmstate_pcihp_state = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_test_use_pcihp, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_HOTPLUG(acpi_pci_hotplug, ICH9LPCPMRegs, NULL, NULL), @@ -239,7 +239,7 @@ const VMStateDescription vmstate_ich9_pm = { .version_id = 1, .minimum_version_id = 1, .post_load = ich9_pm_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(acpi_regs.pm1.evt.sts, ICH9LPCPMRegs), VMSTATE_UINT16(acpi_regs.pm1.evt.en, ICH9LPCPMRegs), VMSTATE_UINT16(acpi_regs.pm1.cnt.cnt, ICH9LPCPMRegs), @@ -251,7 +251,7 @@ const VMStateDescription vmstate_ich9_pm = { VMSTATE_UINT32(smi_sts, ICH9LPCPMRegs), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_memhp_state, &vmstate_tco_io_state, &vmstate_cpuhp_state, diff --git a/hw/acpi/ich9_tco.c b/hw/acpi/ich9_tco.c index 1540f4fd46..81606219f7 100644 --- a/hw/acpi/ich9_tco.c +++ b/hw/acpi/ich9_tco.c @@ -254,7 +254,7 @@ const VMStateDescription vmstate_tco_io_sts = { .name = "tco io device status", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(tco.rld, TCOIORegs), VMSTATE_UINT8(tco.din, TCOIORegs), VMSTATE_UINT8(tco.dout, TCOIORegs), diff --git a/hw/acpi/memory_hotplug.c b/hw/acpi/memory_hotplug.c index 0b883df813..de6f974ebb 100644 --- a/hw/acpi/memory_hotplug.c +++ b/hw/acpi/memory_hotplug.c @@ -317,7 +317,7 @@ static const VMStateDescription vmstate_memhp_sts = { .name = "memory hotplug device state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(is_enabled, MemStatus), VMSTATE_BOOL(is_inserting, MemStatus), VMSTATE_UINT32(ost_event, MemStatus), @@ -330,7 +330,7 @@ const VMStateDescription vmstate_memory_hotplug = { .name = "memory hotplug state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(selector, MemHotplugState), VMSTATE_STRUCT_VARRAY_POINTER_UINT32(devs, MemHotplugState, dev_count, vmstate_memhp_sts, MemStatus), diff --git a/hw/acpi/pcihp.c b/hw/acpi/pcihp.c index 4f75c873e2..5f79c9016b 100644 --- a/hw/acpi/pcihp.c +++ b/hw/acpi/pcihp.c @@ -517,7 +517,7 @@ const VMStateDescription vmstate_acpi_pcihp_pci_status = { .name = "acpi_pcihp_pci_status", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(up, AcpiPciHpPciStatus), VMSTATE_UINT32(down, AcpiPciHpPciStatus), VMSTATE_END_OF_LIST() diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c index dd523d2e4c..debe1adb84 100644 --- a/hw/acpi/piix4.c +++ b/hw/acpi/piix4.c @@ -147,7 +147,7 @@ static const VMStateDescription vmstate_gpe = { .name = "gpe", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_GPE_ARRAY(sts, ACPIGPE), VMSTATE_GPE_ARRAY(en, ACPIGPE), VMSTATE_END_OF_LIST() @@ -158,7 +158,7 @@ static const VMStateDescription vmstate_pci_status = { .name = "pci_status", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(up, struct AcpiPciHpPciStatus), VMSTATE_UINT32(down, struct AcpiPciHpPciStatus), VMSTATE_END_OF_LIST() @@ -189,7 +189,7 @@ static const VMStateDescription vmstate_memhp_state = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_test_use_memhp, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_MEMORY_HOTPLUG(acpi_memory_hotplug, PIIX4PMState), VMSTATE_END_OF_LIST() } @@ -214,7 +214,7 @@ static const VMStateDescription vmstate_cpuhp_state = { .minimum_version_id = 1, .needed = vmstate_test_use_cpuhp, .pre_load = vmstate_cpuhp_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CPU_HOTPLUG(cpuhp_state, PIIX4PMState), VMSTATE_END_OF_LIST() } @@ -247,7 +247,7 @@ static const VMStateDescription vmstate_acpi = { .version_id = 3, .minimum_version_id = 3, .post_load = vmstate_acpi_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PIIX4PMState), VMSTATE_UINT16(ar.pm1.evt.sts, PIIX4PMState), VMSTATE_UINT16(ar.pm1.evt.en, PIIX4PMState), @@ -269,7 +269,7 @@ static const VMStateDescription vmstate_acpi = { vmstate_test_migrate_acpi_index), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_memhp_state, &vmstate_cpuhp_state, NULL diff --git a/hw/acpi/vmgenid.c b/hw/acpi/vmgenid.c index a39315c1b3..e63c8af4c3 100644 --- a/hw/acpi/vmgenid.c +++ b/hw/acpi/vmgenid.c @@ -178,7 +178,7 @@ static const VMStateDescription vmstate_vmgenid = { .version_id = 1, .minimum_version_id = 1, .post_load = vmgenid_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(vmgenid_addr_le, VmGenIdState, sizeof(uint64_t)), VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:22:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758793 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670775wrw; Fri, 29 Dec 2023 13:25:19 -0800 (PST) X-Google-Smtp-Source: AGHT+IEQzOyinxtrCNMvWVzz/PXH2+fjyXODPMyYIYlWw4D0yJg8yvOC2WqbmvMQU8BbrB2avde/ X-Received: by 2002:ad4:5bcc:0:b0:67f:6310:bde6 with SMTP id t12-20020ad45bcc000000b0067f6310bde6mr13278934qvt.5.1703885119771; Fri, 29 Dec 2023 13:25:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885119; cv=none; d=google.com; s=arc-20160816; b=VMXxw4Lemn7EjyukoeJmeECl6r4Oa6tlBdboHV1FnJFEVaMnN+um5CGJog0UtsVxRC qWQ/fjPQrfN08wx4JMZJzuDgi+zMvynSVZ3dPx3Ur0ePL0AqO4O6PmtNMsd0Zj3bkJ4C GkbQatqhV+RNvP68qysGlMS8metkDzzCrFDfOCfBL/bPe8dRTmKapl02zx5dhsQTVd3F kv8OHvNmtTy2Po2Wg9pc4dxlq0T5lGDOqZqtAx3F/5nIFPDOD9ZNcu4BQgFvxfGdHBDQ C7h6xBIasoQpXjhY8t517P9IVCQaFFEqFvd4bqn1WP58sNCinVeNOfHmtO+lnlSXY3Cc yYzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UdAUtVG2pZL0Z9aYfR2pwp7z3p2m4ly+ECo0FK04wVc=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=VIPDF9s1I3DTm1IjGdguZR6xqu0Yn6uijylFuyhQE8QhKlqYkJSQSxNBAgDR2KffKW kYmIRmSn2gTAt1/rLIN8F9/3kiobNm8hwIOWpWBSciu/6JXey6QXrvtX3X4NmMO3hXO4 wXURCcF5ZW0ZFcEhZBx3WdgUfHjcOFzJlLd4fmEwrQD9U3Eecnkx67FsR53YW7oZs7Q+ NBdo4mukbCPJ6PBeBwJpUV9/NZ5LUZd67ETWoX+1bn6thsHjoHO80LIDZs19QI9K5TSu PwX9NmUdK7tZ4u1xebA7uz3LcVnICfUfaesf7ojFvgTKuLPwssk+hTPDFzBRYuHUHjF7 sA2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=lUM6tS1B; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id w11-20020a0cdf8b000000b0067f99bbc781si16380646qvl.109.2023.12.29.13.25.19 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:19 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=lUM6tS1B; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLg-0007XM-LQ; Fri, 29 Dec 2023 16:24:56 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLf-0007T8-0L for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:55 -0500 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLa-0006yg-6f for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:54 -0500 Received: by mail-pf1-x42b.google.com with SMTP id d2e1a72fcca58-6d9b2c8e2a4so2694144b3a.0 for ; Fri, 29 Dec 2023 13:24:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885086; x=1704489886; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=UdAUtVG2pZL0Z9aYfR2pwp7z3p2m4ly+ECo0FK04wVc=; b=lUM6tS1BI2YvjF1BUSvSYs1s2qFvepqlJOx4dRS1Hiv+xP78l++9cqHZ2NF0TVroly KJGLVwk5BmsCuiM3RhhSDZltrXZuaQ79NRV/p6e7en792ZelMvuD2RQZv5BhGvUkA6XS vIY/lrgp9qa90GJPF4y22Oe5/zKpr8+LZ86eD09aB8YdpDHUQRzS9W1XClPHOmmKiXru REy2C3JD8OyBTgZps23huIymHWNB9uGHZ4TetlNY++Nw6tiy+gwCkFkyE5yihN60+ky0 zalpyhNR/himnDfLc9YTC6HemDr36Kg5lHvudj8u2VuFHTIdYODoH0SDfE/mIj2//N9Y ts6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885086; x=1704489886; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UdAUtVG2pZL0Z9aYfR2pwp7z3p2m4ly+ECo0FK04wVc=; b=EX/P6qorjsp28bqCYnWb5vIbRkeAQ06c0VftyZdF/gBRS2XrBd2bWkgQVFX9ljdeKw Q/KUfzmOJ6HKvSE3llRKikrzkmTqen5YN+ibvMYYVBG61XovUzWdGCPnQsGyR0flj6DU TfpIGoCXy7rEel4CJBZI0aQGxLIwB9XdEnVjcAuzs+VFn/V1qbu1uTySyvcM3HEHJkGX E1J2oAnPLkkBFHzEiRuJ88mmmQa4NCnHOXkghKI+Uw91xTRYr/zxLoMTXcOQ05mmhxFc A8eJlHM3pPRbnpEgS79Ghzr3OOEUi9mmliuH9LLYak0EzI/LTR/bmIFfNOCfgQWeKGUM 3y/w== X-Gm-Message-State: AOJu0YxeaL3esT65+eUtUfJX/qQTm+j+9e2T99n+Z0O7DAN+cAc4IOFg nxRmn8gg+tSQWF6WQ7GD3vq3SbHPiqtUFin57qwJEQw5VytTVA== X-Received: by 2002:a05:6a20:4f23:b0:196:5bf1:68a5 with SMTP id gi35-20020a056a204f2300b001965bf168a5mr2690129pzb.45.1703885086620; Fri, 29 Dec 2023 13:24:46 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:46 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 22/71] hw/adc: Constify VMState Date: Sat, 30 Dec 2023 08:22:57 +1100 Message-Id: <20231229212346.147149-23-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42b; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42b.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-23-richard.henderson@linaro.org> --- hw/adc/aspeed_adc.c | 2 +- hw/adc/max111x.c | 2 +- hw/adc/npcm7xx_adc.c | 2 +- hw/adc/stm32f2xx_adc.c | 2 +- hw/adc/zynq-xadc.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/adc/aspeed_adc.c b/hw/adc/aspeed_adc.c index 0d29663129..68bdbc73b0 100644 --- a/hw/adc/aspeed_adc.c +++ b/hw/adc/aspeed_adc.c @@ -280,7 +280,7 @@ static const VMStateDescription vmstate_aspeed_adc_engine = { .name = TYPE_ASPEED_ADC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedADCEngineState, ASPEED_ADC_NR_REGS), VMSTATE_END_OF_LIST(), } diff --git a/hw/adc/max111x.c b/hw/adc/max111x.c index e8bf4cccd4..957d177e1c 100644 --- a/hw/adc/max111x.c +++ b/hw/adc/max111x.c @@ -96,7 +96,7 @@ static const VMStateDescription vmstate_max111x = { .name = "max111x", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SSI_PERIPHERAL(parent_obj, MAX111xState), VMSTATE_UINT8(tb1, MAX111xState), VMSTATE_UINT8(rb2, MAX111xState), diff --git a/hw/adc/npcm7xx_adc.c b/hw/adc/npcm7xx_adc.c index bc6f3f55e6..c6647eec6d 100644 --- a/hw/adc/npcm7xx_adc.c +++ b/hw/adc/npcm7xx_adc.c @@ -253,7 +253,7 @@ static const VMStateDescription vmstate_npcm7xx_adc = { .name = "npcm7xx-adc", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER(conv_timer, NPCM7xxADCState), VMSTATE_UINT32(con, NPCM7xxADCState), VMSTATE_UINT32(data, NPCM7xxADCState), diff --git a/hw/adc/stm32f2xx_adc.c b/hw/adc/stm32f2xx_adc.c index 01a0b14e69..e9df6ea53f 100644 --- a/hw/adc/stm32f2xx_adc.c +++ b/hw/adc/stm32f2xx_adc.c @@ -254,7 +254,7 @@ static const VMStateDescription vmstate_stm32f2xx_adc = { .name = TYPE_STM32F2XX_ADC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(adc_sr, STM32F2XXADCState), VMSTATE_UINT32(adc_cr1, STM32F2XXADCState), VMSTATE_UINT32(adc_cr2, STM32F2XXADCState), diff --git a/hw/adc/zynq-xadc.c b/hw/adc/zynq-xadc.c index 032e19cbd0..34268319a4 100644 --- a/hw/adc/zynq-xadc.c +++ b/hw/adc/zynq-xadc.c @@ -269,7 +269,7 @@ static const VMStateDescription vmstate_zynq_xadc = { .name = "zynq-xadc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, ZynqXADCState, ZYNQ_XADC_NUM_IO_REGS), VMSTATE_UINT16_ARRAY(xadc_regs, ZynqXADCState, ZYNQ_XADC_NUM_ADC_REGS), From patchwork Fri Dec 29 21:22:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758813 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671514wrw; Fri, 29 Dec 2023 13:28:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IFGwJgeFdFZRMHeDbDMdpnkFvcwyZdg2I6ubVJZ/zew8f3LdZkRsn8bGDCP90ctTZvAcnsj X-Received: by 2002:a05:6808:21a6:b0:3b9:e7d1:fa71 with SMTP id be38-20020a05680821a600b003b9e7d1fa71mr15444563oib.47.1703885291130; Fri, 29 Dec 2023 13:28:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885291; cv=none; d=google.com; s=arc-20160816; b=sxvfUZ7Z0K0TWiVVP4P+tx8crtLboVA54L9IxLgo/uTgoIaFyUH9A+H75Bi5vZ5skZ sDwPLvKVPq7X8xUZ1zdsyBdktIMnlnlq9yK8knRvAKjTd3Ngd0Gn7ivKO4fcx0CGmwqF KIwJze6f5Zzx4Cz2qvdKk+t7psHOdZdfNaZRKN2Nrf+mBkPVtrJRssOYDOhfzbG/tkco et3h+ADN1sPtT7tJtv3Y2o146X2HWsd4JDTtR9oRKvGPTaaaIsKjkhneOCKL3LxRkEgJ G6lRfqZzOWoBiLZ+ANdHAPMs9YfxS54+tfZ/vlMUiftw4fJdbehvZd0qRM0ALqdGOIsY saSw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=wkiRN5gKSlXBzzy6BnJb8nASmChqIoevWDoN3WXyORI=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=0G7cIM853XSPQgK/Ky57QR3Qr9wgRIl6D0ePSF3QxOuU+r691sbP55Aav33J947qVA S2dtW72hRDxafWW4cn1e02veSGF2ly6uPttV8JmIwjkicaZqm84ej1ANrsx5rMEZ9reH R3HbmkPx/6bNcO7Gqm149FazL+TQYQQqsib+Kv70T3IxIoNwwW8CQmAuw1ev3E+kSUZY Lkt3Eq52YhQVgZnDb41pZRJvgDgYFWlUqV15spg3IjjkqJPXI8Eqta2fGZ1YHUn/t0by 4HZn4Z2zogIiFOV/5vEaEotQfV6iZlKJ4G5V+eB3+Vkxozh1tswWnBYK7uS06BHM9vRO lJZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zZGD7cWM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id u1-20020a05620a120100b007816820d024si5214563qkj.278.2023.12.29.13.28.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:11 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zZGD7cWM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLo-00087f-5N; Fri, 29 Dec 2023 16:25:04 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLk-0007eX-D0 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:00 -0500 Received: from mail-ot1-x332.google.com ([2607:f8b0:4864:20::332]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLb-0006zN-H0 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:00 -0500 Received: by mail-ot1-x332.google.com with SMTP id 46e09a7af769-6dc00dbb560so1864608a34.3 for ; Fri, 29 Dec 2023 13:24:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885089; x=1704489889; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=wkiRN5gKSlXBzzy6BnJb8nASmChqIoevWDoN3WXyORI=; b=zZGD7cWMprehTmJcZD/J8m9S8M0ddkWMaLEfajDfxi2wAasAeFdFcpWHCtYkc2Ukot gEGkimvGxB4RGbFApXyGOWFY+LkKVxZpcBz131U5YZU2Ift905p+KAYU6jaT1KY7m0/5 /OW2Xwn/fR1VDMUP9vc9BLRY9k2KblfTr+GkCbUJjymxUM1s9eJdElSMKHPM1qU92hMF XE+54hviUDRwCJ2wowim9UULnm/adIdIUci0XjVvz5xBK8aqLUnOoxEFnTr+Y4pemrDL Tk3P1INoHLlKST4znN3uEezq6yqf3io8jzwobj46otRvwldpRseKF/YdxlzzhKPfNJHe t5OA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885089; x=1704489889; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wkiRN5gKSlXBzzy6BnJb8nASmChqIoevWDoN3WXyORI=; b=JVY4/UkZkgObuDliOF94t5QTBUaQIBAs60oYv/QmY5cez81nIkRRLIAY/cDE92EwcK cIjnARo2JlEfZosSLMZtD83BNVvhSJuEuiDch0/9OdJhsc1GSXkFw/vl/OQ3D/s+RcPQ 7yJXKXMkPPYeUFH+FD6Nk9TSRLDNrIUI4hrjkcNgUyCF6S6O01oy0kkdNq4Ff0ua2ZFO wf6sGU5Vc0NUHKzcUnmDWfYnT4CVnU2Y9JpsCb6AXRCGsrUzHluW6sCp6MTyEubyBwyI xVYTs0pZiYewPW67TNQrecAtt9jo/eGgYCIQDxyiVmaRyXCCAb0L1BIQwTcGz6x3Fhki Rnow== X-Gm-Message-State: AOJu0YwnxP5hLX4bnkpsZi0c/J0aVRTWVb94sOzLv6gAn8Y5A5wAxwcX /yQBOKbaEGdpKKQoaFf5IYUsWvgpe71aTWgO+Upr2FkP9OwOmw== X-Received: by 2002:a05:6830:6b48:b0:6db:b3bc:78cf with SMTP id dc8-20020a0568306b4800b006dbb3bc78cfmr8674351otb.65.1703885088755; Fri, 29 Dec 2023 13:24:48 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:48 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 23/71] hw/audio: Constify VMState Date: Sat, 30 Dec 2023 08:22:58 +1100 Message-Id: <20231229212346.147149-24-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::332; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x332.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-24-richard.henderson@linaro.org> --- hw/audio/ac97.c | 4 ++-- hw/audio/asc.c | 4 ++-- hw/audio/cs4231.c | 2 +- hw/audio/cs4231a.c | 2 +- hw/audio/es1370.c | 4 ++-- hw/audio/gus.c | 2 +- hw/audio/hda-codec.c | 8 ++++---- hw/audio/intel-hda.c | 4 ++-- hw/audio/lm4549.c | 2 +- hw/audio/marvell_88w8618.c | 2 +- hw/audio/pcspk.c | 2 +- hw/audio/pl041.c | 8 ++++---- hw/audio/sb16.c | 2 +- hw/audio/virtio-snd.c | 2 +- hw/audio/wm8750.c | 2 +- 15 files changed, 25 insertions(+), 25 deletions(-) diff --git a/hw/audio/ac97.c b/hw/audio/ac97.c index 6a7a2dc80c..3f0053f94d 100644 --- a/hw/audio/ac97.c +++ b/hw/audio/ac97.c @@ -1094,7 +1094,7 @@ static const VMStateDescription vmstate_ac97_bm_regs = { .name = "ac97_bm_regs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(bdbar, AC97BusMasterRegs), VMSTATE_UINT8(civ, AC97BusMasterRegs), VMSTATE_UINT8(lvi, AC97BusMasterRegs), @@ -1142,7 +1142,7 @@ static const VMStateDescription vmstate_ac97 = { .version_id = 3, .minimum_version_id = 2, .post_load = ac97_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, AC97LinkState), VMSTATE_UINT32(glob_cnt, AC97LinkState), VMSTATE_UINT32(glob_sta, AC97LinkState), diff --git a/hw/audio/asc.c b/hw/audio/asc.c index 0f36b4ce9b..87b5624326 100644 --- a/hw/audio/asc.c +++ b/hw/audio/asc.c @@ -555,7 +555,7 @@ static const VMStateDescription vmstate_asc_fifo = { .name = "apple-sound-chip.fifo", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(fifo, ASCFIFOState, ASC_FIFO_SIZE), VMSTATE_UINT8(int_status, ASCFIFOState), VMSTATE_INT32(cnt, ASCFIFOState), @@ -575,7 +575,7 @@ static const VMStateDescription vmstate_asc = { .version_id = 0, .minimum_version_id = 0, .post_load = asc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(fifos, ASCState, 2, 0, vmstate_asc_fifo, ASCFIFOState), VMSTATE_UINT8_ARRAY(regs, ASCState, ASC_REG_SIZE), diff --git a/hw/audio/cs4231.c b/hw/audio/cs4231.c index aefc3edea1..967caa7fcb 100644 --- a/hw/audio/cs4231.c +++ b/hw/audio/cs4231.c @@ -142,7 +142,7 @@ static const VMStateDescription vmstate_cs4231 = { .name ="cs4231", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, CSState, CS_REGS), VMSTATE_UINT8_ARRAY(dregs, CSState, CS_DREGS), VMSTATE_END_OF_LIST() diff --git a/hw/audio/cs4231a.c b/hw/audio/cs4231a.c index 3aa105748d..9ef57f042d 100644 --- a/hw/audio/cs4231a.c +++ b/hw/audio/cs4231a.c @@ -637,7 +637,7 @@ static const VMStateDescription vmstate_cs4231a = { .minimum_version_id = 1, .pre_load = cs4231a_pre_load, .post_load = cs4231a_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY (regs, CSState, CS_REGS), VMSTATE_BUFFER (dregs, CSState), VMSTATE_INT32 (dma_running, CSState), diff --git a/hw/audio/es1370.c b/hw/audio/es1370.c index fad5541211..4ab61d3b9d 100644 --- a/hw/audio/es1370.c +++ b/hw/audio/es1370.c @@ -765,7 +765,7 @@ static const VMStateDescription vmstate_es1370_channel = { .name = "es1370_channel", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32 (shift, struct chan), VMSTATE_UINT32 (leftover, struct chan), VMSTATE_UINT32 (scount, struct chan), @@ -808,7 +808,7 @@ static const VMStateDescription vmstate_es1370 = { .version_id = 2, .minimum_version_id = 2, .post_load = es1370_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE (dev, ES1370State), VMSTATE_STRUCT_ARRAY (chan, ES1370State, NB_CHANNELS, 2, vmstate_es1370_channel, struct chan), diff --git a/hw/audio/gus.c b/hw/audio/gus.c index 6c2b586ca7..4beb3fd74e 100644 --- a/hw/audio/gus.c +++ b/hw/audio/gus.c @@ -209,7 +209,7 @@ static const VMStateDescription vmstate_gus = { .name = "gus", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32 (pos, GUSState), VMSTATE_INT32 (left, GUSState), VMSTATE_INT32 (shift, GUSState), diff --git a/hw/audio/hda-codec.c b/hw/audio/hda-codec.c index 0bc20d49f6..b22e486fda 100644 --- a/hw/audio/hda-codec.c +++ b/hw/audio/hda-codec.c @@ -812,7 +812,7 @@ static const VMStateDescription vmstate_hda_audio_stream_buf = { .name = "hda-audio-stream/buffer", .version_id = 1, .needed = vmstate_hda_audio_stream_buf_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(buf, HDAAudioStream), VMSTATE_INT64(rpos, HDAAudioStream), VMSTATE_INT64(wpos, HDAAudioStream), @@ -825,7 +825,7 @@ static const VMStateDescription vmstate_hda_audio_stream_buf = { static const VMStateDescription vmstate_hda_audio_stream = { .name = "hda-audio-stream", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(stream, HDAAudioStream), VMSTATE_UINT32(channel, HDAAudioStream), VMSTATE_UINT32(format, HDAAudioStream), @@ -837,7 +837,7 @@ static const VMStateDescription vmstate_hda_audio_stream = { VMSTATE_BUFFER(compat_buf, HDAAudioStream), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_hda_audio_stream_buf, NULL } @@ -847,7 +847,7 @@ static const VMStateDescription vmstate_hda_audio = { .name = "hda-audio", .version_id = 2, .post_load = hda_audio_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(st, HDAAudioState, 4, 0, vmstate_hda_audio_stream, HDAAudioStream), diff --git a/hw/audio/intel-hda.c b/hw/audio/intel-hda.c index 78ff9f9a68..9c54e60b71 100644 --- a/hw/audio/intel-hda.c +++ b/hw/audio/intel-hda.c @@ -1158,7 +1158,7 @@ static int intel_hda_post_load(void *opaque, int version) static const VMStateDescription vmstate_intel_hda_stream = { .name = "intel-hda-stream", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctl, IntelHDAStream), VMSTATE_UINT32(lpib, IntelHDAStream), VMSTATE_UINT32(cbl, IntelHDAStream), @@ -1174,7 +1174,7 @@ static const VMStateDescription vmstate_intel_hda = { .name = "intel-hda", .version_id = 1, .post_load = intel_hda_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pci, IntelHDAState), /* registers */ diff --git a/hw/audio/lm4549.c b/hw/audio/lm4549.c index e7bfcc4b9f..a4a77c8dc6 100644 --- a/hw/audio/lm4549.c +++ b/hw/audio/lm4549.c @@ -329,7 +329,7 @@ const VMStateDescription vmstate_lm4549_state = { .version_id = 1, .minimum_version_id = 1, .post_load = lm4549_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(voice_is_active, lm4549_state), VMSTATE_UINT16_ARRAY(regfile, lm4549_state, 128), VMSTATE_UINT16_ARRAY(buffer, lm4549_state, LM4549_BUFFER_SIZE), diff --git a/hw/audio/marvell_88w8618.c b/hw/audio/marvell_88w8618.c index e6c09bdb8e..cc285444bc 100644 --- a/hw/audio/marvell_88w8618.c +++ b/hw/audio/marvell_88w8618.c @@ -273,7 +273,7 @@ static const VMStateDescription mv88w8618_audio_vmsd = { .name = "mv88w8618_audio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(playback_mode, mv88w8618_audio_state), VMSTATE_UINT32(status, mv88w8618_audio_state), VMSTATE_UINT32(irq_enable, mv88w8618_audio_state), diff --git a/hw/audio/pcspk.c b/hw/audio/pcspk.c index fe7f07ced2..a4b89f1768 100644 --- a/hw/audio/pcspk.c +++ b/hw/audio/pcspk.c @@ -208,7 +208,7 @@ static const VMStateDescription vmstate_spk = { .version_id = 1, .minimum_version_id = 1, .needed = migrate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(data_on, PCSpkState), VMSTATE_UINT8(dummy_refresh_clock, PCSpkState), VMSTATE_END_OF_LIST() diff --git a/hw/audio/pl041.c b/hw/audio/pl041.c index 868dffbfd3..b435208c24 100644 --- a/hw/audio/pl041.c +++ b/hw/audio/pl041.c @@ -571,7 +571,7 @@ static const VMStateDescription vmstate_pl041_regfile = { .name = "pl041_regfile", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { #define REGISTER(name, offset) VMSTATE_UINT32(name, pl041_regfile), #include "pl041.hx" #undef REGISTER @@ -583,7 +583,7 @@ static const VMStateDescription vmstate_pl041_fifo = { .name = "pl041_fifo", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, pl041_fifo), VMSTATE_UINT32_ARRAY(data, pl041_fifo, MAX_FIFO_DEPTH), VMSTATE_END_OF_LIST() @@ -594,7 +594,7 @@ static const VMStateDescription vmstate_pl041_channel = { .name = "pl041_channel", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(tx_fifo, pl041_channel, 0, vmstate_pl041_fifo, pl041_fifo), VMSTATE_UINT8(tx_enabled, pl041_channel), @@ -613,7 +613,7 @@ static const VMStateDescription vmstate_pl041 = { .name = "pl041", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(fifo_depth, PL041State), VMSTATE_STRUCT(regs, PL041State, 0, vmstate_pl041_regfile, pl041_regfile), diff --git a/hw/audio/sb16.c b/hw/audio/sb16.c index 18f6d252db..bf7f35a42b 100644 --- a/hw/audio/sb16.c +++ b/hw/audio/sb16.c @@ -1324,7 +1324,7 @@ static const VMStateDescription vmstate_sb16 = { .version_id = 1, .minimum_version_id = 1, .post_load = sb16_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32 (irq, SB16State), VMSTATE_UINT32 (dma, SB16State), VMSTATE_UINT32 (hdma, SB16State), diff --git a/hw/audio/virtio-snd.c b/hw/audio/virtio-snd.c index 137fa77a01..ea2aeaef14 100644 --- a/hw/audio/virtio-snd.c +++ b/hw/audio/virtio-snd.c @@ -72,7 +72,7 @@ static const VMStateDescription vmstate_virtio_snd = { .unmigratable = 1, .minimum_version_id = VIRTIO_SOUND_VM_VERSION, .version_id = VIRTIO_SOUND_VM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/audio/wm8750.c b/hw/audio/wm8750.c index 57954a6314..ec2c4e1374 100644 --- a/hw/audio/wm8750.c +++ b/hw/audio/wm8750.c @@ -592,7 +592,7 @@ static const VMStateDescription vmstate_wm8750 = { .minimum_version_id = 0, .pre_save = wm8750_pre_save, .post_load = wm8750_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(i2c_data, WM8750State, 2), VMSTATE_INT32(i2c_len, WM8750State), VMSTATE_INT32(enable, WM8750State), From patchwork Fri Dec 29 21:22:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758797 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670929wrw; Fri, 29 Dec 2023 13:25:55 -0800 (PST) X-Google-Smtp-Source: AGHT+IEyP++xYpDMgatcTaJ0apQ5gi6FRdH3G1pzfmXuFY9/MhEJoLfEVv5qFgDuS2K3LkOCDOIy X-Received: by 2002:a05:6358:60c9:b0:174:dbdd:f511 with SMTP id i9-20020a05635860c900b00174dbddf511mr9582922rwi.32.1703885154739; Fri, 29 Dec 2023 13:25:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885154; cv=none; d=google.com; s=arc-20160816; b=wCAcJP7RCi3uE6wz1ov5G7OZzZiaChxLkOGXp1s8MoFjnR7Pc/tsNCgFKLPgWlxbqW lhuTMlq8ADpZ0jhH1RsZ4uFdLpDFnLfBMZg1on99ez7+wX8DEhhBV3aQl9zhTIKf1ppR TIWmIRqpW3KjPjhO7F72OYgcZZvYhnrUqN7a6/qvt/HbVfaWFDiNj7K8qG9ItaxKSyfp XaBWFXjLkIjBhXOUqVzocYtIRyETmCyEfRwhFbd8aJYfuv6PT4dzg0yg1tIt1jOPp38D b0QVZ7/spQ6a40HTebaPF1GJk4PxobLkKhQE0WDFeN1e8g/PCzLCsIcFr7pK3kBAGiA4 y04Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=INy+429BuuQVoZsuJFK2Hhv1zxxE+m6svEuazNu+L7w=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=JZ7amCL0OK1OxxVPpZQd59M2iaf2N92XJIBf5KJQRuSTsTsF1eOpyz/+RuUPO+YouA OutRKNDcpJ2wWSIYdMVsFqgQj7PTnjGzyXy8BAEyhfPb5TFzjyD6k+rjARRZLqG1j0qX pwqVapEhL+HixvBbVpuJh8v/JMZDgPS/Vl8oGT715w3a4/cC59Abuul7C7aDBHSH0bN6 kep9ugN48ss1XdfWpHTEW5LE7ZXAh3aGMty9t4F3F56PS6Vs0Nz4GGgadN6hFdYe7COS DSrVPsu9SNg0fIfoeQ77Y8Pk3AByDpY3n8ccmXvOz5+ByxuZVTCabdh32R0I1s/8CFdu ffNA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=mrYz5Fiw; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g5-20020ac85805000000b00427818ff6d9si19450043qtg.775.2023.12.29.13.25.54 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:54 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=mrYz5Fiw; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLl-0007mp-CO; Fri, 29 Dec 2023 16:25:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLj-0007bF-QZ for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:59 -0500 Received: from mail-pg1-x535.google.com ([2607:f8b0:4864:20::535]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLd-0006zS-DV for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:59 -0500 Received: by mail-pg1-x535.google.com with SMTP id 41be03b00d2f7-53fbf2c42bfso5217137a12.3 for ; Fri, 29 Dec 2023 13:24:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885091; x=1704489891; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=INy+429BuuQVoZsuJFK2Hhv1zxxE+m6svEuazNu+L7w=; b=mrYz5FiwZUwQ1aYgsYQFH240Q+4D9twZeYegx1qHATHHRhO5DiP3r1Od9tdJssFMop qIqdMNYEo+IqNUaIpiHb+sYmy7g0Lj85o5ZYoTZRoQ5/tIPNYBVUC5jmsxY6pP3cySrw V/9tbHX0exKQ8TKI74ym3gbjFmsmrMypWCObbSvJFmQ14jfK69gvy1nZfhhU6N+qLWC8 MQi3upjRdJYnizMAaFHVsbMoQdfl84zhabouYzH6CeN8AxXQFPbwl4jf8V1dW6du63HQ O8IJSK11xtZnzZb1h9BhmFPxKokR2jbXaGqb+cx06lIOdpFrhnuIuErduh/khyeOkZZY YilQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885091; x=1704489891; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=INy+429BuuQVoZsuJFK2Hhv1zxxE+m6svEuazNu+L7w=; b=jPkbGeYIiKaqJ93hazIqqBdlz+F9aMqg0gWknoRupJ8YWnifYYtICGvxlgMU6yY0Kw FrQf/x2EKrIjm5hysEjbWyDwTox/HgDAAMUiT/01hkXt7GYsdnN3jYdIuOWLZDUnosN3 /tACM03LxNRzEGDAUCCUPaD+ar1aFIT7FHKO1EqIE3tiaQMg0F52ddHpN3HHFhRo5Bmd saJNROPSIW9DhYGWJHSM4h7yu61DITJsuiUexICzY+gSQQYSkU2GBspvmJtc80KArjSO kFmMWoyhq4GaZJbmUOqnlfMWOrKRNimteB/lqYU/By28Dd28pdV70eo8Ecbpi1iwFk0P G/DA== X-Gm-Message-State: AOJu0YyR1HCAoVqd1havcCnCmbshKvTPnPuMgaNd3OmNa2SshBpgC98z 9oNpgdPu6KFokozpwPjGJt4Lvn5DDIgSIGYnpR40qmlLhO7c1Q== X-Received: by 2002:a05:6a21:78a5:b0:196:ac07:e18e with SMTP id bf37-20020a056a2178a500b00196ac07e18emr89785pzc.115.1703885090792; Fri, 29 Dec 2023 13:24:50 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:50 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 24/71] hw/block: Constify VMState Date: Sat, 30 Dec 2023 08:22:59 +1100 Message-Id: <20231229212346.147149-25-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::535; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x535.google.com X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, DKIM_INVALID=0.1, DKIM_SIGNED=0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-25-richard.henderson@linaro.org> --- hw/block/ecc.c | 2 +- hw/block/fdc-isa.c | 2 +- hw/block/fdc-sysbus.c | 2 +- hw/block/fdc.c | 20 ++++++++++---------- hw/block/m25p80.c | 12 ++++++------ hw/block/nand.c | 2 +- hw/block/onenand.c | 2 +- hw/block/pflash_cfi01.c | 2 +- hw/block/swim.c | 6 +++--- hw/block/vhost-user-blk.c | 2 +- hw/block/virtio-blk.c | 2 +- 11 files changed, 27 insertions(+), 27 deletions(-) diff --git a/hw/block/ecc.c b/hw/block/ecc.c index 6e0d63842c..ed889a4184 100644 --- a/hw/block/ecc.c +++ b/hw/block/ecc.c @@ -82,7 +82,7 @@ const VMStateDescription vmstate_ecc_state = { .name = "ecc-state", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(cp, ECCState), VMSTATE_UINT16_ARRAY(lp, ECCState, 2), VMSTATE_UINT16(count, ECCState), diff --git a/hw/block/fdc-isa.c b/hw/block/fdc-isa.c index 7ec075e470..ad0921c7d3 100644 --- a/hw/block/fdc-isa.c +++ b/hw/block/fdc-isa.c @@ -259,7 +259,7 @@ static const VMStateDescription vmstate_isa_fdc = { .name = "fdc", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, FDCtrlISABus, 0, vmstate_fdc, FDCtrl), VMSTATE_END_OF_LIST() } diff --git a/hw/block/fdc-sysbus.c b/hw/block/fdc-sysbus.c index 86ea51d003..266bc4d145 100644 --- a/hw/block/fdc-sysbus.c +++ b/hw/block/fdc-sysbus.c @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_sysbus_fdc = { .name = "fdc", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, FDCtrlSysBus, 0, vmstate_fdc, FDCtrl), VMSTATE_END_OF_LIST() } diff --git a/hw/block/fdc.c b/hw/block/fdc.c index d7cc4d3ec1..6dd94e98bc 100644 --- a/hw/block/fdc.c +++ b/hw/block/fdc.c @@ -854,7 +854,7 @@ static const VMStateDescription vmstate_fdrive_media_changed = { .version_id = 1, .minimum_version_id = 1, .needed = fdrive_media_changed_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(media_changed, FDrive), VMSTATE_END_OF_LIST() } @@ -864,7 +864,7 @@ static const VMStateDescription vmstate_fdrive_media_rate = { .name = "fdrive/media_rate", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(media_rate, FDrive), VMSTATE_END_OF_LIST() } @@ -882,7 +882,7 @@ static const VMStateDescription vmstate_fdrive_perpendicular = { .version_id = 1, .minimum_version_id = 1, .needed = fdrive_perpendicular_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(perpendicular, FDrive), VMSTATE_END_OF_LIST() } @@ -899,13 +899,13 @@ static const VMStateDescription vmstate_fdrive = { .version_id = 1, .minimum_version_id = 1, .post_load = fdrive_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(head, FDrive), VMSTATE_UINT8(track, FDrive), VMSTATE_UINT8(sect, FDrive), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fdrive_media_changed, &vmstate_fdrive_media_rate, &vmstate_fdrive_perpendicular, @@ -977,7 +977,7 @@ static const VMStateDescription vmstate_fdc_reset_sensei = { .version_id = 1, .minimum_version_id = 1, .needed = fdc_reset_sensei_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(reset_sensei, FDCtrl), VMSTATE_END_OF_LIST() } @@ -995,7 +995,7 @@ static const VMStateDescription vmstate_fdc_result_timer = { .version_id = 1, .minimum_version_id = 1, .needed = fdc_result_timer_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(result_timer, FDCtrl), VMSTATE_END_OF_LIST() } @@ -1013,7 +1013,7 @@ static const VMStateDescription vmstate_fdc_phase = { .version_id = 1, .minimum_version_id = 1, .needed = fdc_phase_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(phase, FDCtrl), VMSTATE_END_OF_LIST() } @@ -1026,7 +1026,7 @@ const VMStateDescription vmstate_fdc = { .pre_save = fdc_pre_save, .pre_load = fdc_pre_load, .post_load = fdc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Controller State */ VMSTATE_UINT8(sra, FDCtrl), VMSTATE_UINT8(srb, FDCtrl), @@ -1057,7 +1057,7 @@ const VMStateDescription vmstate_fdc = { vmstate_fdrive, FDrive), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fdc_reset_sensei, &vmstate_fdc_result_timer, &vmstate_fdc_phase, diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index afc3fdf4d6..26ce895628 100644 --- a/hw/block/m25p80.c +++ b/hw/block/m25p80.c @@ -1684,7 +1684,7 @@ static const VMStateDescription vmstate_m25p80_data_read_loop = { .version_id = 1, .minimum_version_id = 1, .needed = m25p80_data_read_loop_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(data_read_loop, Flash), VMSTATE_END_OF_LIST() } @@ -1702,7 +1702,7 @@ static const VMStateDescription vmstate_m25p80_aai_enable = { .version_id = 1, .minimum_version_id = 1, .needed = m25p80_aai_enable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(aai_enable, Flash), VMSTATE_END_OF_LIST() } @@ -1720,7 +1720,7 @@ static const VMStateDescription vmstate_m25p80_write_protect = { .version_id = 1, .minimum_version_id = 1, .needed = m25p80_wp_level_srwd_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(wp_level, Flash), VMSTATE_BOOL(status_register_write_disabled, Flash), VMSTATE_END_OF_LIST() @@ -1743,7 +1743,7 @@ static const VMStateDescription vmstate_m25p80_block_protect = { .version_id = 1, .minimum_version_id = 1, .needed = m25p80_block_protect_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(block_protect0, Flash), VMSTATE_BOOL(block_protect1, Flash), VMSTATE_BOOL(block_protect2, Flash), @@ -1759,7 +1759,7 @@ static const VMStateDescription vmstate_m25p80 = { .minimum_version_id = 0, .pre_save = m25p80_pre_save, .pre_load = m25p80_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(state, Flash), VMSTATE_UINT8_ARRAY(data, Flash, M25P80_INTERNAL_DATA_BUFFER_SZ), VMSTATE_UINT32(len, Flash), @@ -1781,7 +1781,7 @@ static const VMStateDescription vmstate_m25p80 = { VMSTATE_UINT8(spansion_cr4nv, Flash), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_m25p80_data_read_loop, &vmstate_m25p80_aai_enable, &vmstate_m25p80_write_protect, diff --git a/hw/block/nand.c b/hw/block/nand.c index 9c1b89cfa6..d1435f2207 100644 --- a/hw/block/nand.c +++ b/hw/block/nand.c @@ -345,7 +345,7 @@ static const VMStateDescription vmstate_nand = { .minimum_version_id = 1, .pre_save = nand_pre_save, .post_load = nand_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(cle, NANDFlashState), VMSTATE_UINT8(ale, NANDFlashState), VMSTATE_UINT8(ce, NANDFlashState), diff --git a/hw/block/onenand.c b/hw/block/onenand.c index 50d3d1c985..d8a6944027 100644 --- a/hw/block/onenand.c +++ b/hw/block/onenand.c @@ -179,7 +179,7 @@ static const VMStateDescription vmstate_onenand = { .minimum_version_id = 1, .pre_save = onenand_pre_save, .post_load = onenand_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(current_direction, OneNANDState), VMSTATE_INT32(cycle, OneNANDState), VMSTATE_INT32(otpmode, OneNANDState), diff --git a/hw/block/pflash_cfi01.c b/hw/block/pflash_cfi01.c index 62056b1d74..3e2dc08bd7 100644 --- a/hw/block/pflash_cfi01.c +++ b/hw/block/pflash_cfi01.c @@ -95,7 +95,7 @@ static const VMStateDescription vmstate_pflash = { .version_id = 1, .minimum_version_id = 1, .post_load = pflash_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(wcycle, PFlashCFI01), VMSTATE_UINT8(cmd, PFlashCFI01), VMSTATE_UINT8(status, PFlashCFI01), diff --git a/hw/block/swim.c b/hw/block/swim.c index fd65c59f8a..44761c11cb 100644 --- a/hw/block/swim.c +++ b/hw/block/swim.c @@ -516,7 +516,7 @@ static const VMStateDescription vmstate_fdrive = { .name = "fdrive", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() }, }; @@ -525,7 +525,7 @@ static const VMStateDescription vmstate_swim = { .name = "swim", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(mode, SWIMCtrl), /* IWM mode */ VMSTATE_INT32(iwm_switch, SWIMCtrl), @@ -545,7 +545,7 @@ static const VMStateDescription vmstate_swim = { static const VMStateDescription vmstate_sysbus_swim = { .name = "SWIM", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ctrl, Swim, 0, vmstate_swim, SWIMCtrl), VMSTATE_END_OF_LIST() } diff --git a/hw/block/vhost-user-blk.c b/hw/block/vhost-user-blk.c index 2863d80d15..6a856ad51a 100644 --- a/hw/block/vhost-user-blk.c +++ b/hw/block/vhost-user-blk.c @@ -554,7 +554,7 @@ static const VMStateDescription vmstate_vhost_user_blk = { .name = "vhost-user-blk", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index 46e73b2c96..315b7b364c 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -1743,7 +1743,7 @@ static const VMStateDescription vmstate_virtio_blk = { .name = "virtio-blk", .minimum_version_id = 2, .version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758833 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672220wrw; Fri, 29 Dec 2023 13:31:02 -0800 (PST) X-Google-Smtp-Source: AGHT+IF9xnbnS1GavENkMT0MA4XNS+l8w7ulI7QlWYBw3OsIvcchB0MLrTcWtvn8W0caAiRXuJMD X-Received: by 2002:a05:6214:e8f:b0:67f:592b:d5da with SMTP id hf15-20020a0562140e8f00b0067f592bd5damr23083031qvb.11.1703885462260; Fri, 29 Dec 2023 13:31:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885462; cv=none; d=google.com; s=arc-20160816; b=dxjlYE581dQix0P7j5DyLlVz07SVlSF7OXwxuhkNF8aOk2E8ZK5Vly6OXu2QTmEET+ Z2UyQSsefk3T3gp7GZDq/kdOoqJgV4rhJ+VKUVL5sVYIN9FGxX9AegR2Y7D8qPMsIbSH wd6Y4bvZdF2xuBonzi5IluVwsWzo6E4CQNcFU2tbRZb6qqRnxj9VgcmtjhO2ZqyjVKrL 6fGtesAGKoMaEpD1lNWQlp4se0vWXC8ySz6mHkBQXQySG+r1pahTgZyAAefNOTtHSPx5 6bH60Hy8L9hZFG2+qgCQBhSlDgTKcLkhtP1wYW1NaHHHjW3mfCyo74ncOQCBqBVXwdlp KYVw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=GKnmXAmlXDao5sAmR0LTkuJqXjo38X9rbfTBaSAtIAQ=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=U86blPhlKUzD4Wad3jogCvaWEj9K8bODovY88L04ihLjr4pqBK6jgNXD9dHmAEocsf z65dug5Z3ksgoJnwc/coS9XsSMAkNz6zHmBTrywa0EuwAs9BTnxowNgbU82cPiMCfHoB Aq5SSr3pNxKhPUEjz2Jj1Hz1a2P77o1dcOE3BhvXoVYd1l/QOIpWE9xdPoaNyHExyzFf K8LFmdIIUkpCJws+JpTe7bp3jqZX7uCX+zVRXfXP1fiCBwA+MdEWmfgyTqfM7yhVynUY 3iV6ZchOUMWdYRqrWnB5oRZYt0vbVZzOG6Cik+3siLgD52Ac+F1ibkuJN/zP16zBF2qU oTTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Bnv7GZ9Y; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i14-20020a0c9c8e000000b0067f93134e9fsi17665404qvf.446.2023.12.29.13.31.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:02 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Bnv7GZ9Y; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLr-0008QT-LU; Fri, 29 Dec 2023 16:25:07 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLp-0008Iq-VX for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:06 -0500 Received: from mail-oo1-xc29.google.com ([2607:f8b0:4864:20::c29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLe-00077V-Ej for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:05 -0500 Received: by mail-oo1-xc29.google.com with SMTP id 006d021491bc7-5954039fd01so114426eaf.2 for ; Fri, 29 Dec 2023 13:24:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885093; x=1704489893; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=GKnmXAmlXDao5sAmR0LTkuJqXjo38X9rbfTBaSAtIAQ=; b=Bnv7GZ9Y52ElJhF8ewRaGvKU50gk6TWTLSxqALoOOM7En9SC/dwp20atA7DJZQxchT YpGqx4Qp+wgSOljJEH920oiPSfqIvjqIwZQwYFJiO07jHtMey+Xdi5J5/3yZ0DKeDwuF kJdQ05hiiPJjhMnafgbS6lbYmac5KaR9hcki/jD4q0Nn5wp1GWngLH7NHq/I2VDfXR9X Y0u60/p/nkj8+Hy0viEQ31cBeSoCLjrG0W2zQwFAJGEkMOHpBbJMNazY0IamQX/KX3FO A8LcU5BoKLnAzqIwZvgwr/flBeSe2qo2sHQVzgMmLD4Jg9616o6/ix5xDWOgq3G8KcLt IYTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885093; x=1704489893; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GKnmXAmlXDao5sAmR0LTkuJqXjo38X9rbfTBaSAtIAQ=; b=n1IgETHvPsxfZapRfI13fwAnTpRejSdCtALbqrfn4pMgMH6F3wadGTcVX4O6hmmnPb bJXPjVJWa21KjMDldpG+la/QmlqADJ6xSxsW6eU8Sctx8zI1ThADi6Z7SKLbxh7+7JkD GLV4Uxmy+dvGnjW1vx1zPCb3Zs+w3lZSMMoWd/cEr/IJRsTTUPr7Ktv8VGUjo42gGXYt N9pg2wHz4GhwuTNmKh0J3acxJ6rDKl/aPr0lYdlzcsr96yq5JgXHn6gZiB7mh5ceKuB3 WexuNjsCuKxJ1f3CBB3eyd6g0oiHhd41FOVywf2sS01tq/hYJdTalMXI0ZA9WBqbyst2 A7ew== X-Gm-Message-State: AOJu0Yw2ZcTcHflJP7n4/WCqP2Q1rpI4df1FNYCVBCZG9BQjJjSDDD7Y t9Kl3tnErNPldk+XbRMYZRyzatzkorh3hj/tO5qIJBe7qhbgrQ== X-Received: by 2002:a05:6358:9998:b0:174:d511:6334 with SMTP id j24-20020a056358999800b00174d5116334mr8052936rwb.51.1703885092798; Fri, 29 Dec 2023 13:24:52 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.51 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:52 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 25/71] hw/char: Constify VMState Date: Sat, 30 Dec 2023 08:23:00 +1100 Message-Id: <20231229212346.147149-26-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::c29; envelope-from=richard.henderson@linaro.org; helo=mail-oo1-xc29.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-26-richard.henderson@linaro.org> --- hw/char/bcm2835_aux.c | 2 +- hw/char/cadence_uart.c | 2 +- hw/char/cmsdk-apb-uart.c | 2 +- hw/char/digic-uart.c | 2 +- hw/char/escc.c | 4 ++-- hw/char/exynos4210_uart.c | 4 ++-- hw/char/goldfish_tty.c | 2 +- hw/char/ibex_uart.c | 2 +- hw/char/imx_serial.c | 2 +- hw/char/ipoctal232.c | 6 +++--- hw/char/mchp_pfsoc_mmuart.c | 2 +- hw/char/nrf51_uart.c | 2 +- hw/char/parallel.c | 2 +- hw/char/pl011.c | 6 +++--- hw/char/renesas_sci.c | 2 +- hw/char/sclpconsole-lm.c | 2 +- hw/char/sclpconsole.c | 2 +- hw/char/serial-isa.c | 2 +- hw/char/serial-pci-multi.c | 2 +- hw/char/serial-pci.c | 2 +- hw/char/serial.c | 20 ++++++++++---------- hw/char/sifive_uart.c | 2 +- hw/char/spapr_vty.c | 2 +- hw/char/virtio-serial-bus.c | 2 +- 24 files changed, 39 insertions(+), 39 deletions(-) diff --git a/hw/char/bcm2835_aux.c b/hw/char/bcm2835_aux.c index 96410b1ff8..83990e20f7 100644 --- a/hw/char/bcm2835_aux.c +++ b/hw/char/bcm2835_aux.c @@ -260,7 +260,7 @@ static const VMStateDescription vmstate_bcm2835_aux = { .name = TYPE_BCM2835_AUX, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(read_fifo, BCM2835AuxState, BCM2835_AUX_RX_FIFO_LEN), VMSTATE_UINT8(read_pos, BCM2835AuxState), diff --git a/hw/char/cadence_uart.c b/hw/char/cadence_uart.c index a2ac062b1e..db31d7cc85 100644 --- a/hw/char/cadence_uart.c +++ b/hw/char/cadence_uart.c @@ -602,7 +602,7 @@ static const VMStateDescription vmstate_cadence_uart = { .minimum_version_id = 2, .pre_load = cadence_uart_pre_load, .post_load = cadence_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(r, CadenceUARTState, CADENCE_UART_R_MAX), VMSTATE_UINT8_ARRAY(rx_fifo, CadenceUARTState, CADENCE_UART_RX_FIFO_SIZE), diff --git a/hw/char/cmsdk-apb-uart.c b/hw/char/cmsdk-apb-uart.c index d466cd93de..d07cca1bd4 100644 --- a/hw/char/cmsdk-apb-uart.c +++ b/hw/char/cmsdk-apb-uart.c @@ -366,7 +366,7 @@ static const VMStateDescription cmsdk_apb_uart_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = cmsdk_apb_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(state, CMSDKAPBUART), VMSTATE_UINT32(ctrl, CMSDKAPBUART), VMSTATE_UINT32(intstatus, CMSDKAPBUART), diff --git a/hw/char/digic-uart.c b/hw/char/digic-uart.c index 51d4e7db52..ef2d762726 100644 --- a/hw/char/digic-uart.c +++ b/hw/char/digic-uart.c @@ -165,7 +165,7 @@ static const VMStateDescription vmstate_digic_uart = { .name = "digic-uart", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(reg_rx, DigicUartState), VMSTATE_UINT32(reg_st, DigicUartState), VMSTATE_END_OF_LIST() diff --git a/hw/char/escc.c b/hw/char/escc.c index 48b30ee760..d450d70eda 100644 --- a/hw/char/escc.c +++ b/hw/char/escc.c @@ -766,7 +766,7 @@ static const VMStateDescription vmstate_escc_chn = { .name = "escc_chn", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vmstate_dummy, ESCCChannelState), VMSTATE_UINT32(reg, ESCCChannelState), VMSTATE_UINT32(rxint, ESCCChannelState), @@ -785,7 +785,7 @@ static const VMStateDescription vmstate_escc = { .name = "escc", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(chn, ESCCState, 2, 2, vmstate_escc_chn, ESCCChannelState), VMSTATE_END_OF_LIST() diff --git a/hw/char/exynos4210_uart.c b/hw/char/exynos4210_uart.c index 7b7c56b6ef..8cdd42e54f 100644 --- a/hw/char/exynos4210_uart.c +++ b/hw/char/exynos4210_uart.c @@ -628,7 +628,7 @@ static const VMStateDescription vmstate_exynos4210_uart_fifo = { .name = "exynos4210.uart.fifo", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(sp, Exynos4210UartFIFO), VMSTATE_UINT32(rp, Exynos4210UartFIFO), VMSTATE_VBUFFER_UINT32(data, Exynos4210UartFIFO, 1, NULL, size), @@ -641,7 +641,7 @@ static const VMStateDescription vmstate_exynos4210_uart = { .version_id = 1, .minimum_version_id = 1, .post_load = exynos4210_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(rx, Exynos4210UartState, 1, vmstate_exynos4210_uart_fifo, Exynos4210UartFIFO), VMSTATE_UINT32_ARRAY(reg, Exynos4210UartState, diff --git a/hw/char/goldfish_tty.c b/hw/char/goldfish_tty.c index 20b77885c1..f8ff043c39 100644 --- a/hw/char/goldfish_tty.c +++ b/hw/char/goldfish_tty.c @@ -232,7 +232,7 @@ static const VMStateDescription vmstate_goldfish_tty = { .name = "goldfish_tty", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(data_len, GoldfishTTYState), VMSTATE_UINT64(data_ptr, GoldfishTTYState), VMSTATE_BOOL(int_enabled, GoldfishTTYState), diff --git a/hw/char/ibex_uart.c b/hw/char/ibex_uart.c index 51708c0836..63aae6dc2c 100644 --- a/hw/char/ibex_uart.c +++ b/hw/char/ibex_uart.c @@ -488,7 +488,7 @@ static const VMStateDescription vmstate_ibex_uart = { .version_id = 1, .minimum_version_id = 1, .post_load = ibex_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(tx_fifo, IbexUartState, IBEX_UART_TX_FIFO_SIZE), VMSTATE_UINT32(tx_level, IbexUartState), diff --git a/hw/char/imx_serial.c b/hw/char/imx_serial.c index 377d1d9773..1df862eb7f 100644 --- a/hw/char/imx_serial.c +++ b/hw/char/imx_serial.c @@ -43,7 +43,7 @@ static const VMStateDescription vmstate_imx_serial = { .name = TYPE_IMX_SERIAL, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(readbuff, IMXSerialState), VMSTATE_UINT32(usr1, IMXSerialState), VMSTATE_UINT32(usr2, IMXSerialState), diff --git a/hw/char/ipoctal232.c b/hw/char/ipoctal232.c index 3311e0872c..64be5226d4 100644 --- a/hw/char/ipoctal232.c +++ b/hw/char/ipoctal232.c @@ -130,7 +130,7 @@ static const VMStateDescription vmstate_scc2698_channel = { .name = "scc2698_channel", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(rx_enabled, SCC2698Channel), VMSTATE_UINT8_ARRAY(mr, SCC2698Channel, 2), VMSTATE_UINT8(mr_idx, SCC2698Channel), @@ -146,7 +146,7 @@ static const VMStateDescription vmstate_scc2698_block = { .name = "scc2698_block", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(imr, SCC2698Block), VMSTATE_UINT8(isr, SCC2698Block), VMSTATE_END_OF_LIST() @@ -157,7 +157,7 @@ static const VMStateDescription vmstate_ipoctal = { .name = "ipoctal232", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_IPACK_DEVICE(parent_obj, IPOctalState), VMSTATE_STRUCT_ARRAY(ch, IPOctalState, N_CHANNELS, 1, vmstate_scc2698_channel, SCC2698Channel), diff --git a/hw/char/mchp_pfsoc_mmuart.c b/hw/char/mchp_pfsoc_mmuart.c index 22f3e78eb9..e7908bbfb5 100644 --- a/hw/char/mchp_pfsoc_mmuart.c +++ b/hw/char/mchp_pfsoc_mmuart.c @@ -114,7 +114,7 @@ static const VMStateDescription mchp_pfsoc_mmuart_vmstate = { .name = "mchp.pfsoc.uart", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, MchpPfSoCMMUartState, MCHP_PFSOC_MMUART_REG_COUNT), VMSTATE_END_OF_LIST() diff --git a/hw/char/nrf51_uart.c b/hw/char/nrf51_uart.c index dfe2276d71..c2cd6bb5e7 100644 --- a/hw/char/nrf51_uart.c +++ b/hw/char/nrf51_uart.c @@ -291,7 +291,7 @@ static int nrf51_uart_post_load(void *opaque, int version_id) static const VMStateDescription nrf51_uart_vmstate = { .name = "nrf51_soc.uart", .post_load = nrf51_uart_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, NRF51UARTState, 0x56C), VMSTATE_UINT8_ARRAY(rx_fifo, NRF51UARTState, UART_FIFO_LENGTH), VMSTATE_UINT32(rx_fifo_pos, NRF51UARTState), diff --git a/hw/char/parallel.c b/hw/char/parallel.c index 147c900f0d..bd488cd7f9 100644 --- a/hw/char/parallel.c +++ b/hw/char/parallel.c @@ -478,7 +478,7 @@ static const VMStateDescription vmstate_parallel_isa = { .name = "parallel_isa", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(state.dataw, ISAParallelState), VMSTATE_UINT8(state.datar, ISAParallelState), VMSTATE_UINT8(state.status, ISAParallelState), diff --git a/hw/char/pl011.c b/hw/char/pl011.c index 58edeb9ddb..855cb82d08 100644 --- a/hw/char/pl011.c +++ b/hw/char/pl011.c @@ -398,7 +398,7 @@ static const VMStateDescription vmstate_pl011_clock = { .version_id = 1, .minimum_version_id = 1, .needed = pl011_clock_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clk, PL011State), VMSTATE_END_OF_LIST() } @@ -433,7 +433,7 @@ static const VMStateDescription vmstate_pl011 = { .version_id = 2, .minimum_version_id = 2, .post_load = pl011_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(readbuff, PL011State), VMSTATE_UINT32(flags, PL011State), VMSTATE_UINT32(lcr, PL011State), @@ -452,7 +452,7 @@ static const VMStateDescription vmstate_pl011 = { VMSTATE_INT32(read_trigger, PL011State), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_pl011_clock, NULL } diff --git a/hw/char/renesas_sci.c b/hw/char/renesas_sci.c index 1c63467290..5cb733545c 100644 --- a/hw/char/renesas_sci.c +++ b/hw/char/renesas_sci.c @@ -302,7 +302,7 @@ static const VMStateDescription vmstate_rsci = { .name = "renesas-sci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(trtime, RSCIState), VMSTATE_INT64(rx_next, RSCIState), VMSTATE_UINT8(smr, RSCIState), diff --git a/hw/char/sclpconsole-lm.c b/hw/char/sclpconsole-lm.c index b9e9b2d453..7719f438f6 100644 --- a/hw/char/sclpconsole-lm.c +++ b/hw/char/sclpconsole-lm.c @@ -292,7 +292,7 @@ static const VMStateDescription vmstate_sclplmconsole = { .name = "sclplmconsole", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(event.event_pending, SCLPConsoleLM), VMSTATE_UINT32(write_errors, SCLPConsoleLM), VMSTATE_UINT32(length, SCLPConsoleLM), diff --git a/hw/char/sclpconsole.c b/hw/char/sclpconsole.c index c36b572222..5d630b04bb 100644 --- a/hw/char/sclpconsole.c +++ b/hw/char/sclpconsole.c @@ -206,7 +206,7 @@ static const VMStateDescription vmstate_sclpconsole = { .name = "sclpconsole", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(event.event_pending, SCLPConsole), VMSTATE_UINT8_ARRAY(iov, SCLPConsole, SIZE_BUFFER_VT220), VMSTATE_UINT32(iov_sclp, SCLPConsole), diff --git a/hw/char/serial-isa.c b/hw/char/serial-isa.c index 141a6cb168..1c793b20f7 100644 --- a/hw/char/serial-isa.c +++ b/hw/char/serial-isa.c @@ -106,7 +106,7 @@ static const VMStateDescription vmstate_isa_serial = { .name = "serial", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, ISASerialState, 0, vmstate_serial, SerialState), VMSTATE_END_OF_LIST() } diff --git a/hw/char/serial-pci-multi.c b/hw/char/serial-pci-multi.c index 5d65c534cb..28b275709a 100644 --- a/hw/char/serial-pci-multi.c +++ b/hw/char/serial-pci-multi.c @@ -123,7 +123,7 @@ static const VMStateDescription vmstate_pci_multi_serial = { .name = "pci-serial-multi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCIMultiSerialState), VMSTATE_STRUCT_ARRAY(state, PCIMultiSerialState, PCI_SERIAL_MAX_PORTS, 0, vmstate_serial, SerialState), diff --git a/hw/char/serial-pci.c b/hw/char/serial-pci.c index 087da3059a..f8a1a94d0c 100644 --- a/hw/char/serial-pci.c +++ b/hw/char/serial-pci.c @@ -74,7 +74,7 @@ static const VMStateDescription vmstate_pci_serial = { .name = "pci-serial", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCISerialState), VMSTATE_STRUCT(state, PCISerialState, 0, vmstate_serial, SerialState), VMSTATE_END_OF_LIST() diff --git a/hw/char/serial.c b/hw/char/serial.c index a32eb25f58..d8b2db5082 100644 --- a/hw/char/serial.c +++ b/hw/char/serial.c @@ -707,7 +707,7 @@ static const VMStateDescription vmstate_serial_thr_ipending = { .version_id = 1, .minimum_version_id = 1, .needed = serial_thr_ipending_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(thr_ipending, SerialState), VMSTATE_END_OF_LIST() } @@ -724,7 +724,7 @@ static const VMStateDescription vmstate_serial_tsr = { .version_id = 1, .minimum_version_id = 1, .needed = serial_tsr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tsr_retry, SerialState), VMSTATE_UINT8(thr, SerialState), VMSTATE_UINT8(tsr, SerialState), @@ -744,7 +744,7 @@ static const VMStateDescription vmstate_serial_recv_fifo = { .version_id = 1, .minimum_version_id = 1, .needed = serial_recv_fifo_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(recv_fifo, SerialState, 1, vmstate_fifo8, Fifo8), VMSTATE_END_OF_LIST() } @@ -761,7 +761,7 @@ static const VMStateDescription vmstate_serial_xmit_fifo = { .version_id = 1, .minimum_version_id = 1, .needed = serial_xmit_fifo_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(xmit_fifo, SerialState, 1, vmstate_fifo8, Fifo8), VMSTATE_END_OF_LIST() } @@ -778,7 +778,7 @@ static const VMStateDescription vmstate_serial_fifo_timeout_timer = { .version_id = 1, .minimum_version_id = 1, .needed = serial_fifo_timeout_timer_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(fifo_timeout_timer, SerialState), VMSTATE_END_OF_LIST() } @@ -795,7 +795,7 @@ static const VMStateDescription vmstate_serial_timeout_ipending = { .version_id = 1, .minimum_version_id = 1, .needed = serial_timeout_ipending_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(timeout_ipending, SerialState), VMSTATE_END_OF_LIST() } @@ -812,7 +812,7 @@ static const VMStateDescription vmstate_serial_poll = { .version_id = 1, .needed = serial_poll_needed, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(poll_msl, SerialState), VMSTATE_TIMER_PTR(modem_status_poll, SerialState), VMSTATE_END_OF_LIST() @@ -826,7 +826,7 @@ const VMStateDescription vmstate_serial = { .pre_save = serial_pre_save, .pre_load = serial_pre_load, .post_load = serial_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16_V(divider, SerialState, 2), VMSTATE_UINT8(rbr, SerialState), VMSTATE_UINT8(ier, SerialState), @@ -839,7 +839,7 @@ const VMStateDescription vmstate_serial = { VMSTATE_UINT8_V(fcr_vmstate, SerialState, 3), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_serial_thr_ipending, &vmstate_serial_tsr, &vmstate_serial_recv_fifo, @@ -1056,7 +1056,7 @@ static const VMStateDescription vmstate_serial_mm = { .name = "serial", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(serial, SerialMM, 0, vmstate_serial, SerialState), VMSTATE_END_OF_LIST() } diff --git a/hw/char/sifive_uart.c b/hw/char/sifive_uart.c index f2684e57bc..e8716c4252 100644 --- a/hw/char/sifive_uart.c +++ b/hw/char/sifive_uart.c @@ -224,7 +224,7 @@ static const VMStateDescription vmstate_sifive_uart = { .name = TYPE_SIFIVE_UART, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(rx_fifo, SiFiveUARTState, SIFIVE_UART_RX_FIFO_SIZE), VMSTATE_UINT8(rx_fifo_len, SiFiveUARTState), diff --git a/hw/char/spapr_vty.c b/hw/char/spapr_vty.c index 91eae1a598..3e23d9cbab 100644 --- a/hw/char/spapr_vty.c +++ b/hw/char/spapr_vty.c @@ -173,7 +173,7 @@ static const VMStateDescription vmstate_spapr_vty = { .name = "spapr_vty", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SPAPR_VIO(sdev, SpaprVioVty), VMSTATE_UINT32(in, SpaprVioVty), diff --git a/hw/char/virtio-serial-bus.c b/hw/char/virtio-serial-bus.c index dd619f0731..016aba6374 100644 --- a/hw/char/virtio-serial-bus.c +++ b/hw/char/virtio-serial-bus.c @@ -1148,7 +1148,7 @@ static const VMStateDescription vmstate_virtio_console = { .name = "virtio-console", .minimum_version_id = 3, .version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758811 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671479wrw; Fri, 29 Dec 2023 13:28:04 -0800 (PST) X-Google-Smtp-Source: AGHT+IGfHAv2GTEfNM9xjfK5d+2eucyMGSwuDB7nXuJyKsb3TRrst6PJhHiytfM1VtRQf9hKYV0L X-Received: by 2002:a05:622a:1106:b0:425:a118:eb8c with SMTP id e6-20020a05622a110600b00425a118eb8cmr17553852qty.8.1703885284557; Fri, 29 Dec 2023 13:28:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885284; cv=none; d=google.com; s=arc-20160816; b=ltThTt/1O3KGzV9HN5ZNcNqkWljFgkDuwp4WgxLKl42qod4gnWBxeSQMZKoZQV8hJm Ie29JZFSlQpRLClpl1hYCA4Dk36onwW2Z9pdV+xKR+1CbVE5vjmlk55cHAElpf1vfznG g94E+TsrPA8zaEzajuLSo5y2p2oQ+sTLGcFw51v6RzWkLmPZeRu3uacWbyx9vLZsHtii /yChlbn3Qm/qWodjOJ06DvnDOfvYoSXJcvYeuXDHZr6x5W1DLK8VWnpoXt+chGK1Ke8Z 2B3dxV2thCXysI0vQJwBcVIuByXjvrhm7lFhnMYeMqtqzq1zLISRJ2W8IlRwSuaWIc+T cDxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=805NU8ocQU2VbbubP7JcDpmo/DOhEU3Wqza849t+PTc=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=CyxSlcLAd9MEvobci9hZ04vDU7Kao4iERsVf0d0JHOd4qynZNZ+4VkHDW901MgzuXU 6GCM0Aso2Mdwdgy6si/qQK76I1KfhOgdbtVaRHPKW1pjRiuYk87JtI2BESKUtYy06Qr9 VyENs/MtNFcJ+YoSrEAEoYvCUROI1eHGd/yG9G6vvyGMAhEbCd7dgPsou1HYI1lg95Yr GLLkIsfjDRoZT8qo7AZH2nQU3sOViE1B8qme46aQWOFXneBvvyZK14xGZl5QrlEKOQ54 dtkBA9AkHbNE7i+VFea2voZIoz7gLUW/DjBj51qYABcGJmwwgT5FPRrzayLTU1P8PPBn RvTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jBvxRSP7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y6-20020a05622a004600b0042543ae77e5si19463657qtw.233.2023.12.29.13.28.04 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:04 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jBvxRSP7; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLk-0007e8-9d; Fri, 29 Dec 2023 16:25:00 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLj-0007ZT-0p for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:59 -0500 Received: from mail-oi1-x22d.google.com ([2607:f8b0:4864:20::22d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLg-000789-8j for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:24:58 -0500 Received: by mail-oi1-x22d.google.com with SMTP id 5614622812f47-3bbc648bed4so2172931b6e.3 for ; Fri, 29 Dec 2023 13:24:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885095; x=1704489895; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=805NU8ocQU2VbbubP7JcDpmo/DOhEU3Wqza849t+PTc=; b=jBvxRSP7eVuQY31IMQWI5hOXkN9B6CG4HSsg1TCaC33Z/6bjPzJKl7lf1TnEq4DXHu tsz2JvlrZjATfRf5m0IoLxXAkNEaoyuCrdo+3UoCkSibxPm59stlvZEOXSCguCZKK/OJ 0Xaa3Ea/RceTUYdiA99vi8EEz0/RAd8K/S5SlrduclFN5SyQlUPhZRO+jawxJ8BnaQ4V hu8hAv1pTbhg56LIDHgemmvCB1BCDLRDhHP0kYq+UlX3TpRbVKWQ+uQmg525aV+UKjw9 7GWU8Ty+tGVLX8RyE96059GOnArKh+FGPkJFjc77u1TWAAoYCq8mJSRYJKAtWy5FRMhT y0YQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885095; x=1704489895; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=805NU8ocQU2VbbubP7JcDpmo/DOhEU3Wqza849t+PTc=; b=MNRl5patUeSPzdChGxTHAFE3bR9JpJmsXLyq4PvSofxIJGBCk5h6xRFoMeWwTk9Q5u 6+L20NTxFWCrnZd8gXEgUecBPeQTz7Su/YHmEfJtiRtRbLH+irqAJclBvqSiWiKiTawK XKsDzVSvHw6KEoYXkZDFpKkxg+rAIi9y0VrcfkrarJ3J6igQqFg1/NDMc716GgIQSgzv cySYp2xNztj4455ofWjvqdnWZSlefsAiLmp2r3pDImyXe8bJY1akGdp4DkeUWBLBvt0P SlCQPuY8yVYD8U3yfEnu125XQ2S9KI0afMG5R2VWIIsCJwBcke6QLRCqsnKNBLUxQeXn 5lbQ== X-Gm-Message-State: AOJu0Yzw6ujmhzQWJ9amQEakiigYH5Co4kVVyDPBgQyHlGTHJB0Vf+Rm /ZD08vbI+S4yRexldUnoSLOYDc2se1WGJLIyEZ/fAzvzxyufog== X-Received: by 2002:a05:6808:3094:b0:3bb:d1f2:8802 with SMTP id bl20-20020a056808309400b003bbd1f28802mr3993573oib.40.1703885095049; Fri, 29 Dec 2023 13:24:55 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:54 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 26/71] hw/display: Constify VMState Date: Sat, 30 Dec 2023 08:23:01 +1100 Message-Id: <20231229212346.147149-27-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::22d; envelope-from=richard.henderson@linaro.org; helo=mail-oi1-x22d.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-27-richard.henderson@linaro.org> --- hw/display/artist.c | 2 +- hw/display/bcm2835_fb.c | 2 +- hw/display/bochs-display.c | 2 +- hw/display/cg3.c | 2 +- hw/display/cirrus_vga.c | 4 ++-- hw/display/dpcd.c | 2 +- hw/display/exynos4210_fimd.c | 4 ++-- hw/display/g364fb.c | 4 ++-- hw/display/i2c-ddc.c | 2 +- hw/display/jazz_led.c | 2 +- hw/display/macfb.c | 6 +++--- hw/display/pl110.c | 2 +- hw/display/pxa2xx_lcd.c | 4 ++-- hw/display/qxl.c | 10 +++++----- hw/display/ramfb-standalone.c | 2 +- hw/display/ramfb.c | 2 +- hw/display/sii9022.c | 2 +- hw/display/sm501.c | 6 +++--- hw/display/ssd0303.c | 2 +- hw/display/ssd0323.c | 2 +- hw/display/tcx.c | 2 +- hw/display/vga-pci.c | 2 +- hw/display/vga.c | 6 +++--- hw/display/virtio-gpu.c | 8 ++++---- hw/display/virtio-vga.c | 2 +- hw/display/vmware_vga.c | 4 ++-- hw/display/xlnx_dp.c | 2 +- 27 files changed, 45 insertions(+), 45 deletions(-) diff --git a/hw/display/artist.c b/hw/display/artist.c index fde050c882..d9134532fb 100644 --- a/hw/display/artist.c +++ b/hw/display/artist.c @@ -1435,7 +1435,7 @@ static const VMStateDescription vmstate_artist = { .version_id = 2, .minimum_version_id = 2, .post_load = vmstate_artist_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(height, ARTISTState), VMSTATE_UINT16(width, ARTISTState), VMSTATE_UINT16(depth, ARTISTState), diff --git a/hw/display/bcm2835_fb.c b/hw/display/bcm2835_fb.c index a05277674f..e40ed2d2e1 100644 --- a/hw/display/bcm2835_fb.c +++ b/hw/display/bcm2835_fb.c @@ -355,7 +355,7 @@ static const VMStateDescription vmstate_bcm2835_fb = { .name = TYPE_BCM2835_FB, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(lock, BCM2835FBState), VMSTATE_BOOL(invalidate, BCM2835FBState), VMSTATE_BOOL(pending, BCM2835FBState), diff --git a/hw/display/bochs-display.c b/hw/display/bochs-display.c index 9138e98c3b..3b1d922b6e 100644 --- a/hw/display/bochs-display.c +++ b/hw/display/bochs-display.c @@ -61,7 +61,7 @@ OBJECT_DECLARE_SIMPLE_TYPE(BochsDisplayState, BOCHS_DISPLAY) static const VMStateDescription vmstate_bochs_display = { .name = "bochs-display", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pci, BochsDisplayState), VMSTATE_UINT16_ARRAY(vbe_regs, BochsDisplayState, VBE_DISPI_INDEX_NB), VMSTATE_BOOL(big_endian_fb, BochsDisplayState), diff --git a/hw/display/cg3.c b/hw/display/cg3.c index 2e9656ae1c..b271faaa48 100644 --- a/hw/display/cg3.c +++ b/hw/display/cg3.c @@ -334,7 +334,7 @@ static const VMStateDescription vmstate_cg3 = { .version_id = 1, .minimum_version_id = 1, .post_load = vmstate_cg3_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(height, CG3State), VMSTATE_UINT16(width, CG3State), VMSTATE_UINT16(depth, CG3State), diff --git a/hw/display/cirrus_vga.c b/hw/display/cirrus_vga.c index b80f98b6c4..5dd5136a0c 100644 --- a/hw/display/cirrus_vga.c +++ b/hw/display/cirrus_vga.c @@ -2739,7 +2739,7 @@ const VMStateDescription vmstate_cirrus_vga = { .version_id = 2, .minimum_version_id = 1, .post_load = cirrus_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vga.latch, CirrusVGAState), VMSTATE_UINT8(vga.sr_index, CirrusVGAState), VMSTATE_BUFFER(vga.sr, CirrusVGAState), @@ -2777,7 +2777,7 @@ static const VMStateDescription vmstate_pci_cirrus_vga = { .name = "cirrus_vga", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCICirrusVGAState), VMSTATE_STRUCT(cirrus_vga, PCICirrusVGAState, 0, vmstate_cirrus_vga, CirrusVGAState), diff --git a/hw/display/dpcd.c b/hw/display/dpcd.c index 64463654a1..aab1b1a2d7 100644 --- a/hw/display/dpcd.c +++ b/hw/display/dpcd.c @@ -135,7 +135,7 @@ static const VMStateDescription vmstate_dpcd = { .name = TYPE_DPCD, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY_V(dpcd_info, DPCDState, DPCD_READABLE_AREA, 0), VMSTATE_END_OF_LIST() } diff --git a/hw/display/exynos4210_fimd.c b/hw/display/exynos4210_fimd.c index 34a960a976..84687527d5 100644 --- a/hw/display/exynos4210_fimd.c +++ b/hw/display/exynos4210_fimd.c @@ -1865,7 +1865,7 @@ static const VMStateDescription exynos4210_fimd_window_vmstate = { .name = "exynos4210.fimd_window", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(wincon, Exynos4210fimdWindow), VMSTATE_UINT32_ARRAY(buf_start, Exynos4210fimdWindow, 3), VMSTATE_UINT32_ARRAY(buf_end, Exynos4210fimdWindow, 3), @@ -1895,7 +1895,7 @@ static const VMStateDescription exynos4210_fimd_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = exynos4210_fimd_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(vidcon, Exynos4210fimdState, 4), VMSTATE_UINT32_ARRAY(vidtcon, Exynos4210fimdState, 4), VMSTATE_UINT32(shadowcon, Exynos4210fimdState), diff --git a/hw/display/g364fb.c b/hw/display/g364fb.c index 2903cab82d..e08ec3f8de 100644 --- a/hw/display/g364fb.c +++ b/hw/display/g364fb.c @@ -455,7 +455,7 @@ static const VMStateDescription vmstate_g364fb = { .version_id = 2, .minimum_version_id = 2, .post_load = g364fb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER_UNSAFE(color_palette, G364State, 0, 256 * 3), VMSTATE_BUFFER_UNSAFE(cursor_palette, G364State, 0, 9), VMSTATE_UINT16_ARRAY(cursor, G364State, 512), @@ -521,7 +521,7 @@ static const VMStateDescription vmstate_g364fb_sysbus = { .name = "g364fb-sysbus", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(g364, G364SysBusState, 2, vmstate_g364fb, G364State), VMSTATE_END_OF_LIST() } diff --git a/hw/display/i2c-ddc.c b/hw/display/i2c-ddc.c index 146489518c..3f9d1e1f6f 100644 --- a/hw/display/i2c-ddc.c +++ b/hw/display/i2c-ddc.c @@ -88,7 +88,7 @@ static void i2c_ddc_init(Object *obj) static const VMStateDescription vmstate_i2c_ddc = { .name = TYPE_I2CDDC, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(firstbyte, I2CDDCState), VMSTATE_UINT8(reg, I2CDDCState), VMSTATE_END_OF_LIST() diff --git a/hw/display/jazz_led.c b/hw/display/jazz_led.c index dd5f4696c4..534f15dcfd 100644 --- a/hw/display/jazz_led.c +++ b/hw/display/jazz_led.c @@ -257,7 +257,7 @@ static const VMStateDescription vmstate_jazz_led = { .version_id = 0, .minimum_version_id = 0, .post_load = jazz_led_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(segments, LedState), VMSTATE_END_OF_LIST() } diff --git a/hw/display/macfb.c b/hw/display/macfb.c index d61541ccb5..418e99c8e1 100644 --- a/hw/display/macfb.c +++ b/hw/display/macfb.c @@ -627,7 +627,7 @@ static const VMStateDescription vmstate_macfb = { .version_id = 1, .minimum_version_id = 1, .post_load = macfb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(type, MacfbState), VMSTATE_UINT8_ARRAY(color_palette, MacfbState, 256 * 3), VMSTATE_UINT32(palette_current, MacfbState), @@ -770,7 +770,7 @@ static const VMStateDescription vmstate_macfb_sysbus = { .name = "macfb-sysbus", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(macfb, MacfbSysBusState, 1, vmstate_macfb, MacfbState), VMSTATE_END_OF_LIST() } @@ -789,7 +789,7 @@ static const VMStateDescription vmstate_macfb_nubus = { .name = "macfb-nubus", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(macfb, MacfbNubusState, 1, vmstate_macfb, MacfbState), VMSTATE_END_OF_LIST() } diff --git a/hw/display/pl110.c b/hw/display/pl110.c index 4bf15c1da5..4b83db9322 100644 --- a/hw/display/pl110.c +++ b/hw/display/pl110.c @@ -83,7 +83,7 @@ static const VMStateDescription vmstate_pl110 = { .version_id = 2, .minimum_version_id = 1, .post_load = vmstate_pl110_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(version, PL110State), VMSTATE_UINT32_ARRAY(timing, PL110State, 4), VMSTATE_UINT32(cr, PL110State), diff --git a/hw/display/pxa2xx_lcd.c b/hw/display/pxa2xx_lcd.c index eb83d88222..a9d0d981a0 100644 --- a/hw/display/pxa2xx_lcd.c +++ b/hw/display/pxa2xx_lcd.c @@ -1371,7 +1371,7 @@ static const VMStateDescription vmstate_dma_channel = { .name = "dma_channel", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(branch, struct DMAChannel), VMSTATE_UINT8(up, struct DMAChannel), VMSTATE_BUFFER(pbuffer, struct DMAChannel), @@ -1398,7 +1398,7 @@ static const VMStateDescription vmstate_pxa2xx_lcdc = { .version_id = 0, .minimum_version_id = 0, .post_load = pxa2xx_lcdc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(irqlevel, PXA2xxLCDState), VMSTATE_INT32(transp, PXA2xxLCDState), VMSTATE_UINT32_ARRAY(control, PXA2xxLCDState, 6), diff --git a/hw/display/qxl.c b/hw/display/qxl.c index 7bb00d68f5..7178dec85d 100644 --- a/hw/display/qxl.c +++ b/hw/display/qxl.c @@ -2388,7 +2388,7 @@ static const VMStateDescription qxl_memslot = { .name = "qxl-memslot", .version_id = QXL_SAVE_VERSION, .minimum_version_id = QXL_SAVE_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(slot.mem_start, struct guest_slots), VMSTATE_UINT64(slot.mem_end, struct guest_slots), VMSTATE_UINT32(active, struct guest_slots), @@ -2400,7 +2400,7 @@ static const VMStateDescription qxl_surface = { .name = "qxl-surface", .version_id = QXL_SAVE_VERSION, .minimum_version_id = QXL_SAVE_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(width, QXLSurfaceCreate), VMSTATE_UINT32(height, QXLSurfaceCreate), VMSTATE_INT32(stride, QXLSurfaceCreate), @@ -2419,7 +2419,7 @@ static const VMStateDescription qxl_vmstate_monitors_config = { .version_id = 1, .minimum_version_id = 1, .needed = qxl_monitors_config_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(guest_monitors_config, PCIQXLDevice), VMSTATE_END_OF_LIST() }, @@ -2432,7 +2432,7 @@ static const VMStateDescription qxl_vmstate = { .pre_save = qxl_pre_save, .pre_load = qxl_pre_load, .post_load = qxl_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pci, PCIQXLDevice), VMSTATE_STRUCT(vga, PCIQXLDevice, 0, vmstate_vga_common, VGACommonState), VMSTATE_UINT32(shadow_rom.mode, PCIQXLDevice), @@ -2452,7 +2452,7 @@ static const VMStateDescription qxl_vmstate = { VMSTATE_UINT64(guest_cursor, PCIQXLDevice), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &qxl_vmstate_monitors_config, NULL } diff --git a/hw/display/ramfb-standalone.c b/hw/display/ramfb-standalone.c index a96e7ebcd9..20eab34ff4 100644 --- a/hw/display/ramfb-standalone.c +++ b/hw/display/ramfb-standalone.c @@ -54,7 +54,7 @@ static const VMStateDescription ramfb_dev_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = migrate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER(state, RAMFBStandaloneState, ramfb_vmstate, RAMFBState), VMSTATE_END_OF_LIST() } diff --git a/hw/display/ramfb.c b/hw/display/ramfb.c index 477ef7272a..6086baf7a9 100644 --- a/hw/display/ramfb.c +++ b/hw/display/ramfb.c @@ -129,7 +129,7 @@ const VMStateDescription ramfb_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = ramfb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER_UNSAFE(cfg, RAMFBState, 0, sizeof(RAMFBCfg)), VMSTATE_END_OF_LIST() } diff --git a/hw/display/sii9022.c b/hw/display/sii9022.c index 664fd4046d..60c3f78549 100644 --- a/hw/display/sii9022.c +++ b/hw/display/sii9022.c @@ -51,7 +51,7 @@ static const VMStateDescription vmstate_sii9022 = { .name = "sii9022", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(parent_obj, sii9022_state), VMSTATE_UINT8(ptr, sii9022_state), VMSTATE_BOOL(addr_byte, sii9022_state), diff --git a/hw/display/sm501.c b/hw/display/sm501.c index 5b4e4509e1..26dc8170d8 100644 --- a/hw/display/sm501.c +++ b/hw/display/sm501.c @@ -1940,7 +1940,7 @@ static const VMStateDescription vmstate_sm501_state = { .name = "sm501-state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(local_mem_size_index, SM501State), VMSTATE_UINT32(system_control, SM501State), VMSTATE_UINT32(misc_control, SM501State), @@ -2071,7 +2071,7 @@ static const VMStateDescription vmstate_sm501_sysbus = { .name = TYPE_SYSBUS_SM501, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, SM501SysBusState, 1, vmstate_sm501_state, SM501State), VMSTATE_END_OF_LIST() @@ -2161,7 +2161,7 @@ static const VMStateDescription vmstate_sm501_pci = { .name = TYPE_PCI_SM501, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, SM501PCIState), VMSTATE_STRUCT(state, SM501PCIState, 1, vmstate_sm501_state, SM501State), diff --git a/hw/display/ssd0303.c b/hw/display/ssd0303.c index 32b32a3044..e292cff44e 100644 --- a/hw/display/ssd0303.c +++ b/hw/display/ssd0303.c @@ -281,7 +281,7 @@ static const VMStateDescription vmstate_ssd0303 = { .name = "ssd0303_oled", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(row, ssd0303_state), VMSTATE_INT32(col, ssd0303_state), VMSTATE_INT32(start_line, ssd0303_state), diff --git a/hw/display/ssd0323.c b/hw/display/ssd0323.c index 09b1bbed0a..96cf0dc662 100644 --- a/hw/display/ssd0323.c +++ b/hw/display/ssd0323.c @@ -324,7 +324,7 @@ static const VMStateDescription vmstate_ssd0323 = { .version_id = 2, .minimum_version_id = 2, .post_load = ssd0323_post_load, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(cmd_len, ssd0323_state), VMSTATE_INT32(cmd, ssd0323_state), VMSTATE_INT32_ARRAY(cmd_data, ssd0323_state, 8), diff --git a/hw/display/tcx.c b/hw/display/tcx.c index 1b27b64f6d..99507e7638 100644 --- a/hw/display/tcx.c +++ b/hw/display/tcx.c @@ -344,7 +344,7 @@ static const VMStateDescription vmstate_tcx = { .version_id = 4, .minimum_version_id = 4, .post_load = vmstate_tcx_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(height, TCXState), VMSTATE_UINT16(width, TCXState), VMSTATE_UINT16(depth, TCXState), diff --git a/hw/display/vga-pci.c b/hw/display/vga-pci.c index e4f45b4476..2d8adce5da 100644 --- a/hw/display/vga-pci.c +++ b/hw/display/vga-pci.c @@ -61,7 +61,7 @@ static const VMStateDescription vmstate_vga_pci = { .name = "vga", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCIVGAState), VMSTATE_STRUCT(vga, PCIVGAState, 0, vmstate_vga_common, VGACommonState), VMSTATE_END_OF_LIST() diff --git a/hw/display/vga.c b/hw/display/vga.c index 37557c3442..886a4020e5 100644 --- a/hw/display/vga.c +++ b/hw/display/vga.c @@ -2106,7 +2106,7 @@ static const VMStateDescription vmstate_vga_endian = { .version_id = 1, .minimum_version_id = 1, .needed = vga_endian_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(big_endian_fb, VGACommonState), VMSTATE_END_OF_LIST() } @@ -2117,7 +2117,7 @@ const VMStateDescription vmstate_vga_common = { .version_id = 2, .minimum_version_id = 2, .post_load = vga_common_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(latch, VGACommonState), VMSTATE_UINT8(sr_index, VGACommonState), VMSTATE_PARTIAL_BUFFER(sr, VGACommonState, 8), @@ -2149,7 +2149,7 @@ const VMStateDescription vmstate_vga_common = { VMSTATE_UINT32(vbe_bank_mask, VGACommonState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_vga_endian, NULL } diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio-gpu.c index b016d3bac8..bae1c2a803 100644 --- a/hw/display/virtio-gpu.c +++ b/hw/display/virtio-gpu.c @@ -1164,7 +1164,7 @@ static void virtio_gpu_cursor_bh(void *opaque) static const VMStateDescription vmstate_virtio_gpu_scanout = { .name = "virtio-gpu-one-scanout", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(resource_id, struct virtio_gpu_scanout), VMSTATE_UINT32(width, struct virtio_gpu_scanout), VMSTATE_UINT32(height, struct virtio_gpu_scanout), @@ -1182,7 +1182,7 @@ static const VMStateDescription vmstate_virtio_gpu_scanout = { static const VMStateDescription vmstate_virtio_gpu_scanouts = { .name = "virtio-gpu-scanouts", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(parent_obj.enable, struct VirtIOGPU), VMSTATE_UINT32_EQUAL(parent_obj.conf.max_outputs, struct VirtIOGPU, NULL), @@ -1592,7 +1592,7 @@ static const VMStateDescription vmstate_virtio_gpu = { .name = "virtio-gpu", .minimum_version_id = VIRTIO_GPU_VM_VERSION, .version_id = VIRTIO_GPU_VM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE /* core */, { .name = "virtio-gpu", @@ -1605,7 +1605,7 @@ static const VMStateDescription vmstate_virtio_gpu = { } /* device */, VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_gpu_blob_state, NULL }, diff --git a/hw/display/virtio-vga.c b/hw/display/virtio-vga.c index c8552ff760..94d3353f54 100644 --- a/hw/display/virtio-vga.c +++ b/hw/display/virtio-vga.c @@ -88,7 +88,7 @@ static const VMStateDescription vmstate_virtio_vga_base = { .name = "virtio-vga", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* no pci stuff here, saving the virtio device will handle that */ VMSTATE_STRUCT(vga, VirtIOVGABase, 0, vmstate_vga_common, VGACommonState), diff --git a/hw/display/vmware_vga.c b/hw/display/vmware_vga.c index 3f26bea190..1c0f9d9a99 100644 --- a/hw/display/vmware_vga.c +++ b/hw/display/vmware_vga.c @@ -1210,7 +1210,7 @@ static const VMStateDescription vmstate_vmware_vga_internal = { .version_id = 0, .minimum_version_id = 0, .post_load = vmsvga_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(new_depth, struct vmsvga_state_s, NULL), VMSTATE_INT32(enable, struct vmsvga_state_s), VMSTATE_INT32(config, struct vmsvga_state_s), @@ -1235,7 +1235,7 @@ static const VMStateDescription vmstate_vmware_vga = { .name = "vmware_vga", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, struct pci_vmsvga_state_s), VMSTATE_STRUCT(chip, struct pci_vmsvga_state_s, 0, vmstate_vmware_vga_internal, struct vmsvga_state_s), diff --git a/hw/display/xlnx_dp.c b/hw/display/xlnx_dp.c index eee8f33a58..c42fc388dc 100644 --- a/hw/display/xlnx_dp.c +++ b/hw/display/xlnx_dp.c @@ -262,7 +262,7 @@ typedef enum DPVideoFmt DPVideoFmt; static const VMStateDescription vmstate_dp = { .name = TYPE_XLNX_DP, .version_id = 2, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32_ARRAY(core_registers, XlnxDPState, DP_CORE_REG_ARRAY_SIZE), VMSTATE_UINT32_ARRAY(avbufm_registers, XlnxDPState, From patchwork Fri Dec 29 21:23:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758796 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670913wrw; Fri, 29 Dec 2023 13:25:51 -0800 (PST) X-Google-Smtp-Source: AGHT+IFUxNurwEo8TnJuhy0WTEbPX1OJOoyBxP3UFdv50+J6JDFIuYJMmZL35kE3D29iulXbKNWf X-Received: by 2002:a05:620a:4001:b0:781:2299:6b0c with SMTP id h1-20020a05620a400100b0078122996b0cmr13899026qko.10.1703885151475; Fri, 29 Dec 2023 13:25:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885151; cv=none; d=google.com; s=arc-20160816; b=fOjsskCDsefkQY+aWL8hu3jhrY8Aypghxp4Uav69cpqEgaTJ/dAqYKGUMj1dq5s10G zKnPGcbVXX64djiC1eel6m1ZjfmMKfigTRP4ZxwTRzt0XBTXtgLcJoyip0undJImsh0W 2Crk9edm4IDSpHgtDt5wjiSk/9RcfuhAO6saMSX2I1P6ibes/0XsOizFkHUecs2X8QwH miFhGylhYm6P2+N3UYBxo5I2P00VkWHe+CpfcwJvaMKUEOi8fkunJFjfsFHOlA6YzH9f p4WPaY/ShmG3i015heH055tnXRNm6TzCn+ix5ASFpasIwd2LfIthoPimEc34+oWXLcm/ euNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=PP6EKVnGveQh2qDxwNT0eC81BelG1anG2yG8w9GFwNA=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=APXRoJRvB0w5v3lCS9703LJ7gzosJ4txXSW3kqafApjdjgPvIwLdVLDshV/rb12SuH EyDUXABD3wAChxupfjC3nCHf4Gz+LJ2vykEOcJE1T3PsdUn2m98jeYsBgQz1GmS8GA2a wDOn1xnMLLbzA6dQ+jPv+KSuwXdgk6KzumUkrqXzOEw85tXEbVW+nxMH0n/YMmyttC86 gjDVcrwqLBM5exWzKezhyQ894x5uouNzkwtR96nZxFCtWsXrXk+i8U8tSbFDWVcj5sjl lmCXXM6DLUGN1JxvF7LqaLe4eNd+48IZ+svJ7BxTmfS/+v5asS76ASzVWCopvHhxzKCo 4hNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d7X9uKnP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id vv7-20020a05620a562700b0077d8f0bfe49si19089190qkn.732.2023.12.29.13.25.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:25:51 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d7X9uKnP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLm-0007vl-N4; Fri, 29 Dec 2023 16:25:03 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLk-0007hd-Or for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:00 -0500 Received: from mail-pf1-x433.google.com ([2607:f8b0:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLi-0007AM-PF for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:00 -0500 Received: by mail-pf1-x433.google.com with SMTP id d2e1a72fcca58-6d9b51093a0so3529369b3a.0 for ; Fri, 29 Dec 2023 13:24:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885097; x=1704489897; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=PP6EKVnGveQh2qDxwNT0eC81BelG1anG2yG8w9GFwNA=; b=d7X9uKnPchasoGk5zl4BkC8BqLWeMDjne3eQQ4qANRF3/9Qoo1TGPsuyBb0Hd3dpxr d+yJ6dui1bzOQvQNtAyMF5xomSn717wWsz12lXSmm8/+FxapSNbpJ/uK2JN/+sMroIMm gywpXJibrtZe9WxACzpXVi7hZ6e/wmH+7MMPyr6zxyaQ9tz/we4Od39pJy1jLnSswEvZ NSAcPdisw+K2dsqJdSd9o/C2+sSxCE/TZ8j2OXSwyUA8lhY3O6/3zODE2yl7kZw0Aj5L FLXoetpqyZJkbLRACpt5m8n0rvKkJ8nASwqqvtfBScS8Suv6TgfgW+ipjAqLnQNUnEyN VawA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885097; x=1704489897; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=PP6EKVnGveQh2qDxwNT0eC81BelG1anG2yG8w9GFwNA=; b=HuMBMc6vFlRjpaza69NTVTR9+t0sLc2xGlSeAT5S7qS85a6oborUx6yDQxYgqnd0iA Mf7NTXkb1I5e2RCgVm1E+N/ukEp/x/jgTT0ZaH92DFgzMvc+USuVfPh+OvLoKBiLKnnT UVQwLAWaooydmv4PBR1LQesyyNzOKCTaCzmu7+bMOGWMMHP65W6x5e3Tnz4dJZbjdZXE l86cp0YiG7pv0V8UILRRdjPKjO5XPPcucrTvVyn5s6qTXGR3/GnztkZHxLtStg1FqiEy cSsBWhuPSkSj/P34DwD+cS3bBTanOba2IM91KM7F/ab2Zfw0whahCM94a8PQ9lMxgZn+ OSFA== X-Gm-Message-State: AOJu0YyUL7T47mQWpbiEBNKvgqNEcoyjYxraGg3UkdL7f1OIWlrIyh3D HDsKycuNFaknNsrvvs3q4w0mb/TlgqxPaqhBuUVc0gGSnwairw== X-Received: by 2002:a05:6a20:914f:b0:196:9770:2a05 with SMTP id x15-20020a056a20914f00b0019697702a05mr991070pzc.58.1703885097251; Fri, 29 Dec 2023 13:24:57 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:56 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 27/71] hw/dma: Constify VMState Date: Sat, 30 Dec 2023 08:23:02 +1100 Message-Id: <20231229212346.147149-28-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::433; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x433.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-28-richard.henderson@linaro.org> --- hw/dma/bcm2835_dma.c | 4 ++-- hw/dma/i82374.c | 2 +- hw/dma/i8257.c | 4 ++-- hw/dma/pl080.c | 4 ++-- hw/dma/pl330.c | 10 +++++----- hw/dma/pxa2xx_dma.c | 4 ++-- hw/dma/rc4030.c | 2 +- hw/dma/sparc32_dma.c | 2 +- hw/dma/xlnx-zdma.c | 2 +- hw/dma/xlnx-zynq-devcfg.c | 4 ++-- hw/dma/xlnx_csu_dma.c | 2 +- hw/dma/xlnx_dpdma.c | 2 +- 12 files changed, 21 insertions(+), 21 deletions(-) diff --git a/hw/dma/bcm2835_dma.c b/hw/dma/bcm2835_dma.c index 5e9306110d..9bda45072b 100644 --- a/hw/dma/bcm2835_dma.c +++ b/hw/dma/bcm2835_dma.c @@ -311,7 +311,7 @@ static const VMStateDescription vmstate_bcm2835_dma_chan = { .name = TYPE_BCM2835_DMA "-chan", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cs, BCM2835DMAChan), VMSTATE_UINT32(conblk_ad, BCM2835DMAChan), VMSTATE_UINT32(ti, BCM2835DMAChan), @@ -329,7 +329,7 @@ static const VMStateDescription vmstate_bcm2835_dma = { .name = TYPE_BCM2835_DMA, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(chan, BCM2835DMAState, BCM2835_DMA_NCHANS, 1, vmstate_bcm2835_dma_chan, BCM2835DMAChan), VMSTATE_UINT32(int_status, BCM2835DMAState), diff --git a/hw/dma/i82374.c b/hw/dma/i82374.c index 63734c22c9..f6ddfc51c5 100644 --- a/hw/dma/i82374.c +++ b/hw/dma/i82374.c @@ -58,7 +58,7 @@ static const VMStateDescription vmstate_i82374 = { .name = "i82374", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(commands, I82374State, 8), VMSTATE_END_OF_LIST() }, diff --git a/hw/dma/i8257.c b/hw/dma/i8257.c index de5f696919..de1d5b110c 100644 --- a/hw/dma/i8257.c +++ b/hw/dma/i8257.c @@ -517,7 +517,7 @@ static const VMStateDescription vmstate_i8257_regs = { .name = "dma_regs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_ARRAY(now, I8257Regs, 2), VMSTATE_UINT16_ARRAY(base, I8257Regs, 2), VMSTATE_UINT8(mode, I8257Regs), @@ -542,7 +542,7 @@ static const VMStateDescription vmstate_i8257 = { .version_id = 1, .minimum_version_id = 1, .post_load = i8257_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(command, I8257State), VMSTATE_UINT8(mask, I8257State), VMSTATE_UINT8(flip_flop, I8257State), diff --git a/hw/dma/pl080.c b/hw/dma/pl080.c index 2627307cc8..1e49c22e93 100644 --- a/hw/dma/pl080.c +++ b/hw/dma/pl080.c @@ -39,7 +39,7 @@ static const VMStateDescription vmstate_pl080_channel = { .name = "pl080_channel", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(src, pl080_channel), VMSTATE_UINT32(dest, pl080_channel), VMSTATE_UINT32(lli, pl080_channel), @@ -53,7 +53,7 @@ static const VMStateDescription vmstate_pl080 = { .name = "pl080", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(tc_int, PL080State), VMSTATE_UINT8(tc_mask, PL080State), VMSTATE_UINT8(err_int, PL080State), diff --git a/hw/dma/pl330.c b/hw/dma/pl330.c index e7e67dd8b6..70a502d245 100644 --- a/hw/dma/pl330.c +++ b/hw/dma/pl330.c @@ -139,7 +139,7 @@ static const VMStateDescription vmstate_pl330_chan = { .name = "pl330_chan", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(src, PL330Chan), VMSTATE_UINT32(dst, PL330Chan), VMSTATE_UINT32(pc, PL330Chan), @@ -170,7 +170,7 @@ static const VMStateDescription vmstate_pl330_fifo = { .name = "pl330_chan", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VBUFFER_UINT32(buf, PL330Fifo, 1, NULL, buf_size), VMSTATE_VBUFFER_UINT32(tag, PL330Fifo, 1, NULL, buf_size), VMSTATE_UINT32(head, PL330Fifo), @@ -194,7 +194,7 @@ static const VMStateDescription vmstate_pl330_queue_entry = { .name = "pl330_queue_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(addr, PL330QueueEntry), VMSTATE_UINT32(len, PL330QueueEntry), VMSTATE_UINT8(n, PL330QueueEntry), @@ -216,7 +216,7 @@ static const VMStateDescription vmstate_pl330_queue = { .name = "pl330_queue", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_UINT32(queue, PL330Queue, queue_size, vmstate_pl330_queue_entry, PL330QueueEntry), @@ -280,7 +280,7 @@ static const VMStateDescription vmstate_pl330 = { .name = "pl330", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(manager, PL330State, 0, vmstate_pl330_chan, PL330Chan), VMSTATE_STRUCT_VARRAY_POINTER_UINT32(chan, PL330State, num_chnls, vmstate_pl330_chan, PL330Chan), diff --git a/hw/dma/pxa2xx_dma.c b/hw/dma/pxa2xx_dma.c index fa896f7edf..9f62f0b633 100644 --- a/hw/dma/pxa2xx_dma.c +++ b/hw/dma/pxa2xx_dma.c @@ -529,7 +529,7 @@ static const VMStateDescription vmstate_pxa2xx_dma_chan = { .name = "pxa2xx_dma_chan", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(descr, PXA2xxDMAChannel), VMSTATE_UINT32(src, PXA2xxDMAChannel), VMSTATE_UINT32(dest, PXA2xxDMAChannel), @@ -544,7 +544,7 @@ static const VMStateDescription vmstate_pxa2xx_dma = { .name = "pxa2xx_dma", .version_id = 1, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UNUSED_TEST(is_version_0, 4), VMSTATE_UINT32(stopintr, PXA2xxDMAState), VMSTATE_UINT32(eorintr, PXA2xxDMAState), diff --git a/hw/dma/rc4030.c b/hw/dma/rc4030.c index aa1d323a36..915284194f 100644 --- a/hw/dma/rc4030.c +++ b/hw/dma/rc4030.c @@ -568,7 +568,7 @@ static const VMStateDescription vmstate_rc4030 = { .name = "rc4030", .version_id = 3, .post_load = rc4030_post_load, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(config, rc4030State), VMSTATE_UINT32(invalid_address_register, rc4030State), VMSTATE_UINT32_2DARRAY(dma_regs, rc4030State, 8, 4), diff --git a/hw/dma/sparc32_dma.c b/hw/dma/sparc32_dma.c index 0ef13c5e9a..8019641942 100644 --- a/hw/dma/sparc32_dma.c +++ b/hw/dma/sparc32_dma.c @@ -249,7 +249,7 @@ static const VMStateDescription vmstate_sparc32_dma_device = { .name ="sparc32_dma", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(dmaregs, DMADeviceState, DMA_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/dma/xlnx-zdma.c b/hw/dma/xlnx-zdma.c index 84c0083013..670c956866 100644 --- a/hw/dma/xlnx-zdma.c +++ b/hw/dma/xlnx-zdma.c @@ -801,7 +801,7 @@ static const VMStateDescription vmstate_zdma = { .name = TYPE_XLNX_ZDMA, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZDMA, ZDMA_R_MAX), VMSTATE_UINT32(state, XlnxZDMA), VMSTATE_UINT32_ARRAY(dsc_src.words, XlnxZDMA, 4), diff --git a/hw/dma/xlnx-zynq-devcfg.c b/hw/dma/xlnx-zynq-devcfg.c index f5ad1a0d22..e901f68ff3 100644 --- a/hw/dma/xlnx-zynq-devcfg.c +++ b/hw/dma/xlnx-zynq-devcfg.c @@ -333,7 +333,7 @@ static const VMStateDescription vmstate_xlnx_zynq_devcfg_dma_cmd = { .name = "xlnx_zynq_devcfg_dma_cmd", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(src_addr, XlnxZynqDevcfgDMACmd), VMSTATE_UINT32(dest_addr, XlnxZynqDevcfgDMACmd), VMSTATE_UINT32(src_len, XlnxZynqDevcfgDMACmd), @@ -346,7 +346,7 @@ static const VMStateDescription vmstate_xlnx_zynq_devcfg = { .name = "xlnx_zynq_devcfg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(dma_cmd_fifo, XlnxZynqDevcfg, XLNX_ZYNQ_DEVCFG_DMA_CMD_FIFO_LEN, 0, vmstate_xlnx_zynq_devcfg_dma_cmd, diff --git a/hw/dma/xlnx_csu_dma.c b/hw/dma/xlnx_csu_dma.c index bc1505aade..ae307482f2 100644 --- a/hw/dma/xlnx_csu_dma.c +++ b/hw/dma/xlnx_csu_dma.c @@ -681,7 +681,7 @@ static const VMStateDescription vmstate_xlnx_csu_dma = { .name = TYPE_XLNX_CSU_DMA, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(src_timer, XlnxCSUDMA), VMSTATE_UINT16(width, XlnxCSUDMA), VMSTATE_BOOL(is_dst, XlnxCSUDMA), diff --git a/hw/dma/xlnx_dpdma.c b/hw/dma/xlnx_dpdma.c index dd66be5265..1f5cd64ed1 100644 --- a/hw/dma/xlnx_dpdma.c +++ b/hw/dma/xlnx_dpdma.c @@ -277,7 +277,7 @@ static inline bool xlnx_dpdma_desc_ignore_done_bit(DPDMADescriptor *desc) static const VMStateDescription vmstate_xlnx_dpdma = { .name = TYPE_XLNX_DPDMA, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(registers, XlnxDPDMAState, XLNX_DPDMA_REG_ARRAY_SIZE), VMSTATE_BOOL_ARRAY(operation_finished, XlnxDPDMAState, 6), From patchwork Fri Dec 29 21:23:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758804 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671226wrw; Fri, 29 Dec 2023 13:27:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IHxGIYVb3ioKLRBu/JVf804EPVfL3KexuxyIVsC+fjnzeIfyU9FWmXBaSIqSxKmznEVfSfG X-Received: by 2002:a0c:f785:0:b0:680:a45:3a29 with SMTP id s5-20020a0cf785000000b006800a453a29mr8319499qvn.20.1703885227386; Fri, 29 Dec 2023 13:27:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885227; cv=none; d=google.com; s=arc-20160816; b=E7Y4sBwpPwThC+avVQmOOs6eKU8mpClNGWpwS+w3fJcHp/L0PYdcd5cV6ol1autGhg eXYZ7BtTbTZrZry28xyRw2q2p0EmJBdMAQvj8Ccq/p/Ac7qH3Mwa5iiJwwR3ekfJ2Ugx oQkl21Y/9SqtVTf7092OdySQxLh+XA2BAJlEqK4Sig7bCd5i6Prgzs4QleoumsWQ9Nty hdGmmYIlUrpWyftrIusEBLrfcww7Z3SLQoi9ZRJvEeBjxcRiBdaVqu5XiyevbLYHEcBR kPExkW1hGRDJMj4ATbXshgVQpzD1+mA16npp/Dux2jVGiyXtNm7EN2EGQFpMN01HyN91 OXPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=xQyRHBkLI0FgtPz8q8Pr42xSokamiCI15aesiSNpptA=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=GPLZOtokqdNs1zJjIgrrWZw4cavnqxebWNqPMnv8f7H3bAjdE0DvrTp4pL4roTt9OG MaeP4gb2JOZxl4ZbBj0580q7LQk6/t/HJ299yMwzCCaGCVwCmteq/mALoLRIG04JTgcS /+IqqsyLF8XPHdciop0k+BWfqKAyaWLZyjzoP9inzXk45gz7DuVu/HGNAXTaHTQLcrLw 37W+gV+4SZZrjH3/9eWiaYwKZoa5w5D9tZHc/h4DjNRyVQuVXKZ8auuFWH91qvXJkye6 QTldbDG808Ege8oZKL/Xn75XR0tVK/H9CZzGosmXEtIKd/ygmYmDAeQZvHzZcYv4AOSi I6EQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=l5TckRjt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f7-20020a0ccc87000000b0067eab9e436fsi4768754qvl.547.2023.12.29.13.27.07 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:07 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=l5TckRjt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLq-0008LZ-RI; Fri, 29 Dec 2023 16:25:06 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLn-0007xg-38 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:03 -0500 Received: from mail-il1-x12c.google.com ([2607:f8b0:4864:20::12c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLk-0007E5-PR for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:02 -0500 Received: by mail-il1-x12c.google.com with SMTP id e9e14a558f8ab-35fd9e40039so36728915ab.1 for ; Fri, 29 Dec 2023 13:25:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885099; x=1704489899; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=xQyRHBkLI0FgtPz8q8Pr42xSokamiCI15aesiSNpptA=; b=l5TckRjtIqr8RcsWpMm2f3m6h6Gw8K8dexk6LtaO7u3Dy/lRWWshJHxHHubg+VOVqP Kbhq/+v6BtyvNhNL74L1kPR7Sfx9SZ6JUlKe4NTwIdoUJ5wUaGpS/cHsfulwikxCyCXl qsenKYcpfuml0TyadeZArL6OSLzGysZbyeCibbHlq99/9SY23mC4uSxhl5S9wIln9kA5 Zv6Z8xe83G/s1MSgC6x3OvTxNLvOyM9gelyedfywfsFbT89cqLp0V2nIlA7H0uX1yk2t /6+9Njcf/F92jNtgcjLsvppeAMeTRqFERvqnmK9FG3RRjAje0gez6PWxu2SU46PE9O8K OzMw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885099; x=1704489899; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=xQyRHBkLI0FgtPz8q8Pr42xSokamiCI15aesiSNpptA=; b=puEKuq3Mol4D6IykUOCj3pxl70GjHttbSwH2yh6sDB6dVDwxMv70PSbKgu2hRnGi3U SQ+LYMgZsLVVkMi0DxdUx+cUmc5i9pkEUOA8PeK0rW1D9lzyUty2w1GpvKpM/CfLa0mH wK1InDgMZno/AE4ye5dI0dHJaUCsmCMGjviNpPPuesN0mtb9YwZKpGQRqWxx2RaMstaP EOwHmvtZoP3bPkHNqbOw3VEmjKlPtcvbGoT9lC6L2bFLL96EvGCOHCDPXV0Rckl+8KoI vIkkfzGRsF6wO1hGT0yg8J3ZFrtp9CH8Yqacmz1v3au2YPf+ZH/kgn4nfjuWmKiK72ZL +z3Q== X-Gm-Message-State: AOJu0YwlFAegql5bJwm4c2fMBbFepdAvHABphJbN2FFyVj3xk6pCMhjk r4Bno3gX+gotrmxCrVhP/fK3E/82K4kwtHRuGr//t0QHcTgmsg== X-Received: by 2002:a05:6e02:1848:b0:360:de:3437 with SMTP id b8-20020a056e02184800b0036000de3437mr13450683ilv.26.1703885099530; Fri, 29 Dec 2023 13:24:59 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.57 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:24:59 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 28/71] hw/gpio: Constify VMState Date: Sat, 30 Dec 2023 08:23:03 +1100 Message-Id: <20231229212346.147149-29-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::12c; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x12c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-29-richard.henderson@linaro.org> --- hw/gpio/aspeed_gpio.c | 4 ++-- hw/gpio/bcm2835_gpio.c | 2 +- hw/gpio/gpio_key.c | 2 +- hw/gpio/imx_gpio.c | 2 +- hw/gpio/max7310.c | 2 +- hw/gpio/mpc8xxx.c | 2 +- hw/gpio/npcm7xx_gpio.c | 2 +- hw/gpio/nrf51_gpio.c | 2 +- hw/gpio/pl061.c | 2 +- hw/gpio/sifive_gpio.c | 2 +- hw/gpio/zaurus.c | 2 +- 11 files changed, 12 insertions(+), 12 deletions(-) diff --git a/hw/gpio/aspeed_gpio.c b/hw/gpio/aspeed_gpio.c index 1e267dd482..c1781e2ba3 100644 --- a/hw/gpio/aspeed_gpio.c +++ b/hw/gpio/aspeed_gpio.c @@ -1067,7 +1067,7 @@ static const VMStateDescription vmstate_gpio_regs = { .name = TYPE_ASPEED_GPIO"/regs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(data_value, GPIOSets), VMSTATE_UINT32(data_read, GPIOSets), VMSTATE_UINT32(direction, GPIOSets), @@ -1090,7 +1090,7 @@ static const VMStateDescription vmstate_aspeed_gpio = { .name = TYPE_ASPEED_GPIO, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(sets, AspeedGPIOState, ASPEED_GPIO_MAX_NR_SETS, 1, vmstate_gpio_regs, GPIOSets), VMSTATE_UINT32_ARRAY(debounce_regs, AspeedGPIOState, diff --git a/hw/gpio/bcm2835_gpio.c b/hw/gpio/bcm2835_gpio.c index c995bba1d9..6bd50bb0b6 100644 --- a/hw/gpio/bcm2835_gpio.c +++ b/hw/gpio/bcm2835_gpio.c @@ -284,7 +284,7 @@ static const VMStateDescription vmstate_bcm2835_gpio = { .name = "bcm2835_gpio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(fsel, BCM2835GpioState, 54), VMSTATE_UINT32(lev0, BCM2835GpioState), VMSTATE_UINT32(lev1, BCM2835GpioState), diff --git a/hw/gpio/gpio_key.c b/hw/gpio/gpio_key.c index 74f6138356..61bb587058 100644 --- a/hw/gpio/gpio_key.c +++ b/hw/gpio/gpio_key.c @@ -45,7 +45,7 @@ static const VMStateDescription vmstate_gpio_key = { .name = "gpio-key", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, GPIOKEYState), VMSTATE_END_OF_LIST() } diff --git a/hw/gpio/imx_gpio.c b/hw/gpio/imx_gpio.c index c7f98b7bb1..e53b00d951 100644 --- a/hw/gpio/imx_gpio.c +++ b/hw/gpio/imx_gpio.c @@ -277,7 +277,7 @@ static const VMStateDescription vmstate_imx_gpio = { .name = TYPE_IMX_GPIO, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(dr, IMXGPIOState), VMSTATE_UINT32(gdir, IMXGPIOState), VMSTATE_UINT32(psr, IMXGPIOState), diff --git a/hw/gpio/max7310.c b/hw/gpio/max7310.c index 4470cfe985..86315714fb 100644 --- a/hw/gpio/max7310.c +++ b/hw/gpio/max7310.c @@ -155,7 +155,7 @@ static const VMStateDescription vmstate_max7310 = { .name = "max7310", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(i2c_command_byte, MAX7310State), VMSTATE_INT32(len, MAX7310State), VMSTATE_UINT8(level, MAX7310State), diff --git a/hw/gpio/mpc8xxx.c b/hw/gpio/mpc8xxx.c index cb42acb6da..0b3f9e516d 100644 --- a/hw/gpio/mpc8xxx.c +++ b/hw/gpio/mpc8xxx.c @@ -48,7 +48,7 @@ static const VMStateDescription vmstate_mpc8xxx_gpio = { .name = "mpc8xxx_gpio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(dir, MPC8XXXGPIOState), VMSTATE_UINT32(odr, MPC8XXXGPIOState), VMSTATE_UINT32(dat, MPC8XXXGPIOState), diff --git a/hw/gpio/npcm7xx_gpio.c b/hw/gpio/npcm7xx_gpio.c index 3376901ab1..6e70ac1f24 100644 --- a/hw/gpio/npcm7xx_gpio.c +++ b/hw/gpio/npcm7xx_gpio.c @@ -377,7 +377,7 @@ static const VMStateDescription vmstate_npcm7xx_gpio = { .name = "npcm7xx-gpio", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pin_level, NPCM7xxGPIOState), VMSTATE_UINT32(ext_level, NPCM7xxGPIOState), VMSTATE_UINT32(ext_driven, NPCM7xxGPIOState), diff --git a/hw/gpio/nrf51_gpio.c b/hw/gpio/nrf51_gpio.c index 08396c69a4..ffc7dff796 100644 --- a/hw/gpio/nrf51_gpio.c +++ b/hw/gpio/nrf51_gpio.c @@ -280,7 +280,7 @@ static const VMStateDescription vmstate_nrf51_gpio = { .name = TYPE_NRF51_GPIO, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(out, NRF51GPIOState), VMSTATE_UINT32(in, NRF51GPIOState), VMSTATE_UINT32(in_mask, NRF51GPIOState), diff --git a/hw/gpio/pl061.c b/hw/gpio/pl061.c index 899be861cc..86f2383655 100644 --- a/hw/gpio/pl061.c +++ b/hw/gpio/pl061.c @@ -87,7 +87,7 @@ static const VMStateDescription vmstate_pl061 = { .name = "pl061", .version_id = 4, .minimum_version_id = 4, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(locked, PL061State), VMSTATE_UINT32(data, PL061State), VMSTATE_UINT32(old_out_data, PL061State), diff --git a/hw/gpio/sifive_gpio.c b/hw/gpio/sifive_gpio.c index 78bf29e996..995a43c795 100644 --- a/hw/gpio/sifive_gpio.c +++ b/hw/gpio/sifive_gpio.c @@ -326,7 +326,7 @@ static const VMStateDescription vmstate_sifive_gpio = { .name = TYPE_SIFIVE_GPIO, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(value, SIFIVEGPIOState), VMSTATE_UINT32(input_en, SIFIVEGPIOState), VMSTATE_UINT32(output_en, SIFIVEGPIOState), diff --git a/hw/gpio/zaurus.c b/hw/gpio/zaurus.c index 7cf52a5041..5884804c58 100644 --- a/hw/gpio/zaurus.c +++ b/hw/gpio/zaurus.c @@ -222,7 +222,7 @@ static const VMStateDescription vmstate_scoop_regs = { .version_id = 1, .minimum_version_id = 0, .post_load = scoop_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(status, ScoopInfo), VMSTATE_UINT16(power, ScoopInfo), VMSTATE_UINT32(gpio_level, ScoopInfo), From patchwork Fri Dec 29 21:23:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758842 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672392wrw; Fri, 29 Dec 2023 13:31:32 -0800 (PST) X-Google-Smtp-Source: AGHT+IH+63sayDA0GT6CAkcZXp8Ifqs/mwB285oLKRy3U/9THdcqcU3bDD0x8qc66OulOdKpIXv+ X-Received: by 2002:a05:6808:178b:b0:3b8:b706:3a47 with SMTP id bg11-20020a056808178b00b003b8b7063a47mr17446086oib.74.1703885492269; Fri, 29 Dec 2023 13:31:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885492; cv=none; d=google.com; s=arc-20160816; b=aXdyQAleXQye3hVWcxNFFy2MGCjPTdeX9YjgKd5OpGXEybXqfCh7JWlqRdyiOMfkqB uAD9t5QNo8mSXBq+JQ96l94TGKFKDcaSW84QlaVHO2NvZDgZh78+ME0vxpehsar6XyZ6 DS8DAiZWuCebD27+7r1MR83KTU6Q9+QXUepevF+W51qyND0eNOEITFxJrRYCZglQzC0Z Wc5kzWIr8TTTuDdFzROmXvWjBLoDJa096Mjh0njQw077xwkrq76muY3lTgXoAapizqQq pMEH3CaVlNg9abRZzG5qTMe2+oU7mxdV9faZUshf+FZHwRIA26aJ+5u/cl8CAR7KNDAH c1JA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=izfNzYDpLE+8KKtYZNbE9Cly+hRboP1BshDphjqE/aM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=CEDENPGBABkulgi09DS4F8jR2MEB9/PuSTLLJuAa+3ogCPTyprUaET2VfhZXh+Zooj r78BncfaJvWKnlh3UsNnb+0iIRFHaPZlfeCSL5v4ZALNDKNr+DGb8Lf2NbPXanZGuPqJ gRA/t3cXTB1jGAKt/Kmv1rZOEXAbAUL4DkAWXAgUffGtG3MmgpKaRsS6ax3y91Gotyo3 eJ7U+48jlN2aeGfvJ2Te9yBBFW0tOCHeq4EI/v4KO2p4/hhOSar7P+F2fCqYUSglGNvg 29kVk1Ma8V0vJacoW1+D8i3JAV0uX6lS9M5wwxySpLjVJdygOc/m7lezEFpIBCW1twNw 2r5A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NZD2SeQx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id p20-20020a05622a049400b00425f0a73de7si20027693qtx.472.2023.12.29.13.31.32 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:32 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NZD2SeQx; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLt-0000C9-JD; Fri, 29 Dec 2023 16:25:09 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLq-0008Lk-NK for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:06 -0500 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLn-0007EY-77 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:06 -0500 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6d9b1589a75so1481096b3a.3 for ; Fri, 29 Dec 2023 13:25:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885101; x=1704489901; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=izfNzYDpLE+8KKtYZNbE9Cly+hRboP1BshDphjqE/aM=; b=NZD2SeQxdKaexV3cLhFd/RLJLv7OS1HCDM+FHtzb5vX1EEBi8NyIPehTwxO3cJBxZ/ QNQR4GEZx5uViE34A7lKYOtaNPCdwXodorSfvyu2LFxobnTo4SkOtsmu1X3UKoGSYzXI QOQaXbNtErGVv6Ls3pMINvbclmxTXOo5uKFmpd3PvAFa2gnk/vWzi0RqUwyiZOY8pCXE Pp8n01zYBSA6pvDefJPFikbi9fGLpJNn8VB7MF+zNlAK/7VnfpWef7TKlh3YOaiEcZnY cJ/RTGN8sKsLxZ9bvz9J+Y2g3QuvTrk/65d2QdYxT1dWRB5qllpP0iHwwSYPhkokFfNs vc3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885101; x=1704489901; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=izfNzYDpLE+8KKtYZNbE9Cly+hRboP1BshDphjqE/aM=; b=nreXE9uiIVp/qfweEhOKtBgrG4qZYPtnCI3GaXMEaeMUpo6W5fSRPKHvSsmUriGFYS GBDVC0KTyEYj4xoM9s0Gjoa7EpoBhaKnujyYlHDZ+RtSqVmrO+s6Py6xnFcTN/fPmzBl VEXlNJ5s+g4iSUaT24bOZM0H0NnQnkHrAuup7zOjG7LuKoaMnsrnKUBFr4tvPTSR5pMT rzBBk3p/U/oaPHqb+Sl9tyCITkLayHl3tNJDRUkHBbPPzC2vM5A+N4OiJEDu8iJ/cg+8 x/3xhR9+bAstR676CV/9A5S7W6SdDfzPGz5XkBwk6D0PrukmXdNBwLG/Kkbq62TZ3lYI yjrw== X-Gm-Message-State: AOJu0Yzpke1DVbOvpSlk5z2oYyS3aS2kIUi7BAwPvg/wXS/Pzy64o8qb 2EJUNXfD8s/uQ4Fj4+alRkEQe6RJgBuQCS3P8mtZ7B//bO93wA== X-Received: by 2002:aa7:93b9:0:b0:6d9:97f5:392e with SMTP id x25-20020aa793b9000000b006d997f5392emr4819512pff.44.1703885101513; Fri, 29 Dec 2023 13:25:01 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.24.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:01 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 29/71] hw/hyperv: Constify VMState Date: Sat, 30 Dec 2023 08:23:04 +1100 Message-Id: <20231229212346.147149-30-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x432.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-30-richard.henderson@linaro.org> --- hw/hyperv/vmbus.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/hw/hyperv/vmbus.c b/hw/hyperv/vmbus.c index c64eaa5a46..c86d1895ba 100644 --- a/hw/hyperv/vmbus.c +++ b/hw/hyperv/vmbus.c @@ -526,7 +526,7 @@ static const VMStateDescription vmstate_gpadl = { .name = "vmbus/gpadl", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, VMBusGpadl), VMSTATE_UINT32(child_relid, VMBusGpadl), VMSTATE_UINT32(num_gfns, VMBusGpadl), @@ -1489,7 +1489,7 @@ static const VMStateDescription vmstate_channel = { .version_id = 0, .minimum_version_id = 0, .post_load = channel_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, VMBusChannel), VMSTATE_UINT16(subchan_idx, VMBusChannel), VMSTATE_UINT32(open_id, VMBusChannel), @@ -2380,7 +2380,7 @@ const VMStateDescription vmstate_vmbus_dev = { .name = TYPE_VMBUS_DEVICE, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(instanceid.data, VMBusDevice, 16), VMSTATE_UINT16(num_channels, VMBusDevice), VMSTATE_STRUCT_VARRAY_POINTER_UINT16(channels, VMBusDevice, @@ -2549,7 +2549,7 @@ static const VMStateDescription vmstate_post_message_input = { .name = "vmbus/hyperv_post_message_input", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* * skip connection_id and message_type as they are validated before * queueing and ignored on dequeueing @@ -2572,7 +2572,7 @@ static const VMStateDescription vmstate_rx_queue = { .version_id = 0, .minimum_version_id = 0, .needed = vmbus_rx_queue_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(rx_queue_head, VMBus), VMSTATE_UINT8(rx_queue_size, VMBus), VMSTATE_STRUCT_ARRAY(rx_queue, VMBus, @@ -2589,7 +2589,7 @@ static const VMStateDescription vmstate_vmbus = { .minimum_version_id = 0, .pre_load = vmbus_pre_load, .post_load = vmbus_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(state, VMBus), VMSTATE_UINT32(version, VMBus), VMSTATE_UINT32(target_vp, VMBus), @@ -2598,7 +2598,7 @@ static const VMStateDescription vmstate_vmbus = { vmstate_gpadl, VMBusGpadl, link), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_rx_queue, NULL } @@ -2643,7 +2643,7 @@ static const VMStateDescription vmstate_vmbus_bridge = { .name = TYPE_VMBUS_BRIDGE, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER(bus, VMBusBridge, vmstate_vmbus, VMBus), VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758825 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671864wrw; Fri, 29 Dec 2023 13:29:45 -0800 (PST) X-Google-Smtp-Source: AGHT+IHuo+l0bsHcxv/0xmiIvTRd3+UwsnATP2P9mJZWO/zcuJxbYX46QlSJkdbS/8S+db6pql4Y X-Received: by 2002:a05:620a:1369:b0:77e:fbba:6455 with SMTP id d9-20020a05620a136900b0077efbba6455mr17772431qkl.52.1703885385536; Fri, 29 Dec 2023 13:29:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885385; cv=none; d=google.com; s=arc-20160816; b=fd6znyh3eFWgQYD6Hp0Sd9YkWhMjQeqVb684SDP26TBEZZusQ/necQ6iIMr8bu4BqH IeLnQ0m3qtCm4CSlN9EOl4wGKzYCAF31NUzMHCWe0xJW7vYpMH29Op4DLBgWvDirfVf+ 2BHtb5fkz41OKyZmsrI9nAuudePqLa9EsKtW/IX/eqI8uXXEArhz/lT7mlvxezhbpD/1 HM3x5yBJ9ajIPwC9iwH8+6HPdee3KkkoSIASN/nGisa7YQDe3goHmI7LIp2clXIk8fkw jiG34rE3OmiMSWWvJrVtEyMDVS/dc5Jf7TcHqXo0obzTfbjZjmfk2EsIjvxZqSpDorEL Vn2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=+Wwej5FafOJ8fI218fEuynLOdRo+m4FmJrXnm4IxM2M=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=VWmB/WNuojxJdqFhtw+JlqEBiQpq/J89ySeuTIfBG4Kkeex5OSlhaWrzZWMZqm/bO1 GHQA72kFUohhuI/PHoRpe3ImP1j4AkIWaEiKjiTL350mBFTcmWgnzHLAfc95N0pvjJsD 7CD7M+kDaNu7X1gGGrX40pn6ObCSRKcm3Y/3R33jW1PqQZWtHzp+wpWjmNCGIvVgR6Kj mNyYlVDPkxIv6WyeAv9S1Q/4NuqsZJAxCFb7fBfmTRhrESqaMrmSnK+mHPSvolgbZGvD iUqVqUQ5c7XVrqSBOgV6FnNu2x19irliIKw+Okgj/H6g7nMinumh5YBaGTnNREnirtOs UyYg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d89d7qRA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id cx13-20020a05620a51cd00b007815e45a5d0si6615390qkb.331.2023.12.29.13.29.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:45 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d89d7qRA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLu-0000IC-EB; Fri, 29 Dec 2023 16:25:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLs-0008V6-GJ for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:08 -0500 Received: from mail-pj1-x102e.google.com ([2607:f8b0:4864:20::102e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLp-0007Ml-9k for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:08 -0500 Received: by mail-pj1-x102e.google.com with SMTP id 98e67ed59e1d1-28c0df4b42eso3708291a91.1 for ; Fri, 29 Dec 2023 13:25:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885103; x=1704489903; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=+Wwej5FafOJ8fI218fEuynLOdRo+m4FmJrXnm4IxM2M=; b=d89d7qRA8DaMWZb3MuIyub3/xKm4BSlwTCcAjdHQ6slnrSwjfxq3Tod3rgi1r30MI6 3C+jQTO6mJYVuozmPFfsmQd0K8sBkC16AIw2lJZt06gX0gurpLXxbJX33a35PzHyvADs VpM8ibmnzoBtl9AIIeq1Bg/Mu3FLPju99bWGXuH6dlixAbjs4UOw1zUxawDbNmNEZAzc XLZINZSTQD5PF7Xy7TFdiAV6GBwvFwg+2ptpZR2XhL2gEc+xwFBGi/3ivlnEKhFaPKPF WRK1vjx1zU4vXBVqrC/QcG1/wOz3yEA0y3LHtyg/55aeSBQ3bOVfpuJx0qwp2IF97tiU WB8w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885103; x=1704489903; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=+Wwej5FafOJ8fI218fEuynLOdRo+m4FmJrXnm4IxM2M=; b=NK5XKu07zN8JA6jsv+kFJ8Tpf7LWQhgzEdMnkgshPhtKG9Fpm40PTMQjXFqvnMmTse vKIX1aNh7xCRc4f4oLSbEwz1yqVBqYoj2zBxn9ko8p4/zOky2Q2wTT3ypm0X8h6qK+IR t5We5RkFzC+QvA2NsjbsuYSG3mPUSRlgJb6uTij1xcp2W/LOGNiIgXzOy/zIx8iugYpZ OeeRnGpkBONa7kvkKQLL3Ela1okuaWqa3YSsn9YPKSIfpJpKG8h5jsia6/WirAwOR5iX nZvtldh+bTXv6jQ3ycidNtqhd7lriWdykOFtZ9CH/L0MXRWxwQktoX5nrFCgxtDv+NT9 8rJg== X-Gm-Message-State: AOJu0YwFatsOVh5IwPF1wTZuzt6Ty1EbZdLmPaz/1F9mkpF46w4FvCQD P25JFMyioLQy+CCfHvrEw6FvR3ivj59vV3zDAqkbk5cYVx2lig== X-Received: by 2002:a17:90a:5286:b0:28c:4f11:1894 with SMTP id w6-20020a17090a528600b0028c4f111894mr10002559pjh.39.1703885103670; Fri, 29 Dec 2023 13:25:03 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:03 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 30/71] hw/i2c: Constify VMState Date: Sat, 30 Dec 2023 08:23:05 +1100 Message-Id: <20231229212346.147149-31-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::102e; envelope-from=richard.henderson@linaro.org; helo=mail-pj1-x102e.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-31-richard.henderson@linaro.org> --- hw/i2c/allwinner-i2c.c | 2 +- hw/i2c/aspeed_i2c.c | 4 ++-- hw/i2c/core.c | 4 ++-- hw/i2c/exynos4210_i2c.c | 2 +- hw/i2c/imx_i2c.c | 2 +- hw/i2c/microbit_i2c.c | 2 +- hw/i2c/mpc_i2c.c | 2 +- hw/i2c/npcm7xx_smbus.c | 2 +- hw/i2c/pm_smbus.c | 2 +- hw/i2c/pmbus_device.c | 2 +- hw/i2c/smbus_eeprom.c | 2 +- hw/i2c/smbus_ich9.c | 2 +- hw/i2c/smbus_slave.c | 2 +- 13 files changed, 15 insertions(+), 15 deletions(-) diff --git a/hw/i2c/allwinner-i2c.c b/hw/i2c/allwinner-i2c.c index 9e8efa1d63..8abcc39a5c 100644 --- a/hw/i2c/allwinner-i2c.c +++ b/hw/i2c/allwinner-i2c.c @@ -415,7 +415,7 @@ static const VMStateDescription allwinner_i2c_vmstate = { .name = TYPE_AW_I2C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(addr, AWI2CState), VMSTATE_UINT8(xaddr, AWI2CState), VMSTATE_UINT8(data, AWI2CState), diff --git a/hw/i2c/aspeed_i2c.c b/hw/i2c/aspeed_i2c.c index 1037c22b2f..b43afd250d 100644 --- a/hw/i2c/aspeed_i2c.c +++ b/hw/i2c/aspeed_i2c.c @@ -945,7 +945,7 @@ static const VMStateDescription aspeed_i2c_bus_vmstate = { .name = TYPE_ASPEED_I2C, .version_id = 5, .minimum_version_id = 5, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedI2CBus, ASPEED_I2C_NEW_NUM_REG), VMSTATE_END_OF_LIST() } @@ -955,7 +955,7 @@ static const VMStateDescription aspeed_i2c_vmstate = { .name = TYPE_ASPEED_I2C, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(intr_status, AspeedI2CState), VMSTATE_STRUCT_ARRAY(busses, AspeedI2CState, ASPEED_I2C_NR_BUSSES, 1, aspeed_i2c_bus_vmstate, diff --git a/hw/i2c/core.c b/hw/i2c/core.c index 879a1d45cb..4cf30b2c86 100644 --- a/hw/i2c/core.c +++ b/hw/i2c/core.c @@ -50,7 +50,7 @@ static const VMStateDescription vmstate_i2c_bus = { .version_id = 1, .minimum_version_id = 1, .pre_save = i2c_bus_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(saved_address, I2CBus), VMSTATE_END_OF_LIST() } @@ -359,7 +359,7 @@ const VMStateDescription vmstate_i2c_slave = { .version_id = 1, .minimum_version_id = 1, .post_load = i2c_slave_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(address, I2CSlave), VMSTATE_END_OF_LIST() } diff --git a/hw/i2c/exynos4210_i2c.c b/hw/i2c/exynos4210_i2c.c index b65a7d0222..9445424d5f 100644 --- a/hw/i2c/exynos4210_i2c.c +++ b/hw/i2c/exynos4210_i2c.c @@ -273,7 +273,7 @@ static const VMStateDescription exynos4210_i2c_vmstate = { .name = "exynos4210.i2c", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(i2ccon, Exynos4210I2CState), VMSTATE_UINT8(i2cstat, Exynos4210I2CState), VMSTATE_UINT8(i2cds, Exynos4210I2CState), diff --git a/hw/i2c/imx_i2c.c b/hw/i2c/imx_i2c.c index 9792583fea..a25676f025 100644 --- a/hw/i2c/imx_i2c.c +++ b/hw/i2c/imx_i2c.c @@ -285,7 +285,7 @@ static const VMStateDescription imx_i2c_vmstate = { .name = TYPE_IMX_I2C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(address, IMXI2CState), VMSTATE_UINT16(iadr, IMXI2CState), VMSTATE_UINT16(ifdr, IMXI2CState), diff --git a/hw/i2c/microbit_i2c.c b/hw/i2c/microbit_i2c.c index e92f9f84ea..24d36d15b0 100644 --- a/hw/i2c/microbit_i2c.c +++ b/hw/i2c/microbit_i2c.c @@ -80,7 +80,7 @@ static const VMStateDescription microbit_i2c_vmstate = { .name = TYPE_MICROBIT_I2C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, MicrobitI2CState, MICROBIT_I2C_NREGS), VMSTATE_UINT32(read_idx, MicrobitI2CState), VMSTATE_END_OF_LIST() diff --git a/hw/i2c/mpc_i2c.c b/hw/i2c/mpc_i2c.c index 219c548402..cb051a520f 100644 --- a/hw/i2c/mpc_i2c.c +++ b/hw/i2c/mpc_i2c.c @@ -312,7 +312,7 @@ static const VMStateDescription mpc_i2c_vmstate = { .name = TYPE_MPC_I2C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(address, MPCI2CState), VMSTATE_UINT8(adr, MPCI2CState), VMSTATE_UINT8(fdr, MPCI2CState), diff --git a/hw/i2c/npcm7xx_smbus.c b/hw/i2c/npcm7xx_smbus.c index e7e0ba66fe..0ea3083bb6 100644 --- a/hw/i2c/npcm7xx_smbus.c +++ b/hw/i2c/npcm7xx_smbus.c @@ -1046,7 +1046,7 @@ static const VMStateDescription vmstate_npcm7xx_smbus = { .name = "npcm7xx-smbus", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(sda, NPCM7xxSMBusState), VMSTATE_UINT8(st, NPCM7xxSMBusState), VMSTATE_UINT8(cst, NPCM7xxSMBusState), diff --git a/hw/i2c/pm_smbus.c b/hw/i2c/pm_smbus.c index 78e7c229a8..3eed8110b9 100644 --- a/hw/i2c/pm_smbus.c +++ b/hw/i2c/pm_smbus.c @@ -455,7 +455,7 @@ const VMStateDescription pmsmb_vmstate = { .name = "pmsmb", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(smb_stat, PMSMBus), VMSTATE_UINT8(smb_ctl, PMSMBus), VMSTATE_UINT8(smb_cmd, PMSMBus), diff --git a/hw/i2c/pmbus_device.c b/hw/i2c/pmbus_device.c index 1b978e588f..ba1d2fd716 100644 --- a/hw/i2c/pmbus_device.c +++ b/hw/i2c/pmbus_device.c @@ -1886,7 +1886,7 @@ const VMStateDescription vmstate_pmbus_device = { .name = TYPE_PMBUS_DEVICE, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SMBUS_DEVICE(smb, PMBusDevice), VMSTATE_UINT8(num_pages, PMBusDevice), VMSTATE_UINT8(code, PMBusDevice), diff --git a/hw/i2c/smbus_eeprom.c b/hw/i2c/smbus_eeprom.c index 12c5741f38..c42236bb13 100644 --- a/hw/i2c/smbus_eeprom.c +++ b/hw/i2c/smbus_eeprom.c @@ -100,7 +100,7 @@ static const VMStateDescription vmstate_smbus_eeprom = { .version_id = 1, .minimum_version_id = 1, .needed = smbus_eeprom_vmstate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SMBUS_DEVICE(smbusdev, SMBusEEPROMDevice), VMSTATE_UINT8_ARRAY(data, SMBusEEPROMDevice, SMBUS_EEPROM_SIZE), VMSTATE_UINT8(offset, SMBusEEPROMDevice), diff --git a/hw/i2c/smbus_ich9.c b/hw/i2c/smbus_ich9.c index 18d40e93c1..208f263ac5 100644 --- a/hw/i2c/smbus_ich9.c +++ b/hw/i2c/smbus_ich9.c @@ -50,7 +50,7 @@ static const VMStateDescription vmstate_ich9_smbus = { .name = "ich9_smb", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, ICH9SMBState), VMSTATE_BOOL_TEST(irq_enabled, ICH9SMBState, ich9_vmstate_need_smbus), VMSTATE_STRUCT_TEST(smb, ICH9SMBState, ich9_vmstate_need_smbus, 1, diff --git a/hw/i2c/smbus_slave.c b/hw/i2c/smbus_slave.c index 2ef2c7c5f6..1300c9ec72 100644 --- a/hw/i2c/smbus_slave.c +++ b/hw/i2c/smbus_slave.c @@ -215,7 +215,7 @@ const VMStateDescription vmstate_smbus_device = { .name = TYPE_SMBUS_DEVICE, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(i2c, SMBusDevice), VMSTATE_INT32(mode, SMBusDevice), VMSTATE_INT32(data_len, SMBusDevice), From patchwork Fri Dec 29 21:23:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758816 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671569wrw; Fri, 29 Dec 2023 13:28:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IGra+I/syWFzYQY7JxMKfVUVjFYQ65UMj4i+vfy+hel4GVKM1323+AsUB/y6woHU/JX9YLz X-Received: by 2002:ad4:5ccd:0:b0:67f:6952:d0ef with SMTP id iu13-20020ad45ccd000000b0067f6952d0efmr21260020qvb.6.1703885303381; Fri, 29 Dec 2023 13:28:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885303; cv=none; d=google.com; s=arc-20160816; b=Z/kDHwf/UuNq6lHXKluNGRH42cLGisaXHpMx2Gs6RbWW0SuPWaUSiZqmCy2n2i+gce Aksnstzs6n4AxdsGvU6tufi+lUW3gCVqrA2qvkj6Xc3WJ5ZoH8OwUy64bZiCdzkGeKGW c5ihV9s2MLC4AQ6U7UPYKgudT79ahKbtJTu8/D7oyvCGSElZb4euITI3waC7rEx+VPsJ snzBaCnfNcLJ/l+6ycEjq4hV4FFEK5u0v8tYIuA+6P+vdqe1/rh66CRvtQIovbED/szz pVSd1J2CV+4U0SBibDrFqTQNSHkFYJdK95b9kIMojRjpJbYiq82Zxt7J3ivQeVw/UP5M VyLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=wia1mwDSmhvHBc7XK8M+uSpbG5o3R0nD6ejibX0WzAE=; fh=GstYAhRjUP+ivyXSmazQSCet1zGHWK0juBUWG85sowQ=; b=D9t+/mdDWD3zWVjz4ffBzcIeSFNZp400HYY8I3uOr5JnQLhxm1pvIY5bJ3JVBbfAca EYU/Rvlz+BwK/uAg4uBeBWBjdjtZc5kzjfpYbqtQmT+jawqR9m+oLNLU6+HhzgjrK6D1 GrouRKEaXCfERaas3MCsfDNPkZc1xX+3QlUpP2I+tkzmRwPjsWhu0eBFGzK09C5bH8pP 9EMtFTtch8foImKST/aFfnd1+M9259N4OJNYQTS4tjHeeuWicZCji2wOyE6Djk0lR22X 11ZyF7nCXW63yrHqifBTHs8HLYI/FBS0/NmRJB6G3/FWiK/8d/t7JiXKjACfCwfghtzX 3zQg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZZ62eRgU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t3-20020a0ce2c3000000b0067f0aa02082si19889805qvl.268.2023.12.29.13.28.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:23 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZZ62eRgU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLw-0000U2-0g; Fri, 29 Dec 2023 16:25:12 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLt-0000Bw-H9 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:09 -0500 Received: from mail-il1-x133.google.com ([2607:f8b0:4864:20::133]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLr-0007Vy-9J for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:09 -0500 Received: by mail-il1-x133.google.com with SMTP id e9e14a558f8ab-35fb96f3404so39393165ab.2 for ; Fri, 29 Dec 2023 13:25:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885106; x=1704489906; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=wia1mwDSmhvHBc7XK8M+uSpbG5o3R0nD6ejibX0WzAE=; b=ZZ62eRgUm0vTsK1pJZF8eaS4j+I4HCQPSCumTb6kBcuNfAAX3bZr928TCHi5IMZNfN RCCqdNv4YL36a6fz2bcKmVEh1pZWdNtHTich7L965arfx7ZGP39l05sPucN1iXpJYfU0 YwDyI5eXLTGTDjs/GmoXCjpuVpfgA9NUGXHOZGzLE/zDyua1KLP5PboeErCSfAQr6hRY lCBIFCs8+HLpTdguWPWFaOGspvjxPzAlbn4iGvCVgBzQm/ec7VyeoGj87MB/Zc6Yx4hD z+6uMf8lThenalJS2KEhXyztMo6AsX9eSyYr+QrpwQ0PkSjOGyg7ThRFUOf6UnHtSK86 qNfg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885106; x=1704489906; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wia1mwDSmhvHBc7XK8M+uSpbG5o3R0nD6ejibX0WzAE=; b=Ol4KgqG3bAEAUFHso9RS86l18uXTd3TMms23e1zwku0ovGdLW2EN5xphLW/tEsftsx Ux6NkZEm1ndFGtJJG85KI2voce2EI3lFweD4FZy4Z6soTcr7fla2/jI8Egc/3iu7CVdp fCmtnyU4LK8Rw8VNXOCJzXqmBELzy2BiTdKj5x6N08k4lC3lgAOG9n3/yhhF1vuJEKgq p/dc2Xx7h/WraTB7Y38M2ENhIH1hOGnaIKJVkzd+FOK5nrU/Z7DQCEzAVpg3zxY+/n59 FkGsbZQmm1SF/PNFMQETbzHcHf0Jv+T4cI2iVUr3c9RAcNow8WPHKP6AqlAkTwySQ3wV ETtw== X-Gm-Message-State: AOJu0Yylm6uDuBiyUHGnM91BnWmg+96tGQZjGXTCVXCvVahRBR9boENk doLy/a9oDozK34MHz0cb6JJ4nQMt+4K073xYfneG3YtObMK8Yg== X-Received: by 2002:a05:6e02:180e:b0:35f:e1c5:b13c with SMTP id a14-20020a056e02180e00b0035fe1c5b13cmr22522749ilv.45.1703885106028; Fri, 29 Dec 2023 13:25:06 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:05 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Zhao Liu Subject: [PULL 31/71] hw/i386: Constify VMState Date: Sat, 30 Dec 2023 08:23:06 +1100 Message-Id: <20231229212346.147149-32-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::133; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x133.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Reviewed-by: Zhao Liu Message-Id: <20231221031652.119827-32-richard.henderson@linaro.org> --- hw/i386/acpi-build.c | 2 +- hw/i386/intel_iommu.c | 2 +- hw/i386/kvm/clock.c | 6 +++--- hw/i386/kvm/xen_evtchn.c | 4 ++-- hw/i386/kvm/xen_gnttab.c | 2 +- hw/i386/kvm/xen_overlay.c | 2 +- hw/i386/kvm/xen_xenstore.c | 2 +- hw/i386/kvmvapic.c | 6 +++--- hw/i386/port92.c | 2 +- hw/i386/vmmouse.c | 2 +- hw/i386/xen/xen_platform.c | 2 +- hw/i386/xen/xen_pvdevice.c | 2 +- 12 files changed, 17 insertions(+), 17 deletions(-) diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index 80db183b78..edc979379c 100644 --- a/hw/i386/acpi-build.c +++ b/hw/i386/acpi-build.c @@ -2770,7 +2770,7 @@ static const VMStateDescription vmstate_acpi_build = { .name = "acpi_build", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(patched, AcpiBuildState), VMSTATE_END_OF_LIST() }, diff --git a/hw/i386/intel_iommu.c b/hw/i386/intel_iommu.c index 5085a6fee3..ed5677c0ae 100644 --- a/hw/i386/intel_iommu.c +++ b/hw/i386/intel_iommu.c @@ -3289,7 +3289,7 @@ static const VMStateDescription vtd_vmstate = { .minimum_version_id = 1, .priority = MIG_PRI_IOMMU, .post_load = vtd_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(root, IntelIOMMUState), VMSTATE_UINT64(intr_root, IntelIOMMUState), VMSTATE_UINT64(iq, IntelIOMMUState), diff --git a/hw/i386/kvm/clock.c b/hw/i386/kvm/clock.c index e756b0aa43..40aa9a32c3 100644 --- a/hw/i386/kvm/clock.c +++ b/hw/i386/kvm/clock.c @@ -245,7 +245,7 @@ static const VMStateDescription kvmclock_reliable_get_clock = { .version_id = 1, .minimum_version_id = 1, .needed = kvmclock_clock_is_reliable_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(clock_is_reliable, KVMClockState), VMSTATE_END_OF_LIST() } @@ -295,11 +295,11 @@ static const VMStateDescription kvmclock_vmsd = { .minimum_version_id = 1, .pre_load = kvmclock_pre_load, .pre_save = kvmclock_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(clock, KVMClockState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &kvmclock_reliable_get_clock, NULL } diff --git a/hw/i386/kvm/xen_evtchn.c b/hw/i386/kvm/xen_evtchn.c index 02b8cbf8df..9a5f3caa24 100644 --- a/hw/i386/kvm/xen_evtchn.c +++ b/hw/i386/kvm/xen_evtchn.c @@ -240,7 +240,7 @@ static const VMStateDescription xen_evtchn_port_vmstate = { .name = "xen_evtchn_port", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vcpu, XenEvtchnPort), VMSTATE_UINT16(type, XenEvtchnPort), VMSTATE_UINT16(u.val, XenEvtchnPort), @@ -255,7 +255,7 @@ static const VMStateDescription xen_evtchn_vmstate = { .needed = xen_evtchn_is_needed, .pre_load = xen_evtchn_pre_load, .post_load = xen_evtchn_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(callback_param, XenEvtchnState), VMSTATE_UINT32(nr_ports, XenEvtchnState), VMSTATE_STRUCT_VARRAY_UINT32(port_table, XenEvtchnState, nr_ports, 1, diff --git a/hw/i386/kvm/xen_gnttab.c b/hw/i386/kvm/xen_gnttab.c index 0a24f53f20..a0cc30f619 100644 --- a/hw/i386/kvm/xen_gnttab.c +++ b/hw/i386/kvm/xen_gnttab.c @@ -127,7 +127,7 @@ static const VMStateDescription xen_gnttab_vmstate = { .minimum_version_id = 1, .needed = xen_gnttab_is_needed, .post_load = xen_gnttab_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(nr_frames, XenGnttabState), VMSTATE_VARRAY_UINT32(gnt_frame_gpas, XenGnttabState, nr_frames, 0, vmstate_info_uint64, uint64_t), diff --git a/hw/i386/kvm/xen_overlay.c b/hw/i386/kvm/xen_overlay.c index 39fda1b72c..526f7a6077 100644 --- a/hw/i386/kvm/xen_overlay.c +++ b/hw/i386/kvm/xen_overlay.c @@ -139,7 +139,7 @@ static const VMStateDescription xen_overlay_vmstate = { .needed = xen_overlay_is_needed, .pre_save = xen_overlay_pre_save, .post_load = xen_overlay_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(shinfo_gpa, XenOverlayState), VMSTATE_BOOL(long_mode, XenOverlayState), VMSTATE_END_OF_LIST() diff --git a/hw/i386/kvm/xen_xenstore.c b/hw/i386/kvm/xen_xenstore.c index 6e651960b3..c3633f7829 100644 --- a/hw/i386/kvm/xen_xenstore.c +++ b/hw/i386/kvm/xen_xenstore.c @@ -243,7 +243,7 @@ static const VMStateDescription xen_xenstore_vmstate = { .needed = xen_xenstore_is_needed, .pre_save = xen_xenstore_pre_save, .post_load = xen_xenstore_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(req_data, XenXenstoreState, sizeof_field(XenXenstoreState, req_data)), VMSTATE_UINT8_ARRAY(rsp_data, XenXenstoreState, diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c index 43f8a8f679..f2b0aff479 100644 --- a/hw/i386/kvmvapic.c +++ b/hw/i386/kvmvapic.c @@ -802,7 +802,7 @@ static const VMStateDescription vmstate_handlers = { .name = "kvmvapic-handlers", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(set_tpr, VAPICHandlers), VMSTATE_UINT32(set_tpr_eax, VAPICHandlers), VMSTATE_UINT32_ARRAY(get_tpr, VAPICHandlers, 8), @@ -815,7 +815,7 @@ static const VMStateDescription vmstate_guest_rom = { .name = "kvmvapic-guest-rom", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UNUSED(8), /* signature */ VMSTATE_UINT32(vaddr, GuestROMState), VMSTATE_UINT32(fixup_start, GuestROMState), @@ -835,7 +835,7 @@ static const VMStateDescription vmstate_vapic = { .version_id = 1, .minimum_version_id = 1, .post_load = vapic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(rom_state, VAPICROMState, 0, vmstate_guest_rom, GuestROMState), VMSTATE_UINT32(state, VAPICROMState), diff --git a/hw/i386/port92.c b/hw/i386/port92.c index e1379a4f98..1070bfbf36 100644 --- a/hw/i386/port92.c +++ b/hw/i386/port92.c @@ -54,7 +54,7 @@ static const VMStateDescription vmstate_port92_isa = { .name = "port92", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(outport, Port92State), VMSTATE_END_OF_LIST() } diff --git a/hw/i386/vmmouse.c b/hw/i386/vmmouse.c index 91320afa2f..a8d014d09a 100644 --- a/hw/i386/vmmouse.c +++ b/hw/i386/vmmouse.c @@ -277,7 +277,7 @@ static const VMStateDescription vmstate_vmmouse = { .version_id = 0, .minimum_version_id = 0, .post_load = vmmouse_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(queue_size, VMMouseState, NULL), VMSTATE_UINT32_ARRAY(queue, VMMouseState, VMMOUSE_QUEUE_SIZE), VMSTATE_UINT16(nb_queue, VMMouseState), diff --git a/hw/i386/xen/xen_platform.c b/hw/i386/xen/xen_platform.c index ef7d3fc05f..708488af32 100644 --- a/hw/i386/xen/xen_platform.c +++ b/hw/i386/xen/xen_platform.c @@ -537,7 +537,7 @@ static const VMStateDescription vmstate_xen_platform = { .version_id = 4, .minimum_version_id = 4, .post_load = xen_platform_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIXenPlatformState), VMSTATE_UINT8(flags, PCIXenPlatformState), VMSTATE_END_OF_LIST() diff --git a/hw/i386/xen/xen_pvdevice.c b/hw/i386/xen/xen_pvdevice.c index e62e06622b..ed621531d8 100644 --- a/hw/i386/xen/xen_pvdevice.c +++ b/hw/i386/xen/xen_pvdevice.c @@ -77,7 +77,7 @@ static const VMStateDescription vmstate_xen_pvdevice = { .name = "xen-pvdevice", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, XenPVDevice), VMSTATE_END_OF_LIST() } From patchwork Fri Dec 29 21:23:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758815 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671568wrw; Fri, 29 Dec 2023 13:28:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IGpnodLa2BTG6R6b5S5xxSFitH/RIm8RaFwuwsCILtK1Nzg2PggV3TMJ+Y8bECJmk3EBEUM X-Received: by 2002:a05:622a:2287:b0:428:5d4:2414 with SMTP id ay7-20020a05622a228700b0042805d42414mr1653119qtb.81.1703885303491; Fri, 29 Dec 2023 13:28:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885303; cv=none; d=google.com; s=arc-20160816; b=E1c3BbSiAkqcPS+BTKHIHtGQY55zpHmiub8wYlOs5lY4yTJLg3LYI+5NHyZ1xGQG4s evToGr4T96URDnzSEkC6ZV9cw0SmwPk2XpWe4ZtfVx2X6dYzevPY5sLYmYREIao0NoXV /1t7yG0VEgqsiDiy5QyEo8+f+DWS1uEgQtJnDJsPCmDF1t/66rmEdfPj2XfgPW/UY4kY F9G2t/qGjtdc+uEDJ4iIFLL3vkAk622qlLfZQaOiQgp/tjjJlmrC+698Y2BlGHD62+Gp FLWRjieZiE3HeDv6CpamsUCKm/jvEgRA1KGDteE+ImVyVadptRlyj7YbXCBowO6YKDG3 378A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=fMrkYLAKhlidNhCsAe4IjSCxPohHb/FzPsi2dGbb00E=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=rxtXd3FRnb/hh20gfpWA6Zwzdno9QaL66IqqUmNwcGKpBSiAFrTyVyUDGRcUmfgxVh kBOQowie4KE6vsxSEyTS4y+0zbFFtx7GRraw/5Lr/0LuSbS04jGpXjnqgS5G63Wt/jlT 5HbhQfbWpKZHNDQLbBUDnembMH3ofWuK/hsbnzjNhv1qGLOxAHJtbXwb95WOOUDvob42 wp8HCPB9ExsiR6U0PgNvK6uWsedczkzFJJXgqTIkXmRcWLiNbeNzFEbzj9J7VK8f4GSM B1Cd4Z5tzQTawDUt3tZ82OfGN2/O/TY10S1rRMvpzbH3AlD2XH9q57xUJJtX4EUfgTSO H8ZA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wwoXPhUS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t1-20020ac85881000000b00427f05e9762si6084951qta.109.2023.12.29.13.28.23 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:23 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wwoXPhUS; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKLw-0000dA-Tn; Fri, 29 Dec 2023 16:25:12 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLv-0000U4-Mz for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:11 -0500 Received: from mail-oa1-x32.google.com ([2001:4860:4864:20::32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLt-0007dw-BM for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:11 -0500 Received: by mail-oa1-x32.google.com with SMTP id 586e51a60fabf-204520717b3so4271215fac.0 for ; Fri, 29 Dec 2023 13:25:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885108; x=1704489908; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=fMrkYLAKhlidNhCsAe4IjSCxPohHb/FzPsi2dGbb00E=; b=wwoXPhUSkKqkizyoIFBrO5tsUEupVSxSwTeRJ5EYjFH228tDdFSPdSFdYCLGl1lcbD lR79SeFGa7HjdHI2J0K5+MXVYtCse7S1NJ3deYqpRIR4V7w2tBBp3lhVzKwNak3W9HtH pYmtBVIerE7Xil+7bRLYKdk1bxwVNPD06eRjV2c255U8VxGdCR2KoLWC+01vs9toudAL uqTXr2fsw1AIESvDyuHey5xK9w20gvVDPrc2rJ/SQcDDrxE32lWm34iJucl+/XbRWLXe ruglT12r5vs7jS+MEa+aSr5fqXH/EaaV19DRX2b5eZjkRGwKx5YCzB0znCAri/YXlnK1 Tm+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885108; x=1704489908; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fMrkYLAKhlidNhCsAe4IjSCxPohHb/FzPsi2dGbb00E=; b=cXLR+Dsh1J3uqFcR70D3Qlmk78EhxxZokskWj24fFsqU8b1IWSq+3fcm+3A4OZ+Amq kVl9GfphRYczdluCjNL7oGy76uAm6vN5kPwvtfjp4sMK8D5RafB4fo6paycFiGvG70pT vzm1nwSAcKowl7tRq9qkeKi3gLSomTLFXLbMTB0Xyc4unK00+//kWlPfks0U0yag6Blm 2JsRe8Fm8TqwFtiUZgnd/hsuMGFF4SGB3tfipodb1j5vfNBAxKbrRG8w8gRSAluLmijN F/EvuSM9o/eDUZyiCtXd3IfGOEdXmfaOKZs18TC3YbYYkSTBHlGbINfMU/ez2Pfnv6Ni P8GA== X-Gm-Message-State: AOJu0YyQHScij5yROx+yXmvXu+NxYBGr5qGrpp5Sfm/T1zRIkfeuesCg rDobp7HWFTkaZqd0ID9UlwKsnMiYG9EtKkRUtxZoRvfWtrIyXw== X-Received: by 2002:a05:6870:3104:b0:204:76d:dbe1 with SMTP id v4-20020a056870310400b00204076ddbe1mr13617229oaa.61.1703885108110; Fri, 29 Dec 2023 13:25:08 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:07 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 32/71] hw/ide: Constify VMState Date: Sat, 30 Dec 2023 08:23:07 +1100 Message-Id: <20231229212346.147149-33-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::32; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x32.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-33-richard.henderson@linaro.org> --- hw/ide/ahci-allwinner.c | 2 +- hw/ide/ahci.c | 8 ++++---- hw/ide/core.c | 16 ++++++++-------- hw/ide/ich.c | 2 +- hw/ide/isa.c | 2 +- hw/ide/macio.c | 2 +- hw/ide/microdrive.c | 2 +- hw/ide/mmio.c | 2 +- hw/ide/pci.c | 10 +++++----- 9 files changed, 23 insertions(+), 23 deletions(-) diff --git a/hw/ide/ahci-allwinner.c b/hw/ide/ahci-allwinner.c index 227e747ba7..b173121006 100644 --- a/hw/ide/ahci-allwinner.c +++ b/hw/ide/ahci-allwinner.c @@ -97,7 +97,7 @@ static const VMStateDescription vmstate_allwinner_ahci = { .name = "allwinner-ahci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AllwinnerAHCIState, ALLWINNER_AHCI_MMIO_SIZE / 4), VMSTATE_END_OF_LIST() diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c index afdc44b8e0..0eb83a6d46 100644 --- a/hw/ide/ahci.c +++ b/hw/ide/ahci.c @@ -1685,7 +1685,7 @@ void ahci_reset(AHCIState *s) static const VMStateDescription vmstate_ncq_tfs = { .name = "ncq state", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(sector_count, NCQTransferState), VMSTATE_UINT64(lba, NCQTransferState), VMSTATE_UINT8(tag, NCQTransferState), @@ -1700,7 +1700,7 @@ static const VMStateDescription vmstate_ncq_tfs = { static const VMStateDescription vmstate_ahci_device = { .name = "ahci port", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_IDE_BUS(port, AHCIDevice), VMSTATE_IDE_DRIVE(port.ifs[0], AHCIDevice), VMSTATE_UINT32(port_state, AHCIDevice), @@ -1817,7 +1817,7 @@ const VMStateDescription vmstate_ahci = { .name = "ahci", .version_id = 1, .post_load = ahci_state_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_INT32(dev, AHCIState, ports, vmstate_ahci_device, AHCIDevice), VMSTATE_UINT32(control_regs.cap, AHCIState), @@ -1833,7 +1833,7 @@ const VMStateDescription vmstate_ahci = { static const VMStateDescription vmstate_sysbus_ahci = { .name = "sysbus-ahci", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_AHCI(ahci, SysbusAHCIState), VMSTATE_END_OF_LIST() }, diff --git a/hw/ide/core.c b/hw/ide/core.c index 8a0579bff4..9c4a812902 100644 --- a/hw/ide/core.c +++ b/hw/ide/core.c @@ -2918,7 +2918,7 @@ static const VMStateDescription vmstate_ide_atapi_gesn_state = { .version_id = 1, .minimum_version_id = 1, .needed = ide_atapi_gesn_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(events.new_media, IDEState), VMSTATE_BOOL(events.eject_request, IDEState), VMSTATE_END_OF_LIST() @@ -2930,7 +2930,7 @@ static const VMStateDescription vmstate_ide_tray_state = { .version_id = 1, .minimum_version_id = 1, .needed = ide_tray_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(tray_open, IDEState), VMSTATE_BOOL(tray_locked, IDEState), VMSTATE_END_OF_LIST() @@ -2944,7 +2944,7 @@ static const VMStateDescription vmstate_ide_drive_pio_state = { .pre_save = ide_drive_pio_pre_save, .post_load = ide_drive_pio_post_load, .needed = ide_drive_pio_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(req_nb_sectors, IDEState), VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1, vmstate_info_uint8, uint8_t), @@ -2962,7 +2962,7 @@ const VMStateDescription vmstate_ide_drive = { .version_id = 3, .minimum_version_id = 0, .post_load = ide_drive_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(mult_sectors, IDEState), VMSTATE_INT32(identify_set, IDEState), VMSTATE_BUFFER_TEST(identify_data, IDEState, is_identify_set), @@ -2985,7 +2985,7 @@ const VMStateDescription vmstate_ide_drive = { VMSTATE_UINT8_V(cdrom_changed, IDEState, 3), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_ide_drive_pio_state, &vmstate_ide_tray_state, &vmstate_ide_atapi_gesn_state, @@ -2998,7 +2998,7 @@ static const VMStateDescription vmstate_ide_error_status = { .version_id = 2, .minimum_version_id = 1, .needed = ide_error_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(error_status, IDEBus), VMSTATE_INT64_V(retry_sector_num, IDEBus, 2), VMSTATE_UINT32_V(retry_nsector, IDEBus, 2), @@ -3011,12 +3011,12 @@ const VMStateDescription vmstate_ide_bus = { .name = "ide_bus", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(cmd, IDEBus), VMSTATE_UINT8(unit, IDEBus), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_ide_error_status, NULL } diff --git a/hw/ide/ich.c b/hw/ide/ich.c index d61faab532..49f8eb8a7d 100644 --- a/hw/ide/ich.c +++ b/hw/ide/ich.c @@ -83,7 +83,7 @@ static const VMStateDescription vmstate_ich9_ahci = { .name = "ich9_ahci", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, AHCIPCIState), VMSTATE_AHCI(ahci, AHCIPCIState), VMSTATE_END_OF_LIST() diff --git a/hw/ide/isa.c b/hw/ide/isa.c index ea60c08116..cc865c83dc 100644 --- a/hw/ide/isa.c +++ b/hw/ide/isa.c @@ -58,7 +58,7 @@ static const VMStateDescription vmstate_ide_isa = { .name = "isa-ide", .version_id = 3, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_IDE_BUS(bus, ISAIDEState), VMSTATE_IDE_DRIVES(bus.ifs, ISAIDEState), VMSTATE_END_OF_LIST() diff --git a/hw/ide/macio.c b/hw/ide/macio.c index dca1cc9efc..0d2c6ba910 100644 --- a/hw/ide/macio.c +++ b/hw/ide/macio.c @@ -361,7 +361,7 @@ static const VMStateDescription vmstate_pmac = { .name = "ide", .version_id = 5, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_IDE_BUS(bus, MACIOIDEState), VMSTATE_IDE_DRIVES(bus.ifs, MACIOIDEState), VMSTATE_BOOL(dma_active, MACIOIDEState), diff --git a/hw/ide/microdrive.c b/hw/ide/microdrive.c index 981cfbd97f..a7f415f0fc 100644 --- a/hw/ide/microdrive.c +++ b/hw/ide/microdrive.c @@ -336,7 +336,7 @@ static const VMStateDescription vmstate_microdrive = { .name = "microdrive", .version_id = 3, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(opt, MicroDriveState), VMSTATE_UINT8(stat, MicroDriveState), VMSTATE_UINT8(pins, MicroDriveState), diff --git a/hw/ide/mmio.c b/hw/ide/mmio.c index 3aeacab3bb..e8f41c0610 100644 --- a/hw/ide/mmio.c +++ b/hw/ide/mmio.c @@ -110,7 +110,7 @@ static const VMStateDescription vmstate_ide_mmio = { .name = "mmio-ide", .version_id = 3, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_IDE_BUS(bus, MMIOIDEState), VMSTATE_IDE_DRIVES(bus.ifs, MMIOIDEState), VMSTATE_END_OF_LIST() diff --git a/hw/ide/pci.c b/hw/ide/pci.c index 810c6b6d98..ca85d8474c 100644 --- a/hw/ide/pci.c +++ b/hw/ide/pci.c @@ -501,7 +501,7 @@ static const VMStateDescription vmstate_bmdma_current = { .version_id = 1, .minimum_version_id = 1, .needed = ide_bmdma_current_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cur_addr, BMDMAState), VMSTATE_UINT32(cur_prd_last, BMDMAState), VMSTATE_UINT32(cur_prd_addr, BMDMAState), @@ -515,7 +515,7 @@ static const VMStateDescription vmstate_bmdma_status = { .version_id = 1, .minimum_version_id = 1, .needed = ide_bmdma_status_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(status, BMDMAState), VMSTATE_END_OF_LIST() } @@ -526,7 +526,7 @@ static const VMStateDescription vmstate_bmdma = { .version_id = 3, .minimum_version_id = 0, .pre_save = ide_bmdma_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(cmd, BMDMAState), VMSTATE_UINT8(migration_compat_status, BMDMAState), VMSTATE_UINT32(addr, BMDMAState), @@ -535,7 +535,7 @@ static const VMStateDescription vmstate_bmdma = { VMSTATE_UINT8(migration_retry_unit, BMDMAState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_bmdma_current, &vmstate_bmdma_status, NULL @@ -562,7 +562,7 @@ const VMStateDescription vmstate_ide_pci = { .version_id = 3, .minimum_version_id = 0, .post_load = ide_pci_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIIDEState), VMSTATE_STRUCT_ARRAY(bmdma, PCIIDEState, 2, 0, vmstate_bmdma, BMDMAState), From patchwork Fri Dec 29 21:23:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758805 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671239wrw; Fri, 29 Dec 2023 13:27:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IFY4KeHFf9l6Xw4YYPdXfPP6I5Uqfrv8OilBTmiOuFDFGPhfF5DF/bcjwyD2kv3gFVpgS5B X-Received: by 2002:a05:6214:2a85:b0:67f:4d05:bd5 with SMTP id jr5-20020a0562142a8500b0067f4d050bd5mr13607142qvb.58.1703885230440; Fri, 29 Dec 2023 13:27:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885230; cv=none; d=google.com; s=arc-20160816; b=nrm4iHXMn8NpKLYL5ihTKIqWVlnrRCCDB6du4gLkJ5cvR+CJtMQeFu4lioQWuyy47J BR+yOnZIRi0WfRd74lwCcQSjl95Y1JenWB3nDEy/j7bIRgtV0iboekmWO+epDaAUy9YU fI08lmZwRDD5gMR0nPsc/lT+MGM03mgpn0R3m3McMxjKi6M+njc0CTR6QPqaESwA4Och NIDkr+QHHdq/9LGqPpE4A4p8ez/b6dNFPYlygHxWgDnfNGCDUaifyostxrIMepgYFf3A 3ErRCfSHzP1lAvDHj0EjkQQ3dv0bKHeTw2IrTObHZZhQMFXmgjU8KX/+QY/MmQwU/dVQ NWUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=qgkuS+i2FIBjbyaVYxu+JMHtGHEswSdNhRbEwEalApI=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=rpqlDaI53UC+p6ctCEdnBob9mjEHKr3xzUqiJDBxcTSU/zQ+OSnTQEwc/3wiYKYKtd 3LCLJFPO0zcEMrqyO//Jf7yum5t5Za/9PiBOzKaB/jEw9uwqaQkThQ5vYeUiOJRU46iJ pxpkhxAaBWLBR9BZWHSCZywAJKlMlLtrEjqrrMhoPq28/nWY+eOQH3BVVZf926eudL6j r7Zcg+0wn5sB0O6xB2+bexi121lTBXixSPvuxgbfsgU86TtzDqCyoYXm4LkqII4ALUCS Z1Wbs7diUV6ZMrOCOFTyTVuXNGF7l89cywHS1nF5FZN9o4V4QkxD1Zen9CqFSRq7Rh9H 6wnA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RandzgvR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id n15-20020a0ce48f000000b0067ef248cd77si16857767qvl.420.2023.12.29.13.27.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:10 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RandzgvR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKM1-00015V-3x; Fri, 29 Dec 2023 16:25:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKLy-0000td-On for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:14 -0500 Received: from mail-pf1-x431.google.com ([2607:f8b0:4864:20::431]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLw-0007eO-9m for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:14 -0500 Received: by mail-pf1-x431.google.com with SMTP id d2e1a72fcca58-6d9b13fe9e9so3722769b3a.2 for ; Fri, 29 Dec 2023 13:25:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885110; x=1704489910; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=qgkuS+i2FIBjbyaVYxu+JMHtGHEswSdNhRbEwEalApI=; b=RandzgvRkvovy/27gKG+CMPiYr2zfj7kkryCXTsU7aOhL+mXnNhHA8VwlndiI7uM7X 1LQPiOl3bpc7DWoK903nhgFcejTrlQpuh5zD6lw9cU7VkryVy9ueqwWgYoVJsgK+H1L/ dRNpwaAhb4rcv53K/j/xMrOlXxZCZJ0UGaEQQJSY4dCDeakRQY7sgJiIZMRZHrxqEuSu jaZVyXuo8Ez4j1wSLUak4XSVV538roJWdmw/n7HES2Y8zenC2urrX0ldJyJMrcJ2cwCm U/p//t9Bf41642ZkIraf1JAKgQo0QoAeWxBQNZxO2H1SMmBpGvYUW/D6sMcprbvI81AT rABQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885110; x=1704489910; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qgkuS+i2FIBjbyaVYxu+JMHtGHEswSdNhRbEwEalApI=; b=scnv4zptnCJWeqS7D+2YfbBQCCSzyp8S4mey7+g6QSZCSen1ERcINtUadoUZ7mOiDs FPY5dGOMetbf7YI9ZlToEm+vpLeRRxaXJLyQjhS8cK2gkCS2xWj7QMXbjpgUr3kiFnD8 J9n3yiXrTQ1zYAewLDk2W9mukxnp1xIhREYCKPMTiGgvaC2IEpgAlW25tbtBlPW3FlBp 6UAaAWWnLSknmZF+5Z7eYDC7TiakkhAPDKlsXJ0ai5IzP4MGf/TJH0G+ifgl1XX7zLKH 9fxI4/HQ4L6+q2ZUclJcoatsxBX8M+4uK/F5RTXHks5g+/pp+rDlArHGWfjFhbhCKVhI yWkA== X-Gm-Message-State: AOJu0YxVfQp1Hc+v2QqYGCa8y1RRlqqJZqpboSRAy4K2c6MjJP+IR1U1 luwOUOBQIlldJT2YROGTR4umaLQGpYQbamoMnsjrARAd1s8ALQ== X-Received: by 2002:a05:6a20:3d06:b0:196:5283:39a7 with SMTP id y6-20020a056a203d0600b00196528339a7mr3523490pzi.75.1703885110239; Fri, 29 Dec 2023 13:25:10 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:09 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 33/71] hw/input: Constify VMState Date: Sat, 30 Dec 2023 08:23:08 +1100 Message-Id: <20231229212346.147149-34-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::431; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x431.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-34-richard.henderson@linaro.org> --- hw/input/adb-kbd.c | 2 +- hw/input/adb-mouse.c | 2 +- hw/input/adb.c | 4 ++-- hw/input/ads7846.c | 2 +- hw/input/hid.c | 6 +++--- hw/input/lasips2.c | 4 ++-- hw/input/lm832x.c | 2 +- hw/input/pckbd.c | 12 ++++++------ hw/input/pl050.c | 2 +- hw/input/ps2.c | 14 +++++++------- hw/input/pxa2xx_keypad.c | 2 +- hw/input/stellaris_gamepad.c | 2 +- hw/input/tsc2005.c | 2 +- hw/input/tsc210x.c | 2 +- hw/input/virtio-input.c | 2 +- 15 files changed, 30 insertions(+), 30 deletions(-) diff --git a/hw/input/adb-kbd.c b/hw/input/adb-kbd.c index e21edf9acd..758fa6d267 100644 --- a/hw/input/adb-kbd.c +++ b/hw/input/adb-kbd.c @@ -332,7 +332,7 @@ static const VMStateDescription vmstate_adb_kbd = { .name = "adb_kbd", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, KBDState, 0, vmstate_adb_device, ADBDevice), VMSTATE_BUFFER(data, KBDState), VMSTATE_INT32(rptr, KBDState), diff --git a/hw/input/adb-mouse.c b/hw/input/adb-mouse.c index e6b341f028..144a0ccce7 100644 --- a/hw/input/adb-mouse.c +++ b/hw/input/adb-mouse.c @@ -217,7 +217,7 @@ static const VMStateDescription vmstate_adb_mouse = { .name = "adb_mouse", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, MouseState, 0, vmstate_adb_device, ADBDevice), VMSTATE_INT32(buttons_state, MouseState), diff --git a/hw/input/adb.c b/hw/input/adb.c index 8aed0da2cd..0f3c73d6d0 100644 --- a/hw/input/adb.c +++ b/hw/input/adb.c @@ -221,7 +221,7 @@ static const VMStateDescription vmstate_adb_bus = { .name = "adb_bus", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(autopoll_timer, ADBBusState), VMSTATE_BOOL(autopoll_enabled, ADBBusState), VMSTATE_UINT8(autopoll_rate_ms, ADBBusState), @@ -279,7 +279,7 @@ const VMStateDescription vmstate_adb_device = { .name = "adb_device", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(devaddr, ADBDevice), VMSTATE_INT32(handler, ADBDevice), VMSTATE_END_OF_LIST() diff --git a/hw/input/ads7846.c b/hw/input/ads7846.c index 91116c6bdb..cde3892216 100644 --- a/hw/input/ads7846.c +++ b/hw/input/ads7846.c @@ -130,7 +130,7 @@ static const VMStateDescription vmstate_ads7846 = { .version_id = 1, .minimum_version_id = 1, .post_load = ads7856_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SSI_PERIPHERAL(ssidev, ADS7846State), VMSTATE_INT32_ARRAY(input, ADS7846State, 8), VMSTATE_INT32(noise, ADS7846State), diff --git a/hw/input/hid.c b/hw/input/hid.c index b8e85374ca..76bedc1844 100644 --- a/hw/input/hid.c +++ b/hw/input/hid.c @@ -581,7 +581,7 @@ static const VMStateDescription vmstate_hid_ptr_queue = { .name = "HIDPointerEventQueue", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(xdx, HIDPointerEvent), VMSTATE_INT32(ydy, HIDPointerEvent), VMSTATE_INT32(dz, HIDPointerEvent), @@ -595,7 +595,7 @@ const VMStateDescription vmstate_hid_ptr_device = { .version_id = 1, .minimum_version_id = 1, .post_load = hid_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(ptr.queue, HIDState, QUEUE_LENGTH, 0, vmstate_hid_ptr_queue, HIDPointerEvent), VMSTATE_UINT32(head, HIDState), @@ -611,7 +611,7 @@ const VMStateDescription vmstate_hid_keyboard_device = { .version_id = 1, .minimum_version_id = 1, .post_load = hid_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(kbd.keycodes, HIDState, QUEUE_LENGTH), VMSTATE_UINT32(head, HIDState), VMSTATE_UINT32(n, HIDState), diff --git a/hw/input/lasips2.c b/hw/input/lasips2.c index 6075121b72..d9f8c36778 100644 --- a/hw/input/lasips2.c +++ b/hw/input/lasips2.c @@ -39,7 +39,7 @@ static const VMStateDescription vmstate_lasips2_port = { .name = "lasips2-port", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(control, LASIPS2Port), VMSTATE_UINT8(buf, LASIPS2Port), VMSTATE_BOOL(loopback_rbne, LASIPS2Port), @@ -51,7 +51,7 @@ static const VMStateDescription vmstate_lasips2 = { .name = "lasips2", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(int_status, LASIPS2State), VMSTATE_STRUCT(kbd_port.parent_obj, LASIPS2State, 1, vmstate_lasips2_port, LASIPS2Port), diff --git a/hw/input/lm832x.c b/hw/input/lm832x.c index 19a646d9bb..59e5567afd 100644 --- a/hw/input/lm832x.c +++ b/hw/input/lm832x.c @@ -441,7 +441,7 @@ static const VMStateDescription vmstate_lm_kbd = { .version_id = 0, .minimum_version_id = 0, .post_load = lm_kbd_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(parent_obj, LM823KbdState), VMSTATE_UINT8(i2c_dir, LM823KbdState), VMSTATE_UINT8(i2c_cycle, LM823KbdState), diff --git a/hw/input/pckbd.c b/hw/input/pckbd.c index b92b63bedc..90a4d9eb40 100644 --- a/hw/input/pckbd.c +++ b/hw/input/pckbd.c @@ -510,7 +510,7 @@ static const VMStateDescription vmstate_kbd_outport = { .minimum_version_id = 1, .post_load = kbd_outport_post_load, .needed = kbd_outport_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(outport, KBDState), VMSTATE_END_OF_LIST() } @@ -552,7 +552,7 @@ static const VMStateDescription vmstate_kbd_extended_state = { .post_load = kbd_extended_state_post_load, .pre_save = kbd_extended_state_pre_save, .needed = kbd_extended_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(migration_flags, KBDState), VMSTATE_UINT32(obsrc, KBDState), VMSTATE_UINT8(obdata, KBDState), @@ -619,14 +619,14 @@ static const VMStateDescription vmstate_kbd = { .pre_load = kbd_pre_load, .post_load = kbd_post_load, .pre_save = kbd_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(write_cmd, KBDState), VMSTATE_UINT8(status, KBDState), VMSTATE_UINT8(mode, KBDState), VMSTATE_UINT8(pending_tmp, KBDState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_kbd_outport, &vmstate_kbd_extended_state, NULL @@ -745,7 +745,7 @@ static const VMStateDescription vmstate_kbd_mmio = { .name = "pckbd-mmio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(kbd, MMIOKBDState, 0, vmstate_kbd, KBDState), VMSTATE_END_OF_LIST() } @@ -786,7 +786,7 @@ static const VMStateDescription vmstate_kbd_isa = { .name = "pckbd", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(kbd, ISAKBDState, 0, vmstate_kbd, KBDState), VMSTATE_END_OF_LIST() } diff --git a/hw/input/pl050.c b/hw/input/pl050.c index ec5e19285e..6519e260ed 100644 --- a/hw/input/pl050.c +++ b/hw/input/pl050.c @@ -30,7 +30,7 @@ static const VMStateDescription vmstate_pl050 = { .name = "pl050", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cr, PL050State), VMSTATE_UINT32(clk, PL050State), VMSTATE_UINT32(last, PL050State), diff --git a/hw/input/ps2.c b/hw/input/ps2.c index c8fd23cf36..00b695a0b9 100644 --- a/hw/input/ps2.c +++ b/hw/input/ps2.c @@ -1093,7 +1093,7 @@ static const VMStateDescription vmstate_ps2_common = { .name = "PS2 Common State", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(write_cmd, PS2State), VMSTATE_INT32(queue.rptr, PS2State), VMSTATE_INT32(queue.wptr, PS2State), @@ -1124,7 +1124,7 @@ static const VMStateDescription vmstate_ps2_keyboard_ledstate = { .minimum_version_id = 2, .post_load = ps2_kbd_ledstate_post_load, .needed = ps2_keyboard_ledstate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(ledstate, PS2KbdState), VMSTATE_END_OF_LIST() } @@ -1141,7 +1141,7 @@ static const VMStateDescription vmstate_ps2_keyboard_need_high_bit = { .version_id = 1, .minimum_version_id = 1, .needed = ps2_keyboard_need_high_bit_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(need_high_bit, PS2KbdState), VMSTATE_END_OF_LIST() } @@ -1158,7 +1158,7 @@ static bool ps2_keyboard_cqueue_needed(void *opaque) static const VMStateDescription vmstate_ps2_keyboard_cqueue = { .name = "ps2kbd/command_reply_queue", .needed = ps2_keyboard_cqueue_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(parent_obj.queue.cwptr, PS2KbdState), VMSTATE_END_OF_LIST() } @@ -1183,7 +1183,7 @@ static const VMStateDescription vmstate_ps2_keyboard = { .version_id = 3, .minimum_version_id = 2, .post_load = ps2_kbd_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, PS2KbdState, 0, vmstate_ps2_common, PS2State), VMSTATE_INT32(scan_enabled, PS2KbdState), @@ -1191,7 +1191,7 @@ static const VMStateDescription vmstate_ps2_keyboard = { VMSTATE_INT32_V(scancode_set, PS2KbdState, 3), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_ps2_keyboard_ledstate, &vmstate_ps2_keyboard_need_high_bit, &vmstate_ps2_keyboard_cqueue, @@ -1214,7 +1214,7 @@ static const VMStateDescription vmstate_ps2_mouse = { .version_id = 2, .minimum_version_id = 2, .post_load = ps2_mouse_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, PS2MouseState, 0, vmstate_ps2_common, PS2State), VMSTATE_UINT8(mouse_status, PS2MouseState), diff --git a/hw/input/pxa2xx_keypad.c b/hw/input/pxa2xx_keypad.c index 3dd03e8c9f..3858648d9f 100644 --- a/hw/input/pxa2xx_keypad.c +++ b/hw/input/pxa2xx_keypad.c @@ -288,7 +288,7 @@ static const VMStateDescription vmstate_pxa2xx_keypad = { .name = "pxa2xx_keypad", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(kpc, PXA2xxKeyPadState), VMSTATE_UINT32(kpdk, PXA2xxKeyPadState), VMSTATE_UINT32(kprec, PXA2xxKeyPadState), diff --git a/hw/input/stellaris_gamepad.c b/hw/input/stellaris_gamepad.c index 9dfa620e29..17ee42b9fc 100644 --- a/hw/input/stellaris_gamepad.c +++ b/hw/input/stellaris_gamepad.c @@ -35,7 +35,7 @@ static const VMStateDescription vmstate_stellaris_gamepad = { .name = "stellaris_gamepad", .version_id = 4, .minimum_version_id = 4, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(pressed, StellarisGamepad, num_buttons, 0, vmstate_info_uint8, uint8_t), VMSTATE_END_OF_LIST() diff --git a/hw/input/tsc2005.c b/hw/input/tsc2005.c index db2b80e35f..941f163d36 100644 --- a/hw/input/tsc2005.c +++ b/hw/input/tsc2005.c @@ -454,7 +454,7 @@ static const VMStateDescription vmstate_tsc2005 = { .version_id = 2, .minimum_version_id = 2, .post_load = tsc2005_post_load, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_BOOL(pressure, TSC2005State), VMSTATE_BOOL(irq, TSC2005State), VMSTATE_BOOL(command, TSC2005State), diff --git a/hw/input/tsc210x.c b/hw/input/tsc210x.c index 950506fb38..c4e32c7a42 100644 --- a/hw/input/tsc210x.c +++ b/hw/input/tsc210x.c @@ -1017,7 +1017,7 @@ static int tsc210x_post_load(void *opaque, int version_id) return 0; } -static VMStateField vmstatefields_tsc210x[] = { +static const VMStateField vmstatefields_tsc210x[] = { VMSTATE_BOOL(enabled, TSC210xState), VMSTATE_BOOL(host_mode, TSC210xState), VMSTATE_BOOL(irq, TSC210xState), diff --git a/hw/input/virtio-input.c b/hw/input/virtio-input.c index 5b5398b3ca..3bcdae41b2 100644 --- a/hw/input/virtio-input.c +++ b/hw/input/virtio-input.c @@ -293,7 +293,7 @@ static const VMStateDescription vmstate_virtio_input = { .name = "virtio-input", .minimum_version_id = VIRTIO_INPUT_VM_VERSION, .version_id = VIRTIO_INPUT_VM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758818 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671665wrw; Fri, 29 Dec 2023 13:28:56 -0800 (PST) X-Google-Smtp-Source: AGHT+IEqEBxt+dLHseM9PWXiJtwVYv5HTHdGIxdZ96hvl9dCCoVO3+NuWjix10g+0p3c8h+hHfgR X-Received: by 2002:a05:622a:50f:b0:425:4043:18c9 with SMTP id l15-20020a05622a050f00b00425404318c9mr14773448qtx.124.1703885335923; Fri, 29 Dec 2023 13:28:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885335; cv=none; d=google.com; s=arc-20160816; b=OWnLj8sYWr8awmZQKzggu7I3PkiCs8q3SL/cOobY+W8t/kGIzXQCNpOncoHkJBxNLF zbTaaKVjd8PLRZMj3FJHQyTrE+pJ0B/riyfrOaUBnCgMTJNwR9ezq2ZTWPS8cdoBZXvr ACR2cjVqw2p2Kv+ZbSMeo7iyzIBMHfMw2g418qio1hN6mBapg9KCYo5LHoEyUioDg10Y o/ZULjh2pMUy3nXlverSIZdVsTsmeVpeDTch435qzNtt5H8/FZLp2u54Witg5sm1gqLU 7dSKBu7zqQlC+XRGCUm6OhnNPlM8wR0ns4tmITd0t3aPxCEbFXH18LlGgJf7mSc8H5Rt npyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=zlUtpy3tSLM66FeSQHvLPTz1N9428UOhUZbuUDNx4S0=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=loXCGE4KurvhUwvZyY8jHJiTbtG9+uXQ8QFnyDOHxyS6cYpFxSyikSmpPBc2w+aVIM uMRO+54dt/EjAYECjM9XI0DCIC6FtwvA01Ig65AJ/yhglEQiFqo6Nv7pDBOE+UR6oVyE +/s8y1bc4c56R50RGlaycuNVuYxUffrt+yPeGeWOYeG47LEsXUOyZHVhsyCvr+qGcmjE LgeQev75HlF8GgS0WE02KY4S3zN4T9cTmb7EPir1PpIosabfyim7eWST6PIPUbE0qq34 eorWTyCVS5mbuM6iqmOqNyViNklDRDNcLHu7OLu2LqUK+PEan3ju20j/vI/T47ZL9Sdy TVfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HEJhF7OG; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id o3-20020ac85a43000000b0042808d6b3b4si1545122qta.579.2023.12.29.13.28.55 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:28:55 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HEJhF7OG; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKM4-0001Iy-1C; Fri, 29 Dec 2023 16:25:20 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKM1-00018N-Pi for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:17 -0500 Received: from mail-oi1-x22c.google.com ([2607:f8b0:4864:20::22c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKLy-0007h3-0a for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:17 -0500 Received: by mail-oi1-x22c.google.com with SMTP id 5614622812f47-3bbc648bed4so2173141b6e.3 for ; Fri, 29 Dec 2023 13:25:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885113; x=1704489913; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=zlUtpy3tSLM66FeSQHvLPTz1N9428UOhUZbuUDNx4S0=; b=HEJhF7OG78rbMBpE2nQYvYWrL3FiuolfKCybMMN3SbZoVfP3BXbmAHkzF46y6GZB7H kQPjTjySPDvSLBNYDCgrNsDEq0en4i1LXD10R8hfEg4ziCy7RyF5+OfvNQ0SKnrgRsWs drN+DXLNWUXMVQnlY9q/ziWUsxXL+GDB8+Ta9jkN596LZgXLd/5SIemTak0dzJVzjjvJ 3MwGA8e2sXoX1cp6pZThuoPPCXIVif8iakEG6L7Uy4o2uWA6pe3seU5eiMBWPDZOojDk 9X5J0Qitg3MvQyj3Ag+w3554HlpRMKkMBR1bdEGmdK4D3W24KmOlLsFk3Wzi5Z9KmfcK 8T4g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885113; x=1704489913; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=zlUtpy3tSLM66FeSQHvLPTz1N9428UOhUZbuUDNx4S0=; b=VvBWfmRQzK/6AVZP4kJGvwlWTiHEm9Rx3bcNxc0KMJo89CYhYmxvXrhgm/2ZpLJa35 iuZ9kwTNm85n4rPfCuHsnqPrfiD6d6bLTuy6UF5Gk+RisMcThRS0M7jHDsat4iAAPaj3 jx+B9DaJSq/+WViwcVxUJLloc4NkpN31/9K/7Wf93s5HM8d5xOO49ZTCgMLoGE+d452o LRSY2AH6129vw78WU75ogrG5jF5oKt4IBF4YStETqYy28sWci239u1CJbHMEGkS1lXGV oa9/dUWiVyMduUErsQoCpBZBT5iZubwWPOYeQUISyup5wQ38rK/J6zwVQVl5gu+mKORr W3nw== X-Gm-Message-State: AOJu0YxnbVEqmzIQUJX03mzHfw9wWkdJlQHO9TU/2gy53kHFYaRBXMXe NrSpjrmEQODBuW5un1+97myAX2T8mWKwOSnQnXcx7s14PymjkQ== X-Received: by 2002:a05:6808:228c:b0:3bb:d3b0:32e7 with SMTP id bo12-20020a056808228c00b003bbd3b032e7mr2846442oib.25.1703885112790; Fri, 29 Dec 2023 13:25:12 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:12 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 34/71] hw/intc: Constify VMState Date: Sat, 30 Dec 2023 08:23:09 +1100 Message-Id: <20231229212346.147149-35-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::22c; envelope-from=richard.henderson@linaro.org; helo=mail-oi1-x22c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-35-richard.henderson@linaro.org> --- hw/intc/allwinner-a10-pic.c | 2 +- hw/intc/apic_common.c | 6 +++--- hw/intc/arm_gic_common.c | 8 ++++---- hw/intc/arm_gicv3_common.c | 16 ++++++++-------- hw/intc/arm_gicv3_its_common.c | 2 +- hw/intc/armv7m_nvic.c | 8 ++++---- hw/intc/aspeed_vic.c | 2 +- hw/intc/bcm2835_ic.c | 2 +- hw/intc/bcm2836_control.c | 2 +- hw/intc/exynos4210_combiner.c | 4 ++-- hw/intc/goldfish_pic.c | 2 +- hw/intc/heathrow_pic.c | 4 ++-- hw/intc/i8259_common.c | 6 +++--- hw/intc/imx_avic.c | 2 +- hw/intc/imx_gpcv2.c | 2 +- hw/intc/ioapic_common.c | 2 +- hw/intc/loongarch_extioi.c | 2 +- hw/intc/loongarch_ipi.c | 4 ++-- hw/intc/loongarch_pch_pic.c | 2 +- hw/intc/m68k_irqc.c | 2 +- hw/intc/nios2_vic.c | 2 +- hw/intc/ompic.c | 4 ++-- hw/intc/openpic.c | 12 ++++++------ hw/intc/pl190.c | 2 +- hw/intc/ppc-uic.c | 2 +- hw/intc/riscv_aclint.c | 2 +- hw/intc/riscv_aplic.c | 2 +- hw/intc/riscv_imsic.c | 2 +- hw/intc/rx_icu.c | 2 +- hw/intc/s390_flic.c | 10 +++++----- hw/intc/s390_flic_kvm.c | 8 ++++---- hw/intc/sifive_plic.c | 2 +- hw/intc/slavio_intctl.c | 4 ++-- hw/intc/spapr_xive.c | 6 +++--- hw/intc/xics.c | 6 +++--- hw/intc/xive.c | 4 ++-- hw/intc/xlnx-pmu-iomod-intc.c | 2 +- hw/intc/xlnx-zynqmp-ipi.c | 2 +- 38 files changed, 77 insertions(+), 77 deletions(-) diff --git a/hw/intc/allwinner-a10-pic.c b/hw/intc/allwinner-a10-pic.c index d0bf8d545b..cea559c39d 100644 --- a/hw/intc/allwinner-a10-pic.c +++ b/hw/intc/allwinner-a10-pic.c @@ -142,7 +142,7 @@ static const VMStateDescription vmstate_aw_a10_pic = { .name = "a10.pic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vector, AwA10PICState), VMSTATE_UINT32(base_addr, AwA10PICState), VMSTATE_UINT32(protect, AwA10PICState), diff --git a/hw/intc/apic_common.c b/hw/intc/apic_common.c index bccb4241c2..6c100b48d6 100644 --- a/hw/intc/apic_common.c +++ b/hw/intc/apic_common.c @@ -349,7 +349,7 @@ static const VMStateDescription vmstate_apic_common_sipi = { .version_id = 1, .minimum_version_id = 1, .needed = apic_common_sipi_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(sipi_vector, APICCommonState), VMSTATE_INT32(wait_for_sipi, APICCommonState), VMSTATE_END_OF_LIST() @@ -363,7 +363,7 @@ static const VMStateDescription vmstate_apic_common = { .pre_load = apic_pre_load, .pre_save = apic_dispatch_pre_save, .post_load = apic_dispatch_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(apicbase, APICCommonState), VMSTATE_UINT8(id, APICCommonState), VMSTATE_UINT8(arb_id, APICCommonState), @@ -386,7 +386,7 @@ static const VMStateDescription vmstate_apic_common = { APICCommonState), /* open-coded timer state */ VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_apic_common_sipi, NULL } diff --git a/hw/intc/arm_gic_common.c b/hw/intc/arm_gic_common.c index 7c28504ace..94c173cb07 100644 --- a/hw/intc/arm_gic_common.c +++ b/hw/intc/arm_gic_common.c @@ -62,7 +62,7 @@ static const VMStateDescription vmstate_gic_irq_state = { .name = "arm_gic_irq_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(enabled, gic_irq_state), VMSTATE_UINT8(pending, gic_irq_state), VMSTATE_UINT8(active, gic_irq_state), @@ -79,7 +79,7 @@ static const VMStateDescription vmstate_gic_virt_state = { .version_id = 1, .minimum_version_id = 1, .needed = gic_virt_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Virtual interface */ VMSTATE_UINT32_ARRAY(h_hcr, GICState, GIC_NCPU), VMSTATE_UINT32_ARRAY(h_misr, GICState, GIC_NCPU), @@ -104,7 +104,7 @@ static const VMStateDescription vmstate_gic = { .minimum_version_id = 12, .pre_save = gic_pre_save, .post_load = gic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctlr, GICState), VMSTATE_UINT32_SUB_ARRAY(cpu_ctlr, GICState, 0, GIC_NCPU), VMSTATE_STRUCT_ARRAY(irq_state, GICState, GIC_MAXIRQ, 1, @@ -122,7 +122,7 @@ static const VMStateDescription vmstate_gic = { VMSTATE_UINT32_2DARRAY(nsapr, GICState, GIC_NR_APRS, GIC_NCPU), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_gic_virt_state, NULL } diff --git a/hw/intc/arm_gicv3_common.c b/hw/intc/arm_gicv3_common.c index 2ebf880ead..cb55c72681 100644 --- a/hw/intc/arm_gicv3_common.c +++ b/hw/intc/arm_gicv3_common.c @@ -105,7 +105,7 @@ static const VMStateDescription vmstate_gicv3_cpu_virt = { .version_id = 1, .minimum_version_id = 1, .needed = virt_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_2DARRAY(ich_apr, GICv3CPUState, 3, 4), VMSTATE_UINT64(ich_hcr_el2, GICv3CPUState), VMSTATE_UINT64_ARRAY(ich_lr_el2, GICv3CPUState, GICV3_LR_MAX), @@ -139,7 +139,7 @@ const VMStateDescription vmstate_gicv3_cpu_sre_el1 = { .version_id = 1, .minimum_version_id = 1, .needed = icc_sre_el1_reg_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(icc_sre_el1, GICv3CPUState), VMSTATE_END_OF_LIST() } @@ -157,7 +157,7 @@ const VMStateDescription vmstate_gicv3_gicv4 = { .version_id = 1, .minimum_version_id = 1, .needed = gicv4_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(gicr_vpropbaser, GICv3CPUState), VMSTATE_UINT64(gicr_vpendbaser, GICv3CPUState), VMSTATE_END_OF_LIST() @@ -169,7 +169,7 @@ static const VMStateDescription vmstate_gicv3_cpu = { .version_id = 1, .minimum_version_id = 1, .pre_load = vmstate_gicv3_cpu_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, GICv3CPUState), VMSTATE_UINT32(gicr_ctlr, GICv3CPUState), VMSTATE_UINT32_ARRAY(gicr_statusr, GICv3CPUState, 2), @@ -192,7 +192,7 @@ static const VMStateDescription vmstate_gicv3_cpu = { VMSTATE_UINT64(icc_ctlr_el3, GICv3CPUState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_gicv3_cpu_virt, &vmstate_gicv3_cpu_sre_el1, &vmstate_gicv3_gicv4, @@ -232,7 +232,7 @@ const VMStateDescription vmstate_gicv3_gicd_no_migration_shift_bug = { .version_id = 1, .minimum_version_id = 1, .needed = needed_always, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(gicd_no_migration_shift_bug, GICv3State), VMSTATE_END_OF_LIST() } @@ -246,7 +246,7 @@ static const VMStateDescription vmstate_gicv3 = { .pre_save = gicv3_pre_save, .post_load = gicv3_post_load, .priority = MIG_PRI_GICV3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(gicd_ctlr, GICv3State), VMSTATE_UINT32_ARRAY(gicd_statusr, GICv3State, 2), VMSTATE_UINT32_ARRAY(group, GICv3State, GICV3_BMP_SIZE), @@ -264,7 +264,7 @@ static const VMStateDescription vmstate_gicv3 = { vmstate_gicv3_cpu, GICv3CPUState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_gicv3_gicd_no_migration_shift_bug, NULL } diff --git a/hw/intc/arm_gicv3_its_common.c b/hw/intc/arm_gicv3_its_common.c index fddd6d490c..331d6b93cc 100644 --- a/hw/intc/arm_gicv3_its_common.c +++ b/hw/intc/arm_gicv3_its_common.c @@ -54,7 +54,7 @@ static const VMStateDescription vmstate_its = { .pre_save = gicv3_its_pre_save, .post_load = gicv3_its_post_load, .priority = MIG_PRI_GICV3_ITS, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctlr, GICv3ITSState), VMSTATE_UINT32(iidr, GICv3ITSState), VMSTATE_UINT64(cbaser, GICv3ITSState), diff --git a/hw/intc/armv7m_nvic.c b/hw/intc/armv7m_nvic.c index 942be7bd11..50f9a973a2 100644 --- a/hw/intc/armv7m_nvic.c +++ b/hw/intc/armv7m_nvic.c @@ -2498,7 +2498,7 @@ static const VMStateDescription vmstate_VecInfo = { .name = "armv7m_nvic_info", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT16(prio, VecInfo), VMSTATE_UINT8(enabled, VecInfo), VMSTATE_UINT8(pending, VecInfo), @@ -2543,7 +2543,7 @@ static const VMStateDescription vmstate_nvic_security = { .minimum_version_id = 1, .needed = nvic_security_needed, .post_load = &nvic_security_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(sec_vectors, NVICState, NVIC_INTERNAL_VECTORS, 1, vmstate_VecInfo, VecInfo), VMSTATE_UINT32(prigroup[M_REG_S], NVICState), @@ -2557,13 +2557,13 @@ static const VMStateDescription vmstate_nvic = { .version_id = 4, .minimum_version_id = 4, .post_load = &nvic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(vectors, NVICState, NVIC_MAX_VECTORS, 1, vmstate_VecInfo, VecInfo), VMSTATE_UINT32(prigroup[M_REG_NS], NVICState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_nvic_security, NULL } diff --git a/hw/intc/aspeed_vic.c b/hw/intc/aspeed_vic.c index 5ba06c5262..ba1d953c2c 100644 --- a/hw/intc/aspeed_vic.c +++ b/hw/intc/aspeed_vic.c @@ -326,7 +326,7 @@ static const VMStateDescription vmstate_aspeed_vic = { .name = "aspeed.new-vic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(level, AspeedVICState), VMSTATE_UINT64(raw, AspeedVICState), VMSTATE_UINT64(select, AspeedVICState), diff --git a/hw/intc/bcm2835_ic.c b/hw/intc/bcm2835_ic.c index 4513fad16f..2c2e2b1822 100644 --- a/hw/intc/bcm2835_ic.c +++ b/hw/intc/bcm2835_ic.c @@ -208,7 +208,7 @@ static const VMStateDescription vmstate_bcm2835_ic = { .name = TYPE_BCM2835_IC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(gpu_irq_level, BCM2835ICState), VMSTATE_UINT64(gpu_irq_enable, BCM2835ICState), VMSTATE_UINT8(arm_irq_level, BCM2835ICState), diff --git a/hw/intc/bcm2836_control.c b/hw/intc/bcm2836_control.c index b0589df188..81faf032b0 100644 --- a/hw/intc/bcm2836_control.c +++ b/hw/intc/bcm2836_control.c @@ -369,7 +369,7 @@ static const VMStateDescription vmstate_bcm2836_control = { .name = TYPE_BCM2836_CONTROL, .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(mailboxes, BCM2836ControlState, BCM2836_NCORES * BCM2836_MBPERCORE), VMSTATE_UINT8(route_gpu_irq, BCM2836ControlState), diff --git a/hw/intc/exynos4210_combiner.c b/hw/intc/exynos4210_combiner.c index 4ba448fdb1..f0d310a0eb 100644 --- a/hw/intc/exynos4210_combiner.c +++ b/hw/intc/exynos4210_combiner.c @@ -54,7 +54,7 @@ static const VMStateDescription vmstate_exynos4210_combiner_group_state = { .name = "exynos4210.combiner.groupstate", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(src_mask, CombinerGroupState), VMSTATE_UINT8(src_pending, CombinerGroupState), VMSTATE_END_OF_LIST() @@ -65,7 +65,7 @@ static const VMStateDescription vmstate_exynos4210_combiner = { .name = "exynos4210.combiner", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(group, Exynos4210CombinerState, IIC_NGRP, 0, vmstate_exynos4210_combiner_group_state, CombinerGroupState), VMSTATE_UINT32_ARRAY(reg_set, Exynos4210CombinerState, diff --git a/hw/intc/goldfish_pic.c b/hw/intc/goldfish_pic.c index dfd53275f6..d662dfeb99 100644 --- a/hw/intc/goldfish_pic.c +++ b/hw/intc/goldfish_pic.c @@ -161,7 +161,7 @@ static const VMStateDescription vmstate_goldfish_pic = { .name = "goldfish_pic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pending, GoldfishPICState), VMSTATE_UINT32(enabled, GoldfishPICState), VMSTATE_END_OF_LIST() diff --git a/hw/intc/heathrow_pic.c b/hw/intc/heathrow_pic.c index 13048a2735..c2946ba1ad 100644 --- a/hw/intc/heathrow_pic.c +++ b/hw/intc/heathrow_pic.c @@ -141,7 +141,7 @@ static const VMStateDescription vmstate_heathrow_pic_one = { .name = "heathrow_pic_one", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(events, HeathrowPICState), VMSTATE_UINT32(mask, HeathrowPICState), VMSTATE_UINT32(levels, HeathrowPICState), @@ -154,7 +154,7 @@ static const VMStateDescription vmstate_heathrow = { .name = "heathrow_pic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(pics, HeathrowState, 2, 1, vmstate_heathrow_pic_one, HeathrowPICState), VMSTATE_END_OF_LIST() diff --git a/hw/intc/i8259_common.c b/hw/intc/i8259_common.c index c931dc2d07..ee0041115c 100644 --- a/hw/intc/i8259_common.c +++ b/hw/intc/i8259_common.c @@ -156,7 +156,7 @@ static const VMStateDescription vmstate_pic_ltim = { .version_id = 1, .minimum_version_id = 1, .needed = ltim_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(ltim, PICCommonState), VMSTATE_END_OF_LIST() } @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_pic_common = { .minimum_version_id = 1, .pre_save = pic_dispatch_pre_save, .post_load = pic_dispatch_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(last_irr, PICCommonState), VMSTATE_UINT8(irr, PICCommonState), VMSTATE_UINT8(imr, PICCommonState), @@ -187,7 +187,7 @@ static const VMStateDescription vmstate_pic_common = { VMSTATE_UINT8(elcr, PICCommonState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_pic_ltim, NULL } diff --git a/hw/intc/imx_avic.c b/hw/intc/imx_avic.c index 63fc602a1a..aedc708bed 100644 --- a/hw/intc/imx_avic.c +++ b/hw/intc/imx_avic.c @@ -38,7 +38,7 @@ static const VMStateDescription vmstate_imx_avic = { .name = TYPE_IMX_AVIC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(pending, IMXAVICState), VMSTATE_UINT64(enabled, IMXAVICState), VMSTATE_UINT64(is_fiq, IMXAVICState), diff --git a/hw/intc/imx_gpcv2.c b/hw/intc/imx_gpcv2.c index 237d5f97eb..af45e5194c 100644 --- a/hw/intc/imx_gpcv2.c +++ b/hw/intc/imx_gpcv2.c @@ -96,7 +96,7 @@ static const VMStateDescription vmstate_imx_gpcv2 = { .name = TYPE_IMX_GPCV2, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IMXGPCv2State, GPC_NUM), VMSTATE_END_OF_LIST() }, diff --git a/hw/intc/ioapic_common.c b/hw/intc/ioapic_common.c index b05f436dac..cb9bf62146 100644 --- a/hw/intc/ioapic_common.c +++ b/hw/intc/ioapic_common.c @@ -182,7 +182,7 @@ static const VMStateDescription vmstate_ioapic_common = { .minimum_version_id = 1, .pre_save = ioapic_dispatch_pre_save, .post_load = ioapic_dispatch_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(id, IOAPICCommonState), VMSTATE_UINT8(ioregsel, IOAPICCommonState), VMSTATE_UNUSED_V(2, 8), /* to account for qemu-kvm's v2 format */ diff --git a/hw/intc/loongarch_extioi.c b/hw/intc/loongarch_extioi.c index 24fb3af8cc..4fa97f05bd 100644 --- a/hw/intc/loongarch_extioi.c +++ b/hw/intc/loongarch_extioi.c @@ -252,7 +252,7 @@ static const VMStateDescription vmstate_loongarch_extioi = { .name = TYPE_LOONGARCH_EXTIOI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(bounce, LoongArchExtIOI, EXTIOI_IRQS_GROUP_COUNT), VMSTATE_UINT32_2DARRAY(coreisr, LoongArchExtIOI, EXTIOI_CPUS, EXTIOI_IRQS_GROUP_COUNT), diff --git a/hw/intc/loongarch_ipi.c b/hw/intc/loongarch_ipi.c index 67858b521c..a155c16509 100644 --- a/hw/intc/loongarch_ipi.c +++ b/hw/intc/loongarch_ipi.c @@ -270,7 +270,7 @@ static const VMStateDescription vmstate_ipi_core = { .name = "ipi-single", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(status, IPICore), VMSTATE_UINT32(en, IPICore), VMSTATE_UINT32(set, IPICore), @@ -284,7 +284,7 @@ static const VMStateDescription vmstate_loongarch_ipi = { .name = TYPE_LOONGARCH_IPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ipi_core, LoongArchIPI, 0, vmstate_ipi_core, IPICore), VMSTATE_END_OF_LIST() } diff --git a/hw/intc/loongarch_pch_pic.c b/hw/intc/loongarch_pch_pic.c index 6aa4cadfa4..2d5e65abff 100644 --- a/hw/intc/loongarch_pch_pic.c +++ b/hw/intc/loongarch_pch_pic.c @@ -420,7 +420,7 @@ static const VMStateDescription vmstate_loongarch_pch_pic = { .name = TYPE_LOONGARCH_PCH_PIC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(int_mask, LoongArchPCHPIC), VMSTATE_UINT64(htmsi_en, LoongArchPCHPIC), VMSTATE_UINT64(intedge, LoongArchPCHPIC), diff --git a/hw/intc/m68k_irqc.c b/hw/intc/m68k_irqc.c index e09705eeaf..4b11fb9f72 100644 --- a/hw/intc/m68k_irqc.c +++ b/hw/intc/m68k_irqc.c @@ -80,7 +80,7 @@ static const VMStateDescription vmstate_m68k_irqc = { .name = "m68k-irqc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(ipr, M68KIRQCState), VMSTATE_END_OF_LIST() } diff --git a/hw/intc/nios2_vic.c b/hw/intc/nios2_vic.c index cf63212a88..7e2d9d6327 100644 --- a/hw/intc/nios2_vic.c +++ b/hw/intc/nios2_vic.c @@ -275,7 +275,7 @@ static const VMStateDescription nios2_vic_vmstate = { .name = "nios2-vic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32_ARRAY(int_config, Nios2VIC, 32), VMSTATE_UINT32(vic_config, Nios2VIC), VMSTATE_UINT32(int_raw_status, Nios2VIC), diff --git a/hw/intc/ompic.c b/hw/intc/ompic.c index 1f10314807..99032ea7f7 100644 --- a/hw/intc/ompic.c +++ b/hw/intc/ompic.c @@ -137,7 +137,7 @@ static const VMStateDescription vmstate_or1k_ompic_cpu = { .name = "or1k_ompic_cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(status, OR1KOMPICCPUState), VMSTATE_UINT32(control, OR1KOMPICCPUState), VMSTATE_END_OF_LIST() @@ -148,7 +148,7 @@ static const VMStateDescription vmstate_or1k_ompic = { .name = TYPE_OR1K_OMPIC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(cpus, OR1KOMPICState, OMPIC_MAX_CPUS, 1, vmstate_or1k_ompic_cpu, OR1KOMPICCPUState), VMSTATE_UINT32(num_cpus, OR1KOMPICState), diff --git a/hw/intc/openpic.c b/hw/intc/openpic.c index a6f91d4bcd..9792a11224 100644 --- a/hw/intc/openpic.c +++ b/hw/intc/openpic.c @@ -1391,7 +1391,7 @@ static const VMStateDescription vmstate_openpic_irq_queue = { .name = "openpic_irq_queue", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BITMAP(queue, IRQQueue, 0, queue_size), VMSTATE_INT32(next, IRQQueue), VMSTATE_INT32(priority, IRQQueue), @@ -1403,7 +1403,7 @@ static const VMStateDescription vmstate_openpic_irqdest = { .name = "openpic_irqdest", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(ctpr, IRQDest), VMSTATE_STRUCT(raised, IRQDest, 0, vmstate_openpic_irq_queue, IRQQueue), @@ -1418,7 +1418,7 @@ static const VMStateDescription vmstate_openpic_irqsource = { .name = "openpic_irqsource", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ivpr, IRQSource), VMSTATE_UINT32(idr, IRQSource), VMSTATE_UINT32(destmask, IRQSource), @@ -1432,7 +1432,7 @@ static const VMStateDescription vmstate_openpic_timer = { .name = "openpic_timer", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tccr, OpenPICTimer), VMSTATE_UINT32(tbcr, OpenPICTimer), VMSTATE_END_OF_LIST() @@ -1443,7 +1443,7 @@ static const VMStateDescription vmstate_openpic_msi = { .name = "openpic_msi", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(msir, OpenPICMSI), VMSTATE_END_OF_LIST() } @@ -1468,7 +1468,7 @@ static const VMStateDescription vmstate_openpic = { .version_id = 3, .minimum_version_id = 3, .post_load = openpic_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(gcr, OpenPICState), VMSTATE_UINT32(vir, OpenPICState), VMSTATE_UINT32(pir, OpenPICState), diff --git a/hw/intc/pl190.c b/hw/intc/pl190.c index cd88443601..d79e5d8076 100644 --- a/hw/intc/pl190.c +++ b/hw/intc/pl190.c @@ -258,7 +258,7 @@ static const VMStateDescription vmstate_pl190 = { .name = "pl190", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, PL190State), VMSTATE_UINT32(soft_level, PL190State), VMSTATE_UINT32(irq_enable, PL190State), diff --git a/hw/intc/ppc-uic.c b/hw/intc/ppc-uic.c index dcf5de5d43..9a67f7f651 100644 --- a/hw/intc/ppc-uic.c +++ b/hw/intc/ppc-uic.c @@ -269,7 +269,7 @@ static const VMStateDescription ppc_uic_vmstate = { .name = "ppc-uic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(level, PPCUIC), VMSTATE_UINT32(uicsr, PPCUIC), VMSTATE_UINT32(uicer, PPCUIC), diff --git a/hw/intc/riscv_aclint.c b/hw/intc/riscv_aclint.c index ab1a0b4b3a..e9f0536b1c 100644 --- a/hw/intc/riscv_aclint.c +++ b/hw/intc/riscv_aclint.c @@ -321,7 +321,7 @@ static const VMStateDescription vmstate_riscv_mtimer = { .name = "riscv_mtimer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(timecmp, RISCVAclintMTimerState, num_harts, 0, vmstate_info_uint64, uint64_t), diff --git a/hw/intc/riscv_aplic.c b/hw/intc/riscv_aplic.c index c677b5cfbb..e98e258deb 100644 --- a/hw/intc/riscv_aplic.c +++ b/hw/intc/riscv_aplic.c @@ -878,7 +878,7 @@ static const VMStateDescription vmstate_riscv_aplic = { .name = "riscv_aplic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(domaincfg, RISCVAPLICState), VMSTATE_UINT32(mmsicfgaddr, RISCVAPLICState), VMSTATE_UINT32(mmsicfgaddrH, RISCVAPLICState), diff --git a/hw/intc/riscv_imsic.c b/hw/intc/riscv_imsic.c index b31d07980c..b90f0d731d 100644 --- a/hw/intc/riscv_imsic.c +++ b/hw/intc/riscv_imsic.c @@ -386,7 +386,7 @@ static const VMStateDescription vmstate_riscv_imsic = { .name = "riscv_imsic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(eidelivery, RISCVIMSICState, num_pages, 0, vmstate_info_uint32, uint32_t), diff --git a/hw/intc/rx_icu.c b/hw/intc/rx_icu.c index e5c01807b9..b2d4338f61 100644 --- a/hw/intc/rx_icu.c +++ b/hw/intc/rx_icu.c @@ -345,7 +345,7 @@ static const VMStateDescription vmstate_rxicu = { .name = "rx-icu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(ir, RXICUState, NR_IRQS), VMSTATE_UINT8_ARRAY(dtcer, RXICUState, NR_IRQS), VMSTATE_UINT8_ARRAY(ier, RXICUState, NR_IRQS / 8), diff --git a/hw/intc/s390_flic.c b/hw/intc/s390_flic.c index 74e02858d4..212f268581 100644 --- a/hw/intc/s390_flic.c +++ b/hw/intc/s390_flic.c @@ -366,7 +366,7 @@ static const VMStateDescription qemu_s390_flic_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = ais_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(simm, QEMUS390FLICState), VMSTATE_UINT8(nimm, QEMUS390FLICState), VMSTATE_END_OF_LIST() @@ -465,7 +465,7 @@ const VMStateDescription vmstate_adapter_info_so = { .version_id = 1, .minimum_version_id = 1, .needed = adapter_info_so_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(summary_offset, AdapterInfo), VMSTATE_END_OF_LIST() } @@ -475,7 +475,7 @@ const VMStateDescription vmstate_adapter_info = { .name = "s390_adapter_info", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ind_offset, AdapterInfo), /* * We do not have to migrate neither the id nor the addresses. @@ -484,7 +484,7 @@ const VMStateDescription vmstate_adapter_info = { */ VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_adapter_info_so, NULL } @@ -495,7 +495,7 @@ const VMStateDescription vmstate_adapter_routes = { .name = "s390_adapter_routes", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(adapter, AdapterRoutes, 1, vmstate_adapter_info, AdapterInfo), VMSTATE_END_OF_LIST() diff --git a/hw/intc/s390_flic_kvm.c b/hw/intc/s390_flic_kvm.c index 28364b22d6..4d5cbb2a2f 100644 --- a/hw/intc/s390_flic_kvm.c +++ b/hw/intc/s390_flic_kvm.c @@ -525,7 +525,7 @@ static const VMStateDescription kvm_s390_flic_ais_tmp = { .name = "s390-flic-ais-tmp", .pre_save = kvm_flic_ais_pre_save, .post_load = kvm_flic_ais_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(simm, KVMS390FLICStateMigTmp), VMSTATE_UINT8(nimm, KVMS390FLICStateMigTmp), VMSTATE_END_OF_LIST() @@ -537,7 +537,7 @@ static const VMStateDescription kvm_s390_flic_vmstate_ais = { .version_id = 1, .minimum_version_id = 1, .needed = ais_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP(KVMS390FLICState, KVMS390FLICStateMigTmp, kvm_s390_flic_ais_tmp), VMSTATE_END_OF_LIST() @@ -550,7 +550,7 @@ static const VMStateDescription kvm_s390_flic_vmstate = { .name = "s390-flic", .version_id = FLIC_SAVEVM_VERSION, .minimum_version_id = FLIC_SAVEVM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { { .name = "irqs", .info = &(const VMStateInfo) { @@ -562,7 +562,7 @@ static const VMStateDescription kvm_s390_flic_vmstate = { }, VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &kvm_s390_flic_vmstate_ais, NULL } diff --git a/hw/intc/sifive_plic.c b/hw/intc/sifive_plic.c index 5522ede2cf..e559f11805 100644 --- a/hw/intc/sifive_plic.c +++ b/hw/intc/sifive_plic.c @@ -406,7 +406,7 @@ static const VMStateDescription vmstate_sifive_plic = { .name = "riscv_sifive_plic", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(source_priority, SiFivePLICState, num_sources, 0, vmstate_info_uint32, uint32_t), diff --git a/hw/intc/slavio_intctl.c b/hw/intc/slavio_intctl.c index f7e59ba643..36b4a12f60 100644 --- a/hw/intc/slavio_intctl.c +++ b/hw/intc/slavio_intctl.c @@ -353,7 +353,7 @@ static const VMStateDescription vmstate_intctl_cpu = { .name ="slavio_intctl_cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(intreg_pending, SLAVIO_CPUINTCTLState), VMSTATE_END_OF_LIST() } @@ -364,7 +364,7 @@ static const VMStateDescription vmstate_intctl = { .version_id = 1, .minimum_version_id = 1, .post_load = vmstate_intctl_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(slaves, SLAVIO_INTCTLState, MAX_CPUS, 1, vmstate_intctl_cpu, SLAVIO_CPUINTCTLState), VMSTATE_UINT32(intregm_pending, SLAVIO_INTCTLState), diff --git a/hw/intc/spapr_xive.c b/hw/intc/spapr_xive.c index 199c261b07..d7e56bfb20 100644 --- a/hw/intc/spapr_xive.c +++ b/hw/intc/spapr_xive.c @@ -522,7 +522,7 @@ static const VMStateDescription vmstate_spapr_xive_end = { .name = TYPE_SPAPR_XIVE "/end", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(w0, XiveEND), VMSTATE_UINT32(w1, XiveEND), VMSTATE_UINT32(w2, XiveEND), @@ -539,7 +539,7 @@ static const VMStateDescription vmstate_spapr_xive_eas = { .name = TYPE_SPAPR_XIVE "/eas", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT64(w, XiveEAS), VMSTATE_END_OF_LIST() }, @@ -577,7 +577,7 @@ static const VMStateDescription vmstate_spapr_xive = { .minimum_version_id = 1, .pre_save = vmstate_spapr_xive_pre_save, .post_load = NULL, /* handled at the machine level */ - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_EQUAL(nr_irqs, SpaprXive, NULL), VMSTATE_STRUCT_VARRAY_POINTER_UINT32(eat, SpaprXive, nr_irqs, vmstate_spapr_xive_eas, XiveEAS), diff --git a/hw/intc/xics.c b/hw/intc/xics.c index c77e986136..8b25787227 100644 --- a/hw/intc/xics.c +++ b/hw/intc/xics.c @@ -273,7 +273,7 @@ static const VMStateDescription vmstate_icp_server = { .minimum_version_id = 1, .pre_save = icp_pre_save, .post_load = icp_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Sanity check */ VMSTATE_UINT32(xirr, ICPState), VMSTATE_UINT8(pending_priority, ICPState), @@ -665,7 +665,7 @@ static const VMStateDescription vmstate_ics_irq = { .name = "ics/irq", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(server, ICSIRQState), VMSTATE_UINT8(priority, ICSIRQState), VMSTATE_UINT8(saved_priority, ICSIRQState), @@ -681,7 +681,7 @@ static const VMStateDescription vmstate_ics = { .minimum_version_id = 1, .pre_save = ics_pre_save, .post_load = ics_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Sanity check */ VMSTATE_UINT32_EQUAL(nr_irqs, ICSState, NULL), diff --git a/hw/intc/xive.c b/hw/intc/xive.c index a3585593d8..057b308ae9 100644 --- a/hw/intc/xive.c +++ b/hw/intc/xive.c @@ -798,7 +798,7 @@ static const VMStateDescription vmstate_xive_tctx = { .minimum_version_id = 1, .pre_save = vmstate_xive_tctx_pre_save, .post_load = vmstate_xive_tctx_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(regs, XiveTCTX), VMSTATE_END_OF_LIST() }, @@ -1271,7 +1271,7 @@ static const VMStateDescription vmstate_xive_source = { .name = TYPE_XIVE_SOURCE, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_EQUAL(nr_irqs, XiveSource, NULL), VMSTATE_VBUFFER_UINT32(status, XiveSource, 1, NULL, nr_irqs), VMSTATE_END_OF_LIST() diff --git a/hw/intc/xlnx-pmu-iomod-intc.c b/hw/intc/xlnx-pmu-iomod-intc.c index acaa1c3e6f..12bd1a3fff 100644 --- a/hw/intc/xlnx-pmu-iomod-intc.c +++ b/hw/intc/xlnx-pmu-iomod-intc.c @@ -526,7 +526,7 @@ static const VMStateDescription vmstate_xlnx_pmu_io_intc = { .name = TYPE_XLNX_PMU_IO_INTC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxPMUIOIntc, XLNXPMUIOINTC_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/intc/xlnx-zynqmp-ipi.c b/hw/intc/xlnx-zynqmp-ipi.c index adc1179014..509ee799cc 100644 --- a/hw/intc/xlnx-zynqmp-ipi.c +++ b/hw/intc/xlnx-zynqmp-ipi.c @@ -349,7 +349,7 @@ static const VMStateDescription vmstate_zynqmp_pmu_ipi = { .name = TYPE_XLNX_ZYNQMP_IPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZynqMPIPI, R_XLNX_ZYNQMP_IPI_MAX), VMSTATE_END_OF_LIST(), } From patchwork Fri Dec 29 21:23:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758856 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672896wrw; Fri, 29 Dec 2023 13:33:27 -0800 (PST) X-Google-Smtp-Source: AGHT+IH5pIxJlVP9BL/s6pgN2hKuJsN7RHHJh6nN0NQl/0a9pQ8GQNFVqSMO15GJ/ZQ3td/ZIkrK X-Received: by 2002:ad4:5305:0:b0:67f:a8b3:7975 with SMTP id y5-20020ad45305000000b0067fa8b37975mr12716556qvr.86.1703885607289; Fri, 29 Dec 2023 13:33:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885607; cv=none; d=google.com; s=arc-20160816; b=0kZDp3pvdciUi/iKmgTpoUjgw7UtFJZzReVh+epSSM3CLhECL1E7fc0mN3uYZ48kRi yeZgU1DpcgsOHPPNk6VjGGkFPdCI4mq5+DTaB3xowJJTaXFPb2Wj7p65J4prhX6sE76L 6WVnsNptkzeru3Wktr7a/pnMSib5bntHOD/sFcRB0SL0H7UoRlVcw/bDXS6L0/5RWfE7 QGMjm9QEyFqiAH8JNNJwei+qddTSvMNxcpx3d71c72/UVQaeVvTdHyL7+aXJ6faZFRp/ Tq3QcsXhTQgtS8KdIrdIypGSArBCfSpk07d6/X0n/TaHPaoVmeQsBuyd9Z/ytMeRgjYj WABg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=l/g/xbbVARm94nOrfgxhdYMz88vGBMTmt5c/f0fX3lI=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=ne4M9HY1bS/9Gl37CgT1jV3itsboaUSYnjfNK3WWaoXGU+LnrbA5ws0PBLlxGPPOfv /64Y+zcQXus2dICQvwfEMjM7WR7ij3okojyXj72+EBii0JiqQ4OvcjXzo1fHYxI1mipS P/FSVgK37uuJhMC7csE8LP/sTYhPvsZtMIRlGzMaatlDeDKmMotZrqHNWwfTfagd1UwU BCBx9RDAmy5iwm9bzEO24PMi3uy/iFd+2DS57w7dIngcJHfnEfs+u97EtO8ltVh1Fr+4 +ksRj2tK7Z6p3RRBNlU/CSloZuMReOiC5FW/PwEPtjqya9WQgRdorJrPpJc429o65WBX ps6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hTyjRbMT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id q8-20020a0cf5c8000000b0067ef2e4e420si20529412qvm.37.2023.12.29.13.33.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:33:27 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hTyjRbMT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKMK-0001ar-Te; Fri, 29 Dec 2023 16:25:37 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKM2-00019r-1o for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:18 -0500 Received: from mail-pf1-x42e.google.com ([2607:f8b0:4864:20::42e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKM0-0007pD-FF for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:17 -0500 Received: by mail-pf1-x42e.google.com with SMTP id d2e1a72fcca58-6da16ec9be4so1554680b3a.1 for ; Fri, 29 Dec 2023 13:25:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885115; x=1704489915; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=l/g/xbbVARm94nOrfgxhdYMz88vGBMTmt5c/f0fX3lI=; b=hTyjRbMTHtOC0nD9vIItkb9Mf2NUnV+VsfDkU+YxX8m2LQBZlzMVuCdFljI7xxgs0p RrsmBec/OGuVkG99E4FscoPjAquODmVYvSs00bfubelSTKK6bYk9ADisMDRXOtEA0/uJ Cx5Xwfywf6MNgeT+Up2Ua+yCksh2CHeMrYF1SkU/QcVPcXl4B8MM2Sl65EFR1Xou3pQW 52TzNPlKWNbEJ0YuECqm4cGqMCQAQb3HHNuhC84KG3hMINwNwpquPe+sBaqRA9Sdi34s 8NbbFMRSTLsR8TlYW5LggbWyMubP3hGyJDaOK5sV4Kb4uFKP3BpPTrXhKQfwIk0ChdbW qofQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885115; x=1704489915; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=l/g/xbbVARm94nOrfgxhdYMz88vGBMTmt5c/f0fX3lI=; b=eijyahXEP1QpNdrLLXXgxDTV85p6gy2dnpXdNkoyNWAZsxvm6EwPeI0Tm/VkgTr/IJ mLubsAzNT7oM7XYMTXmL9QvTS+e/M91O73BUdDIw9vDBjyyGmEdbfOFfilTkxVuO/USe w6YtFi1+UwM18AcNLgR6Pft9t7DXHjyd+2KBQq9SraYxbRcU91t+C2C6/AdSFDC+yP6d aDq4v1vo9GMVd1cACcKpv+12mns5QF3Y+ZmkGLwf4Rah+pCn+A0gNuVOVcZjMmPVyfL7 Sf0Ru/zpMsrmrzB4mVYFGszHhdOvgOStRqeVIsdJBkT72obGTx2/EUo8OVraMZsaZAjP +OMQ== X-Gm-Message-State: AOJu0YyUAsxhZKZ2W9YmAtACcJNlYC8vr1wa+VP/mRJkR4jzaqK0Phw/ IVjcx2zQ4QMFjzvRJyaeqUqBn0v2c/1t60fixAaM+rBVPfbUxw== X-Received: by 2002:aa7:8c42:0:b0:6d9:ac6f:20b4 with SMTP id e2-20020aa78c42000000b006d9ac6f20b4mr8950106pfd.42.1703885115090; Fri, 29 Dec 2023 13:25:15 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:14 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 35/71] hw/ipack: Constify VMState Date: Sat, 30 Dec 2023 08:23:10 +1100 Message-Id: <20231229212346.147149-36-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42e; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42e.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-36-richard.henderson@linaro.org> --- hw/ipack/ipack.c | 2 +- hw/ipack/tpci200.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/ipack/ipack.c b/hw/ipack/ipack.c index ae20f36da6..c39dbb481f 100644 --- a/hw/ipack/ipack.c +++ b/hw/ipack/ipack.c @@ -93,7 +93,7 @@ const VMStateDescription vmstate_ipack_device = { .name = "ipack_device", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(slot, IPackDevice), VMSTATE_END_OF_LIST() } diff --git a/hw/ipack/tpci200.c b/hw/ipack/tpci200.c index 6b3edbf017..88eef4b830 100644 --- a/hw/ipack/tpci200.c +++ b/hw/ipack/tpci200.c @@ -619,7 +619,7 @@ static const VMStateDescription vmstate_tpci200 = { .name = "tpci200", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, TPCI200State), VMSTATE_BOOL_ARRAY(big_endian, TPCI200State, 3), VMSTATE_UINT8_ARRAY(ctrl, TPCI200State, N_MODULES), From patchwork Fri Dec 29 21:23:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758802 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4670982wrw; Fri, 29 Dec 2023 13:26:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IHI1VVi/Kpz+KUW4j2GHu+cw4CFdNXw8Fknzepeq+bOSLYHUuuqNAyhznrdo24TQFRSJ1zb X-Received: by 2002:a05:6214:2a85:b0:67f:50f:d7a with SMTP id jr5-20020a0562142a8500b0067f050f0d7amr17682719qvb.100.1703885166890; Fri, 29 Dec 2023 13:26:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885166; cv=none; d=google.com; s=arc-20160816; b=SfFLjiJEkhlPnuLNNaEr59e1HUVkABa/gBC2UGOwtCaX15r3YmSRaRmiVIbZM5Y7qn l1gN4PDafnORu4xG2zFOE1l7lAmMzFevT6Ot/l8W/6WOWglxG002KIq+xLy499Q7epg1 yyFd6iZ1R7d3v5DfdD2kgabHXhPWWfmJ3jysAvZi6xXKkTjauu+yMVQZoBT5e0psNO/m zI/vf9AfDNy7654ZWM2dzrFx+iksnJcB6ZcJ2LMl03wcIJxE3s3C5f0RPx+2bFc/UrMn Yb2BxiOj/NZhMp5PpmCcFdiL/KMXe1OkO5y9KcaxwsQRjUBgTZbZkiBdA5JQObNGI13t cJNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=UmojhtqB/2kgYwvLaiczALHqxM8c341rP1GYhTqnzXY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=XZpImzD8OE/H4VAHJc9u04CYFqFPmdyXYfGIIjYPh7RHM9h42HOZeV8AN8/di+rZgU itXu9BQQxLv4a7pSPMv1uUOr225Z0fQZTA2e6SHHNiNkNR/X92VOUCEIryzSLH2p4zX4 4No62yEvZykY7yLeRSROSq65tuKbi36Q/7pOETgQZ9CrQDzIw0J2eUMDw7l//nRKsADH pe/5QL/iyjP++slOHBZ4ua7j2KgMVmh0kzr8V8djzhyI9vcigxoD7SETkwjYvQqJmed6 HUeS59NYzvTxNKSFOQEnRWQjjA6pN2SnLWXdwlhK6EvJXPiEh9DE+xXTm6qFOlp3+Kwt OL3A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aYhSWXxH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y7-20020a0ceac7000000b0067f7e8b1e60si20079874qvp.311.2023.12.29.13.26.06 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:26:06 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=aYhSWXxH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKM6-0001Tt-Hj; Fri, 29 Dec 2023 16:25:22 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKM4-0001OC-Az for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:20 -0500 Received: from mail-il1-x134.google.com ([2607:f8b0:4864:20::134]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKM2-0007rx-8b for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:19 -0500 Received: by mail-il1-x134.google.com with SMTP id e9e14a558f8ab-35fcea0ac1aso35509955ab.1 for ; Fri, 29 Dec 2023 13:25:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885117; x=1704489917; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=UmojhtqB/2kgYwvLaiczALHqxM8c341rP1GYhTqnzXY=; b=aYhSWXxHou54bDtk4eJPGUKhMRdfsePrb9TJCRVQZJmzuozI8c5X14v062TMKDqkpF aBA3HWQVUl2cjjdov+n05ftkrd77blCgKfjNobduTC0DRNIJYi3JgBsdSWZAWLoCMhb+ urCBm/W5aKiKQe5dWy6yhKaYou5+U5xFHeKoVXhK+sF8dhUpa7f+VWE5SPHTziXOF0uN Z5ZnvPFomqADqyLDch1fdfaEnLjoibJIlBwKo5LMcG9+4YPAv6qiBHX/GvNYvvyyTGTC CqlNufNk+M2wZ9H0cFIyk/K0K5UM46G/PCARP/M+4zknJ3JVFjSljE/VFnNseprlH2Q1 HyZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885117; x=1704489917; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UmojhtqB/2kgYwvLaiczALHqxM8c341rP1GYhTqnzXY=; b=xARZkUtwF8nYYl7F2igqB4h1euKidGthJXLyRiQN/O4FMpP1IMgVexIA/eDCD8pt0o xdPthIe0luz69ActFSKNzKHIp5xA4Ia0pQjmiu7SOVGZRcXcvGA8cLZ0fNV3uOyw4pxz 9Cg8WflQCA7+CzuKf2cpTwUxUv3eTwfqRxLNhg2Gj//lHQf6e4jtL5uDRSwH2Kr/KEKs Lc0ZNU2VmPbiozuBho9FBPHmDT5Ju3mYK2tT8FdZbQ4yTNUQJjLliywhqPe4dcqYDYpJ teZnePX4Lcst7Cim74w/7agdquVHHXc+0WQshV3xg6Aap5ax3NKmWlycpvZvLgGH1wQ4 jCcA== X-Gm-Message-State: AOJu0YymKjQBtTNOnuQc9HPeXu0VOkCvmA9rWyhTEuEGoyjonDrFBjZa Z1/bOoCXRvxoqLqZzhwgHqZrIIRsiiHUp/CUxlJwrRa9UikKoA== X-Received: by 2002:a05:6e02:1caf:b0:360:d98:5387 with SMTP id x15-20020a056e021caf00b003600d985387mr6830555ill.122.1703885117296; Fri, 29 Dec 2023 13:25:17 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.15 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:16 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 36/71] hw/ipmi: Constify VMState Date: Sat, 30 Dec 2023 08:23:11 +1100 Message-Id: <20231229212346.147149-37-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::134; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x134.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-37-richard.henderson@linaro.org> --- hw/ipmi/ipmi_bmc_extern.c | 2 +- hw/ipmi/ipmi_bmc_sim.c | 2 +- hw/ipmi/ipmi_bt.c | 2 +- hw/ipmi/ipmi_kcs.c | 2 +- hw/ipmi/isa_ipmi_bt.c | 2 +- hw/ipmi/isa_ipmi_kcs.c | 2 +- hw/ipmi/pci_ipmi_bt.c | 2 +- hw/ipmi/pci_ipmi_kcs.c | 2 +- hw/ipmi/smbus_ipmi.c | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/hw/ipmi/ipmi_bmc_extern.c b/hw/ipmi/ipmi_bmc_extern.c index 2117dad35a..29c5af3cc3 100644 --- a/hw/ipmi/ipmi_bmc_extern.c +++ b/hw/ipmi/ipmi_bmc_extern.c @@ -479,7 +479,7 @@ static const VMStateDescription vmstate_ipmi_bmc_extern = { .version_id = 1, .minimum_version_id = 1, .post_load = ipmi_bmc_extern_post_migrate, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(send_reset, IPMIBmcExtern), VMSTATE_BOOL(waiting_rsp, IPMIBmcExtern), VMSTATE_END_OF_LIST() diff --git a/hw/ipmi/ipmi_bmc_sim.c b/hw/ipmi/ipmi_bmc_sim.c index 905e091094..33c839c65a 100644 --- a/hw/ipmi/ipmi_bmc_sim.c +++ b/hw/ipmi/ipmi_bmc_sim.c @@ -2103,7 +2103,7 @@ static const VMStateDescription vmstate_ipmi_sim = { .name = TYPE_IPMI_BMC_SIMULATOR, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(bmc_global_enables, IPMIBmcSim), VMSTATE_UINT8(msg_flags, IPMIBmcSim), VMSTATE_BOOL(watchdog_initialized, IPMIBmcSim), diff --git a/hw/ipmi/ipmi_bt.c b/hw/ipmi/ipmi_bt.c index 22f94fb98d..583fc64730 100644 --- a/hw/ipmi/ipmi_bt.c +++ b/hw/ipmi/ipmi_bt.c @@ -396,7 +396,7 @@ const VMStateDescription vmstate_IPMIBT = { .version_id = 1, .minimum_version_id = 1, .post_load = ipmi_bt_vmstate_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(obf_irq_set, IPMIBT), VMSTATE_BOOL(atn_irq_set, IPMIBT), VMSTATE_BOOL(irqs_enabled, IPMIBT), diff --git a/hw/ipmi/ipmi_kcs.c b/hw/ipmi/ipmi_kcs.c index a77612946a..c15977cab4 100644 --- a/hw/ipmi/ipmi_kcs.c +++ b/hw/ipmi/ipmi_kcs.c @@ -379,7 +379,7 @@ const VMStateDescription vmstate_IPMIKCS = { .version_id = 2, .minimum_version_id = 1, .post_load = ipmi_kcs_vmstate_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(obf_irq_set, IPMIKCS), VMSTATE_BOOL(atn_irq_set, IPMIKCS), VMSTATE_UNUSED_TEST(vmstate_kcs_before_version2, 1), /* Was use_irq */ diff --git a/hw/ipmi/isa_ipmi_bt.c b/hw/ipmi/isa_ipmi_bt.c index aec064d3cd..7b36d51494 100644 --- a/hw/ipmi/isa_ipmi_bt.c +++ b/hw/ipmi/isa_ipmi_bt.c @@ -77,7 +77,7 @@ static const VMStateDescription vmstate_ISAIPMIBTDevice = { * because it used VMSTATE_VBUFFER_UINT32, but it did not transfer * the buffer length, so random things would happen. */ - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(bt, ISAIPMIBTDevice, 1, vmstate_IPMIBT, IPMIBT), VMSTATE_END_OF_LIST() } diff --git a/hw/ipmi/isa_ipmi_kcs.c b/hw/ipmi/isa_ipmi_kcs.c index b5dcb64616..f52b32e590 100644 --- a/hw/ipmi/isa_ipmi_kcs.c +++ b/hw/ipmi/isa_ipmi_kcs.c @@ -76,7 +76,7 @@ static const VMStateDescription vmstate_ISAIPMIKCSDevice = { .name = TYPE_IPMI_INTERFACE, .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VSTRUCT_TEST(kcs, ISAIPMIKCSDevice, vmstate_kcs_before_version2, 0, vmstate_IPMIKCS, IPMIKCS, 1), VMSTATE_VSTRUCT_V(kcs, ISAIPMIKCSDevice, 2, vmstate_IPMIKCS, diff --git a/hw/ipmi/pci_ipmi_bt.c b/hw/ipmi/pci_ipmi_bt.c index 633931b825..afeea6f303 100644 --- a/hw/ipmi/pci_ipmi_bt.c +++ b/hw/ipmi/pci_ipmi_bt.c @@ -87,7 +87,7 @@ const VMStateDescription vmstate_PCIIPMIBTDevice = { .name = TYPE_IPMI_INTERFACE_PREFIX "pci-bt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCIIPMIBTDevice), VMSTATE_STRUCT(bt, PCIIPMIBTDevice, 1, vmstate_IPMIBT, IPMIBT), VMSTATE_END_OF_LIST() diff --git a/hw/ipmi/pci_ipmi_kcs.c b/hw/ipmi/pci_ipmi_kcs.c index 1a581413c2..05ba97ec58 100644 --- a/hw/ipmi/pci_ipmi_kcs.c +++ b/hw/ipmi/pci_ipmi_kcs.c @@ -87,7 +87,7 @@ const VMStateDescription vmstate_PCIIPMIKCSDevice = { .name = TYPE_IPMI_INTERFACE_PREFIX "pci-kcs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCIIPMIKCSDevice), VMSTATE_STRUCT(kcs, PCIIPMIKCSDevice, 1, vmstate_IPMIKCS, IPMIKCS), VMSTATE_END_OF_LIST() diff --git a/hw/ipmi/smbus_ipmi.c b/hw/ipmi/smbus_ipmi.c index d0991ab7f9..56865df7db 100644 --- a/hw/ipmi/smbus_ipmi.c +++ b/hw/ipmi/smbus_ipmi.c @@ -299,7 +299,7 @@ static const VMStateDescription vmstate_smbus_ipmi = { .name = TYPE_SMBUS_IPMI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SMBUS_DEVICE(parent, SMBusIPMIDevice), VMSTATE_UINT8(waiting_rsp, SMBusIPMIDevice), VMSTATE_UINT32(outlen, SMBusIPMIDevice), From patchwork Fri Dec 29 21:23:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758848 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672481wrw; Fri, 29 Dec 2023 13:31:51 -0800 (PST) X-Google-Smtp-Source: AGHT+IGG1z8cZw/Hyp6Kxnv6yGjwBBHT+SpnlI9Nz278fUyjKz6BLsXWhwL4k9gIh3b4iplxrUMf X-Received: by 2002:ac8:57d1:0:b0:428:c37:9846 with SMTP id w17-20020ac857d1000000b004280c379846mr701484qta.14.1703885511524; Fri, 29 Dec 2023 13:31:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885511; cv=none; d=google.com; s=arc-20160816; b=GDObVmM9oGeWQYSzMnsceCFkTiGMhb80eWfZRQ2kplnXw9SEXTynbbF+cabrSabJnE bjdEJX4UupUTQD9B+XIR17V3O3pUHES7FAAcQK+OhMIKJHEU6bIIBj4qJffWcnl3gBvZ hXjxPsIqk9hy4QV0ABdEDgYulLn4ONahogvptuCnwVnNpzISAFN2uYjyEIubm3QK0TIZ Xn1QuMjpEK9AitWSMD+g9w8VCn/io4HabOdBRFFAdRkdMxVd6q901BXoiIzssjXvR4tn Lx4TerHjG69I4EaROggHUWMF6c3Km3iPNr7z0iYM/uiiq6XblukbYZRobebWnSDSqyc4 KVEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=l3kpg/BKaYly+4qds3DN/RI8tOaGgyQRhusJUu7sn+4=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=AM8qiUECf2YX+lGNHZQ98sFPNigD6Nplc5aS2tDgAG+5LktR/xcCnSLgMXmkw00mfr uhKhg4YUyS9c/yN6dLMNBamErmVx/HR6abxoYtKwt+kTbhvW8gn2w7g7E0evg38KKBuq qoa/OKODe5H3AFqXLdtLL5vLAuc+OhftK1XB8U8aIsbfSW9f41sdF78VOsH/V46qIGDX m8Y2G/xTdgFVNrMstYEdKBKdbmVPha6f4aXm0NMp+QWzoUAUJIBRI0oVCAYeJvd3DJ6m pbEjSJc5IeC/MnbTrUY16EU4YSrCUeiFnBnjuI6V64VQM9502aO6ClEPMBT2KlTQhali 2Cfg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oW00ye9v; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id bw9-20020a05622a098900b00427f62df2fbsi5240027qtb.531.2023.12.29.13.31.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:51 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oW00ye9v; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKMa-0002AM-5A; Fri, 29 Dec 2023 16:25:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKM6-0001Vf-N4 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:22 -0500 Received: from mail-il1-x12e.google.com ([2607:f8b0:4864:20::12e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKM4-00080B-OZ for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:22 -0500 Received: by mail-il1-x12e.google.com with SMTP id e9e14a558f8ab-35feb61c91fso23482865ab.3 for ; Fri, 29 Dec 2023 13:25:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885119; x=1704489919; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=l3kpg/BKaYly+4qds3DN/RI8tOaGgyQRhusJUu7sn+4=; b=oW00ye9vap3W8I3Bu5JO6M3fyEx6XRcZQY5RWXxYlAHbNBCox4B7vG/s4UFARdBm9m fqCe0X8m8ZnQ+G2qmMZo4yxAbYRqDSXjWPY2C/3m1LqymWi/FidBdCvAzZoC1LHoOj4k ZHF2nlMfgIROwNGpPWY8eO4Z2aAyALwCIekVOykl91vYMTLyAwGXiGsKukooYrtaN6K1 TYEamriJ+9q/pEwNrnKMgCiCxAG4tJ1+c5mhGqGs95+7litN/mQ/jA0/N74THTbAIPdo drN4aHuNkrqDHcxMB3yzbv6FBixvfvZgHgM/M8tGT7SDGCUY7lfnlwSORzLTIj0RmS/f gdxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885119; x=1704489919; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=l3kpg/BKaYly+4qds3DN/RI8tOaGgyQRhusJUu7sn+4=; b=lF2oxiX/i7UR/vnY9DkhKBtbuylbyhxDwmQRWiOojDQ1xDbmSZy003dNoApnek0CYj lLPPpawg0Zgb8qnT22J1DJznRBxw8C2drUjALzD13nOoikNEwJI5SHKuHg3mwhNessUc ozO8ybkYwVRATeyLx+PJsVknWwqEB5qkvhj4Ctgy9LGOkQzZPk0tmGFQnn2hDTx+EhQM Ko0BXtMmiNFzRAiQWCYLRPp4SujDyCMwoBAtohntaRN/6vGE/sneDAANiVpeKIz3zLPR nkZyFlXyYB9DDYQYmXK4UejOYQ2hLoXStAxRaI4lag8wCdLU+79FbDQ9pJGBV+zqpkXy LcXw== X-Gm-Message-State: AOJu0Yz/6+EBkXiLshx3d1fTSgjNf2ajBZFz607ulh0lmza0hYYrYZqf 6Z4EUVv5WryerfK70K/DiK3x523Kwbaog7x7KUW1zJCQ6vqedA== X-Received: by 2002:a05:6e02:214e:b0:35f:da92:11e1 with SMTP id d14-20020a056e02214e00b0035fda9211e1mr10842543ilv.46.1703885119567; Fri, 29 Dec 2023 13:25:19 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:19 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 37/71] hw/isa: Constify VMState Date: Sat, 30 Dec 2023 08:23:12 +1100 Message-Id: <20231229212346.147149-38-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::12e; envelope-from=richard.henderson@linaro.org; helo=mail-il1-x12e.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-38-richard.henderson@linaro.org> --- hw/isa/apm.c | 2 +- hw/isa/i82378.c | 2 +- hw/isa/lpc_ich9.c | 8 ++++---- hw/isa/pc87312.c | 2 +- hw/isa/piix.c | 8 ++++---- hw/isa/vt82c686.c | 4 ++-- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/hw/isa/apm.c b/hw/isa/apm.c index dfe9020d30..e34edb864c 100644 --- a/hw/isa/apm.c +++ b/hw/isa/apm.c @@ -68,7 +68,7 @@ const VMStateDescription vmstate_apm = { .name = "APM State", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(apmc, APMState), VMSTATE_UINT8(apms, APMState), VMSTATE_END_OF_LIST() diff --git a/hw/isa/i82378.c b/hw/isa/i82378.c index 203b92c264..cbaa152a89 100644 --- a/hw/isa/i82378.c +++ b/hw/isa/i82378.c @@ -40,7 +40,7 @@ static const VMStateDescription vmstate_i82378 = { .name = "pci-i82378", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, I82378State), VMSTATE_END_OF_LIST() }, diff --git a/hw/isa/lpc_ich9.c b/hw/isa/lpc_ich9.c index 23eba64f22..3924eec483 100644 --- a/hw/isa/lpc_ich9.c +++ b/hw/isa/lpc_ich9.c @@ -768,7 +768,7 @@ static const VMStateDescription vmstate_ich9_rst_cnt = { .version_id = 1, .minimum_version_id = 1, .needed = ich9_rst_cnt_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(rst_cnt, ICH9LPCState), VMSTATE_END_OF_LIST() } @@ -788,7 +788,7 @@ static const VMStateDescription vmstate_ich9_smi_feat = { .version_id = 1, .minimum_version_id = 1, .needed = ich9_smi_feat_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(smi_guest_features_le, ICH9LPCState, sizeof(uint64_t)), VMSTATE_UINT8(smi_features_ok, ICH9LPCState), @@ -802,7 +802,7 @@ static const VMStateDescription vmstate_ich9_lpc = { .version_id = 1, .minimum_version_id = 1, .post_load = ich9_lpc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(d, ICH9LPCState), VMSTATE_STRUCT(apm, ICH9LPCState, 0, vmstate_apm, APMState), VMSTATE_STRUCT(pm, ICH9LPCState, 0, vmstate_ich9_pm, ICH9LPCPMRegs), @@ -810,7 +810,7 @@ static const VMStateDescription vmstate_ich9_lpc = { VMSTATE_UINT32(sci_level, ICH9LPCState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_ich9_rst_cnt, &vmstate_ich9_smi_feat, NULL diff --git a/hw/isa/pc87312.c b/hw/isa/pc87312.c index 8d7b8d3db2..ee23f3e164 100644 --- a/hw/isa/pc87312.c +++ b/hw/isa/pc87312.c @@ -319,7 +319,7 @@ static const VMStateDescription vmstate_pc87312 = { .version_id = 1, .minimum_version_id = 1, .post_load = pc87312_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(read_id_step, PC87312State), VMSTATE_UINT8(selected_index, PC87312State), VMSTATE_UINT8_ARRAY(regs, PC87312State, 3), diff --git a/hw/isa/piix.c b/hw/isa/piix.c index 04ebed5b52..344bf32e54 100644 --- a/hw/isa/piix.c +++ b/hw/isa/piix.c @@ -230,7 +230,7 @@ static const VMStateDescription vmstate_piix3_rcr = { .version_id = 1, .minimum_version_id = 1, .needed = piix3_rcr_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(rcr, PIIXState), VMSTATE_END_OF_LIST() } @@ -242,13 +242,13 @@ static const VMStateDescription vmstate_piix3 = { .minimum_version_id = 2, .post_load = piix_post_load, .pre_save = piix3_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PIIXState), VMSTATE_INT32_ARRAY_V(pci_irq_levels_vmstate, PIIXState, PIIX_NUM_PIRQS, 3), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_piix3_rcr, NULL } @@ -259,7 +259,7 @@ static const VMStateDescription vmstate_piix4 = { .version_id = 3, .minimum_version_id = 2, .post_load = piix4_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PIIXState), VMSTATE_UINT8_V(rcr, PIIXState, 3), VMSTATE_END_OF_LIST() diff --git a/hw/isa/vt82c686.c b/hw/isa/vt82c686.c index 9c2333a277..d3e0f6d01f 100644 --- a/hw/isa/vt82c686.c +++ b/hw/isa/vt82c686.c @@ -82,7 +82,7 @@ static const VMStateDescription vmstate_acpi = { .version_id = 1, .minimum_version_id = 1, .post_load = vmstate_acpi_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, ViaPMState), VMSTATE_UINT16(ar.pm1.evt.sts, ViaPMState), VMSTATE_UINT16(ar.pm1.evt.en, ViaPMState), @@ -563,7 +563,7 @@ static const VMStateDescription vmstate_via = { .name = "via-isa", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, ViaISAState), VMSTATE_END_OF_LIST() } From patchwork Fri Dec 29 21:23:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758860 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4673117wrw; Fri, 29 Dec 2023 13:34:16 -0800 (PST) X-Google-Smtp-Source: AGHT+IEFiwXpP1ckvzDBUXHJrUxGpPwOrlsqNog4/95qdelkNSR6WnKTXmGKzIiFpenOV+5mckbf X-Received: by 2002:ac8:4603:0:b0:427:fa8c:82a7 with SMTP id p3-20020ac84603000000b00427fa8c82a7mr4251037qtn.44.1703885655858; Fri, 29 Dec 2023 13:34:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885655; cv=none; d=google.com; s=arc-20160816; b=NFR/SUtoSCa246zbN9zoouy0PNLB+Sqlm49mNzU3avdgUzm9dH5MCSWENUCFI39KZf 4ROoY4/YJWU0x2zQYXvrtZ6J4BOjFaLTe3YxQoyybuwUg2VtGyh6UzRh5UZizmRzF30M B+XvFKJy9hZp5X8IL/YDT0PThgVERSha2j+29KpUfwapkCp0xTxYiAUmPtFYPhvOrsDd N5cyuYp4lv9Cr9MxASKCkqiyqKseaolbo85YowH5v7tPM5EJ/0LOYm+uAcQd1y35QROq 86tRfr+7XD7oqtgyyT2ypxZijiBrHe7Loe9Kp2AglJH6kNPu0J+/q0B3cTFBvomHbPzz Z63g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=G7X80Y/pAYkS9ptMo/yJ1dNZkar4tYwTu/+PVpKo0ts=; fh=KXT8skN7RFTc7N6YjUNlSMSjM9WXZW43UAg6bOEDSoc=; b=GhLU1338HCMe7YhRyvYEUOG+KbSJO10gzgYLxg7shjE6rzqcTUVox5tEw7K66A+QTb KfzAy/bhVzFp0NMdQnrqdEocLutT/cLG9vnwlGyOuDYeWCAQ6CQAPkPsXBNGN+/Q73kM TEE3OM25aBf5mAjXlPhoIRk8Z/1qnKzyGo8CUxp2Plcggn270yFNsfbfC0v9sOuF6mhJ cw2q4YH9YfVb3alvDykZnS2k8BwDfsEUR2rITzzQzM/9ValPf/C/DpMD38mRvcMjz2ku FCoUbDk89ZOng3YMg3lI0vfkT1QmkJxS4TDsuzOdQuTtbp1dhcHsCxo+aEjbYs0vQSzR Bikg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hIUuqALj; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i17-20020ac85c11000000b00427f5df7de2si4985998qti.348.2023.12.29.13.34.15 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:34:15 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hIUuqALj; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKMZ-00027F-4M; Fri, 29 Dec 2023 16:25:51 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKMB-0001Yt-LC for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:30 -0500 Received: from mail-pf1-x42c.google.com ([2607:f8b0:4864:20::42c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKM8-00086T-Iq for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:25 -0500 Received: by mail-pf1-x42c.google.com with SMTP id d2e1a72fcca58-6d9b2c8e2a4so2694268b3a.0 for ; Fri, 29 Dec 2023 13:25:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885122; x=1704489922; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=G7X80Y/pAYkS9ptMo/yJ1dNZkar4tYwTu/+PVpKo0ts=; b=hIUuqALjDOrX3i6FzaJYHa0WsCMrWrYhyqzf6RU2EV9ZJ5aZd/sVWb+OodLIUT11b5 nmP5dFFbNVGXn6TIwLIyW9UH0zRACuBqzJzMnx0vxhNU3kNXKN2XH5VuFNlV7B9Ftj7w 1W9l2oSC1K0b70KE1yP07sGomL9DMQD8ozlltkgiQ3zh+UfniLgWxL/jihmwnsT4kRJR rzh2sYmmhv60fi3onoqmWDPz5eumOyx8B0wumVN3gLJMtMclg1q+tygqTN1GMTbRV3c0 El49GpDXlM7mk9+U9kYlifAQNZtHNGoxgG/s8O3MHfPIHP7CBoF4xUrGT0d7vEv0VCgl GEOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885122; x=1704489922; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=G7X80Y/pAYkS9ptMo/yJ1dNZkar4tYwTu/+PVpKo0ts=; b=OjJOaGq3/HsLw62qULfjc9XcMjQHmQlvfNbMlR4itcC2IoSGhb/CGQpToFXWwpPI4c aeSCDvQg56Vo7Xl1svlZj7NhwgWmy8IQUyYh9PjfW3nOGgtUSXdvLNAjWVbxEjcu4nU1 uBMAGPIdynfttHLPP17+Ms5aWyXZCL0TTF6oFxY87nbDoHauj4knBmHsq66lOkUw+lXd Uyp21jnzIYFoNevO2rxDYXU432ZG4jXHIYCVLz+YSgVY8ga934srzETUZ8Uu9lT1CIi8 ML6rob/r7lCTkNEAzIFEysxXM3eZIKHS0UUNCl/H/ysuS9MZUbaqPgCJchMmjHE63Lv5 C02A== X-Gm-Message-State: AOJu0YzdQwQmR04NPAATJgVKQ5M3Ywiw98f+Vx466ipJT1ekJNnAmbiS I9leuZypWGP+/oT/p3kGNzJITyegyfVoM8S6CuVdXpKx1z6Ekw== X-Received: by 2002:a05:6a20:3955:b0:196:21f5:7aff with SMTP id r21-20020a056a20395500b0019621f57affmr5295128pzg.47.1703885121992; Fri, 29 Dec 2023 13:25:21 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:21 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Song Gao Subject: [PULL 38/71] hw/loongarch: Constify VMState Date: Sat, 30 Dec 2023 08:23:13 +1100 Message-Id: <20231229212346.147149-39-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42c; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Reviewed-by: Song Gao Message-Id: <20231221031652.119827-39-richard.henderson@linaro.org> --- hw/loongarch/acpi-build.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/loongarch/acpi-build.c b/hw/loongarch/acpi-build.c index ae292fc543..730bc4a748 100644 --- a/hw/loongarch/acpi-build.c +++ b/hw/loongarch/acpi-build.c @@ -564,7 +564,7 @@ static const VMStateDescription vmstate_acpi_build = { .name = "acpi_build", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(patched, AcpiBuildState), VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758808 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671427wrw; Fri, 29 Dec 2023 13:27:53 -0800 (PST) X-Google-Smtp-Source: AGHT+IGS/SIhOzBGoH2dJ+DmRwwaIRCNCqpSjVBJNFenR0V9bjhGpzNztyE875r/3w7aAAoRiaVv X-Received: by 2002:a05:620a:2104:b0:781:5fec:57a5 with SMTP id l4-20020a05620a210400b007815fec57a5mr5404692qkl.76.1703885273517; Fri, 29 Dec 2023 13:27:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885273; cv=none; d=google.com; s=arc-20160816; b=ONTdy1bhT3xlmBF1emE19P15iHL7z0rlgkX8H4mxirtAfjfxMIQVXWWSzRE45AvFsj t/e+q2K60zGPjzaZ23t4EEfi6UAqeAo9AKQO6EJmjjULGmVXxfbhKlAWXY7I+Vgu6pGv x2bvT5XKwGEpPsi1c+e68V6KLQc4LrlY66i/O/eE5hdHg8HrnDurpRM1ZS5p43b8bhGD 6CYi+PDob9tc9JhCgHsLyHIkmff4oWSBQhtZTIO6fuc4tG+z4AbQ/Dfxi2WRYTzjvH2x eE93hodLYBwLZUttyHGI3tBGHMKkmARF2ILntstigXlJZnpwYwTuliWOp3p8bR3yHy/p 4UPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=BjXj4u95pV2k58Z8fsH2ZnhnBu4eBDV3ePIvCvfEGnQ=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=bXudhJEcxDMF9Pn1cew/8tCsauba4lxfLmAy5xxrZQUFYIEd1UfGMH3SY7W5a4rVdK cNyw8DoRXKvEH7JLmDGmRJJT+roCuGdavxCpjefUDgMoGrhleaBpqcG3EfMks/USuDdn qZe2g0lLcVKZdwv+sH3mkOIRbuiY78Xm0FzFaUHsc0UbwkkPddi5kiS7dydZucYT1hth TsZpzjzO2aCJpUBjGvsJF6EIe9ZtOWukRZArJG1K9c/7w6+qwUVVAVU8WT7vHAKfKU9L iXDh+Kdik1zpBY6T6VSf8Q7tV0gEOPzaaxhAF19b53ponwyTXik/QXDI3uhrlj1S+SFO 3d1A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BnYKIYId; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id s25-20020a05620a031900b0077dcaf5a910si19012479qkm.589.2023.12.29.13.27.53 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:27:53 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BnYKIYId; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKMW-0001qw-Bv; Fri, 29 Dec 2023 16:25:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKMB-0001Yu-MP for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:30 -0500 Received: from mail-oa1-x29.google.com ([2001:4860:4864:20::29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKM9-0008C4-6p for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:25:27 -0500 Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-204fdd685fdso1196072fac.2 for ; Fri, 29 Dec 2023 13:25:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885124; x=1704489924; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=BjXj4u95pV2k58Z8fsH2ZnhnBu4eBDV3ePIvCvfEGnQ=; b=BnYKIYIdmd/L6ZpFNisWCzjog/cLhHLYUT2ujsJ/HtKFZYDGHC/uYN54HjgK9hImXv 19hw1hV78bMyeyYfNxp24dgtjGnoZl5I78/p49u4GyyTjzKjGEsyefuJJPwjJ+iBNDsD 1JW/1UpT40q17LV+fs4D6lCPsVEdiSksWDqRLmg+3spsRy8LuSnCumVfu8e0Vo00+YMq x3ocnyTmT4gEQETAbYgLZu774WKxJZdtCWdjXDGM9em2KHe8GhcPWtkpS5/KY6KIEvow 1jd+Q29Q1uvWWp6F9RWAEZef5AeW2M5t43XJ2ifJ4oZFpPWZwoMDzxs1UPQ3CkXAmJsS B/gA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885124; x=1704489924; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BjXj4u95pV2k58Z8fsH2ZnhnBu4eBDV3ePIvCvfEGnQ=; b=mSlRb1lOD/GyTswRQe9xjLDlhzLH63DUXKpqQViTKwClIWgvcNrx4uSM+OUK6T1/QT lk/B56fcdUdY2qeYBetioV0fjyjtIz/o8NY+qaTX+I0Q5QOy3M/JjVoqQ3WcpYJcG30H YEmM2yKmdCCFXNbRNSq0xHSXDgzRQSYSo6ua6KaO16eSnI/PhosnjnhzbzEjEXvnK/Vr /apkhsZEfT+MPO+62GOsoOhcmvzeV4J3XejBxtXFJYGvpkIS1zFHahcMVggXwZJwfBS7 QpJkKchlze3znuVLOVkjy92W6+vWF5GphLfusAlfEKyW63xX2HUOK5lcJPPy2ELYrzLu Hm7Q== X-Gm-Message-State: AOJu0Ywop9bC8FYwDR16IOBAPifaeJVn7prSFYAw2uqfCF0BCUxPt9oo PmtvesreZqIPmohu9Rn3DQHR9AjwYkYyASA6ctnej7bQdhHMdw== X-Received: by 2002:a05:6870:b4a6:b0:1fb:75c:3fdf with SMTP id y38-20020a056870b4a600b001fb075c3fdfmr17158247oap.63.1703885123957; Fri, 29 Dec 2023 13:25:23 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id a34-20020a631a22000000b005c65e82a0cbsm15016237pga.17.2023.12.29.13.25.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:25:23 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 39/71] hw/m68k: Constify VMState Date: Sat, 30 Dec 2023 08:23:14 +1100 Message-Id: <20231229212346.147149-40-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::29; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x29.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-40-richard.henderson@linaro.org> --- hw/m68k/next-cube.c | 4 ++-- hw/m68k/q800-glue.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/m68k/next-cube.c b/hw/m68k/next-cube.c index 292f13defb..9f6f90d68b 100644 --- a/hw/m68k/next-cube.c +++ b/hw/m68k/next-cube.c @@ -923,7 +923,7 @@ static const VMStateDescription next_rtc_vmstate = { .name = "next-rtc", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT8(phase, NextRtc), VMSTATE_UINT8_ARRAY(ram, NextRtc, 32), VMSTATE_UINT8(command, NextRtc), @@ -939,7 +939,7 @@ static const VMStateDescription next_pc_vmstate = { .name = "next-pc", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(scr1, NeXTPC), VMSTATE_UINT32(scr2, NeXTPC), VMSTATE_UINT32(old_scr2, NeXTPC), diff --git a/hw/m68k/q800-glue.c b/hw/m68k/q800-glue.c index f413b1599a..b5a7713863 100644 --- a/hw/m68k/q800-glue.c +++ b/hw/m68k/q800-glue.c @@ -189,7 +189,7 @@ static const VMStateDescription vmstate_glue = { .name = "q800-glue", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(ipr, GLUEState), VMSTATE_UINT8(auxmode, GLUEState), VMSTATE_TIMER_PTR(nmi_release, GLUEState), From patchwork Fri Dec 29 21:23:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758821 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671736wrw; Fri, 29 Dec 2023 13:29:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IFNREMMhKLnYDZfUNBaWHLOqKfn5S5i4SLYa15EteKBbNwymYbaXZBQwLBAfE6jLCc7c+Bi X-Received: by 2002:ac8:6684:0:b0:427:f034:4c38 with SMTP id d4-20020ac86684000000b00427f0344c38mr5751818qtp.28.1703885350587; Fri, 29 Dec 2023 13:29:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885350; cv=none; d=google.com; s=arc-20160816; b=ZWedKE69mRsXYt/NohZmelWLfMdGYF9r7SgUDASg2nEh+z5CfROYvLv+XFMPQ+4MDs iQmMbWlZ0Wgaz1PUdfq09+piD4jonCXzf6G64micN82XVvMBhWfI8gun44AXmFfbx0ul ZMpQPZcgjFuZ5mZYC4ha/9h2ttdEBO+884+0Ua+tniyY7OM4f/Y5sMKbdZ3oqwQZR85c yPa+IGn5X/SZAT2VZ93hLr0ZmnGU3xltEuFgT/RrmynwRmaRG100yrYRQ5e+gYfIEJz2 ec4NdH/m1hXx6nzfGMc+ZYYo3zIR1C8U9UGfOEz1iQC/cjNgl8BVbuJo0wZzzjwqRGxX Xzdw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=EfkRGSf0CkBRN5i/7Ek8SCwcjwSIpAV2/kJznqWEe1A=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=aJ+Ux2eBnHmf5Tjlf2k9j03iL/XPOQFtAIsbUl+Z9aqOgi9iESo0rWeZbpFbn1NUzL bqE8f9G50Y7+7nXynE4IDn6zgRWFVIHvXDZo/s8etXG8+txskvvDYMX3gYXYRkCpb3wX ADvcVQCi9su27QwALtScH+82g3QyzBWNpj012bU/lNLlbXzqaKjOrN2B+ZZrRjbeEP30 ADsIplrJza/uvW7d+iiBThP44qRe3P9Kv9hcOc6W6O63/Nd3fSygzyTnn3w8Y5co0cPH MUbqHVFC3gnm715T+aA4AAFMKjhuGyAZLrHlBPow40YcF2KM9nIiufLyK5h/c3bHL4N0 U9gA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zVyGnwH4; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id y17-20020a05622a121100b00427f0321be1si6175654qtx.62.2023.12.29.13.29.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:10 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=zVyGnwH4; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPI-0005A0-Hg; Fri, 29 Dec 2023 16:28:42 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPD-0004qj-VE for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:36 -0500 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKP9-0000JK-DY for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:35 -0500 Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-6d9b2c8e2a4so2695123b3a.0 for ; Fri, 29 Dec 2023 13:28:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885310; x=1704490110; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=EfkRGSf0CkBRN5i/7Ek8SCwcjwSIpAV2/kJznqWEe1A=; b=zVyGnwH4YhAfgJBJ/VC9wMO2q/gY72/2tXgTZ9V4eji2jYJZPE5o1aF1TQoe1v/JZX 8t/Y87JDFzse8w9OP9VSVuejugnQD4GUHvJLd9L0+WzhFuRhMgY2WnwRneB/8vSniE7M fDcGjvSW8GwZ3K3mndXJHObOOKtDR7gcuAXB0P8rbiEwFEfPxGVbK+R78pKykukkXswt mtZdj/geKq05Sbbof40mK/ODRCIJ0BN++b4GxCjSGffJj7QdGCST7Eu1twCd9NDyb+EX c51IlHgYC1BrkQVnYQXtH1eXUsSXXRz6al4aB3Ajd8w/6EufE7rLpoW8libUm1kOJfzR kL+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885310; x=1704490110; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EfkRGSf0CkBRN5i/7Ek8SCwcjwSIpAV2/kJznqWEe1A=; b=iWbJ8H6Tl7eeYgj0UvDwb5lQSAD6MykT6RXH8jp1tEW1lZS9MPRT+8Enfg3TPZnSbK X4fkRnpKoBYmX5Y2cdMh5K8pbhIl28hnmlz34kMdqfP59HVstXfF4eFYArBIofxq24Dt lqYlWerz3pxZLZFor2xp2YHKe54kJMpSyyEAwHBrGHpxLP7mX6e7v4b8yXkeVgocvH0c +MA9CRwgq7jJrRug7CN0skjFOED7KvbcNVgK3N0blbJ6A8l0yEKP/uqcU0TGPyzjPAw7 VSGgKTi4qkJHwBEK1isU5HjTdS8KKgBXair46p+VvCRLY/0vcBEMlRzJ0CdzMpWXYj4x cqfA== X-Gm-Message-State: AOJu0YxS9ogMItyj6i47cpiPo9t0CfPBxXavHlp03i8udS1T4UMuGV8K DTvhSGZAgDEEaxPAJqiWtDrH34stak56m1lP7mprJTF1mz7p6A== X-Received: by 2002:a05:6a20:430a:b0:196:9a3d:b107 with SMTP id h10-20020a056a20430a00b001969a3db107mr948259pzk.4.1703885309713; Fri, 29 Dec 2023 13:28:29 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:29 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 40/71] hw/misc: Constify VMState Date: Sat, 30 Dec 2023 08:23:15 +1100 Message-Id: <20231229212346.147149-41-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::436; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x436.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-41-richard.henderson@linaro.org> --- hw/misc/a9scu.c | 2 +- hw/misc/allwinner-a10-ccm.c | 2 +- hw/misc/allwinner-a10-dramc.c | 2 +- hw/misc/allwinner-cpucfg.c | 2 +- hw/misc/allwinner-h3-ccu.c | 2 +- hw/misc/allwinner-h3-dramc.c | 2 +- hw/misc/allwinner-h3-sysctrl.c | 2 +- hw/misc/allwinner-r40-ccu.c | 2 +- hw/misc/allwinner-r40-dramc.c | 2 +- hw/misc/allwinner-sid.c | 2 +- hw/misc/allwinner-sramc.c | 2 +- hw/misc/arm_l2x0.c | 2 +- hw/misc/arm_sysctl.c | 2 +- hw/misc/armsse-cpu-pwrctrl.c | 2 +- hw/misc/armsse-mhu.c | 2 +- hw/misc/aspeed_hace.c | 2 +- hw/misc/aspeed_i3c.c | 4 ++-- hw/misc/aspeed_lpc.c | 2 +- hw/misc/aspeed_sbc.c | 2 +- hw/misc/aspeed_scu.c | 2 +- hw/misc/aspeed_sdmc.c | 2 +- hw/misc/aspeed_xdma.c | 2 +- hw/misc/axp2xx.c | 2 +- hw/misc/bcm2835_cprman.c | 10 +++++----- hw/misc/bcm2835_mbox.c | 4 ++-- hw/misc/bcm2835_mphi.c | 2 +- hw/misc/bcm2835_powermgt.c | 2 +- hw/misc/bcm2835_property.c | 2 +- hw/misc/bcm2835_rng.c | 2 +- hw/misc/bcm2835_thermal.c | 2 +- hw/misc/djmemc.c | 2 +- hw/misc/eccmemctl.c | 2 +- hw/misc/exynos4210_clk.c | 2 +- hw/misc/exynos4210_pmu.c | 2 +- hw/misc/exynos4210_rng.c | 2 +- hw/misc/imx25_ccm.c | 2 +- hw/misc/imx31_ccm.c | 2 +- hw/misc/imx6_ccm.c | 2 +- hw/misc/imx6_src.c | 2 +- hw/misc/imx6ul_ccm.c | 2 +- hw/misc/imx7_ccm.c | 4 ++-- hw/misc/imx7_snvs.c | 2 +- hw/misc/imx7_src.c | 2 +- hw/misc/imx_rngc.c | 2 +- hw/misc/iosb.c | 2 +- hw/misc/iotkit-secctl.c | 10 +++++----- hw/misc/iotkit-sysctl.c | 8 ++++---- hw/misc/ivshmem.c | 4 ++-- hw/misc/lasi.c | 2 +- hw/misc/led.c | 2 +- hw/misc/mac_via.c | 4 ++-- hw/misc/mips_cmgcr.c | 2 +- hw/misc/mips_cpc.c | 2 +- hw/misc/mos6522.c | 4 ++-- hw/misc/mps2-fpgaio.c | 2 +- hw/misc/mps2-scc.c | 2 +- hw/misc/msf2-sysreg.c | 2 +- hw/misc/mst_fpga.c | 2 +- hw/misc/npcm7xx_clk.c | 8 ++++---- hw/misc/npcm7xx_gcr.c | 2 +- hw/misc/npcm7xx_mft.c | 2 +- hw/misc/npcm7xx_pwm.c | 4 ++-- hw/misc/npcm7xx_rng.c | 2 +- hw/misc/nrf51_rng.c | 2 +- hw/misc/pca9552.c | 2 +- hw/misc/pvpanic-pci.c | 2 +- hw/misc/slavio_misc.c | 2 +- hw/misc/stm32f4xx_exti.c | 2 +- hw/misc/stm32f4xx_syscfg.c | 2 +- hw/misc/tz-mpc.c | 2 +- hw/misc/tz-msc.c | 2 +- hw/misc/tz-ppc.c | 2 +- hw/misc/virt_ctrl.c | 2 +- hw/misc/vmcoreinfo.c | 2 +- hw/misc/xlnx-versal-cframe-reg.c | 6 +++--- hw/misc/xlnx-versal-cfu.c | 6 +++--- hw/misc/xlnx-versal-crl.c | 2 +- hw/misc/xlnx-versal-pmc-iou-slcr.c | 2 +- hw/misc/xlnx-versal-trng.c | 2 +- hw/misc/xlnx-versal-xramc.c | 2 +- hw/misc/xlnx-zynqmp-apu-ctrl.c | 2 +- hw/misc/xlnx-zynqmp-crf.c | 2 +- hw/misc/zynq_slcr.c | 2 +- 83 files changed, 108 insertions(+), 108 deletions(-) diff --git a/hw/misc/a9scu.c b/hw/misc/a9scu.c index a375ebc987..04225dfb78 100644 --- a/hw/misc/a9scu.c +++ b/hw/misc/a9scu.c @@ -116,7 +116,7 @@ static const VMStateDescription vmstate_a9_scu = { .name = "a9-scu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, A9SCUState), VMSTATE_UINT32(status, A9SCUState), VMSTATE_END_OF_LIST() diff --git a/hw/misc/allwinner-a10-ccm.c b/hw/misc/allwinner-a10-ccm.c index 68146ee340..575b018952 100644 --- a/hw/misc/allwinner-a10-ccm.c +++ b/hw/misc/allwinner-a10-ccm.c @@ -193,7 +193,7 @@ static const VMStateDescription allwinner_a10_ccm_vmstate = { .name = "allwinner-a10-ccm", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwA10ClockCtlState, AW_A10_CCM_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/allwinner-a10-dramc.c b/hw/misc/allwinner-a10-dramc.c index e118b0c2fd..a7c58fa6d0 100644 --- a/hw/misc/allwinner-a10-dramc.c +++ b/hw/misc/allwinner-a10-dramc.c @@ -147,7 +147,7 @@ static const VMStateDescription allwinner_a10_dramc_vmstate = { .name = "allwinner-a10-dramc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwA10DramControllerState, AW_A10_DRAMC_REGS_NUM), VMSTATE_END_OF_LIST() diff --git a/hw/misc/allwinner-cpucfg.c b/hw/misc/allwinner-cpucfg.c index bbd33a7dac..31b9780969 100644 --- a/hw/misc/allwinner-cpucfg.c +++ b/hw/misc/allwinner-cpucfg.c @@ -250,7 +250,7 @@ static const VMStateDescription allwinner_cpucfg_vmstate = { .name = "allwinner-cpucfg", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(gen_ctrl, AwCpuCfgState), VMSTATE_UINT32(super_standby, AwCpuCfgState), VMSTATE_UINT32(entry_addr, AwCpuCfgState), diff --git a/hw/misc/allwinner-h3-ccu.c b/hw/misc/allwinner-h3-ccu.c index 18d1074545..cfc68522d3 100644 --- a/hw/misc/allwinner-h3-ccu.c +++ b/hw/misc/allwinner-h3-ccu.c @@ -212,7 +212,7 @@ static const VMStateDescription allwinner_h3_ccu_vmstate = { .name = "allwinner-h3-ccu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwH3ClockCtlState, AW_H3_CCU_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/allwinner-h3-dramc.c b/hw/misc/allwinner-h3-dramc.c index 1d37cf422c..e168ffe623 100644 --- a/hw/misc/allwinner-h3-dramc.c +++ b/hw/misc/allwinner-h3-dramc.c @@ -324,7 +324,7 @@ static const VMStateDescription allwinner_h3_dramc_vmstate = { .name = "allwinner-h3-dramc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(dramcom, AwH3DramCtlState, AW_H3_DRAMCOM_REGS_NUM), VMSTATE_UINT32_ARRAY(dramctl, AwH3DramCtlState, AW_H3_DRAMCTL_REGS_NUM), VMSTATE_UINT32_ARRAY(dramphy, AwH3DramCtlState, AW_H3_DRAMPHY_REGS_NUM), diff --git a/hw/misc/allwinner-h3-sysctrl.c b/hw/misc/allwinner-h3-sysctrl.c index 1d07efa880..2d29be83e3 100644 --- a/hw/misc/allwinner-h3-sysctrl.c +++ b/hw/misc/allwinner-h3-sysctrl.c @@ -110,7 +110,7 @@ static const VMStateDescription allwinner_h3_sysctrl_vmstate = { .name = "allwinner-h3-sysctrl", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwH3SysCtrlState, AW_H3_SYSCTRL_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/allwinner-r40-ccu.c b/hw/misc/allwinner-r40-ccu.c index d82fee12db..33baf4429d 100644 --- a/hw/misc/allwinner-r40-ccu.c +++ b/hw/misc/allwinner-r40-ccu.c @@ -179,7 +179,7 @@ static const VMStateDescription allwinner_r40_ccu_vmstate = { .name = "allwinner-r40-ccu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwR40ClockCtlState, AW_R40_CCU_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/allwinner-r40-dramc.c b/hw/misc/allwinner-r40-dramc.c index 3d81ddb2e1..75b0bef4fd 100644 --- a/hw/misc/allwinner-r40-dramc.c +++ b/hw/misc/allwinner-r40-dramc.c @@ -474,7 +474,7 @@ static const VMStateDescription allwinner_r40_dramc_vmstate = { .name = "allwinner-r40-dramc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(dramcom, AwR40DramCtlState, AW_R40_DRAMCOM_REGS_NUM), VMSTATE_UINT32_ARRAY(dramctl, AwR40DramCtlState, diff --git a/hw/misc/allwinner-sid.c b/hw/misc/allwinner-sid.c index 6d61f55b1d..e5cd431743 100644 --- a/hw/misc/allwinner-sid.c +++ b/hw/misc/allwinner-sid.c @@ -136,7 +136,7 @@ static const VMStateDescription allwinner_sid_vmstate = { .name = "allwinner-sid", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, AwSidState), VMSTATE_UINT32(rdkey, AwSidState), VMSTATE_UINT8_ARRAY_V(identifier.data, AwSidState, sizeof(QemuUUID), 1), diff --git a/hw/misc/allwinner-sramc.c b/hw/misc/allwinner-sramc.c index d76c24d081..cf10ca8ffe 100644 --- a/hw/misc/allwinner-sramc.c +++ b/hw/misc/allwinner-sramc.c @@ -116,7 +116,7 @@ static const VMStateDescription allwinner_sramc_vmstate = { .name = "allwinner-sramc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(sram_ver, AwSRAMCState), VMSTATE_UINT32(sram_soft_entry_reg0, AwSRAMCState), VMSTATE_END_OF_LIST() diff --git a/hw/misc/arm_l2x0.c b/hw/misc/arm_l2x0.c index 75c3eb8982..b14d0a2676 100644 --- a/hw/misc/arm_l2x0.c +++ b/hw/misc/arm_l2x0.c @@ -49,7 +49,7 @@ static const VMStateDescription vmstate_l2x0 = { .name = "l2x0", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctrl, L2x0State), VMSTATE_UINT32(aux_ctrl, L2x0State), VMSTATE_UINT32(data_ctrl, L2x0State), diff --git a/hw/misc/arm_sysctl.c b/hw/misc/arm_sysctl.c index 3e4f4b0524..5108f3eda9 100644 --- a/hw/misc/arm_sysctl.c +++ b/hw/misc/arm_sysctl.c @@ -57,7 +57,7 @@ static const VMStateDescription vmstate_arm_sysctl = { .name = "realview_sysctl", .version_id = 4, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(leds, arm_sysctl_state), VMSTATE_UINT16(lockval, arm_sysctl_state), VMSTATE_UINT32(cfgdata1, arm_sysctl_state), diff --git a/hw/misc/armsse-cpu-pwrctrl.c b/hw/misc/armsse-cpu-pwrctrl.c index 42fc38879f..bfc51d175c 100644 --- a/hw/misc/armsse-cpu-pwrctrl.c +++ b/hw/misc/armsse-cpu-pwrctrl.c @@ -109,7 +109,7 @@ static const VMStateDescription pwrctrl_vmstate = { .name = "armsse-cpu-pwrctrl", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cpupwrcfg, ARMSSECPUPwrCtrl), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/armsse-mhu.c b/hw/misc/armsse-mhu.c index 0be7f0fc87..55625b2cca 100644 --- a/hw/misc/armsse-mhu.c +++ b/hw/misc/armsse-mhu.c @@ -157,7 +157,7 @@ static const VMStateDescription armsse_mhu_vmstate = { .name = "armsse-mhu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cpu0intr, ARMSSEMHU), VMSTATE_UINT32(cpu1intr, ARMSSEMHU), VMSTATE_END_OF_LIST() diff --git a/hw/misc/aspeed_hace.c b/hw/misc/aspeed_hace.c index b07506ec04..c06c04ddc6 100644 --- a/hw/misc/aspeed_hace.c +++ b/hw/misc/aspeed_hace.c @@ -433,7 +433,7 @@ static const VMStateDescription vmstate_aspeed_hace = { .name = TYPE_ASPEED_HACE, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedHACEState, ASPEED_HACE_NR_REGS), VMSTATE_UINT32(total_req_len, AspeedHACEState), VMSTATE_UINT32(iov_count, AspeedHACEState), diff --git a/hw/misc/aspeed_i3c.c b/hw/misc/aspeed_i3c.c index d1ff617671..827c9e522d 100644 --- a/hw/misc/aspeed_i3c.c +++ b/hw/misc/aspeed_i3c.c @@ -168,7 +168,7 @@ static const VMStateDescription aspeed_i3c_device_vmstate = { .name = TYPE_ASPEED_I3C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_UINT32_ARRAY(regs, AspeedI3CDevice, ASPEED_I3C_DEVICE_NR_REGS), VMSTATE_END_OF_LIST(), } @@ -349,7 +349,7 @@ static const VMStateDescription vmstate_aspeed_i3c = { .name = TYPE_ASPEED_I3C, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedI3CState, ASPEED_I3C_NR_REGS), VMSTATE_STRUCT_ARRAY(devices, AspeedI3CState, ASPEED_I3C_NR_DEVICES, 1, aspeed_i3c_device_vmstate, AspeedI3CDevice), diff --git a/hw/misc/aspeed_lpc.c b/hw/misc/aspeed_lpc.c index 2dddb27c35..193f0dea59 100644 --- a/hw/misc/aspeed_lpc.c +++ b/hw/misc/aspeed_lpc.c @@ -447,7 +447,7 @@ static const VMStateDescription vmstate_aspeed_lpc = { .name = TYPE_ASPEED_LPC, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedLPCState, ASPEED_LPC_NR_REGS), VMSTATE_UINT32(subdevice_irqs_pending, AspeedLPCState), VMSTATE_END_OF_LIST(), diff --git a/hw/misc/aspeed_sbc.c b/hw/misc/aspeed_sbc.c index c6f328e3be..8bb1f90e4e 100644 --- a/hw/misc/aspeed_sbc.c +++ b/hw/misc/aspeed_sbc.c @@ -130,7 +130,7 @@ static const VMStateDescription vmstate_aspeed_sbc = { .name = TYPE_ASPEED_SBC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedSBCState, ASPEED_SBC_NR_REGS), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/aspeed_scu.c b/hw/misc/aspeed_scu.c index 8335364906..1ac04b6cb0 100644 --- a/hw/misc/aspeed_scu.c +++ b/hw/misc/aspeed_scu.c @@ -531,7 +531,7 @@ static const VMStateDescription vmstate_aspeed_scu = { .name = "aspeed.scu", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedSCUState, ASPEED_AST2600_SCU_NR_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/aspeed_sdmc.c b/hw/misc/aspeed_sdmc.c index abb2727933..64cd1a81dc 100644 --- a/hw/misc/aspeed_sdmc.c +++ b/hw/misc/aspeed_sdmc.c @@ -243,7 +243,7 @@ static const VMStateDescription vmstate_aspeed_sdmc = { .name = "aspeed.sdmc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedSDMCState, ASPEED_SDMC_NR_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/aspeed_xdma.c b/hw/misc/aspeed_xdma.c index 1c21577c98..76ab8467dd 100644 --- a/hw/misc/aspeed_xdma.c +++ b/hw/misc/aspeed_xdma.c @@ -144,7 +144,7 @@ static void aspeed_xdma_reset(DeviceState *dev) static const VMStateDescription aspeed_xdma_vmstate = { .name = TYPE_ASPEED_XDMA, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedXDMAState, ASPEED_XDMA_NUM_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/misc/axp2xx.c b/hw/misc/axp2xx.c index 41538c1cd7..af646878cd 100644 --- a/hw/misc/axp2xx.c +++ b/hw/misc/axp2xx.c @@ -217,7 +217,7 @@ static int axp2xx_tx(I2CSlave *i2c, uint8_t data) static const VMStateDescription vmstate_axp2xx = { .name = TYPE_AXP2XX, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(regs, AXP2xxI2CState, NR_REGS), VMSTATE_UINT8(ptr, AXP2xxI2CState), VMSTATE_UINT8(count, AXP2xxI2CState), diff --git a/hw/misc/bcm2835_cprman.c b/hw/misc/bcm2835_cprman.c index 75e6c574d4..91c8f7bd17 100644 --- a/hw/misc/bcm2835_cprman.c +++ b/hw/misc/bcm2835_cprman.c @@ -125,7 +125,7 @@ static const VMStateDescription pll_vmstate = { .name = TYPE_CPRMAN_PLL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(xosc_in, CprmanPllState), VMSTATE_END_OF_LIST() } @@ -229,7 +229,7 @@ static const VMStateDescription pll_channel_vmstate = { .name = TYPE_CPRMAN_PLL_CHANNEL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(pll_in, CprmanPllChannelState), VMSTATE_END_OF_LIST() } @@ -349,7 +349,7 @@ static const VMStateDescription clock_mux_vmstate = { .name = TYPE_CPRMAN_CLOCK_MUX, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_ARRAY_CLOCK(srcs, CprmanClockMuxState, CPRMAN_NUM_CLOCK_MUX_SRC), VMSTATE_END_OF_LIST() @@ -404,7 +404,7 @@ static const VMStateDescription dsi0hsck_mux_vmstate = { .name = TYPE_CPRMAN_DSI0HSCK_MUX, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(plla_in, CprmanDsi0HsckMuxState), VMSTATE_CLOCK(plld_in, CprmanDsi0HsckMuxState), VMSTATE_END_OF_LIST() @@ -772,7 +772,7 @@ static const VMStateDescription cprman_vmstate = { .name = TYPE_BCM2835_CPRMAN, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, BCM2835CprmanState, CPRMAN_NUM_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/bcm2835_mbox.c b/hw/misc/bcm2835_mbox.c index 1e4e061bc1..67bfc3bd71 100644 --- a/hw/misc/bcm2835_mbox.c +++ b/hw/misc/bcm2835_mbox.c @@ -257,7 +257,7 @@ static const VMStateDescription vmstate_bcm2835_mbox_box = { .name = TYPE_BCM2835_MBOX "_box", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, BCM2835Mbox, MBOX_SIZE), VMSTATE_UINT32(count, BCM2835Mbox), VMSTATE_UINT32(status, BCM2835Mbox), @@ -271,7 +271,7 @@ static const VMStateDescription vmstate_bcm2835_mbox = { .name = TYPE_BCM2835_MBOX, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL_ARRAY(available, BCM2835MboxState, MBOX_CHAN_COUNT), VMSTATE_STRUCT_ARRAY(mbox, BCM2835MboxState, 2, 1, vmstate_bcm2835_mbox_box, BCM2835Mbox), diff --git a/hw/misc/bcm2835_mphi.c b/hw/misc/bcm2835_mphi.c index 0428e10ba5..f1eeda2786 100644 --- a/hw/misc/bcm2835_mphi.c +++ b/hw/misc/bcm2835_mphi.c @@ -156,7 +156,7 @@ const VMStateDescription vmstate_mphi_state = { .name = "mphi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(outdda, BCM2835MphiState), VMSTATE_UINT32(outddb, BCM2835MphiState), VMSTATE_UINT32(ctrl, BCM2835MphiState), diff --git a/hw/misc/bcm2835_powermgt.c b/hw/misc/bcm2835_powermgt.c index 976f3d34e5..1649da8668 100644 --- a/hw/misc/bcm2835_powermgt.c +++ b/hw/misc/bcm2835_powermgt.c @@ -109,7 +109,7 @@ static const VMStateDescription vmstate_bcm2835_powermgt = { .name = TYPE_BCM2835_POWERMGT, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(rstc, BCM2835PowerMgtState), VMSTATE_UINT32(rsts, BCM2835PowerMgtState), VMSTATE_UINT32(wdog, BCM2835PowerMgtState), diff --git a/hw/misc/bcm2835_property.c b/hw/misc/bcm2835_property.c index ff55a4e2cd..5c48f8d743 100644 --- a/hw/misc/bcm2835_property.c +++ b/hw/misc/bcm2835_property.c @@ -384,7 +384,7 @@ static const VMStateDescription vmstate_bcm2835_property = { .name = TYPE_BCM2835_PROPERTY, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_MACADDR(macaddr, BCM2835PropertyState), VMSTATE_UINT32(addr, BCM2835PropertyState), VMSTATE_BOOL(pending, BCM2835PropertyState), diff --git a/hw/misc/bcm2835_rng.c b/hw/misc/bcm2835_rng.c index b3c80cf186..10e741b11d 100644 --- a/hw/misc/bcm2835_rng.c +++ b/hw/misc/bcm2835_rng.c @@ -99,7 +99,7 @@ static const VMStateDescription vmstate_bcm2835_rng = { .name = TYPE_BCM2835_RNG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(rng_ctrl, BCM2835RngState), VMSTATE_UINT32(rng_status, BCM2835RngState), VMSTATE_END_OF_LIST() diff --git a/hw/misc/bcm2835_thermal.c b/hw/misc/bcm2835_thermal.c index c6f3b1ad60..ee7816b8a5 100644 --- a/hw/misc/bcm2835_thermal.c +++ b/hw/misc/bcm2835_thermal.c @@ -105,7 +105,7 @@ static const VMStateDescription bcm2835_thermal_vmstate = { .name = "bcm2835_thermal", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctl, Bcm2835ThermalState), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/djmemc.c b/hw/misc/djmemc.c index fd02640838..9b69656c3a 100644 --- a/hw/misc/djmemc.c +++ b/hw/misc/djmemc.c @@ -107,7 +107,7 @@ static const VMStateDescription vmstate_djmemc = { .name = "djMEMC", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, DJMEMCState, DJMEMC_NUM_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/eccmemctl.c b/hw/misc/eccmemctl.c index c65806e3d9..5a14a48999 100644 --- a/hw/misc/eccmemctl.c +++ b/hw/misc/eccmemctl.c @@ -272,7 +272,7 @@ static const VMStateDescription vmstate_ecc = { .name ="ECC", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, ECCState, ECC_NREGS), VMSTATE_BUFFER(diag, ECCState), VMSTATE_UINT32(version, ECCState), diff --git a/hw/misc/exynos4210_clk.c b/hw/misc/exynos4210_clk.c index 58cec282f7..4566a426fa 100644 --- a/hw/misc/exynos4210_clk.c +++ b/hw/misc/exynos4210_clk.c @@ -135,7 +135,7 @@ static const VMStateDescription exynos4210_clk_vmstate = { .name = TYPE_EXYNOS4210_CLK, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, Exynos4210ClkState, EXYNOS4210_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/exynos4210_pmu.c b/hw/misc/exynos4210_pmu.c index e24139c630..7e28e790d7 100644 --- a/hw/misc/exynos4210_pmu.c +++ b/hw/misc/exynos4210_pmu.c @@ -492,7 +492,7 @@ static const VMStateDescription exynos4210_pmu_vmstate = { .name = "exynos4210.pmu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, Exynos4210PmuState, PMU_NUM_OF_REGISTERS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/exynos4210_rng.c b/hw/misc/exynos4210_rng.c index 9214ec14cc..0756bd3205 100644 --- a/hw/misc/exynos4210_rng.c +++ b/hw/misc/exynos4210_rng.c @@ -243,7 +243,7 @@ static const VMStateDescription exynos4210_rng_vmstate = { .name = TYPE_EXYNOS4210_RNG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_ARRAY(randr_value, Exynos4210RngState, EXYNOS4210_RNG_PRNG_NUM), VMSTATE_UINT32(seed_set, Exynos4210RngState), diff --git a/hw/misc/imx25_ccm.c b/hw/misc/imx25_ccm.c index ff996e2f2c..d888966014 100644 --- a/hw/misc/imx25_ccm.c +++ b/hw/misc/imx25_ccm.c @@ -101,7 +101,7 @@ static const VMStateDescription vmstate_imx25_ccm = { .name = TYPE_IMX25_CCM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, IMX25CCMState, IMX25_CCM_MAX_REG), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/imx31_ccm.c b/hw/misc/imx31_ccm.c index ad30a4b2c0..a9059bb1f7 100644 --- a/hw/misc/imx31_ccm.c +++ b/hw/misc/imx31_ccm.c @@ -98,7 +98,7 @@ static const VMStateDescription vmstate_imx31_ccm = { .name = TYPE_IMX31_CCM, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, IMX31CCMState, IMX31_CCM_MAX_REG), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/imx6_ccm.c b/hw/misc/imx6_ccm.c index 85af466c2b..56489d8b57 100644 --- a/hw/misc/imx6_ccm.c +++ b/hw/misc/imx6_ccm.c @@ -235,7 +235,7 @@ static const VMStateDescription vmstate_imx6_ccm = { .name = TYPE_IMX6_CCM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(ccm, IMX6CCMState, CCM_MAX), VMSTATE_UINT32_ARRAY(analog, IMX6CCMState, CCM_ANALOG_MAX), VMSTATE_END_OF_LIST() diff --git a/hw/misc/imx6_src.c b/hw/misc/imx6_src.c index a9c64d06eb..d20727e20b 100644 --- a/hw/misc/imx6_src.c +++ b/hw/misc/imx6_src.c @@ -77,7 +77,7 @@ static const VMStateDescription vmstate_imx6_src = { .name = TYPE_IMX6_SRC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IMX6SRCState, SRC_MAX), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/imx6ul_ccm.c b/hw/misc/imx6ul_ccm.c index e01bb68ac7..bbc0be9921 100644 --- a/hw/misc/imx6ul_ccm.c +++ b/hw/misc/imx6ul_ccm.c @@ -285,7 +285,7 @@ static const VMStateDescription vmstate_imx6ul_ccm = { .name = TYPE_IMX6UL_CCM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(ccm, IMX6ULCCMState, CCM_MAX), VMSTATE_UINT32_ARRAY(analog, IMX6ULCCMState, CCM_ANALOG_MAX), VMSTATE_END_OF_LIST() diff --git a/hw/misc/imx7_ccm.c b/hw/misc/imx7_ccm.c index 7539f7fb45..88354f020e 100644 --- a/hw/misc/imx7_ccm.c +++ b/hw/misc/imx7_ccm.c @@ -214,7 +214,7 @@ static const VMStateDescription vmstate_imx7_ccm = { .name = TYPE_IMX7_CCM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(ccm, IMX7CCMState, CCM_MAX), VMSTATE_END_OF_LIST() }, @@ -286,7 +286,7 @@ static const VMStateDescription vmstate_imx7_analog = { .name = TYPE_IMX7_ANALOG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(analog, IMX7AnalogState, ANALOG_MAX), VMSTATE_UINT32_ARRAY(pmu, IMX7AnalogState, PMU_MAX), VMSTATE_END_OF_LIST() diff --git a/hw/misc/imx7_snvs.c b/hw/misc/imx7_snvs.c index 8e7f43187f..edb2df215a 100644 --- a/hw/misc/imx7_snvs.c +++ b/hw/misc/imx7_snvs.c @@ -30,7 +30,7 @@ static const VMStateDescription vmstate_imx7_snvs = { .name = TYPE_IMX7_SNVS, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tick_offset, IMX7SNVSState), VMSTATE_UINT64(lpcr, IMX7SNVSState), VMSTATE_END_OF_LIST() diff --git a/hw/misc/imx7_src.c b/hw/misc/imx7_src.c index 983251e86f..24a0b4618c 100644 --- a/hw/misc/imx7_src.c +++ b/hw/misc/imx7_src.c @@ -84,7 +84,7 @@ static const VMStateDescription vmstate_imx7_src = { .name = TYPE_IMX7_SRC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IMX7SRCState, SRC_MAX), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/imx_rngc.c b/hw/misc/imx_rngc.c index 082c6980ad..ab7775e095 100644 --- a/hw/misc/imx_rngc.c +++ b/hw/misc/imx_rngc.c @@ -245,7 +245,7 @@ static const VMStateDescription vmstate_imx_rngc = { .name = RNGC_NAME, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(op_self_test, IMXRNGCState), VMSTATE_UINT8(op_seed, IMXRNGCState), VMSTATE_UINT8(mask, IMXRNGCState), diff --git a/hw/misc/iosb.c b/hw/misc/iosb.c index e7e9dcca47..e20305e801 100644 --- a/hw/misc/iosb.c +++ b/hw/misc/iosb.c @@ -105,7 +105,7 @@ static const VMStateDescription vmstate_iosb = { .name = "IOSB", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IOSBState, IOSB_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/iotkit-secctl.c b/hw/misc/iotkit-secctl.c index b5a9e30a2c..f9c45f60bf 100644 --- a/hw/misc/iotkit-secctl.c +++ b/hw/misc/iotkit-secctl.c @@ -753,7 +753,7 @@ static const VMStateDescription iotkit_secctl_ppc_vmstate = { .name = "iotkit-secctl-ppc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ns, IoTKitSecCtlPPC), VMSTATE_UINT32(sp, IoTKitSecCtlPPC), VMSTATE_UINT32(nsp, IoTKitSecCtlPPC), @@ -765,7 +765,7 @@ static const VMStateDescription iotkit_secctl_mpcintstatus_vmstate = { .name = "iotkit-secctl-mpcintstatus", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(mpcintstatus, IoTKitSecCtl), VMSTATE_END_OF_LIST() } @@ -781,7 +781,7 @@ static const VMStateDescription iotkit_secctl_msc_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = needed_always, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(secmscintstat, IoTKitSecCtl), VMSTATE_UINT32(secmscinten, IoTKitSecCtl), VMSTATE_UINT32(nsmscexp, IoTKitSecCtl), @@ -793,7 +793,7 @@ static const VMStateDescription iotkit_secctl_vmstate = { .name = "iotkit-secctl", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(secppcintstat, IoTKitSecCtl), VMSTATE_UINT32(secppcinten, IoTKitSecCtl), VMSTATE_UINT32(secrespcfg, IoTKitSecCtl), @@ -807,7 +807,7 @@ static const VMStateDescription iotkit_secctl_vmstate = { iotkit_secctl_ppc_vmstate, IoTKitSecCtlPPC), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &iotkit_secctl_mpcintstatus_vmstate, &iotkit_secctl_msc_vmstate, NULL diff --git a/hw/misc/iotkit-sysctl.c b/hw/misc/iotkit-sysctl.c index e664215ee6..45393e84ba 100644 --- a/hw/misc/iotkit-sysctl.c +++ b/hw/misc/iotkit-sysctl.c @@ -777,7 +777,7 @@ static const VMStateDescription iotkit_sysctl_sse300_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = sse300_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pwrctrl, IoTKitSysCtl), VMSTATE_UINT32(pdcm_pd_cpu0_sense, IoTKitSysCtl), VMSTATE_UINT32(pdcm_pd_vmr0_sense, IoTKitSysCtl), @@ -798,7 +798,7 @@ static const VMStateDescription iotkit_sysctl_sse200_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = sse200_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(scsecctrl, IoTKitSysCtl), VMSTATE_UINT32(fclk_div, IoTKitSysCtl), VMSTATE_UINT32(sysclk_div, IoTKitSysCtl), @@ -818,7 +818,7 @@ static const VMStateDescription iotkit_sysctl_vmstate = { .name = "iotkit-sysctl", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(secure_debug, IoTKitSysCtl), VMSTATE_UINT32(reset_syndrome, IoTKitSysCtl), VMSTATE_UINT32(reset_mask, IoTKitSysCtl), @@ -828,7 +828,7 @@ static const VMStateDescription iotkit_sysctl_vmstate = { VMSTATE_UINT32(wicctrl, IoTKitSysCtl), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &iotkit_sysctl_sse200_vmstate, &iotkit_sysctl_sse300_vmstate, NULL diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.c index 0447888029..62af75e862 100644 --- a/hw/misc/ivshmem.c +++ b/hw/misc/ivshmem.c @@ -1015,7 +1015,7 @@ static const VMStateDescription ivshmem_plain_vmsd = { .minimum_version_id = 0, .pre_load = ivshmem_pre_load, .post_load = ivshmem_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, IVShmemState), VMSTATE_UINT32(intrstatus, IVShmemState), VMSTATE_UINT32(intrmask, IVShmemState), @@ -1069,7 +1069,7 @@ static const VMStateDescription ivshmem_doorbell_vmsd = { .minimum_version_id = 0, .pre_load = ivshmem_pre_load, .post_load = ivshmem_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, IVShmemState), VMSTATE_MSIX(parent_obj, IVShmemState), VMSTATE_UINT32(intrstatus, IVShmemState), diff --git a/hw/misc/lasi.c b/hw/misc/lasi.c index ff9dc893ae..003f5b5ed8 100644 --- a/hw/misc/lasi.c +++ b/hw/misc/lasi.c @@ -196,7 +196,7 @@ static const VMStateDescription vmstate_lasi = { .name = "Lasi", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(irr, LasiState), VMSTATE_UINT32(imr, LasiState), VMSTATE_UINT32(ipr, LasiState), diff --git a/hw/misc/led.c b/hw/misc/led.c index 42bb43a39a..d9998ab895 100644 --- a/hw/misc/led.c +++ b/hw/misc/led.c @@ -77,7 +77,7 @@ static const VMStateDescription vmstate_led = { .name = TYPE_LED, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(intensity_percent, LEDState), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/mac_via.c b/hw/misc/mac_via.c index b6206ef73c..db6142b5f4 100644 --- a/hw/misc/mac_via.c +++ b/hw/misc/mac_via.c @@ -1292,7 +1292,7 @@ static const VMStateDescription vmstate_q800_via1 = { .version_id = 0, .minimum_version_id = 0, .post_load = via1_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, MOS6522Q800VIA1State, 0, vmstate_mos6522, MOS6522State), VMSTATE_UINT8(last_b, MOS6522Q800VIA1State), @@ -1411,7 +1411,7 @@ static const VMStateDescription vmstate_q800_via2 = { .name = "q800-via2", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, MOS6522Q800VIA2State, 0, vmstate_mos6522, MOS6522State), VMSTATE_END_OF_LIST() diff --git a/hw/misc/mips_cmgcr.c b/hw/misc/mips_cmgcr.c index 66eb11662c..2703040f45 100644 --- a/hw/misc/mips_cmgcr.c +++ b/hw/misc/mips_cmgcr.c @@ -205,7 +205,7 @@ static const VMStateDescription vmstate_mips_gcr = { .name = "mips-gcr", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(cpc_base, MIPSGCRState), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/mips_cpc.c b/hw/misc/mips_cpc.c index 4a94c87054..1e8fd2e699 100644 --- a/hw/misc/mips_cpc.c +++ b/hw/misc/mips_cpc.c @@ -157,7 +157,7 @@ static const VMStateDescription vmstate_mips_cpc = { .name = "mips-cpc", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(vp_running, MIPSCPCState), VMSTATE_END_OF_LIST() }, diff --git a/hw/misc/mos6522.c b/hw/misc/mos6522.c index d6ba47bde9..e3fe87c20c 100644 --- a/hw/misc/mos6522.c +++ b/hw/misc/mos6522.c @@ -611,7 +611,7 @@ static const VMStateDescription vmstate_mos6522_timer = { .name = "mos6522_timer", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(latch, MOS6522Timer), VMSTATE_UINT16(counter_value, MOS6522Timer), VMSTATE_INT64(load_time, MOS6522Timer), @@ -625,7 +625,7 @@ const VMStateDescription vmstate_mos6522 = { .name = "mos6522", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(a, MOS6522State), VMSTATE_UINT8(b, MOS6522State), VMSTATE_UINT8(dira, MOS6522State), diff --git a/hw/misc/mps2-fpgaio.c b/hw/misc/mps2-fpgaio.c index 07b8cbdad2..aa1bb83e72 100644 --- a/hw/misc/mps2-fpgaio.c +++ b/hw/misc/mps2-fpgaio.c @@ -305,7 +305,7 @@ static const VMStateDescription mps2_fpgaio_vmstate = { .name = "mps2-fpgaio", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(led0, MPS2FPGAIO), VMSTATE_UINT32(prescale, MPS2FPGAIO), VMSTATE_UINT32(misc, MPS2FPGAIO), diff --git a/hw/misc/mps2-scc.c b/hw/misc/mps2-scc.c index fe5034db14..6cfb5ff108 100644 --- a/hw/misc/mps2-scc.c +++ b/hw/misc/mps2-scc.c @@ -340,7 +340,7 @@ static const VMStateDescription mps2_scc_vmstate = { .name = "mps2-scc", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cfg0, MPS2SCC), VMSTATE_UINT32(cfg1, MPS2SCC), VMSTATE_UINT32(cfg2, MPS2SCC), diff --git a/hw/misc/msf2-sysreg.c b/hw/misc/msf2-sysreg.c index 2dce55c364..f54382a816 100644 --- a/hw/misc/msf2-sysreg.c +++ b/hw/misc/msf2-sysreg.c @@ -112,7 +112,7 @@ static const VMStateDescription vmstate_msf2_sysreg = { .name = TYPE_MSF2_SYSREG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, MSF2SysregState, MSF2_SYSREG_MMIO_SIZE / 4), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/mst_fpga.c b/hw/misc/mst_fpga.c index 7692825867..2d7bfa5ad9 100644 --- a/hw/misc/mst_fpga.c +++ b/hw/misc/mst_fpga.c @@ -227,7 +227,7 @@ static const VMStateDescription vmstate_mst_fpga_regs = { .version_id = 0, .minimum_version_id = 0, .post_load = mst_fpga_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(prev_level, mst_irq_state), VMSTATE_UINT32(leddat1, mst_irq_state), VMSTATE_UINT32(leddat2, mst_irq_state), diff --git a/hw/misc/npcm7xx_clk.c b/hw/misc/npcm7xx_clk.c index bc2b879feb..ac1622c38a 100644 --- a/hw/misc/npcm7xx_clk.c +++ b/hw/misc/npcm7xx_clk.c @@ -976,7 +976,7 @@ static const VMStateDescription vmstate_npcm7xx_clk_pll = { .name = "npcm7xx-clock-pll", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clock_in, NPCM7xxClockPLLState), VMSTATE_END_OF_LIST(), }, @@ -986,7 +986,7 @@ static const VMStateDescription vmstate_npcm7xx_clk_sel = { .name = "npcm7xx-clock-sel", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_ARRAY_OF_POINTER_TO_STRUCT(clock_in, NPCM7xxClockSELState, NPCM7XX_CLK_SEL_MAX_INPUT, 0, vmstate_clock, Clock), VMSTATE_END_OF_LIST(), @@ -997,7 +997,7 @@ static const VMStateDescription vmstate_npcm7xx_clk_divider = { .name = "npcm7xx-clock-divider", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clock_in, NPCM7xxClockDividerState), VMSTATE_END_OF_LIST(), }, @@ -1008,7 +1008,7 @@ static const VMStateDescription vmstate_npcm7xx_clk = { .version_id = 1, .minimum_version_id = 1, .post_load = npcm7xx_clk_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, NPCM7xxCLKState, NPCM7XX_CLK_NR_REGS), VMSTATE_INT64(ref_ns, NPCM7xxCLKState), VMSTATE_CLOCK(clkref, NPCM7xxCLKState), diff --git a/hw/misc/npcm7xx_gcr.c b/hw/misc/npcm7xx_gcr.c index eace9e1967..9252f9d148 100644 --- a/hw/misc/npcm7xx_gcr.c +++ b/hw/misc/npcm7xx_gcr.c @@ -227,7 +227,7 @@ static const VMStateDescription vmstate_npcm7xx_gcr = { .name = "npcm7xx-gcr", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, NPCM7xxGCRState, NPCM7XX_GCR_NR_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/misc/npcm7xx_mft.c b/hw/misc/npcm7xx_mft.c index a30583a1b0..9a848584e1 100644 --- a/hw/misc/npcm7xx_mft.c +++ b/hw/misc/npcm7xx_mft.c @@ -503,7 +503,7 @@ static const VMStateDescription vmstate_npcm7xx_mft = { .name = "npcm7xx-mft-module", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clock_in, NPCM7xxMFTState), VMSTATE_CLOCK(clock_1, NPCM7xxMFTState), VMSTATE_CLOCK(clock_2, NPCM7xxMFTState), diff --git a/hw/misc/npcm7xx_pwm.c b/hw/misc/npcm7xx_pwm.c index 2be5bd25c6..fca2dd2e5a 100644 --- a/hw/misc/npcm7xx_pwm.c +++ b/hw/misc/npcm7xx_pwm.c @@ -511,7 +511,7 @@ static const VMStateDescription vmstate_npcm7xx_pwm = { .name = "npcm7xx-pwm", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(running, NPCM7xxPWM), VMSTATE_BOOL(inverted, NPCM7xxPWM), VMSTATE_UINT8(index, NPCM7xxPWM), @@ -529,7 +529,7 @@ static const VMStateDescription vmstate_npcm7xx_pwm_module = { .name = "npcm7xx-pwm-module", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clock, NPCM7xxPWMState), VMSTATE_STRUCT_ARRAY(pwm, NPCM7xxPWMState, NPCM7XX_PWM_PER_MODULE, 0, vmstate_npcm7xx_pwm, diff --git a/hw/misc/npcm7xx_rng.c b/hw/misc/npcm7xx_rng.c index b01df7cdb2..7f7e5eca62 100644 --- a/hw/misc/npcm7xx_rng.c +++ b/hw/misc/npcm7xx_rng.c @@ -150,7 +150,7 @@ static const VMStateDescription vmstate_npcm7xx_rng = { .name = "npcm7xx-rng", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(rngcs, NPCM7xxRNGState), VMSTATE_UINT8(rngd, NPCM7xxRNGState), VMSTATE_UINT8(rngmode, NPCM7xxRNGState), diff --git a/hw/misc/nrf51_rng.c b/hw/misc/nrf51_rng.c index fc86e1b697..2d76c45718 100644 --- a/hw/misc/nrf51_rng.c +++ b/hw/misc/nrf51_rng.c @@ -231,7 +231,7 @@ static const VMStateDescription vmstate_rng = { .name = "nrf51_soc.rng", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(active, NRF51RNGState), VMSTATE_UINT32(event_valrdy, NRF51RNGState), VMSTATE_UINT32(shortcut_stop_on_valrdy, NRF51RNGState), diff --git a/hw/misc/pca9552.c b/hw/misc/pca9552.c index fff19e369a..72b653463f 100644 --- a/hw/misc/pca9552.c +++ b/hw/misc/pca9552.c @@ -328,7 +328,7 @@ static const VMStateDescription pca9552_vmstate = { .name = "PCA9552", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(len, PCA955xState), VMSTATE_UINT8(pointer, PCA955xState), VMSTATE_UINT8_ARRAY(regs, PCA955xState, PCA955X_NR_REGS), diff --git a/hw/misc/pvpanic-pci.c b/hw/misc/pvpanic-pci.c index fbcaa50731..c01e4ce864 100644 --- a/hw/misc/pvpanic-pci.c +++ b/hw/misc/pvpanic-pci.c @@ -37,7 +37,7 @@ static const VMStateDescription vmstate_pvpanic_pci = { .name = "pvpanic-pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PVPanicPCIState), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/slavio_misc.c b/hw/misc/slavio_misc.c index e8eb71570a..94369e4cc8 100644 --- a/hw/misc/slavio_misc.c +++ b/hw/misc/slavio_misc.c @@ -408,7 +408,7 @@ static const VMStateDescription vmstate_misc = { .name ="slavio_misc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(dummy, MiscState), VMSTATE_UINT8(config, MiscState), VMSTATE_UINT8(aux1, MiscState), diff --git a/hw/misc/stm32f4xx_exti.c b/hw/misc/stm32f4xx_exti.c index 02e7810046..7bd3afcd7c 100644 --- a/hw/misc/stm32f4xx_exti.c +++ b/hw/misc/stm32f4xx_exti.c @@ -153,7 +153,7 @@ static const VMStateDescription vmstate_stm32f4xx_exti = { .name = TYPE_STM32F4XX_EXTI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(exti_imr, STM32F4xxExtiState), VMSTATE_UINT32(exti_emr, STM32F4xxExtiState), VMSTATE_UINT32(exti_rtsr, STM32F4xxExtiState), diff --git a/hw/misc/stm32f4xx_syscfg.c b/hw/misc/stm32f4xx_syscfg.c index f960e4ea1e..854fce6a95 100644 --- a/hw/misc/stm32f4xx_syscfg.c +++ b/hw/misc/stm32f4xx_syscfg.c @@ -137,7 +137,7 @@ static const VMStateDescription vmstate_stm32f4xx_syscfg = { .name = TYPE_STM32F4XX_SYSCFG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(syscfg_memrmp, STM32F4xxSyscfgState), VMSTATE_UINT32(syscfg_pmc, STM32F4xxSyscfgState), VMSTATE_UINT32_ARRAY(syscfg_exticr, STM32F4xxSyscfgState, diff --git a/hw/misc/tz-mpc.c b/hw/misc/tz-mpc.c index 30481e1c90..92b994919b 100644 --- a/hw/misc/tz-mpc.c +++ b/hw/misc/tz-mpc.c @@ -574,7 +574,7 @@ static const VMStateDescription tz_mpc_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = tz_mpc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctrl, TZMPC), VMSTATE_UINT32(blk_idx, TZMPC), VMSTATE_UINT32(int_stat, TZMPC), diff --git a/hw/misc/tz-msc.c b/hw/misc/tz-msc.c index acbe94400b..de5a3126cc 100644 --- a/hw/misc/tz-msc.c +++ b/hw/misc/tz-msc.c @@ -269,7 +269,7 @@ static const VMStateDescription tz_msc_vmstate = { .name = "tz-msc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(cfg_nonsec, TZMSC), VMSTATE_BOOL(cfg_sec_resp, TZMSC), VMSTATE_BOOL(irq_clear, TZMSC), diff --git a/hw/misc/tz-ppc.c b/hw/misc/tz-ppc.c index 36495c68e7..6450778720 100644 --- a/hw/misc/tz-ppc.c +++ b/hw/misc/tz-ppc.c @@ -290,7 +290,7 @@ static const VMStateDescription tz_ppc_vmstate = { .name = "tz-ppc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL_ARRAY(cfg_nonsec, TZPPC, 16), VMSTATE_BOOL_ARRAY(cfg_ap, TZPPC, 16), VMSTATE_BOOL(cfg_sec_resp, TZPPC), diff --git a/hw/misc/virt_ctrl.c b/hw/misc/virt_ctrl.c index e75d1e7e17..1a6c744bac 100644 --- a/hw/misc/virt_ctrl.c +++ b/hw/misc/virt_ctrl.c @@ -108,7 +108,7 @@ static const VMStateDescription vmstate_virt_ctrl = { .name = "virt-ctrl", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(irq_enabled, VirtCtrlState), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/vmcoreinfo.c b/hw/misc/vmcoreinfo.c index a9d718fc23..833773ade5 100644 --- a/hw/misc/vmcoreinfo.c +++ b/hw/misc/vmcoreinfo.c @@ -73,7 +73,7 @@ static const VMStateDescription vmstate_vmcoreinfo = { .name = "vmcoreinfo", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(has_vmcoreinfo, VMCoreInfoState), VMSTATE_UINT16(vmcoreinfo.host_format, VMCoreInfoState), VMSTATE_UINT16(vmcoreinfo.guest_format, VMCoreInfoState), diff --git a/hw/misc/xlnx-versal-cframe-reg.c b/hw/misc/xlnx-versal-cframe-reg.c index 8e8ec0715a..a6ab287b01 100644 --- a/hw/misc/xlnx-versal-cframe-reg.c +++ b/hw/misc/xlnx-versal-cframe-reg.c @@ -697,7 +697,7 @@ static const VMStateDescription vmstate_cframe = { .name = "cframe", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(data, XlnxCFrame, FRAME_NUM_WORDS), VMSTATE_END_OF_LIST() } @@ -707,7 +707,7 @@ static const VMStateDescription vmstate_cframe_reg = { .name = TYPE_XLNX_VERSAL_CFRAME_REG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(wfifo, XlnxVersalCFrameReg, 4), VMSTATE_UINT32_ARRAY(regs, XlnxVersalCFrameReg, CFRAME_REG_R_MAX), VMSTATE_BOOL(rowon, XlnxVersalCFrameReg), @@ -765,7 +765,7 @@ static const VMStateDescription vmstate_cframe_bcast_reg = { .name = TYPE_XLNX_VERSAL_CFRAME_BCAST_REG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(wfifo, XlnxVersalCFrameBcastReg, 4), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/xlnx-versal-cfu.c b/hw/misc/xlnx-versal-cfu.c index 8e588ac1d8..6bb82e51c1 100644 --- a/hw/misc/xlnx-versal-cfu.c +++ b/hw/misc/xlnx-versal-cfu.c @@ -463,7 +463,7 @@ static const VMStateDescription vmstate_cfu_apb = { .name = TYPE_XLNX_VERSAL_CFU_APB, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(wfifo, XlnxVersalCFUAPB, 4), VMSTATE_UINT32_ARRAY(regs, XlnxVersalCFUAPB, R_MAX), VMSTATE_UINT8(fdri_row_addr, XlnxVersalCFUAPB), @@ -475,7 +475,7 @@ static const VMStateDescription vmstate_cfu_fdro = { .name = TYPE_XLNX_VERSAL_CFU_FDRO, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO32(fdro_data, XlnxVersalCFUFDRO), VMSTATE_END_OF_LIST(), } @@ -485,7 +485,7 @@ static const VMStateDescription vmstate_cfu_sfr = { .name = TYPE_XLNX_VERSAL_CFU_SFR, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(wfifo, XlnxVersalCFUSFR, 4), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/xlnx-versal-crl.c b/hw/misc/xlnx-versal-crl.c index 767106b7a3..ac6889fcf2 100644 --- a/hw/misc/xlnx-versal-crl.c +++ b/hw/misc/xlnx-versal-crl.c @@ -387,7 +387,7 @@ static const VMStateDescription vmstate_crl = { .name = TYPE_XLNX_VERSAL_CRL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxVersalCRL, CRL_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/xlnx-versal-pmc-iou-slcr.c b/hw/misc/xlnx-versal-pmc-iou-slcr.c index 07b7ebc217..60e13a78ab 100644 --- a/hw/misc/xlnx-versal-pmc-iou-slcr.c +++ b/hw/misc/xlnx-versal-pmc-iou-slcr.c @@ -1412,7 +1412,7 @@ static const VMStateDescription vmstate_pmc_iou_slcr = { .name = TYPE_XILINX_VERSAL_PMC_IOU_SLCR, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxVersalPmcIouSlcr, XILINX_VERSAL_PMC_IOU_SLCR_R_MAX), VMSTATE_END_OF_LIST(), diff --git a/hw/misc/xlnx-versal-trng.c b/hw/misc/xlnx-versal-trng.c index 4d41c262c4..b8111b8b66 100644 --- a/hw/misc/xlnx-versal-trng.c +++ b/hw/misc/xlnx-versal-trng.c @@ -674,7 +674,7 @@ static const VMStateDescription vmstate_trng = { .name = TYPE_XLNX_VERSAL_TRNG, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(rand_count, XlnxVersalTRng), VMSTATE_UINT64(rand_reseed, XlnxVersalTRng), VMSTATE_UINT64(forced_prng_count, XlnxVersalTRng), diff --git a/hw/misc/xlnx-versal-xramc.c b/hw/misc/xlnx-versal-xramc.c index e5b719a0ed..a5f78c190e 100644 --- a/hw/misc/xlnx-versal-xramc.c +++ b/hw/misc/xlnx-versal-xramc.c @@ -212,7 +212,7 @@ static const VMStateDescription vmstate_xram_ctrl = { .name = TYPE_XLNX_XRAM_CTRL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxXramCtrl, XRAM_CTRL_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/xlnx-zynqmp-apu-ctrl.c b/hw/misc/xlnx-zynqmp-apu-ctrl.c index 3d2be95e6d..1d441b41df 100644 --- a/hw/misc/xlnx-zynqmp-apu-ctrl.c +++ b/hw/misc/xlnx-zynqmp-apu-ctrl.c @@ -218,7 +218,7 @@ static const VMStateDescription vmstate_zynqmp_apu = { .name = TYPE_XLNX_ZYNQMP_APU_CTRL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZynqMPAPUCtrl, APU_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/xlnx-zynqmp-crf.c b/hw/misc/xlnx-zynqmp-crf.c index 57bc8cf49a..a83efb44e3 100644 --- a/hw/misc/xlnx-zynqmp-crf.c +++ b/hw/misc/xlnx-zynqmp-crf.c @@ -233,7 +233,7 @@ static const VMStateDescription vmstate_crf = { .name = TYPE_XLNX_ZYNQMP_CRF, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZynqMPCRF, CRF_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/misc/zynq_slcr.c b/hw/misc/zynq_slcr.c index 41f38a98e9..d2ac2e77f2 100644 --- a/hw/misc/zynq_slcr.c +++ b/hw/misc/zynq_slcr.c @@ -603,7 +603,7 @@ static const VMStateDescription vmstate_zynq_slcr = { .name = "zynq_slcr", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, ZynqSLCRState, ZYNQ_SLCR_NUM_REGS), VMSTATE_CLOCK_V(ps_clk, ZynqSLCRState, 3), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:23:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758836 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672237wrw; Fri, 29 Dec 2023 13:31:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IHNZjJOie0Oy3UWmXeIe4rSRAi092uU1hLOo4n169YtA+EznYf/QcELx5Mvc+237S9KXV80 X-Received: by 2002:a05:620a:40cb:b0:781:5fa9:12eb with SMTP id g11-20020a05620a40cb00b007815fa912ebmr10117302qko.4.1703885465811; Fri, 29 Dec 2023 13:31:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885465; cv=none; d=google.com; s=arc-20160816; b=siyB/Wo5DONznDJxn1bnrO3O+8KQLKAp1511KjRDad09cRDj5eqWVVX4MDjurMdokJ 2YZ2WWXX8a9lDhAmsOxda9WbofL2g8kgBIyVuSfElI8tsj9GiIALFeVD9y+Mja4G56yV nr3KCtMN4RLOI10E4NiSVbUlNvvLTJlSbbTaD7m+qY3kajsuPSDHRikUDXn0okLrUtbE dmIAMy5YAlkwbPvlDEnufPYPoVg+TrrMOSGv+aMRCH5hQz+KX4MdGop+fcOK6KKXx1Iu Y6bN079TxmWJRBRjTHNtWraF3V8IH/qlzRjCJeYty2aL9LayNeDzy8pSt9euVxX1fVZ6 BKJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=pRvRbNjEbIwOczpWL3bW5tExgcKzvngsOhwJnChX8Bg=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=1AesjW1x1rG76wdLFvbkHqIgYMz3H280YrSBUkgaoSOkC8LmIzqpSOMGO3BxYUsCp5 R8r+50GJ1zBSiGsNvY35Qv5Ffy/yRCig0r0IALNLJbehhtTlw+IjShbc6nAq6slRyOG/ gtPK9lIEUcbMx7wQn8BGWhTRp+p8ElTDxAtoJztyJgw3A9UgAidG3nxU22wJi/TZAiTz +XUjK99vOlCdT4lwB+RTfLYvu2apAQDXgvrPS56YC9NG+FmS8zMX7Qch/YY0N5K+4Au6 IUxsxWI7RG906gZcU/PSl5J+42bOEc0SkbGCDXdfJ0HSMOjbn5PrwFBf8HxfMNxa6URT +M3g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kDeFc8L0; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i3-20020a05620a248300b00781381609aesi16050155qkn.495.2023.12.29.13.31.05 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:05 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=kDeFc8L0; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPU-0005Nt-1E; Fri, 29 Dec 2023 16:28:53 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPF-00053v-Ny for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:38 -0500 Received: from mail-pf1-x42c.google.com ([2607:f8b0:4864:20::42c]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPB-0000JU-NI for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:37 -0500 Received: by mail-pf1-x42c.google.com with SMTP id d2e1a72fcca58-6d9344f30caso4789337b3a.1 for ; Fri, 29 Dec 2023 13:28:33 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885312; x=1704490112; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=pRvRbNjEbIwOczpWL3bW5tExgcKzvngsOhwJnChX8Bg=; b=kDeFc8L02Zv7wpPH2wVU9pAu7Fj+dj4/pSU8C+1L+61RKKfJz90ajrHNjNkSy8OS6C ZOCoq5buVjgfR66dM9KN8FGWTxheC/I0QNLjv4wr/XYX1mTnLT0aOaRXWiSQBjIG5vW4 HrfOHhLSlFXq+c1c6UGTyg3Bri9Y3JQbxzL3zJzMPWGP/t0gUS8hUQ7ITvqQ5ySD7oT1 CAbusY2z+wiIDgXfMw9rILk3zzxiQyPzR3FN7vSIdnmvCMxuvYpBT9I6xmjoT9NNyr16 I6KuVc5072sSd24D5e2M9UYJ98uC81Vhdw8K4kr9nzn10yS04ZLrSzEdpyaulkAZhoVy 8XKQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885312; x=1704490112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pRvRbNjEbIwOczpWL3bW5tExgcKzvngsOhwJnChX8Bg=; b=sLX/b9KA78NApQQHuZCyLSMOY+WIWenazHaGhFLRt8kOARdvZWgoT3XwK052+uIJdg hOVJetIimPvuNIk1XM2pvAxzFOqX/zayyvJ9xQDiwg4rxWDAqPW0shI2YksQERv0CUdK A7lr9j4rk4pXCb+9bKB4TJmqkotvo3T20eVO7nYwVhi+JASJJ9J1h3qLqDs1prjZtU2r lceER5ojcRZkcG4AuxEZW1WGeXmNtx2x7MyC1y+jK5NQ7I/0dnHbgYxEWIjr04Q9bBdo mxuOTprxT6DkzThbDAPxWwUdaT0xaqxGRsm8faXJu8cRsssusSWTsIMj/LctTG2aMMA8 uELA== X-Gm-Message-State: AOJu0YxNZXTylU4zcOsJQnJ+dg1pdQqjqsLreja7NExspynT1jnfKv4+ roHAauXOU/GlbV+idsKwXhf8i+/kczCNP3ubjiUt093xwd2NGg== X-Received: by 2002:a05:6a00:1c85:b0:6d9:bee5:702d with SMTP id y5-20020a056a001c8500b006d9bee5702dmr9403381pfw.18.1703885312065; Fri, 29 Dec 2023 13:28:32 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.30 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:31 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 41/71] hw/net: Constify VMState Date: Sat, 30 Dec 2023 08:23:16 +1100 Message-Id: <20231229212346.147149-42-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::42c; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42c.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-42-richard.henderson@linaro.org> --- hw/net/allwinner-sun8i-emac.c | 2 +- hw/net/allwinner_emac.c | 4 ++-- hw/net/cadence_gem.c | 2 +- hw/net/can/can_kvaser_pci.c | 2 +- hw/net/can/can_mioe3680_pci.c | 2 +- hw/net/can/can_pcm3680_pci.c | 2 +- hw/net/can/can_sja1000.c | 4 ++-- hw/net/can/ctucan_core.c | 4 ++-- hw/net/can/ctucan_pci.c | 2 +- hw/net/can/xlnx-versal-canfd.c | 2 +- hw/net/can/xlnx-zynqmp-can.c | 2 +- hw/net/dp8393x.c | 2 +- hw/net/e1000.c | 10 +++++----- hw/net/e1000e.c | 6 +++--- hw/net/eepro100.c | 2 +- hw/net/ftgmac100.c | 4 ++-- hw/net/i82596.c | 2 +- hw/net/igb.c | 8 ++++---- hw/net/imx_fec.c | 6 +++--- hw/net/lan9118.c | 4 ++-- hw/net/lance.c | 2 +- hw/net/lasi_i82596.c | 2 +- hw/net/mipsnet.c | 2 +- hw/net/msf2-emac.c | 2 +- hw/net/mv88w8618_eth.c | 2 +- hw/net/ne2000-isa.c | 2 +- hw/net/ne2000-pci.c | 2 +- hw/net/ne2000.c | 2 +- hw/net/npcm7xx_emc.c | 2 +- hw/net/pcnet-pci.c | 2 +- hw/net/pcnet.c | 2 +- hw/net/rtl8139.c | 6 +++--- hw/net/smc91c111.c | 2 +- hw/net/spapr_llan.c | 8 ++++---- hw/net/stellaris_enet.c | 4 ++-- hw/net/sungem.c | 2 +- hw/net/sunhme.c | 2 +- hw/net/tulip.c | 2 +- hw/net/virtio-net.c | 18 +++++++++--------- hw/net/vmxnet3.c | 18 +++++++++--------- hw/net/xgmac.c | 4 ++-- 41 files changed, 80 insertions(+), 80 deletions(-) diff --git a/hw/net/allwinner-sun8i-emac.c b/hw/net/allwinner-sun8i-emac.c index cc350d40e5..108ae9c853 100644 --- a/hw/net/allwinner-sun8i-emac.c +++ b/hw/net/allwinner-sun8i-emac.c @@ -851,7 +851,7 @@ static const VMStateDescription vmstate_aw_emac = { .version_id = 1, .minimum_version_id = 1, .post_load = allwinner_sun8i_emac_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(mii_phy_addr, AwSun8iEmacState), VMSTATE_UINT32(mii_cmd, AwSun8iEmacState), VMSTATE_UINT32(mii_data, AwSun8iEmacState), diff --git a/hw/net/allwinner_emac.c b/hw/net/allwinner_emac.c index e10965de14..989839784a 100644 --- a/hw/net/allwinner_emac.c +++ b/hw/net/allwinner_emac.c @@ -472,7 +472,7 @@ static const VMStateDescription vmstate_mii = { .name = "rtl8201cp", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(bmcr, RTL8201CPState), VMSTATE_UINT16(bmsr, RTL8201CPState), VMSTATE_UINT16(anar, RTL8201CPState), @@ -495,7 +495,7 @@ static const VMStateDescription vmstate_aw_emac = { .version_id = 1, .minimum_version_id = 1, .post_load = aw_emac_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(mii, AwEmacState, 1, vmstate_mii, RTL8201CPState), VMSTATE_UINT32(ctl, AwEmacState), VMSTATE_UINT32(tx_mode, AwEmacState), diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index 296bba238e..d7b7b134b0 100644 --- a/hw/net/cadence_gem.c +++ b/hw/net/cadence_gem.c @@ -1771,7 +1771,7 @@ static const VMStateDescription vmstate_cadence_gem = { .name = "cadence_gem", .version_id = 4, .minimum_version_id = 4, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, CadenceGEMState, CADENCE_GEM_MAXREG), VMSTATE_UINT16_ARRAY(phy_regs, CadenceGEMState, 32), VMSTATE_UINT8(phy_loop, CadenceGEMState), diff --git a/hw/net/can/can_kvaser_pci.c b/hw/net/can/can_kvaser_pci.c index 2cd90cef1e..bf41e6b261 100644 --- a/hw/net/can/can_kvaser_pci.c +++ b/hw/net/can/can_kvaser_pci.c @@ -266,7 +266,7 @@ static const VMStateDescription vmstate_kvaser_pci = { .name = "kvaser_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, KvaserPCIState), /* Load this before sja_state. */ VMSTATE_UINT32(s5920_intcsr, KvaserPCIState), diff --git a/hw/net/can/can_mioe3680_pci.c b/hw/net/can/can_mioe3680_pci.c index b9918773b3..308b17e0c0 100644 --- a/hw/net/can/can_mioe3680_pci.c +++ b/hw/net/can/can_mioe3680_pci.c @@ -203,7 +203,7 @@ static const VMStateDescription vmstate_mioe3680_pci = { .name = "mioe3680_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, Mioe3680PCIState), VMSTATE_STRUCT(sja_state[0], Mioe3680PCIState, 0, vmstate_can_sja, CanSJA1000State), diff --git a/hw/net/can/can_pcm3680_pci.c b/hw/net/can/can_pcm3680_pci.c index 8ef3e4659c..e4c8d93b98 100644 --- a/hw/net/can/can_pcm3680_pci.c +++ b/hw/net/can/can_pcm3680_pci.c @@ -204,7 +204,7 @@ static const VMStateDescription vmstate_pcm3680i_pci = { .name = "pcm3680i_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, Pcm3680iPCIState), VMSTATE_STRUCT(sja_state[0], Pcm3680iPCIState, 0, vmstate_can_sja, CanSJA1000State), diff --git a/hw/net/can/can_sja1000.c b/hw/net/can/can_sja1000.c index 73201f9139..1165d59824 100644 --- a/hw/net/can/can_sja1000.c +++ b/hw/net/can/can_sja1000.c @@ -929,7 +929,7 @@ const VMStateDescription vmstate_qemu_can_filter = { .name = "qemu_can_filter", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(can_id, qemu_can_filter), VMSTATE_UINT32(can_mask, qemu_can_filter), VMSTATE_END_OF_LIST() @@ -953,7 +953,7 @@ const VMStateDescription vmstate_can_sja = { .version_id = 1, .minimum_version_id = 1, .post_load = can_sja_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(mode, CanSJA1000State), VMSTATE_UINT8(status_pel, CanSJA1000State), diff --git a/hw/net/can/ctucan_core.c b/hw/net/can/ctucan_core.c index f2c3b6a706..812b83e93e 100644 --- a/hw/net/can/ctucan_core.c +++ b/hw/net/can/ctucan_core.c @@ -617,7 +617,7 @@ const VMStateDescription vmstate_qemu_ctucan_tx_buffer = { .name = "qemu_ctucan_tx_buffer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(data, CtuCanCoreMsgBuffer, CTUCAN_CORE_MSG_MAX_LEN), VMSTATE_END_OF_LIST() } @@ -636,7 +636,7 @@ const VMStateDescription vmstate_ctucan = { .version_id = 1, .minimum_version_id = 1, .post_load = ctucan_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(mode_settings.u32, CtuCanCoreState), VMSTATE_UINT32(status.u32, CtuCanCoreState), VMSTATE_UINT32(int_stat.u32, CtuCanCoreState), diff --git a/hw/net/can/ctucan_pci.c b/hw/net/can/ctucan_pci.c index ea079e2af5..d8f7344ddc 100644 --- a/hw/net/can/ctucan_pci.c +++ b/hw/net/can/ctucan_pci.c @@ -215,7 +215,7 @@ static const VMStateDescription vmstate_ctucan_pci = { .name = "ctucan_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, CtuCanPCIState), VMSTATE_STRUCT(ctucan_state[0], CtuCanPCIState, 0, vmstate_ctucan, CtuCanCoreState), diff --git a/hw/net/can/xlnx-versal-canfd.c b/hw/net/can/xlnx-versal-canfd.c index 5b8ce0a285..47a14cfe63 100644 --- a/hw/net/can/xlnx-versal-canfd.c +++ b/hw/net/can/xlnx-versal-canfd.c @@ -2060,7 +2060,7 @@ static const VMStateDescription vmstate_canfd = { .name = TYPE_XILINX_CANFD, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxVersalCANFDState, XLNX_VERSAL_CANFD_R_MAX), VMSTATE_PTIMER(canfd_timer, XlnxVersalCANFDState), diff --git a/hw/net/can/xlnx-zynqmp-can.c b/hw/net/can/xlnx-zynqmp-can.c index f60e480c3a..ca0ce4e8bb 100644 --- a/hw/net/can/xlnx-zynqmp-can.c +++ b/hw/net/can/xlnx-zynqmp-can.c @@ -1159,7 +1159,7 @@ static const VMStateDescription vmstate_can = { .name = TYPE_XLNX_ZYNQMP_CAN, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO32(rx_fifo, XlnxZynqMPCANState), VMSTATE_FIFO32(tx_fifo, XlnxZynqMPCANState), VMSTATE_FIFO32(txhpb_fifo, XlnxZynqMPCANState), diff --git a/hw/net/dp8393x.c b/hw/net/dp8393x.c index b16b18b3c3..bf0652da1b 100644 --- a/hw/net/dp8393x.c +++ b/hw/net/dp8393x.c @@ -924,7 +924,7 @@ static const VMStateDescription vmstate_dp8393x = { .name = "dp8393x", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT16_2DARRAY(cam, dp8393xState, 16, 3), VMSTATE_UINT16_ARRAY(regs, dp8393xState, SONIC_REG_COUNT), VMSTATE_END_OF_LIST() diff --git a/hw/net/e1000.c b/hw/net/e1000.c index 8ffe1077f1..43f3a4a701 100644 --- a/hw/net/e1000.c +++ b/hw/net/e1000.c @@ -1437,7 +1437,7 @@ static const VMStateDescription vmstate_e1000_mit_state = { .name = "e1000/mit_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(mac_reg[RDTR], E1000State), VMSTATE_UINT32(mac_reg[RADV], E1000State), VMSTATE_UINT32(mac_reg[TADV], E1000State), @@ -1452,7 +1452,7 @@ static const VMStateDescription vmstate_e1000_full_mac_state = { .version_id = 1, .minimum_version_id = 1, .needed = e1000_full_mac_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(mac_reg, E1000State, 0x8000), VMSTATE_END_OF_LIST() } @@ -1464,7 +1464,7 @@ static const VMStateDescription vmstate_e1000_tx_tso_state = { .minimum_version_id = 1, .needed = e1000_tso_state_needed, .post_load = e1000_tx_tso_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(tx.tso_props.ipcss, E1000State), VMSTATE_UINT8(tx.tso_props.ipcso, E1000State), VMSTATE_UINT16(tx.tso_props.ipcse, E1000State), @@ -1486,7 +1486,7 @@ static const VMStateDescription vmstate_e1000 = { .minimum_version_id = 1, .pre_save = e1000_pre_save, .post_load = e1000_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, E1000State), VMSTATE_UNUSED_TEST(is_version_1, 4), /* was instance id */ VMSTATE_UNUSED(4), /* Was mmio_base. */ @@ -1558,7 +1558,7 @@ static const VMStateDescription vmstate_e1000 = { E1000_VLAN_FILTER_TBL_SIZE), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_e1000_mit_state, &vmstate_e1000_full_mac_state, &vmstate_e1000_tx_tso_state, diff --git a/hw/net/e1000e.c b/hw/net/e1000e.c index e41a6c1038..7c6f602951 100644 --- a/hw/net/e1000e.c +++ b/hw/net/e1000e.c @@ -564,7 +564,7 @@ static const VMStateDescription e1000e_vmstate_tx = { .name = "e1000e-tx", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(sum_needed, struct e1000e_tx), VMSTATE_UINT8(props.ipcss, struct e1000e_tx), VMSTATE_UINT8(props.ipcso, struct e1000e_tx), @@ -588,7 +588,7 @@ static const VMStateDescription e1000e_vmstate_intr_timer = { .name = "e1000e-intr-timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, E1000IntrDelayTimer), VMSTATE_BOOL(running, E1000IntrDelayTimer), VMSTATE_END_OF_LIST() @@ -609,7 +609,7 @@ static const VMStateDescription e1000e_vmstate = { .minimum_version_id = 1, .pre_save = e1000e_pre_save, .post_load = e1000e_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, E1000EState), VMSTATE_MSIX(parent_obj, E1000EState), diff --git a/hw/net/eepro100.c b/hw/net/eepro100.c index 69e1c4bb89..d9a70c4544 100644 --- a/hw/net/eepro100.c +++ b/hw/net/eepro100.c @@ -1772,7 +1772,7 @@ static ssize_t nic_receive(NetClientState *nc, const uint8_t * buf, size_t size) static const VMStateDescription vmstate_eepro100 = { .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, EEPRO100State), VMSTATE_UNUSED(32), VMSTATE_BUFFER(mult, EEPRO100State), diff --git a/hw/net/ftgmac100.c b/hw/net/ftgmac100.c index 78e594afa4..74b6c3d9a7 100644 --- a/hw/net/ftgmac100.c +++ b/hw/net/ftgmac100.c @@ -1119,7 +1119,7 @@ static const VMStateDescription vmstate_ftgmac100 = { .name = TYPE_FTGMAC100, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(irq_state, FTGMAC100State), VMSTATE_UINT32(isr, FTGMAC100State), VMSTATE_UINT32(ier, FTGMAC100State), @@ -1304,7 +1304,7 @@ static const VMStateDescription vmstate_aspeed_mii = { .name = TYPE_ASPEED_MII, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(phycr, FTGMAC100State), VMSTATE_UINT32(phydata, FTGMAC100State), VMSTATE_END_OF_LIST() diff --git a/hw/net/i82596.c b/hw/net/i82596.c index a907f0df8c..6cc8292a65 100644 --- a/hw/net/i82596.c +++ b/hw/net/i82596.c @@ -713,7 +713,7 @@ const VMStateDescription vmstate_i82596 = { .name = "i82596", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(lnkst, I82596State), VMSTATE_TIMER_PTR(flush_queue_timer, I82596State), VMSTATE_END_OF_LIST() diff --git a/hw/net/igb.c b/hw/net/igb.c index 8089acfea4..0b5c31a58b 100644 --- a/hw/net/igb.c +++ b/hw/net/igb.c @@ -520,7 +520,7 @@ static const VMStateDescription igb_vmstate_tx_ctx = { .name = "igb-tx-ctx", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vlan_macip_lens, struct e1000_adv_tx_context_desc), VMSTATE_UINT32(seqnum_seed, struct e1000_adv_tx_context_desc), VMSTATE_UINT32(type_tucmd_mlhl, struct e1000_adv_tx_context_desc), @@ -533,7 +533,7 @@ static const VMStateDescription igb_vmstate_tx = { .name = "igb-tx", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(ctx, struct igb_tx, 2, 0, igb_vmstate_tx_ctx, struct e1000_adv_tx_context_desc), VMSTATE_UINT32(first_cmd_type_len, struct igb_tx), @@ -548,7 +548,7 @@ static const VMStateDescription igb_vmstate_intr_timer = { .name = "igb-intr-timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, IGBIntrDelayTimer), VMSTATE_BOOL(running, IGBIntrDelayTimer), VMSTATE_END_OF_LIST() @@ -569,7 +569,7 @@ static const VMStateDescription igb_vmstate = { .minimum_version_id = 1, .pre_save = igb_pre_save, .post_load = igb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, IGBState), VMSTATE_MSIX(parent_obj, IGBState), diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 6881e3e4f0..cee84af7ba 100644 --- a/hw/net/imx_fec.c +++ b/hw/net/imx_fec.c @@ -195,7 +195,7 @@ static const VMStateDescription vmstate_imx_eth_txdescs = { .version_id = 1, .minimum_version_id = 1, .needed = imx_eth_is_multi_tx_ring, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tx_descriptor[1], IMXFECState), VMSTATE_UINT32(tx_descriptor[2], IMXFECState), VMSTATE_END_OF_LIST() @@ -206,7 +206,7 @@ static const VMStateDescription vmstate_imx_eth = { .name = TYPE_IMX_FEC, .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IMXFECState, ENET_MAX), VMSTATE_UINT32(rx_descriptor, IMXFECState), VMSTATE_UINT32(tx_descriptor[0], IMXFECState), @@ -217,7 +217,7 @@ static const VMStateDescription vmstate_imx_eth = { VMSTATE_UINT32(phy_int_mask, IMXFECState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_imx_eth_txdescs, NULL }, diff --git a/hw/net/lan9118.c b/hw/net/lan9118.c index cf7b8c897a..598dd79e17 100644 --- a/hw/net/lan9118.c +++ b/hw/net/lan9118.c @@ -173,7 +173,7 @@ static const VMStateDescription vmstate_lan9118_packet = { .name = "lan9118_packet", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(state, LAN9118Packet), VMSTATE_UINT32(cmd_a, LAN9118Packet), VMSTATE_UINT32(cmd_b, LAN9118Packet), @@ -271,7 +271,7 @@ static const VMStateDescription vmstate_lan9118 = { .name = "lan9118", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(timer, lan9118_state), VMSTATE_UINT32(irq_cfg, lan9118_state), VMSTATE_UINT32(int_sts, lan9118_state), diff --git a/hw/net/lance.c b/hw/net/lance.c index 4c5f01baad..e1ed24c2ce 100644 --- a/hw/net/lance.c +++ b/hw/net/lance.c @@ -94,7 +94,7 @@ static const VMStateDescription vmstate_lance = { .name = "pcnet", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, SysBusPCNetState, 0, vmstate_pcnet, PCNetState), VMSTATE_END_OF_LIST() } diff --git a/hw/net/lasi_i82596.c b/hw/net/lasi_i82596.c index e37f7fabe9..6a3147fe2d 100644 --- a/hw/net/lasi_i82596.c +++ b/hw/net/lasi_i82596.c @@ -99,7 +99,7 @@ static const VMStateDescription vmstate_lasi_82596 = { .name = "i82596", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(state, SysBusI82596State, 0, vmstate_i82596, I82596State), VMSTATE_END_OF_LIST() diff --git a/hw/net/mipsnet.c b/hw/net/mipsnet.c index 8e925de867..df5101aed7 100644 --- a/hw/net/mipsnet.c +++ b/hw/net/mipsnet.c @@ -218,7 +218,7 @@ static const VMStateDescription vmstate_mipsnet = { .name = "mipsnet", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(busy, MIPSnetState), VMSTATE_UINT32(rx_count, MIPSnetState), VMSTATE_UINT32(rx_read, MIPSnetState), diff --git a/hw/net/msf2-emac.c b/hw/net/msf2-emac.c index 145a5e46ab..c1fc10de2a 100644 --- a/hw/net/msf2-emac.c +++ b/hw/net/msf2-emac.c @@ -557,7 +557,7 @@ static const VMStateDescription vmstate_msf2_emac = { .name = TYPE_MSS_EMAC, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(mac_addr, MSF2EmacState, ETH_ALEN), VMSTATE_UINT32(rx_desc, MSF2EmacState), VMSTATE_UINT16_ARRAY(phy_regs, MSF2EmacState, PHY_MAX_REGS), diff --git a/hw/net/mv88w8618_eth.c b/hw/net/mv88w8618_eth.c index 2185f1131a..96c65f4d46 100644 --- a/hw/net/mv88w8618_eth.c +++ b/hw/net/mv88w8618_eth.c @@ -358,7 +358,7 @@ static const VMStateDescription mv88w8618_eth_vmsd = { .name = "mv88w8618_eth", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(smir, mv88w8618_eth_state), VMSTATE_UINT32(icr, mv88w8618_eth_state), VMSTATE_UINT32(imr, mv88w8618_eth_state), diff --git a/hw/net/ne2000-isa.c b/hw/net/ne2000-isa.c index a79f7fad1f..26980e087e 100644 --- a/hw/net/ne2000-isa.c +++ b/hw/net/ne2000-isa.c @@ -53,7 +53,7 @@ static const VMStateDescription vmstate_isa_ne2000 = { .name = "ne2000", .version_id = 2, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ne2000, ISANE2000State, 0, vmstate_ne2000, NE2000State), VMSTATE_END_OF_LIST() } diff --git a/hw/net/ne2000-pci.c b/hw/net/ne2000-pci.c index fee93c6ec0..74773069c6 100644 --- a/hw/net/ne2000-pci.c +++ b/hw/net/ne2000-pci.c @@ -39,7 +39,7 @@ static const VMStateDescription vmstate_pci_ne2000 = { .name = "ne2000", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCINE2000State), VMSTATE_STRUCT(ne2000, PCINE2000State, 0, vmstate_ne2000, NE2000State), VMSTATE_END_OF_LIST() diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c index d79c884d50..b482c5f3af 100644 --- a/hw/net/ne2000.c +++ b/hw/net/ne2000.c @@ -606,7 +606,7 @@ const VMStateDescription vmstate_ne2000 = { .version_id = 2, .minimum_version_id = 0, .post_load = ne2000_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_V(rxcr, NE2000State, 2), VMSTATE_UINT8(cmd, NE2000State), VMSTATE_UINT32(start, NE2000State), diff --git a/hw/net/npcm7xx_emc.c b/hw/net/npcm7xx_emc.c index 1d4e8f59f3..d1583b6f9b 100644 --- a/hw/net/npcm7xx_emc.c +++ b/hw/net/npcm7xx_emc.c @@ -837,7 +837,7 @@ static const VMStateDescription vmstate_npcm7xx_emc = { .name = TYPE_NPCM7XX_EMC, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(emc_num, NPCM7xxEMCState), VMSTATE_UINT32_ARRAY(regs, NPCM7xxEMCState, NPCM7XX_NUM_EMC_REGS), VMSTATE_BOOL(tx_active, NPCM7xxEMCState), diff --git a/hw/net/pcnet-pci.c b/hw/net/pcnet-pci.c index 96a302c141..fe1a845b2b 100644 --- a/hw/net/pcnet-pci.c +++ b/hw/net/pcnet-pci.c @@ -147,7 +147,7 @@ static const VMStateDescription vmstate_pci_pcnet = { .name = "pcnet", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIPCNetState), VMSTATE_STRUCT(state, PCIPCNetState, 0, vmstate_pcnet, PCNetState), VMSTATE_END_OF_LIST() diff --git a/hw/net/pcnet.c b/hw/net/pcnet.c index a7e123e60d..494eab8479 100644 --- a/hw/net/pcnet.c +++ b/hw/net/pcnet.c @@ -1682,7 +1682,7 @@ const VMStateDescription vmstate_pcnet = { .name = "pcnet", .version_id = 3, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(rap, PCNetState), VMSTATE_INT32(isr, PCNetState), VMSTATE_INT32(lnkst, PCNetState), diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c index 4af8c66266..897c86ec41 100644 --- a/hw/net/rtl8139.c +++ b/hw/net/rtl8139.c @@ -3150,7 +3150,7 @@ static const VMStateDescription vmstate_rtl8139_hotplug_ready ={ .version_id = 1, .minimum_version_id = 1, .needed = rtl8139_hotplug_ready_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() } }; @@ -3173,7 +3173,7 @@ static const VMStateDescription vmstate_rtl8139 = { .minimum_version_id = 3, .post_load = rtl8139_post_load, .pre_save = rtl8139_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, RTL8139State), VMSTATE_PARTIAL_BUFFER(phys, RTL8139State, 6), VMSTATE_BUFFER(mult, RTL8139State), @@ -3257,7 +3257,7 @@ static const VMStateDescription vmstate_rtl8139 = { VMSTATE_UINT32_V(cplus_enabled, RTL8139State, 4), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_rtl8139_hotplug_ready, NULL } diff --git a/hw/net/smc91c111.c b/hw/net/smc91c111.c index 876a78456a..49b7c26102 100644 --- a/hw/net/smc91c111.c +++ b/hw/net/smc91c111.c @@ -62,7 +62,7 @@ static const VMStateDescription vmstate_smc91c111 = { .name = "smc91c111", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(tcr, smc91c111_state), VMSTATE_UINT16(rcr, smc91c111_state), VMSTATE_UINT16(cr, smc91c111_state), diff --git a/hw/net/spapr_llan.c b/hw/net/spapr_llan.c index 475d5f3a34..ecb30b7c76 100644 --- a/hw/net/spapr_llan.c +++ b/hw/net/spapr_llan.c @@ -800,7 +800,7 @@ static const VMStateDescription vmstate_rx_buffer_pool = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_vlan_rx_buffer_pools_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(bufsize, RxBufPool), VMSTATE_INT32(count, RxBufPool), VMSTATE_UINT64_ARRAY(bds, RxBufPool, RX_POOL_MAX_BDS), @@ -813,7 +813,7 @@ static const VMStateDescription vmstate_rx_pools = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_vlan_rx_buffer_pools_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_ARRAY_OF_POINTER_TO_STRUCT(rx_pool, SpaprVioVlan, RX_MAX_POOLS, 1, vmstate_rx_buffer_pool, RxBufPool), @@ -825,7 +825,7 @@ static const VMStateDescription vmstate_spapr_llan = { .name = "spapr_llan", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SPAPR_VIO(sdev, SpaprVioVlan), /* LLAN state */ VMSTATE_BOOL(isopen, SpaprVioVlan), @@ -837,7 +837,7 @@ static const VMStateDescription vmstate_spapr_llan = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_rx_pools, NULL } diff --git a/hw/net/stellaris_enet.c b/hw/net/stellaris_enet.c index 6768a6912f..db95766e29 100644 --- a/hw/net/stellaris_enet.c +++ b/hw/net/stellaris_enet.c @@ -88,7 +88,7 @@ static const VMStateDescription vmstate_rx_frame = { .name = "stellaris_enet/rx_frame", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(data, StellarisEnetRxFrame, 2048), VMSTATE_UINT32(len, StellarisEnetRxFrame), VMSTATE_END_OF_LIST() @@ -133,7 +133,7 @@ static const VMStateDescription vmstate_stellaris_enet = { .version_id = 2, .minimum_version_id = 2, .post_load = stellaris_enet_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ris, stellaris_enet_state), VMSTATE_UINT32(im, stellaris_enet_state), VMSTATE_UINT32(rctl, stellaris_enet_state), diff --git a/hw/net/sungem.c b/hw/net/sungem.c index 013cfc2736..dd1b4a1344 100644 --- a/hw/net/sungem.c +++ b/hw/net/sungem.c @@ -1434,7 +1434,7 @@ static const VMStateDescription vmstate_sungem = { .name = "sungem", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pdev, SunGEMState), VMSTATE_MACADDR(conf.macaddr, SunGEMState), VMSTATE_UINT32(phy_addr, SunGEMState), diff --git a/hw/net/sunhme.c b/hw/net/sunhme.c index ddc83a64bd..ae8452e5f9 100644 --- a/hw/net/sunhme.c +++ b/hw/net/sunhme.c @@ -925,7 +925,7 @@ static const VMStateDescription vmstate_hme = { .name = "sunhme", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, SunHMEState), VMSTATE_MACADDR(conf.macaddr, SunHMEState), VMSTATE_UINT32_ARRAY(sebregs, SunHMEState, (HME_SEB_REG_SIZE >> 2)), diff --git a/hw/net/tulip.c b/hw/net/tulip.c index 962086aae4..6d4fb06dad 100644 --- a/hw/net/tulip.c +++ b/hw/net/tulip.c @@ -48,7 +48,7 @@ struct TULIPState { static const VMStateDescription vmstate_pci_tulip = { .name = "tulip", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, TULIPState), VMSTATE_UINT32_ARRAY(csr, TULIPState, 16), VMSTATE_UINT32(old_csr9, TULIPState), diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 80c56f0cfc..7a2846fa1c 100644 --- a/hw/net/virtio-net.c +++ b/hw/net/virtio-net.c @@ -3113,7 +3113,7 @@ static int virtio_net_post_load_virtio(VirtIODevice *vdev) /* tx_waiting field of a VirtIONetQueue */ static const VMStateDescription vmstate_virtio_net_queue_tx_waiting = { .name = "virtio-net-queue-tx_waiting", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tx_waiting, VirtIONetQueue), VMSTATE_END_OF_LIST() }, @@ -3191,7 +3191,7 @@ static const VMStateDescription vmstate_virtio_net_tx_waiting = { .name = "virtio-net-tx_waiting", .pre_load = virtio_net_tx_waiting_pre_load, .pre_save = virtio_net_tx_waiting_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_UINT16(vqs_1, struct VirtIONetMigTmp, curr_queue_pairs_1, vmstate_virtio_net_queue_tx_waiting, @@ -3228,7 +3228,7 @@ static const VMStateDescription vmstate_virtio_net_has_ufo = { .name = "virtio-net-ufo", .post_load = virtio_net_ufo_post_load, .pre_save = virtio_net_ufo_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(has_ufo, struct VirtIONetMigTmp), VMSTATE_END_OF_LIST() }, @@ -3262,7 +3262,7 @@ static const VMStateDescription vmstate_virtio_net_has_vnet = { .name = "virtio-net-vnet", .post_load = virtio_net_vnet_post_load, .pre_save = virtio_net_vnet_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(has_vnet_hdr, struct VirtIONetMigTmp), VMSTATE_END_OF_LIST() }, @@ -3278,7 +3278,7 @@ static const VMStateDescription vmstate_virtio_net_rss = { .version_id = 1, .minimum_version_id = 1, .needed = virtio_net_rss_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(rss_data.enabled, VirtIONet), VMSTATE_BOOL(rss_data.redirect, VirtIONet), VMSTATE_BOOL(rss_data.populate_hash, VirtIONet), @@ -3299,7 +3299,7 @@ static const VMStateDescription vmstate_virtio_net_device = { .version_id = VIRTIO_NET_VM_VERSION, .minimum_version_id = VIRTIO_NET_VM_VERSION, .post_load = virtio_net_post_load_device, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(mac, VirtIONet, ETH_ALEN), VMSTATE_STRUCT_POINTER(vqs, VirtIONet, vmstate_virtio_net_queue_tx_waiting, @@ -3343,8 +3343,8 @@ static const VMStateDescription vmstate_virtio_net_device = { VMSTATE_UINT64_TEST(curr_guest_offloads, VirtIONet, has_ctrl_guest_offloads), VMSTATE_END_OF_LIST() - }, - .subsections = (const VMStateDescription * []) { + }, + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_net_rss, NULL } @@ -3871,7 +3871,7 @@ static const VMStateDescription vmstate_virtio_net = { .name = "virtio-net", .minimum_version_id = VIRTIO_NET_VM_VERSION, .version_id = VIRTIO_NET_VM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index 6fb4102d03..707487c636 100644 --- a/hw/net/vmxnet3.c +++ b/hw/net/vmxnet3.c @@ -2307,7 +2307,7 @@ static const VMStateDescription vmxstate_vmxnet3_mcast_list = { .minimum_version_id = 1, .pre_load = vmxnet3_mcast_list_pre_load, .needed = vmxnet3_mc_list_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VBUFFER_UINT32(mcast_list, VMXNET3State, 0, NULL, mcast_list_buff_size), VMSTATE_END_OF_LIST() @@ -2317,7 +2317,7 @@ static const VMStateDescription vmxstate_vmxnet3_mcast_list = { static const VMStateDescription vmstate_vmxnet3_ring = { .name = "vmxnet3-ring", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(pa, Vmxnet3Ring), VMSTATE_UINT32(size, Vmxnet3Ring), VMSTATE_UINT32(cell_size, Vmxnet3Ring), @@ -2330,7 +2330,7 @@ static const VMStateDescription vmstate_vmxnet3_ring = { static const VMStateDescription vmstate_vmxnet3_tx_stats = { .name = "vmxnet3-tx-stats", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(TSOPktsTxOK, struct UPT1_TxStats), VMSTATE_UINT64(TSOBytesTxOK, struct UPT1_TxStats), VMSTATE_UINT64(ucastPktsTxOK, struct UPT1_TxStats), @@ -2348,7 +2348,7 @@ static const VMStateDescription vmstate_vmxnet3_tx_stats = { static const VMStateDescription vmstate_vmxnet3_txq_descr = { .name = "vmxnet3-txq-descr", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(tx_ring, Vmxnet3TxqDescr, 0, vmstate_vmxnet3_ring, Vmxnet3Ring), VMSTATE_STRUCT(comp_ring, Vmxnet3TxqDescr, 0, vmstate_vmxnet3_ring, @@ -2364,7 +2364,7 @@ static const VMStateDescription vmstate_vmxnet3_txq_descr = { static const VMStateDescription vmstate_vmxnet3_rx_stats = { .name = "vmxnet3-rx-stats", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(LROPktsRxOK, struct UPT1_RxStats), VMSTATE_UINT64(LROBytesRxOK, struct UPT1_RxStats), VMSTATE_UINT64(ucastPktsRxOK, struct UPT1_RxStats), @@ -2382,7 +2382,7 @@ static const VMStateDescription vmstate_vmxnet3_rx_stats = { static const VMStateDescription vmstate_vmxnet3_rxq_descr = { .name = "vmxnet3-rxq-descr", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(rx_ring, Vmxnet3RxqDescr, VMXNET3_RX_RINGS_PER_QUEUE, 0, vmstate_vmxnet3_ring, Vmxnet3Ring), @@ -2418,7 +2418,7 @@ static int vmxnet3_post_load(void *opaque, int version_id) static const VMStateDescription vmstate_vmxnet3_int_state = { .name = "vmxnet3-int-state", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(is_masked, Vmxnet3IntState), VMSTATE_BOOL(is_pending, Vmxnet3IntState), VMSTATE_BOOL(is_asserted, Vmxnet3IntState), @@ -2432,7 +2432,7 @@ static const VMStateDescription vmstate_vmxnet3 = { .minimum_version_id = 1, .pre_save = vmxnet3_pre_save, .post_load = vmxnet3_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, VMXNET3State), VMSTATE_MSIX(parent_obj, VMXNET3State), VMSTATE_BOOL(rx_packets_compound, VMXNET3State), @@ -2468,7 +2468,7 @@ static const VMStateDescription vmstate_vmxnet3 = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmxstate_vmxnet3_mcast_list, NULL } diff --git a/hw/net/xgmac.c b/hw/net/xgmac.c index 1f4f277d84..ffe3fc8dbe 100644 --- a/hw/net/xgmac.c +++ b/hw/net/xgmac.c @@ -159,7 +159,7 @@ static const VMStateDescription vmstate_rxtx_stats = { .name = "xgmac_stats", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(rx_bytes, RxTxStats), VMSTATE_UINT64(tx_bytes, RxTxStats), VMSTATE_UINT64(rx, RxTxStats), @@ -173,7 +173,7 @@ static const VMStateDescription vmstate_xgmac = { .name = "xgmac", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(stats, XgmacState, 0, vmstate_rxtx_stats, RxTxStats), VMSTATE_UINT32_ARRAY(regs, XgmacState, R_MAX), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:23:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758831 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672147wrw; Fri, 29 Dec 2023 13:30:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IHS9i/bYz9Ha62zkADg+D664ipcHeArH4Go55VS8aOM6eNba0fzW21Zas4YIEOC+9mDgLIr X-Received: by 2002:a05:620a:3916:b0:781:19b2:e1b with SMTP id qr22-20020a05620a391600b0078119b20e1bmr17969346qkn.96.1703885448235; Fri, 29 Dec 2023 13:30:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885448; cv=none; d=google.com; s=arc-20160816; b=fKrzE5REnb8yUGOIlknOqIGbCLNaXQWVA+Fp0WPZgfuvMn0D3h5BkT8JWHQMEpUgsS YZSYXJYnCvp31ngR1dL/366FAnggUZ/pNZA+wWYhcqJFPgSHyoKVZYdpoH/vO+veD6xN D0xyJDfid5XF3cGlIecfSFmTrrHpmn0nj3Syd8xUrTeJTbvmsTUtCKEUsxVmwEqFZn3d 7O99NMkRcP7NCsL1wBk8hfT3VS5TJ6IZCUZ0kXuEUQD+vjpewsVhGKhpL3GFjg92783x yjsQ2I0TKqcOdxLTvvEYlxjbmD977mmZAGD4c+1bTmhqEnEWL9Ms7D8TX3S3gi9H/b/h 5EdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=Vyi0TP52JABfdyZHXUAPl05hmrQ+9G+rb9wPiULLeV0=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=uCSU0eJmBOk8/cxIATwv8vSuYsALfKOXJWIqSK90YXykVDwFkdJHEhjVZmetbBIWEv FFmRqFTaB7YQtJSwJb6TTe+rIxmxjeUh54AaLDgBI61TBVBVeIFwKDsYT/I4DxzDCYp7 M+9faL32z3MJA9BQYueCSXnaI6pdZZa1JgOR47JNzVw8G/M6ECRqNLLcl6uAkJOkdPf5 VENUSX9qgM2+rY33D/NNNDA0LlC+3I8mHsCcC8vduFVAx7Cyds8eblLt+nDvGL07WBLP dIDLkB9xXHhfxABDHPckZZTcAF/UihFLhb23KuiSlmJbEhh6rmmo7zdIgxcS6cB2/GYY R83Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=c7gzHZjB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id f6-20020a05620a280600b007819905a74fsi1541725qkp.474.2023.12.29.13.30.48 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:48 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=c7gzHZjB; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPW-0005ba-Ke; Fri, 29 Dec 2023 16:28:54 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPF-00053u-ND for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:38 -0500 Received: from mail-oa1-x31.google.com ([2001:4860:4864:20::31]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPD-0000JY-C2 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:37 -0500 Received: by mail-oa1-x31.google.com with SMTP id 586e51a60fabf-2043e721daaso4745324fac.2 for ; Fri, 29 Dec 2023 13:28:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885314; x=1704490114; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=Vyi0TP52JABfdyZHXUAPl05hmrQ+9G+rb9wPiULLeV0=; b=c7gzHZjBKrYgsCelADgQktqOxcrT3Pt0CBPNOeJ0iRfgu41ysLdyJoZs8b5aj1Usvm uRHGYBFeE7Qc5oTbgL/m4bq27nxQOu8uhbIuScT1Ffgv3lK8FFXQKJHjgIDh3mpaRIkr 4IIc93hpjSfZm2bn3FWNN9D95vXRxS4z9hptIWnLYjV1jbCeMpnyDbL2VC+dO4/q4Piu 5Xx1DlgdH4IAfWVWyr3Lr+YD4TmiKGE7jDtG4NdRkZ/ZHIf4cdbSnUml7GllyNHFEdLT x8U5EFWGHyPnPSsb/QsnAmzA6K50Sky45ksiKDzf/S6n/wdd7KxHSzJQo5/vhGrZB+Ep W+uw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885314; x=1704490114; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Vyi0TP52JABfdyZHXUAPl05hmrQ+9G+rb9wPiULLeV0=; b=mtKv6KSY482GJwOLqmbxZhMhXVOD9upOgMg3MMSOPuccv6Os15Obk6KL/StBrmp47u OzAgRHcyisk9/6dsElPMjJ6DmnbiJxieUF5cKUF/XnQeWue8RfQOng9czryVvWw6HmSA gYrjYvTILkSKBv8d2tilbZBKfdQpcpL+A+6IvlEzIGXJ+fiUsjd62tfG7BoaVFZ43Ram iHB9794BcjiMc/u13z9tN6PbNaPM40ffRN7u8Y1qUZBC9TPTwSBOcVDHCCQwRcVKrROD yZcxhGGINoOUywVSS/qeAiMFjeeKN3VNoUYKIsKjqN6GswSv0DPsO+lzoNqNoBpxACbx I9UA== X-Gm-Message-State: AOJu0YwKMMAQAzLedfsQwpSBB70T0z/F077HK1eVAkgkla4pmqUiiHHH a34Hai3kN6Hte3cy631oEfSjXMWvM1Sv/vQyCRt3bNRwzPDk+Q== X-Received: by 2002:a05:6870:355:b0:203:e0bc:5e11 with SMTP id n21-20020a056870035500b00203e0bc5e11mr13554325oaf.70.1703885314127; Fri, 29 Dec 2023 13:28:34 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:33 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 42/71] hw/nvram: Constify VMState Date: Sat, 30 Dec 2023 08:23:17 +1100 Message-Id: <20231229212346.147149-43-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::31; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x31.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-43-richard.henderson@linaro.org> --- hw/nvram/ds1225y.c | 2 +- hw/nvram/eeprom93xx.c | 2 +- hw/nvram/fw_cfg.c | 8 ++++---- hw/nvram/mac_nvram.c | 2 +- hw/nvram/npcm7xx_otp.c | 2 +- hw/nvram/nrf51_nvm.c | 2 +- hw/nvram/spapr_nvram.c | 2 +- hw/nvram/xlnx-bbram.c | 2 +- hw/nvram/xlnx-versal-efuse-ctrl.c | 2 +- hw/nvram/xlnx-zynqmp-efuse.c | 2 +- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/hw/nvram/ds1225y.c b/hw/nvram/ds1225y.c index 3660a47c51..6d510dcc68 100644 --- a/hw/nvram/ds1225y.c +++ b/hw/nvram/ds1225y.c @@ -102,7 +102,7 @@ static const VMStateDescription vmstate_nvram = { .version_id = 0, .minimum_version_id = 0, .post_load = nvram_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VARRAY_UINT32(contents, NvRamState, chip_size, 0, vmstate_info_uint8, uint8_t), VMSTATE_END_OF_LIST() diff --git a/hw/nvram/eeprom93xx.c b/hw/nvram/eeprom93xx.c index 57d63638d7..a8fd60a8fb 100644 --- a/hw/nvram/eeprom93xx.c +++ b/hw/nvram/eeprom93xx.c @@ -131,7 +131,7 @@ static const VMStateDescription vmstate_eeprom = { .name = "eeprom", .version_id = EEPROM_VERSION, .minimum_version_id = OLD_EEPROM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(tick, eeprom_t), VMSTATE_UINT8(address, eeprom_t), VMSTATE_UINT8(command, eeprom_t), diff --git a/hw/nvram/fw_cfg.c b/hw/nvram/fw_cfg.c index 4e4524673a..e85493d513 100644 --- a/hw/nvram/fw_cfg.c +++ b/hw/nvram/fw_cfg.c @@ -656,7 +656,7 @@ static int fw_cfg_acpi_mr_restore_post_load(void *opaque, int version_id) static const VMStateDescription vmstate_fw_cfg_dma = { .name = "fw_cfg/dma", .needed = fw_cfg_dma_enabled, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(dma_addr, FWCfgState), VMSTATE_END_OF_LIST() }, @@ -668,7 +668,7 @@ static const VMStateDescription vmstate_fw_cfg_acpi_mr = { .minimum_version_id = 1, .needed = fw_cfg_acpi_mr_restore, .post_load = fw_cfg_acpi_mr_restore_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(table_mr_size, FWCfgState), VMSTATE_UINT64(linker_mr_size, FWCfgState), VMSTATE_UINT64(rsdp_mr_size, FWCfgState), @@ -680,13 +680,13 @@ static const VMStateDescription vmstate_fw_cfg = { .name = "fw_cfg", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(cur_entry, FWCfgState), VMSTATE_UINT16_HACK(cur_offset, FWCfgState, is_version_1), VMSTATE_UINT32_V(cur_offset, FWCfgState, 2), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_fw_cfg_dma, &vmstate_fw_cfg_acpi_mr, NULL, diff --git a/hw/nvram/mac_nvram.c b/hw/nvram/mac_nvram.c index 810e84f07e..5f9d16fb3e 100644 --- a/hw/nvram/mac_nvram.c +++ b/hw/nvram/mac_nvram.c @@ -79,7 +79,7 @@ static const VMStateDescription vmstate_macio_nvram = { .name = "macio_nvram", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VBUFFER_UINT32(data, MacIONVRAMState, 0, NULL, size), VMSTATE_END_OF_LIST() } diff --git a/hw/nvram/npcm7xx_otp.c b/hw/nvram/npcm7xx_otp.c index c61f2fc1aa..f00ebfa931 100644 --- a/hw/nvram/npcm7xx_otp.c +++ b/hw/nvram/npcm7xx_otp.c @@ -384,7 +384,7 @@ static const VMStateDescription vmstate_npcm7xx_otp = { .name = "npcm7xx-otp", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, NPCM7xxOTPState, NPCM7XX_OTP_NR_REGS), VMSTATE_UINT8_ARRAY(array, NPCM7xxOTPState, NPCM7XX_OTP_ARRAY_BYTES), VMSTATE_END_OF_LIST(), diff --git a/hw/nvram/nrf51_nvm.c b/hw/nvram/nrf51_nvm.c index 7f1db8c423..ed8b836074 100644 --- a/hw/nvram/nrf51_nvm.c +++ b/hw/nvram/nrf51_nvm.c @@ -366,7 +366,7 @@ static const VMStateDescription vmstate_nvm = { .name = "nrf51_soc.nvm", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(uicr_content, NRF51NVMState, NRF51_UICR_FIXTURE_SIZE), VMSTATE_UINT32(config, NRF51NVMState), diff --git a/hw/nvram/spapr_nvram.c b/hw/nvram/spapr_nvram.c index 2d72f30442..bfd8aa367e 100644 --- a/hw/nvram/spapr_nvram.c +++ b/hw/nvram/spapr_nvram.c @@ -245,7 +245,7 @@ static const VMStateDescription vmstate_spapr_nvram = { .minimum_version_id = 1, .pre_load = spapr_nvram_pre_load, .post_load = spapr_nvram_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(size, SpaprNvram), VMSTATE_VBUFFER_ALLOC_UINT32(buf, SpaprNvram, 1, NULL, size), VMSTATE_END_OF_LIST() diff --git a/hw/nvram/xlnx-bbram.c b/hw/nvram/xlnx-bbram.c index e18e7770e1..0a71a005c6 100644 --- a/hw/nvram/xlnx-bbram.c +++ b/hw/nvram/xlnx-bbram.c @@ -508,7 +508,7 @@ static const VMStateDescription vmstate_bbram_ctrl = { .name = TYPE_XLNX_BBRAM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxBBRam, R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/nvram/xlnx-versal-efuse-ctrl.c b/hw/nvram/xlnx-versal-efuse-ctrl.c index 2480af35e1..e4b9e11a3d 100644 --- a/hw/nvram/xlnx-versal-efuse-ctrl.c +++ b/hw/nvram/xlnx-versal-efuse-ctrl.c @@ -737,7 +737,7 @@ static const VMStateDescription vmstate_efuse_ctrl = { .name = TYPE_XLNX_VERSAL_EFUSE_CTRL, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxVersalEFuseCtrl, R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/nvram/xlnx-zynqmp-efuse.c b/hw/nvram/xlnx-zynqmp-efuse.c index 3db5f98ec1..ec98456e5d 100644 --- a/hw/nvram/xlnx-zynqmp-efuse.c +++ b/hw/nvram/xlnx-zynqmp-efuse.c @@ -821,7 +821,7 @@ static const VMStateDescription vmstate_efuse = { .name = TYPE_XLNX_ZYNQMP_EFUSE, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZynqMPEFuse, R_MAX), VMSTATE_END_OF_LIST(), } From patchwork Fri Dec 29 21:23:18 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758828 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672068wrw; Fri, 29 Dec 2023 13:30:30 -0800 (PST) X-Google-Smtp-Source: AGHT+IHDsemVMfA6OMig3xlNmmC4theLnQ+YTgxgZFk3j/dxT7Hs9dEGcqNPmjkqcKbwpvZiBCON X-Received: by 2002:a05:6871:5b20:b0:203:e21d:9929 with SMTP id op32-20020a0568715b2000b00203e21d9929mr8776405oac.26.1703885429928; Fri, 29 Dec 2023 13:30:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885429; cv=none; d=google.com; s=arc-20160816; b=a4S8QCiGme4KDY8OELQRvnL6CqJ8FHjXY8qyX3319YjMOH5/vhNiG2Lx8nY8iJLe+P kCW28bKjype3YKn2Sv4lTekz7v1Wzza0TATz2HkNOfSwQxCFcG/VhfBu6UyujWtL3LlT lFQrcGKbClgNH6aZMydZD+QbGkxRW+Mo6bW3ClsKU6vmia2K2I34AFiLD042/tVZjdrS d9/23vEFF5w8NEy/Ud8Ov7AqBTN45WZZGWP7wJ8oMb8x7FxuM5V1/i+iAJQxsVPJu45B Ug6RmLLE9YfXgTfTqTZR+60MEeTyzwm9h1TdDp6UPv7z2yEVnrXFhB+v1lMRRrtOxDMp rSMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=8qiXeFCQHMfrcvkAhK1aChACVtlmSwMwxlo4rTy0C0U=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=e9+T19it/n+wd5Jp9IJqB0Vw0yvNvwcOI4V2j/ZXN+Q5VmKAhlVL0kFJcyjO0ToFry WP9pLVjTR9l+Ch9QZl4DrIhSBSCjNOr+qX7VDxhlklmFGMjhxSsFg/uSiS1R08sShIlT rKLdlXp8EkzLbNDRWXDBVtG5Yac8wnVhAotdHAp+fMd5DdqwU6VqwIEKTFfBqzxRDuQG s+R+wotuAwpOF9QzcIsG+Zhidp1STWtQx0J3p0BcEyDqo33bGhD/h1zCQorwmEwBKRUg anjPhEuxeE7WGObU8Rk9Q4kzrfX0I370K2RxBw/T2dnsPhTIfMHFM1RUcjR43uvOu4Id Tbcw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=uE97oOV+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id u17-20020a05620a023100b00780f8f53c87si19798156qkm.695.2023.12.29.13.30.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:29 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=uE97oOV+; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPR-0005Gv-Tt; Fri, 29 Dec 2023 16:28:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPH-00059z-MY for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:40 -0500 Received: from mail-pg1-x52f.google.com ([2607:f8b0:4864:20::52f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPG-0000Jp-03 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:39 -0500 Received: by mail-pg1-x52f.google.com with SMTP id 41be03b00d2f7-5ce2170b716so2874504a12.1 for ; Fri, 29 Dec 2023 13:28:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885316; x=1704490116; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=8qiXeFCQHMfrcvkAhK1aChACVtlmSwMwxlo4rTy0C0U=; b=uE97oOV+JCRQJNiJHcKbswSjj2hOz7h4Tkb1DgXgKbMhB5jhof945wzjw10apnDq7B oJt71pQTw0QSHPVkdfVREa+lPWNyfCDV3GUovhujUF6NH3ZrsoxUAzELL84vRNKRd5gu YJei2he+4aEvt61WXQBlGOw87YEBRfFfYhDMNF/WdLod+LRTcFEhJMLz1BX70Xuv57nr TntS1h7EDlTGrhd1ui5OCgB4x5VtaV/+2Zl9ypjnh5oWTrvIoKzrE3ue2lE6KB2AUye6 eta6ryq7X70OPQhtkGHBO/MM4D5fR4mdVOfDewn22z3I1xQ/eKEtBXEonegHAFMD7nhj 2SLg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885316; x=1704490116; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8qiXeFCQHMfrcvkAhK1aChACVtlmSwMwxlo4rTy0C0U=; b=J1wlW3B6AuSqjI1hpMWPskzl9ejG74KDRZZHmIuBVIM94Wuy9aiLukTcI8I048B3pV swjESHaSsPgwUiTWalTozl2wDJc6GC7agP5u7zgTRTHh/XsrnxXKdw374nkOxa0RVFX1 FUCDs32yi5PcDZkrqx/zukfWazjZ8mOHSiBuWofWlLoMk7N3OxqeY+VN7EhctJOZTEuY Cbn4CjXKc8y+8dB5WjItNVRCZWSFtFcgZriky+fyG9hRv7t/SVDkekqKVuK2AMfgKlNW QSEOwZv6LTCSekfSmCA5CL4XGsHwMaB1uitGmRZzvzCN9TitFxM+AVvUdkoPyYOkLyer aBOA== X-Gm-Message-State: AOJu0YyTIgam3kYCsYf/rSndJ1kBpKgjY1mVFQ6jDL7S4vT+y5Yg2kfN u0kdEKJdRXE7QEtETQ6QFnEQeZ7OVlsJivVUbhg45ns4KnIeGQ== X-Received: by 2002:a05:6a20:8f01:b0:196:4d6a:c88d with SMTP id b1-20020a056a208f0100b001964d6ac88dmr3359105pzk.50.1703885316349; Fri, 29 Dec 2023 13:28:36 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.34 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:36 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 43/71] hw/openrisc: Constify VMState Date: Sat, 30 Dec 2023 08:23:18 +1100 Message-Id: <20231229212346.147149-44-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52f; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52f.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-44-richard.henderson@linaro.org> --- hw/openrisc/cputimer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/openrisc/cputimer.c b/hw/openrisc/cputimer.c index 10163b391b..835986c4db 100644 --- a/hw/openrisc/cputimer.c +++ b/hw/openrisc/cputimer.c @@ -145,7 +145,7 @@ static const VMStateDescription vmstate_or1k_timer = { .name = "or1k_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ttcr, OR1KTimerState), VMSTATE_UINT64(last_clk, OR1KTimerState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:23:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758853 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672645wrw; Fri, 29 Dec 2023 13:32:22 -0800 (PST) X-Google-Smtp-Source: AGHT+IGXtDR3y80bV/FP3r3Ai+ThnhhlcgL+9e64agpk/2OnYU1Hsj6QCzxAR7PQ15cOMxhKx57p X-Received: by 2002:a05:620a:384f:b0:781:97b:3365 with SMTP id po15-20020a05620a384f00b00781097b3365mr13626811qkn.29.1703885542574; Fri, 29 Dec 2023 13:32:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885542; cv=none; d=google.com; s=arc-20160816; b=Lo9XbR/aEPFq/AAK1jPC6aVQMl1hC4+nOmBmS61nVCM6itjmp0v9oBHFdUZn+ktFLM aD/5uNp++ytW/EZAnGRDIahUgwfYeNxzf6X0gOQfO9pX3iMeyeTRLCZBAfx1xFTt1EXY t+umNQTOA956mfAwLd2KuqrUHV1GCFdvzmqYhMlFNo7Nio64v/yvemGA6ppQcl8rQliC WvYfYsVmUDTdNTxdnohxT/QcRfwRV8rQXgS0YCNy9/D7N22qtuc1xl9M3My794GLlvU4 lZeovqPkaXAbSShqGm0beu4KcvbWRnflZWRgOaVCBQ3YhuaaHweKbE0+H7AqyFYShCwV lHPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=CUHhbLfoN2d7ET2o9i2N09+Q0gqs/g1wftGgAlf1CKE=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=DblJSgdQWqlAYGRC7oJuFCKnChCLAln0Xb4Hm103oNkVhU/3J09ToW3NnddvLnDHHy 3ECRmlTNVeNU67tGHSaUyqWFRazg2pGxaf7iuUnh1jMRamK7iKsHQqSVdSMmXBo2CDzA DG2OECgLUuIgF3YbYN9utMR/4oyZ6EZsVZkj0KimK2rhYLP/dO+oSEcrVyYuMD7qL01q jDKipOhEwngJqPz+DCKYhvh3WMRf6PuPoW8LeMZNvrJGUNnng0WvzBUCO64mJ3ZW/xm8 NqR3QtAjV2fJqFGc4Kum9cIK9w8xWYJKXjjCS+2kDzYyiBB1A+OkmEARrTrxXXhUFOtH 3Gkw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=bljjymqY; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id ov8-20020a05620a628800b007815fe669aesi6768634qkn.50.2023.12.29.13.32.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:32:22 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=bljjymqY; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPa-0006BS-GO; Fri, 29 Dec 2023 16:28:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPQ-0005Gu-3m for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:49 -0500 Received: from mail-pf1-x429.google.com ([2607:f8b0:4864:20::429]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPH-0000KI-Jd for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:41 -0500 Received: by mail-pf1-x429.google.com with SMTP id d2e1a72fcca58-6d9a79a1ad4so1725270b3a.2 for ; Fri, 29 Dec 2023 13:28:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885318; x=1704490118; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=CUHhbLfoN2d7ET2o9i2N09+Q0gqs/g1wftGgAlf1CKE=; b=bljjymqYnNO8iK9/Iq7ctY2yVNoBVBlVjKcTS7/3BTpYLZKhZqvXinfe4tMCb6TKIj 5PrEjeNQSohtxoMtiGDPze0UaGi2tcBpm7TY/CzL6cY5iYAvcEYsBKf8VFvw0QxQjK2Q hmovYkYylKwB1VmDu+RtIr5pm4jTjgFPCJ0wQ//F+78ApUagvJslycxLilYAElzbzJcv KvaTOg22cw4Gq695AUTQvU9KY+JxYohCU5krQcwBGqwtCjzbmHeoHq/uu6EtCiBZliMF pVjoQmnYY7oxTyX9MsrmDDUiI5X0N8jUFKR5IqgQgcHlwtGIoso262Mi7knlJ4IqwF4L oYkg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885318; x=1704490118; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CUHhbLfoN2d7ET2o9i2N09+Q0gqs/g1wftGgAlf1CKE=; b=Zz4txlDWA6Epab1AIuZnOHcbyOZIPk+CQZLCLAE7um7yd4ASr2Ea8qbI+hzGmt5hKo AKZWWigIDZpxGtrqdBAkmm+Eq8MAhsuxat3dkh0wLlj0IaxaNkP1XYlk6ahQjQxwqkQn p2W7UssS6paZsXgjUhEMHX9jAe0rzm6lqT7FGpoBmZWxGANKG6GplhIhHKpz6FRFN2Bz xBNaOeAJnpanTAvQvD8wjgbEEqNwKK1+YAJ5Fwnggi9P1QxGZqfX9VuD4ZUyv451czpC FCU2ZgBB7QkV5opLejji3rLHmfnZkjzTMmiduHRtAdBDMGdB977Jm/qi30ME5zBS8ZS/ VATA== X-Gm-Message-State: AOJu0YzYhEwl6LnPiB/tx1FU7hJo6p2PFz8qZ/rasEwD+hi+ZtbOdFMT YCD71znD8AA+swUO+r5tyz4z+qAwRlRHpu2GQEpBSckowmUyKQ== X-Received: by 2002:a05:6a00:1404:b0:6d9:a9e9:28dd with SMTP id l4-20020a056a00140400b006d9a9e928ddmr5111526pfu.51.1703885318331; Fri, 29 Dec 2023 13:28:38 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:37 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 44/71] hw/pci: Constify VMState Date: Sat, 30 Dec 2023 08:23:19 +1100 Message-Id: <20231229212346.147149-45-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::429; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x429.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-45-richard.henderson@linaro.org> --- include/hw/pci/shpc.h | 2 +- hw/pci/msix.c | 4 ++-- hw/pci/pci.c | 8 ++++---- hw/pci/pci_host.c | 2 +- hw/pci/pcie_aer.c | 4 ++-- hw/pci/shpc.c | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/include/hw/pci/shpc.h b/include/hw/pci/shpc.h index 89c7a3b7fa..a0789df153 100644 --- a/include/hw/pci/shpc.h +++ b/include/hw/pci/shpc.h @@ -52,7 +52,7 @@ void shpc_device_unplug_cb(HotplugHandler *hotplug_dev, DeviceState *dev, void shpc_device_unplug_request_cb(HotplugHandler *hotplug_dev, DeviceState *dev, Error **errp); -extern VMStateInfo shpc_vmstate_info; +extern const VMStateInfo shpc_vmstate_info; #define SHPC_VMSTATE(_field, _type, _test) \ VMSTATE_BUFFER_UNSAFE_INFO_TEST(_field, _type, _test, 0, \ shpc_vmstate_info, 0) diff --git a/hw/pci/msix.c b/hw/pci/msix.c index cd817f4ca8..487e49834e 100644 --- a/hw/pci/msix.c +++ b/hw/pci/msix.c @@ -685,7 +685,7 @@ static int get_msix_state(QEMUFile *f, void *pv, size_t size, return 0; } -static VMStateInfo vmstate_info_msix = { +static const VMStateInfo vmstate_info_msix = { .name = "msix state", .get = get_msix_state, .put = put_msix_state, @@ -693,7 +693,7 @@ static VMStateInfo vmstate_info_msix = { const VMStateDescription vmstate_msix = { .name = "msix", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { { .name = "msix", .version_id = 0, diff --git a/hw/pci/pci.c b/hw/pci/pci.c index c49417abb2..76080af580 100644 --- a/hw/pci/pci.c +++ b/hw/pci/pci.c @@ -92,7 +92,7 @@ static const VMStateDescription vmstate_pcibus = { .name = "PCIBUS", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_EQUAL(nirq, PCIBus, NULL), VMSTATE_VARRAY_INT32(irq_count, PCIBus, nirq, 0, vmstate_info_int32, @@ -673,7 +673,7 @@ static int put_pci_config_device(QEMUFile *f, void *pv, size_t size, return 0; } -static VMStateInfo vmstate_info_pci_config = { +static const VMStateInfo vmstate_info_pci_config = { .name = "pci config", .get = get_pci_config_device, .put = put_pci_config_device, @@ -714,7 +714,7 @@ static int put_pci_irq_state(QEMUFile *f, void *pv, size_t size, return 0; } -static VMStateInfo vmstate_info_pci_irq_state = { +static const VMStateInfo vmstate_info_pci_irq_state = { .name = "pci irq state", .get = get_pci_irq_state, .put = put_pci_irq_state, @@ -734,7 +734,7 @@ const VMStateDescription vmstate_pci_device = { .name = "PCIDevice", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_POSITIVE_LE(version_id, PCIDevice), VMSTATE_BUFFER_UNSAFE_INFO_TEST(config, PCIDevice, migrate_is_not_pcie, diff --git a/hw/pci/pci_host.c b/hw/pci/pci_host.c index a18aa0a8d4..dfe6fe6184 100644 --- a/hw/pci/pci_host.c +++ b/hw/pci/pci_host.c @@ -234,7 +234,7 @@ const VMStateDescription vmstate_pcihost = { .needed = pci_host_needed, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(config_reg, PCIHostState), VMSTATE_END_OF_LIST() } diff --git a/hw/pci/pcie_aer.c b/hw/pci/pcie_aer.c index b68c7ecb49..2c85a78fcd 100644 --- a/hw/pci/pcie_aer.c +++ b/hw/pci/pcie_aer.c @@ -797,7 +797,7 @@ static const VMStateDescription vmstate_pcie_aer_err = { .name = "PCIE_AER_ERROR", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(status, PCIEAERErr), VMSTATE_UINT16(source_id, PCIEAERErr), VMSTATE_UINT16(flags, PCIEAERErr), @@ -818,7 +818,7 @@ const VMStateDescription vmstate_pcie_aer_log = { .name = "PCIE_AER_ERROR_LOG", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(log_num, PCIEAERLog), VMSTATE_UINT16_EQUAL(log_max, PCIEAERLog, NULL), VMSTATE_VALIDATE("log_num <= log_max", pcie_aer_state_log_num_valid), diff --git a/hw/pci/shpc.c b/hw/pci/shpc.c index df7f370111..d2a5eea69e 100644 --- a/hw/pci/shpc.c +++ b/hw/pci/shpc.c @@ -736,7 +736,7 @@ static int shpc_load(QEMUFile *f, void *pv, size_t size, return 0; } -VMStateInfo shpc_vmstate_info = { +const VMStateInfo shpc_vmstate_info = { .name = "shpc", .get = shpc_load, .put = shpc_save, From patchwork Fri Dec 29 21:23:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758822 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671850wrw; Fri, 29 Dec 2023 13:29:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IFqgnQqrHjO3/Se6Zw/ZYQUsSerQ3wPfaziJWM2IzoSbL4wisq1RIm7K3StIDRTKxyjZIen X-Received: by 2002:a05:620a:2233:b0:781:62ce:b0fc with SMTP id n19-20020a05620a223300b0078162ceb0fcmr4080464qkh.27.1703885383138; Fri, 29 Dec 2023 13:29:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885383; cv=none; d=google.com; s=arc-20160816; b=nZ5KBa7VyU2T64azaH7gH+Wht6i5ZgmDYcyZ0u2dtCF2Fn62FbTcGMOIigbO8l4QCe KUC+QYYuuohwefUanXZ1yMfGquv13gtqYuiCCo7prNrgijNELiRfSBrAmD8eMEeH7fJK iUcCEo+C7J6/fHTRrpQ5SWjts+d/ycfS69G19p1g3XYD1tx9UJg6XqhA72Nkw/7x/FSf JXpEOjjCDB4jUSpJ5LGw2w7pEmepuoGOBO8z8bYk5JnaU8D2okDPxMHPThYGeQ5aQsM6 fHV4f4euL7kNsoTB8WHIyfLj3DK7AzDQD2SJ87WaisSg8ucppvUR3VOjOvZmZeE45nac LiHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=sb0kvKmYxUvHaaVG2ec6NYva65clnrsq/dPDXpOeYAM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=Xd3n9O+PJwwfnuL9FxeqHXopfDnmeFyrZ+et3IswYbvVU8s16TXtjSzVF34nzeXJLw avCz69KX1B9fL0ediSIwkcwoYvsMjxm9hmS0CrNXH+mbPmw7PguV45jVuhMZ0JpDn7Vt abZKGTuDi5aDMVvRqwOuXGjUNC3tbI9YIcjap/eOn84QBfniHT8bo1XS51iXWZ+5noRW FvtThNo4X+crhILeVMrBadHW7hOteEkWCZaIIe0y0SZC6Yn3ETcIBGlJC3L/+T70jafy uVKwP45PAlmVd3QEV7BBfdJtCu6WshQXp7YL2H5MRTpj7WGw9FG88vtjxpVjmJOqPpxB vSKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=WbC4PJQA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x12-20020a05620a258c00b00781723f0a42si4847038qko.137.2023.12.29.13.29.42 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:43 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=WbC4PJQA; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPX-0005jb-JA; Fri, 29 Dec 2023 16:28:55 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPR-0005My-GA for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:49 -0500 Received: from mail-oa1-x29.google.com ([2001:4860:4864:20::29]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPP-0000Ka-PM for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:49 -0500 Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-203fe0e3fefso3880165fac.2 for ; Fri, 29 Dec 2023 13:28:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885320; x=1704490120; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=sb0kvKmYxUvHaaVG2ec6NYva65clnrsq/dPDXpOeYAM=; b=WbC4PJQAaiu1zifnjdFMeSOVrJxv4eNzUO3iccmeRuElgM2I+PaAROCJoM+LhtMOYI mCNYklWshXnrr8tOfXRu0X+CtV4werPmoO+mQsm3CmpBAd8jyYtVbdnjxjvnLFkqabYI iT/3s6VXl6M+DfIiBdrsEdvngDTnvkhRxsgKFncWNath1fEGVNmBSEos5jJ3LGRKaH3v pjeOrEPB/Wu4QNC8nvyy0MK3aOSpOXGwAbqKYD8IAyxWgYcJvQvy1wlVSW2UUzcpx9El qacGLlAA2xQ4IU8mklrnPDdxyWSJd2f8TRivJYkYpx8O3KPxosU4LMEw3J6yFrLAQiN6 DEYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885320; x=1704490120; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=sb0kvKmYxUvHaaVG2ec6NYva65clnrsq/dPDXpOeYAM=; b=e5huscZVNrXZONgYfQjWdWorOrctFjnymFtD5ItXlhT4YRIanlP25YpGjzuDGjinoA VJddSHVN0bWBjxbB07AIU4EFJzYXellUeR1yamwP+BcGrZfL2Z++LD3ekHhzQmeHSWD+ lDGMOZz4PBNka4CFFUF6y9G65+647ohqf9vC1BPivmni9lKj9Asm+hgQ2fDtCkFBLSqw ed2FsILL7y4EC+TeKq5dbOvRsfqafjTel6WqAjWnpuIJdosumtJlTgE10OAhU7M09VnT TyjB3T0I1RTOOGTpvCQjG58LKxbBri/lbILeD3RD6IeVIJ94ZJthQ3PgFTglTjuuGsyO kLzQ== X-Gm-Message-State: AOJu0YzJI1ehQZ8Gvr3NwD3+7q+oaHAE8CwIFYkIOERzV/xeuAEV7vzw A7eraZTqyOvqF/i/8HTzTaUF6ue2/jWmoMlm0RgEmbMPf4oemQ== X-Received: by 2002:a05:6870:c1cb:b0:203:4504:542d with SMTP id i11-20020a056870c1cb00b002034504542dmr10400384oad.58.1703885320602; Fri, 29 Dec 2023 13:28:40 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:40 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 45/71] hw/pci-bridge: Constify VMState Date: Sat, 30 Dec 2023 08:23:20 +1100 Message-Id: <20231229212346.147149-46-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::29; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x29.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-46-richard.henderson@linaro.org> --- hw/pci-bridge/gen_pcie_root_port.c | 2 +- hw/pci-bridge/i82801b11.c | 2 +- hw/pci-bridge/ioh3420.c | 2 +- hw/pci-bridge/pci_bridge_dev.c | 2 +- hw/pci-bridge/pcie_pci_bridge.c | 2 +- hw/pci-bridge/xio3130_downstream.c | 2 +- hw/pci-bridge/xio3130_upstream.c | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/hw/pci-bridge/gen_pcie_root_port.c b/hw/pci-bridge/gen_pcie_root_port.c index 1ce4e7beba..784507c826 100644 --- a/hw/pci-bridge/gen_pcie_root_port.c +++ b/hw/pci-bridge/gen_pcie_root_port.c @@ -117,7 +117,7 @@ static const VMStateDescription vmstate_rp_dev = { .version_id = 1, .minimum_version_id = 1, .post_load = pcie_cap_slot_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent_obj.parent_obj, PCIESlot), VMSTATE_STRUCT(parent_obj.parent_obj.parent_obj.exp.aer_log, PCIESlot, 0, vmstate_pcie_aer_log, PCIEAERLog), diff --git a/hw/pci-bridge/i82801b11.c b/hw/pci-bridge/i82801b11.c index 0e83cd11b2..c140919cbc 100644 --- a/hw/pci-bridge/i82801b11.c +++ b/hw/pci-bridge/i82801b11.c @@ -81,7 +81,7 @@ err_bridge: static const VMStateDescription i82801b11_bridge_dev_vmstate = { .name = "i82801b11_bridge", .priority = MIG_PRI_PCI_BUS, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIBridge), VMSTATE_END_OF_LIST() } diff --git a/hw/pci-bridge/ioh3420.c b/hw/pci-bridge/ioh3420.c index f1e16135a3..be752a4bda 100644 --- a/hw/pci-bridge/ioh3420.c +++ b/hw/pci-bridge/ioh3420.c @@ -88,7 +88,7 @@ static const VMStateDescription vmstate_ioh3420 = { .version_id = 1, .minimum_version_id = 1, .post_load = pcie_cap_slot_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent_obj.parent_obj, PCIESlot), VMSTATE_STRUCT(parent_obj.parent_obj.parent_obj.exp.aer_log, PCIESlot, 0, vmstate_pcie_aer_log, PCIEAERLog), diff --git a/hw/pci-bridge/pci_bridge_dev.c b/hw/pci-bridge/pci_bridge_dev.c index 4b2696ea7f..089f91efed 100644 --- a/hw/pci-bridge/pci_bridge_dev.c +++ b/hw/pci-bridge/pci_bridge_dev.c @@ -199,7 +199,7 @@ static bool pci_device_shpc_present(void *opaque, int version_id) static const VMStateDescription pci_bridge_dev_vmstate = { .name = "pci_bridge", .priority = MIG_PRI_PCI_BUS, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIBridge), SHPC_VMSTATE(shpc, PCIDevice, pci_device_shpc_present), VMSTATE_END_OF_LIST() diff --git a/hw/pci-bridge/pcie_pci_bridge.c b/hw/pci-bridge/pcie_pci_bridge.c index 2301b2ca0b..7646ac2397 100644 --- a/hw/pci-bridge/pcie_pci_bridge.c +++ b/hw/pci-bridge/pcie_pci_bridge.c @@ -132,7 +132,7 @@ static Property pcie_pci_bridge_dev_properties[] = { static const VMStateDescription pcie_pci_bridge_dev_vmstate = { .name = TYPE_PCIE_PCI_BRIDGE_DEV, .priority = MIG_PRI_PCI_BUS, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIBridge), SHPC_VMSTATE(shpc, PCIDevice, NULL), VMSTATE_END_OF_LIST() diff --git a/hw/pci-bridge/xio3130_downstream.c b/hw/pci-bridge/xio3130_downstream.c index 38a2361fa2..907d5105b0 100644 --- a/hw/pci-bridge/xio3130_downstream.c +++ b/hw/pci-bridge/xio3130_downstream.c @@ -146,7 +146,7 @@ static const VMStateDescription vmstate_xio3130_downstream = { .version_id = 1, .minimum_version_id = 1, .post_load = pcie_cap_slot_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent_obj.parent_obj, PCIESlot), VMSTATE_STRUCT(parent_obj.parent_obj.parent_obj.exp.aer_log, PCIESlot, 0, vmstate_pcie_aer_log, PCIEAERLog), diff --git a/hw/pci-bridge/xio3130_upstream.c b/hw/pci-bridge/xio3130_upstream.c index a48bfe3bc5..2a6cff6e03 100644 --- a/hw/pci-bridge/xio3130_upstream.c +++ b/hw/pci-bridge/xio3130_upstream.c @@ -115,7 +115,7 @@ static const VMStateDescription vmstate_xio3130_upstream = { .priority = MIG_PRI_PCI_BUS, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent_obj, PCIEPort), VMSTATE_STRUCT(parent_obj.parent_obj.exp.aer_log, PCIEPort, 0, vmstate_pcie_aer_log, PCIEAERLog), From patchwork Fri Dec 29 21:23:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758820 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671697wrw; Fri, 29 Dec 2023 13:29:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IFuVSjqBip4oAtANxtOv6zq7Kkx7tAH7tHIfIVPr/txKnkuqrvkQ706VM/UL4ssRM57iO49 X-Received: by 2002:a05:6214:250d:b0:67a:a721:e13a with SMTP id gf13-20020a056214250d00b0067aa721e13amr15907146qvb.103.1703885342700; Fri, 29 Dec 2023 13:29:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885342; cv=none; d=google.com; s=arc-20160816; b=jMaPjVPMnXls7x++/prrXnYgR/pRNa0H3r3vz9GoA6BfdoZSB5OvtgFaJRwvYI9Hsa pztn8C0zZU1A3QkubkOXYoBXnbYUvz50KPjM2XNMU+PsNJQQ2n6W2PNGmRablam2sE7h zcMotfl948qIZd39MP8EmAbk6UMVHOHtk6XIDzE8fUm9Vq8G+qKKYkbBYfaB2XwSF0QX mfFFq2jg/MAqzbPxBokeB+APoYfLw/sYqjD0g7Ab6j0aD6kvhy8RVlJTaDL7VX8aVA8z EJD/j0aPuLpgPj/ebMKtPJsyPCD/ElpdQsh1fkZvPdQgtofP6p3FhATDlFNpvyYTu6pG zLaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=rVMipdkCvfQWbibmbHXql300byrzbMe7iB+XTgpUb/Q=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=M6PsIOXEnIgqW15S2vhA2J6kO1/sk7PChtU4HN1oOoAlekg/MFNoKN3RoTaA8wLuov cklIDATekv4Fi3E3CkO5caOXuThWpG7GTPc/Hx54Ntuu0NV47dQIGru5EKrBOrB8ZWGe Qeh/5DQWbMLCmVqXDuuijEV3zmYQ1F827YU7qqOF2ExbHml15FtAJYl7v6cCqqs640La DAiewLvcDMUjDpbim45jmpw18YJ3FqX6+86G6P/AY4xSigShxAyHFBzblXF4yZlLCSFX 9RJ9O9MlegTvCZzuG1YR5XXDNilaiEBY7G3UjIhbbJAwfqnv58HVf1olOri7tNhWR42p hd4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ElRh0MHQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id e14-20020a0cb44e000000b0068066068c16si6075249qvf.474.2023.12.29.13.29.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:02 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ElRh0MHQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPY-0005tU-Mn; Fri, 29 Dec 2023 16:28:56 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPR-0005Mz-RL for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:49 -0500 Received: from mail-oo1-xc32.google.com ([2607:f8b0:4864:20::c32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPP-0000Kh-Sq for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:49 -0500 Received: by mail-oo1-xc32.google.com with SMTP id 006d021491bc7-594ce2083easo1616256eaf.2 for ; Fri, 29 Dec 2023 13:28:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885323; x=1704490123; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=rVMipdkCvfQWbibmbHXql300byrzbMe7iB+XTgpUb/Q=; b=ElRh0MHQtOFF2nqR/8kmJxl2AUNh01lv9STkeuZJzT8RohUqMKK4oaslsRnMDM0/nF F6hWjzTeSGnIu8Q/vGr2mjVZykkks2Rt+xibXlZJkcYTxY1OC21gxNcyWcyxzfN4110l jBpvqSS5eN8ShjauZHNljX0EsbSjTWUR1yHR5id3zo3DElWQ73CY+5Os0kKJwkx6PqU5 KaMOYRgMbCCpGMEdDenNkHc90aa2lE9XhvKt0x3m+f2YFvSreQeOy0hB2Tsr7SUAimEX kSNWNsappmNhCnLGIyM1WI3h13WT+ZNhTz1qXPoHX9KDrKqDbIUYqPlUPlNG5WBmj8z0 0zuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885323; x=1704490123; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rVMipdkCvfQWbibmbHXql300byrzbMe7iB+XTgpUb/Q=; b=meG9MWRV9JCq9yQRGwaXMjX8hfuAAp5eciFWQclT94qIJktkDeaBpEGlK/oQIWiWHg GQjUhbMygdRR20jzPd7GlUoKagjXxLbUPe1SCyjcWTClib+VWeizzbIw9rYQdNFGJyCb /FniDVK8hU0UZUFGr9TphzlQeFDTAYQH3CDx20SaqbHQAwnPo9eOLbm7n0KoVjBVmLRC pvIY0BYQzUEpjVGKG5N/Ni50/Fv0kyVw+IRdiezbGLhmgvkdYJUUbdaSrKTHGMUiVztO 8tFqHL3Hl6VCcDm91JVXvBQrdw6WAIrSmGj9jkVqrAiJV9gwUYyGuXXn9mwVjDnJmt8v JSpA== X-Gm-Message-State: AOJu0Yw/3jQujI0yaCJ2jS77s4vN9DwIxGHXlyPTI3QalCboXI3GRHGy 1zGM8K2D3ex7bHYldCeWA9T+xUdxbMHgQmfPiybI0lAo6u5otg== X-Received: by 2002:a05:6358:103:b0:174:dc14:2dea with SMTP id f3-20020a056358010300b00174dc142deamr12316424rwa.47.1703885323257; Fri, 29 Dec 2023 13:28:43 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:42 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 46/71] hw/pci-host: Constify VMState Date: Sat, 30 Dec 2023 08:23:21 +1100 Message-Id: <20231229212346.147149-47-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::c32; envelope-from=richard.henderson@linaro.org; helo=mail-oo1-xc32.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-47-richard.henderson@linaro.org> --- hw/pci-host/astro.c | 4 ++-- hw/pci-host/bonito.c | 2 +- hw/pci-host/designware.c | 10 +++++----- hw/pci-host/dino.c | 2 +- hw/pci-host/gpex.c | 2 +- hw/pci-host/gt64120.c | 2 +- hw/pci-host/i440fx.c | 2 +- hw/pci-host/ppce500.c | 6 +++--- hw/pci-host/q35.c | 2 +- hw/pci-host/raven.c | 2 +- hw/pci-host/versatile.c | 2 +- 11 files changed, 18 insertions(+), 18 deletions(-) diff --git a/hw/pci-host/astro.c b/hw/pci-host/astro.c index 7d68ccee7e..f4de70475c 100644 --- a/hw/pci-host/astro.c +++ b/hw/pci-host/astro.c @@ -459,7 +459,7 @@ static const VMStateDescription vmstate_elroy = { .name = "Elroy", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(hpa, ElroyState), VMSTATE_UINT32(pci_bus_num, ElroyState), VMSTATE_UINT64(config_address, ElroyState), @@ -691,7 +691,7 @@ static const VMStateDescription vmstate_astro = { .name = "Astro", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(ioc_ctrl, AstroState), VMSTATE_UINT64(ioc_status_ctrl, AstroState), VMSTATE_UINT64_ARRAY(ioc_ranges, AstroState, (0x03d8 - 0x300) / 8), diff --git a/hw/pci-host/bonito.c b/hw/pci-host/bonito.c index bab661f3ce..1f0c435348 100644 --- a/hw/pci-host/bonito.c +++ b/hw/pci-host/bonito.c @@ -619,7 +619,7 @@ static const VMStateDescription vmstate_bonito = { .name = "Bonito", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, PCIBonitoState), VMSTATE_END_OF_LIST() } diff --git a/hw/pci-host/designware.c b/hw/pci-host/designware.c index f477f97847..dd9e389c07 100644 --- a/hw/pci-host/designware.c +++ b/hw/pci-host/designware.c @@ -529,7 +529,7 @@ static const VMStateDescription vmstate_designware_pcie_msi_bank = { .name = "designware-pcie-msi-bank", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(enable, DesignwarePCIEMSIBank), VMSTATE_UINT32(mask, DesignwarePCIEMSIBank), VMSTATE_UINT32(status, DesignwarePCIEMSIBank), @@ -541,7 +541,7 @@ static const VMStateDescription vmstate_designware_pcie_msi = { .name = "designware-pcie-msi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(base, DesignwarePCIEMSI), VMSTATE_STRUCT_ARRAY(intr, DesignwarePCIEMSI, @@ -557,7 +557,7 @@ static const VMStateDescription vmstate_designware_pcie_viewport = { .name = "designware-pcie-viewport", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(base, DesignwarePCIEViewport), VMSTATE_UINT64(target, DesignwarePCIEViewport), VMSTATE_UINT32(limit, DesignwarePCIEViewport), @@ -570,7 +570,7 @@ static const VMStateDescription vmstate_designware_pcie_root = { .name = "designware-pcie-root", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIBridge), VMSTATE_UINT32(atu_viewport, DesignwarePCIERoot), VMSTATE_STRUCT_2DARRAY(viewports, @@ -718,7 +718,7 @@ static const VMStateDescription vmstate_designware_pcie_host = { .name = "designware-pcie-host", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(root, DesignwarePCIEHost, 1, diff --git a/hw/pci-host/dino.c b/hw/pci-host/dino.c index 5b0947a16c..d992c4bb69 100644 --- a/hw/pci-host/dino.c +++ b/hw/pci-host/dino.c @@ -287,7 +287,7 @@ static const VMStateDescription vmstate_dino = { .name = "Dino", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(iar0, DinoState), VMSTATE_UINT32(iar1, DinoState), VMSTATE_UINT32(imr, DinoState), diff --git a/hw/pci-host/gpex.c b/hw/pci-host/gpex.c index a6752fac5e..e117e47fa7 100644 --- a/hw/pci-host/gpex.c +++ b/hw/pci-host/gpex.c @@ -195,7 +195,7 @@ static const VMStateDescription vmstate_gpex_root = { .name = "gpex_root", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, GPEXRootState), VMSTATE_END_OF_LIST() } diff --git a/hw/pci-host/gt64120.c b/hw/pci-host/gt64120.c index 143bf053d7..e02efc9e2e 100644 --- a/hw/pci-host/gt64120.c +++ b/hw/pci-host/gt64120.c @@ -431,7 +431,7 @@ static const VMStateDescription vmstate_gt64120 = { .version_id = 1, .minimum_version_id = 1, .post_load = gt64120_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, GT64120State, GT_REGS), VMSTATE_END_OF_LIST() } diff --git a/hw/pci-host/i440fx.c b/hw/pci-host/i440fx.c index 653cc3f149..4f0a0438d7 100644 --- a/hw/pci-host/i440fx.c +++ b/hw/pci-host/i440fx.c @@ -125,7 +125,7 @@ static const VMStateDescription vmstate_i440fx = { .version_id = 3, .minimum_version_id = 3, .post_load = i440fx_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCII440FXState), /* Used to be smm_enabled, which was basically always zero because * SeaBIOS hardly uses SMM. SMRAM is now handled by CPU code. diff --git a/hw/pci-host/ppce500.c b/hw/pci-host/ppce500.c index 453a4e6ed3..fa0d67b342 100644 --- a/hw/pci-host/ppce500.c +++ b/hw/pci-host/ppce500.c @@ -379,7 +379,7 @@ static const VMStateDescription vmstate_pci_outbound = { .name = "pci_outbound", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(potar, struct pci_outbound), VMSTATE_UINT32(potear, struct pci_outbound), VMSTATE_UINT32(powbar, struct pci_outbound), @@ -392,7 +392,7 @@ static const VMStateDescription vmstate_pci_inbound = { .name = "pci_inbound", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(pitar, struct pci_inbound), VMSTATE_UINT32(piwbar, struct pci_inbound), VMSTATE_UINT32(piwbear, struct pci_inbound), @@ -405,7 +405,7 @@ static const VMStateDescription vmstate_ppce500_pci = { .name = "ppce500_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(pob, PPCE500PCIState, PPCE500_PCI_NR_POBS, 1, vmstate_pci_outbound, struct pci_outbound), VMSTATE_STRUCT_ARRAY(pib, PPCE500PCIState, PPCE500_PCI_NR_PIBS, 1, diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c index 08534bc7cc..0d7d4e3f08 100644 --- a/hw/pci-host/q35.c +++ b/hw/pci-host/q35.c @@ -520,7 +520,7 @@ static const VMStateDescription vmstate_mch = { .version_id = 1, .minimum_version_id = 1, .post_load = mch_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, MCHPCIState), /* Used to be smm_enabled, which was basically always zero because * SeaBIOS hardly uses SMM. SMRAM is now handled by CPU code. diff --git a/hw/pci-host/raven.c b/hw/pci-host/raven.c index 86c3a49087..f71d4872c8 100644 --- a/hw/pci-host/raven.c +++ b/hw/pci-host/raven.c @@ -383,7 +383,7 @@ static const VMStateDescription vmstate_raven = { .name = "raven", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, RavenPCIState), VMSTATE_END_OF_LIST() }, diff --git a/hw/pci-host/versatile.c b/hw/pci-host/versatile.c index 60d4e7cd92..0e65deb3f9 100644 --- a/hw/pci-host/versatile.c +++ b/hw/pci-host/versatile.c @@ -147,7 +147,7 @@ static const VMStateDescription pci_vpb_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = pci_vpb_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(imap, PCIVPBState, 3), VMSTATE_UINT32_ARRAY(smap, PCIVPBState, 3), VMSTATE_UINT32(selfid, PCIVPBState), From patchwork Fri Dec 29 21:23:22 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758859 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4673116wrw; Fri, 29 Dec 2023 13:34:15 -0800 (PST) X-Google-Smtp-Source: AGHT+IGdRZKgbZ2Uu4Km3xqogzZy+Xkz1O8hk8Wm8kck6KYPZp7oA+EPOvoNPUP7hm1mssbJRWtq X-Received: by 2002:a05:620a:1087:b0:781:5e07:b436 with SMTP id g7-20020a05620a108700b007815e07b436mr6055733qkk.55.1703885655694; Fri, 29 Dec 2023 13:34:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885655; cv=none; d=google.com; s=arc-20160816; b=o1T2c0xfiYy/xaS0ohZm8odXUlAMREUGmFFIEar/FLP0bM2LpP8nH5IMNM7m1iqNEo kvySOvlJfY6A6TfjIF2Q2f+WR7soO/rMvlQ5QRj+EGLlJDgi6VLT/C2o0xz3uQbD0t3s EgC8X3zwqawoj78vrocNYU5qCcelcE5eVWfo7cqd4uM8oyIg7TLV1RhY+q4SJUov04Uf zX5HoqcHZnhEfdiHKMv6noFFPYDrWQzHUa/uy59uTmQfbio0wzyx69oYmlEA9pJrlqF0 4Ctd/Y0w/Xxbcv4HPPQj0kJjkizxY+danQBX47/Qzzyktda4JQa0o7bKuGhaJLdYggMK Rwsg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=2rrd/F1ImYw18auyJ1KscVM7i5UnYGijSL1Y+QDJUm0=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=aPPQSxiybci6vXR/KL6iosvHagqrAKr9wy2ATZjVzzHLuKecK3U4D88d1Otgskevut t4hbWnjbOJCk5R86EXM0BYgRdqQe2OD/Z5h4bJIELgEwd7elEJeOYHedczoE4P5gLepj cKryjvba7FTHJf/WIPBx2Z3QGXEKmHvZTeQWxu0fK6MEFdjDyTGvrYishOifjvT270E+ GdkSOvEmZItCtXwaVg1dC1Ms+uwUXPkm1ZVouKJLuAS/jnkGvik03oDQjYZMQDjN8lol 9oIphNNCTGkKrBbiK6xzPqj9UFxv6qAxslS1fMCdYkgbG5hgLuIeSoHUKtroe+dltMhP XtHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Mnp02gDt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b11-20020a05620a126b00b0077f0aef8580si19418188qkl.335.2023.12.29.13.34.15 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:34:15 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Mnp02gDt; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPZ-00062N-KZ; Fri, 29 Dec 2023 16:28:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPT-0005Wb-Jg for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:52 -0500 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPP-0000Ko-T6 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:51 -0500 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-6da202aa138so1264772b3a.2 for ; Fri, 29 Dec 2023 13:28:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885325; x=1704490125; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=2rrd/F1ImYw18auyJ1KscVM7i5UnYGijSL1Y+QDJUm0=; b=Mnp02gDtQlZNjsRarSqh0wU3mLPrOVFA7AE5DsXCUm5ugS0eoCLJowP5w7BwbJe1bP Cds7sZgIrdVUpS7OGQ5PuFG1vuv6RcsdJtRy4Lv4fPWnv2fqQPmWW0zOoa2ek+w7JKaP UkyhnafMmwbAyv57JxDQgnRQnBe6SXNdWBpc3kTK9jvrI11fXRo49X9skaNXtCCRQrQv Kzk4SAJCFNamz3U+Jtk4rX+MjSTUrRZkTWNjQnE71AA1TYVtjZLKDtoQv/YZQdK7g+L2 dj8IWgZSpcAkWtF+HTGoAXBaf2wF1QaL9FhAj+70M/pLnigVCj8l9/oIF562Srf5wzt6 Ks9g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885325; x=1704490125; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2rrd/F1ImYw18auyJ1KscVM7i5UnYGijSL1Y+QDJUm0=; b=SrXOL89HPf3PLgKheKnavHUSLIeZ08fEnrkVAKgesLSeAfQ5UyqiaTzOBshJ645WM6 G3dQPMFGlgLK1TsW+WTjfHOYtES64opeMH92clTEUxbUPeWF0CrTBfL35bHu8IB+jeJQ yWvfXH6mB6Ab434ekWJdkmg3uy8DMV9dwhbFFiLL7VkObQEJY0cnyFbopZuq7+cj2CAK /k2o0LlzByP4Dep/HZt7DClpG1M08OAB3mLpbCeUCCCkDqdZ5nBhMYerAJFuJ/BKC3r2 p/LJMaBVsQ13Wh4K0H3+Iz6sWs3m67/ogpjfnhXoqYBrTxLqQ2/LACnzyfB4bFngsJrU ZAUQ== X-Gm-Message-State: AOJu0YzY3HurKQ/WOQXzp+IgHrsEohVh8n/U/MLPjlpJXwuVZnW6Bwl4 i1TQKQC0xMaUyaMLZdMiIPrLqwWAvMTMTVsNQi9hKkMI1FlzmA== X-Received: by 2002:a05:6a20:1447:b0:195:edf4:b086 with SMTP id a7-20020a056a20144700b00195edf4b086mr8033929pzi.83.1703885325312; Fri, 29 Dec 2023 13:28:45 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:44 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 47/71] hw/ppc: Constify VMState Date: Sat, 30 Dec 2023 08:23:22 +1100 Message-Id: <20231229212346.147149-48-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::434; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x434.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-48-richard.henderson@linaro.org> --- hw/ppc/ppc.c | 2 +- hw/ppc/ppc4xx_pci.c | 6 +++--- hw/ppc/prep_systemio.c | 2 +- hw/ppc/rs6000_mc.c | 2 +- hw/ppc/spapr.c | 20 ++++++++++---------- hw/ppc/spapr_caps.c | 2 +- hw/ppc/spapr_cpu_core.c | 12 ++++++------ hw/ppc/spapr_drc.c | 8 ++++---- hw/ppc/spapr_iommu.c | 6 +++--- hw/ppc/spapr_nvdimm.c | 4 ++-- hw/ppc/spapr_ovec.c | 2 +- hw/ppc/spapr_pci.c | 6 +++--- hw/ppc/spapr_rtc.c | 2 +- hw/ppc/spapr_vio.c | 2 +- 14 files changed, 38 insertions(+), 38 deletions(-) diff --git a/hw/ppc/ppc.c b/hw/ppc/ppc.c index be167710a3..c532d79f0e 100644 --- a/hw/ppc/ppc.c +++ b/hw/ppc/ppc.c @@ -1066,7 +1066,7 @@ const VMStateDescription vmstate_ppc_timebase = { .version_id = 1, .minimum_version_id = 1, .pre_save = timebase_pre_save, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT64(guest_timebase, PPCTimebase), VMSTATE_INT64(time_of_the_day_ns, PPCTimebase), VMSTATE_END_OF_LIST() diff --git a/hw/ppc/ppc4xx_pci.c b/hw/ppc/ppc4xx_pci.c index 6652119008..0a07aab5d1 100644 --- a/hw/ppc/ppc4xx_pci.c +++ b/hw/ppc/ppc4xx_pci.c @@ -276,7 +276,7 @@ static const VMStateDescription vmstate_pci_master_map = { .name = "pci_master_map", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(la, struct PCIMasterMap), VMSTATE_UINT32(ma, struct PCIMasterMap), VMSTATE_UINT32(pcila, struct PCIMasterMap), @@ -289,7 +289,7 @@ static const VMStateDescription vmstate_pci_target_map = { .name = "pci_target_map", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ms, struct PCITargetMap), VMSTATE_UINT32(la, struct PCITargetMap), VMSTATE_END_OF_LIST() @@ -300,7 +300,7 @@ static const VMStateDescription vmstate_ppc4xx_pci = { .name = "ppc4xx_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(pmm, PPC4xxPCIState, PPC4xx_PCI_NR_PMMS, 1, vmstate_pci_master_map, struct PCIMasterMap), diff --git a/hw/ppc/prep_systemio.c b/hw/ppc/prep_systemio.c index c96cefb13d..4d3a251ed8 100644 --- a/hw/ppc/prep_systemio.c +++ b/hw/ppc/prep_systemio.c @@ -277,7 +277,7 @@ static const VMStateDescription vmstate_prep_systemio = { .name = "prep_systemio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(sreset, PrepSystemIoState), VMSTATE_UINT8(system_control, PrepSystemIoState), VMSTATE_UINT8(iomap_type, PrepSystemIoState), diff --git a/hw/ppc/rs6000_mc.c b/hw/ppc/rs6000_mc.c index c0bc212e92..b35f8ba112 100644 --- a/hw/ppc/rs6000_mc.c +++ b/hw/ppc/rs6000_mc.c @@ -202,7 +202,7 @@ static const VMStateDescription vmstate_rs6000mc = { .name = "rs6000-mc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(port0820_index, RS6000MCState), VMSTATE_END_OF_LIST() }, diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 9b6c1c129f..4997aa4f1d 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -152,7 +152,7 @@ static const VMStateDescription pre_2_10_vmstate_dummy_icp = { .version_id = 1, .minimum_version_id = 1, .needed = pre_2_10_vmstate_dummy_icp_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UNUSED(4), /* uint32_t xirr */ VMSTATE_UNUSED(1), /* uint8_t pending_priority */ VMSTATE_UNUSED(1), /* uint8_t mfrr */ @@ -1919,7 +1919,7 @@ static const VMStateDescription vmstate_spapr_event_entry = { .name = "spapr_event_log_entry", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(summary, SpaprEventLogEntry), VMSTATE_UINT32(extended_length, SpaprEventLogEntry), VMSTATE_VBUFFER_ALLOC_UINT32(extended_log, SpaprEventLogEntry, 0, @@ -1933,7 +1933,7 @@ static const VMStateDescription vmstate_spapr_pending_events = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_pending_events_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_QTAILQ_V(pending_events, SpaprMachineState, 1, vmstate_spapr_event_entry, SpaprEventLogEntry, next), VMSTATE_END_OF_LIST() @@ -1989,7 +1989,7 @@ static const VMStateDescription vmstate_spapr_ov5_cas = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_ov5_cas_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER_V(ov5_cas, SpaprMachineState, 1, vmstate_spapr_ovec, SpaprOptionVector), VMSTATE_END_OF_LIST() @@ -2008,7 +2008,7 @@ static const VMStateDescription vmstate_spapr_patb_entry = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_patb_entry_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(patb_entry, SpaprMachineState), VMSTATE_END_OF_LIST() }, @@ -2026,7 +2026,7 @@ static const VMStateDescription vmstate_spapr_irq_map = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_irq_map_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BITMAP(irq_map, SpaprMachineState, 0, irq_map_nr), VMSTATE_END_OF_LIST() }, @@ -2056,7 +2056,7 @@ static const VMStateDescription vmstate_spapr_dtb = { .minimum_version_id = 1, .needed = spapr_dtb_needed, .pre_load = spapr_dtb_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(fdt_initial_size, SpaprMachineState), VMSTATE_UINT32(fdt_size, SpaprMachineState), VMSTATE_VBUFFER_ALLOC_UINT32(fdt_blob, SpaprMachineState, 0, NULL, @@ -2094,7 +2094,7 @@ static const VMStateDescription vmstate_spapr_fwnmi = { .minimum_version_id = 1, .needed = spapr_fwnmi_needed, .pre_save = spapr_fwnmi_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(fwnmi_system_reset_addr, SpaprMachineState), VMSTATE_UINT64(fwnmi_machine_check_addr, SpaprMachineState), VMSTATE_INT32(fwnmi_machine_check_interlock, SpaprMachineState), @@ -2109,7 +2109,7 @@ static const VMStateDescription vmstate_spapr = { .pre_load = spapr_pre_load, .post_load = spapr_post_load, .pre_save = spapr_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* used to be @next_irq */ VMSTATE_UNUSED_BUFFER(version_before_3, 0, 4), @@ -2119,7 +2119,7 @@ static const VMStateDescription vmstate_spapr = { VMSTATE_PPC_TIMEBASE_V(tb, SpaprMachineState, 2), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_spapr_ov5_cas, &vmstate_spapr_patb_entry, &vmstate_spapr_pending_events, diff --git a/hw/ppc/spapr_caps.c b/hw/ppc/spapr_caps.c index 5a0755d34f..e889244e52 100644 --- a/hw/ppc/spapr_caps.c +++ b/hw/ppc/spapr_caps.c @@ -904,7 +904,7 @@ const VMStateDescription vmstate_spapr_cap_##sname = { \ .version_id = 1, \ .minimum_version_id = 1, \ .needed = spapr_cap_##sname##_needed, \ - .fields = (VMStateField[]) { \ + .fields = (const VMStateField[]) { \ VMSTATE_UINT8(mig.caps[cap], \ SpaprMachineState), \ VMSTATE_END_OF_LIST() \ diff --git a/hw/ppc/spapr_cpu_core.c b/hw/ppc/spapr_cpu_core.c index 91fae56573..710078e9f7 100644 --- a/hw/ppc/spapr_cpu_core.c +++ b/hw/ppc/spapr_cpu_core.c @@ -127,7 +127,7 @@ static const VMStateDescription vmstate_spapr_cpu_slb_shadow = { .version_id = 1, .minimum_version_id = 1, .needed = slb_shadow_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(slb_shadow_addr, SpaprCpuState), VMSTATE_UINT64(slb_shadow_size, SpaprCpuState), VMSTATE_END_OF_LIST() @@ -146,7 +146,7 @@ static const VMStateDescription vmstate_spapr_cpu_dtl = { .version_id = 1, .minimum_version_id = 1, .needed = dtl_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(dtl_addr, SpaprCpuState), VMSTATE_UINT64(dtl_size, SpaprCpuState), VMSTATE_END_OF_LIST() @@ -165,11 +165,11 @@ static const VMStateDescription vmstate_spapr_cpu_vpa = { .version_id = 1, .minimum_version_id = 1, .needed = vpa_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(vpa_addr, SpaprCpuState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_spapr_cpu_slb_shadow, &vmstate_spapr_cpu_dtl, NULL @@ -180,10 +180,10 @@ static const VMStateDescription vmstate_spapr_cpu_state = { .name = "spapr_cpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_spapr_cpu_vpa, NULL } diff --git a/hw/ppc/spapr_drc.c b/hw/ppc/spapr_drc.c index 2b99d3b4b1..1484e3209d 100644 --- a/hw/ppc/spapr_drc.c +++ b/hw/ppc/spapr_drc.c @@ -471,7 +471,7 @@ static const VMStateDescription vmstate_spapr_drc_unplug_requested = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_drc_unplug_requested_needed, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_BOOL(unplug_requested, SpaprDrc), VMSTATE_END_OF_LIST() } @@ -504,11 +504,11 @@ static const VMStateDescription vmstate_spapr_drc = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_drc_needed, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(state, SpaprDrc), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_spapr_drc_unplug_requested, NULL } @@ -611,7 +611,7 @@ static const VMStateDescription vmstate_spapr_drc_physical = { .version_id = 1, .minimum_version_id = 1, .needed = drc_physical_needed, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(dr_indicator, SpaprDrcPhysical), VMSTATE_END_OF_LIST() } diff --git a/hw/ppc/spapr_iommu.c b/hw/ppc/spapr_iommu.c index 5e3973fc5f..e3c01ef44f 100644 --- a/hw/ppc/spapr_iommu.c +++ b/hw/ppc/spapr_iommu.c @@ -270,7 +270,7 @@ static const VMStateDescription vmstate_spapr_tce_table_ex = { .version_id = 1, .minimum_version_id = 1, .needed = spapr_tce_table_ex_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(bus_offset, SpaprTceTable), VMSTATE_UINT32(page_shift, SpaprTceTable), VMSTATE_END_OF_LIST() @@ -283,7 +283,7 @@ static const VMStateDescription vmstate_spapr_tce_table = { .minimum_version_id = 2, .pre_save = spapr_tce_table_pre_save, .post_load = spapr_tce_table_post_load, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { /* Sanity check */ VMSTATE_UINT32_EQUAL(liobn, SpaprTceTable, NULL), @@ -296,7 +296,7 @@ static const VMStateDescription vmstate_spapr_tce_table = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_spapr_tce_table_ex, NULL } diff --git a/hw/ppc/spapr_nvdimm.c b/hw/ppc/spapr_nvdimm.c index ad7afe7544..7d2dfe5e3d 100644 --- a/hw/ppc/spapr_nvdimm.c +++ b/hw/ppc/spapr_nvdimm.c @@ -528,7 +528,7 @@ static const VMStateDescription vmstate_spapr_nvdimm_flush_state = { .name = "spapr_nvdimm_flush_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(continue_token, SpaprNVDIMMDeviceFlushState), VMSTATE_INT64(hcall_ret, SpaprNVDIMMDeviceFlushState), VMSTATE_UINT32(drcidx, SpaprNVDIMMDeviceFlushState), @@ -541,7 +541,7 @@ const VMStateDescription vmstate_spapr_nvdimm_states = { .version_id = 1, .minimum_version_id = 1, .post_load = spapr_nvdimm_flush_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(hcall_flush_required, SpaprNVDIMMDevice), VMSTATE_UINT64(nvdimm_flush_token, SpaprNVDIMMDevice), VMSTATE_QLIST_V(completed_nvdimm_flush_states, SpaprNVDIMMDevice, 1, diff --git a/hw/ppc/spapr_ovec.c b/hw/ppc/spapr_ovec.c index b2567caa5c..88e29536aa 100644 --- a/hw/ppc/spapr_ovec.c +++ b/hw/ppc/spapr_ovec.c @@ -36,7 +36,7 @@ const VMStateDescription vmstate_spapr_ovec = { .name = "spapr_option_vector", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BITMAP(bitmap, SpaprOptionVector, 1, bitmap_size), VMSTATE_END_OF_LIST() } diff --git a/hw/ppc/spapr_pci.c b/hw/ppc/spapr_pci.c index 6760823e13..25e0295d6f 100644 --- a/hw/ppc/spapr_pci.c +++ b/hw/ppc/spapr_pci.c @@ -2115,7 +2115,7 @@ static const VMStateDescription vmstate_spapr_pci_lsi = { .name = "spapr_pci/lsi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_EQUAL(irq, SpaprPciLsi, NULL), VMSTATE_END_OF_LIST() @@ -2126,7 +2126,7 @@ static const VMStateDescription vmstate_spapr_pci_msi = { .name = "spapr_pci/msi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(key, SpaprPciMsiMig), VMSTATE_UINT32(value.first_irq, SpaprPciMsiMig), VMSTATE_UINT32(value.num, SpaprPciMsiMig), @@ -2216,7 +2216,7 @@ static const VMStateDescription vmstate_spapr_pci = { .pre_save = spapr_pci_pre_save, .post_save = spapr_pci_post_save, .post_load = spapr_pci_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64_EQUAL(buid, SpaprPhbState, NULL), VMSTATE_UINT32_TEST(mig_liobn, SpaprPhbState, pre_2_8_migration), VMSTATE_UINT64_TEST(mig_mem_win_addr, SpaprPhbState, pre_2_8_migration), diff --git a/hw/ppc/spapr_rtc.c b/hw/ppc/spapr_rtc.c index d55b4b0c50..deb3ea4e49 100644 --- a/hw/ppc/spapr_rtc.c +++ b/hw/ppc/spapr_rtc.c @@ -157,7 +157,7 @@ static const VMStateDescription vmstate_spapr_rtc = { .name = "spapr/rtc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(ns_offset, SpaprRtcState), VMSTATE_END_OF_LIST() }, diff --git a/hw/ppc/spapr_vio.c b/hw/ppc/spapr_vio.c index f8ef2b6fa8..3221874848 100644 --- a/hw/ppc/spapr_vio.c +++ b/hw/ppc/spapr_vio.c @@ -616,7 +616,7 @@ const VMStateDescription vmstate_spapr_vio = { .name = "spapr_vio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Sanity check */ VMSTATE_UINT32_EQUAL(reg, SpaprVioDevice, NULL), VMSTATE_UINT32_EQUAL(irq, SpaprVioDevice, NULL), From patchwork Fri Dec 29 21:23:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758854 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672725wrw; Fri, 29 Dec 2023 13:32:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IHAUPt6iecpiaetcTenavg6eVmg41wWCNIggYtOeXpOcCIT3OX6OZOFeIF/EP+Q0oJWkO+I X-Received: by 2002:a05:6214:262d:b0:67f:1f0c:b311 with SMTP id gv13-20020a056214262d00b0067f1f0cb311mr17098995qvb.29.1703885566118; Fri, 29 Dec 2023 13:32:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885566; cv=none; d=google.com; s=arc-20160816; b=of12wzij2SwJUc4Ise/K+/aOx7VnKMSvJmy4iMwaBeAcwscvUpAqPMr/SvxvMkU/tW /cPz0+bRIhKqSvRG7Kja8aq+9N8kYCEiyZQ/tD6ZpQSgrqTRBV4l5zCubuLdmU8VRMJ6 7N/V75ijvTCsFO3Y3AnJcxkQs1fh9kN6GDhidMAlePm52yaDjYDTx4DdNEPqgr/u1xWb FY0mpeGfz8K3eFZFaWYqlJ636YBowjUHJFhSr+fjksg+WiBf5/OxpPKtvN04M3iGwLfT I7M/+0Tl+325kSmo5/Lvx60DAWkHZZq/5cKAjgCGPWKS2u8y42Tw6Uo0Sti+g75IlZvs Nwhg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=v6UWy5Kz/mx3PpYWESm1flcywcYJB9sUPeJQepdOHfY=; fh=OD2lp1dfJFstOGLpXnIzbHomhWx3nF/XGvY6bQVU7c8=; b=iRSIY8OoCbnEG4QDJZxyjLP99zod1vJcgaDwujOfhCWlm7HU7rccCJQYh/VCEYQQ4V IrCsnzJPRTW+7VI2eUiJ8AEvwmmcqze/yjlJ07Xe8dRT7ZANjy2vEQVPOwytM/omjIvO rao/DgxQoauH8sIfyZidMoMSOuWghzj8RpKTtPXIxAK1RlRiJxT1MnSiLntGqpb0pkjW BG7mJaSaCDOVRmqXdjARon9B13CRgb/5pGE9ps+qogdlrsSEZhtsntkAhlmcH65pU/sI FSjos+46oziCiEr7e3WXcIG3IG053iNpVVxhvgwgTuL6OJAg8T6V60Baar2zymzqNoJG rcaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=GEIL1ShM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id gv10-20020a056214262a00b006803a797f51si9372947qvb.612.2023.12.29.13.32.45 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:32:46 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=GEIL1ShM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPb-0006GK-2u; Fri, 29 Dec 2023 16:28:59 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPS-0005VH-T3 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:51 -0500 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPQ-0000Kt-Qi for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:50 -0500 Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-5cd68a0de49so5228422a12.2 for ; Fri, 29 Dec 2023 13:28:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885327; x=1704490127; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=v6UWy5Kz/mx3PpYWESm1flcywcYJB9sUPeJQepdOHfY=; b=GEIL1ShM+rwndJMRIa+AmGCPLf6DhneoUM5LzqYD3UGxqEZkgcC+8QgvQwQUQrSe1N vp3M08MvzCter6LYFRKgwyj/8I8Y5WEI2tboM3oTnMzU7xSGGavzDduy6COnb7wrZNWz W2RrBa3CG1PqRTd/vnNuMzLrLaaW5SuW4u16QmfV0n18MsaykOzZlawy8dGpTC76tRmM LAPc8qFF9LRQVyOXIWSSTlKBpdE5zi80FC3sa4vVignLEFCZzsIn1A3zp5ngS0HktEpP 0sNvpD3yT4ZXPh4mG9iyba3o+puqnuqCRy1Rh2DITyQgQ1TprTOAQdH8AGdgq2TLLk+l kMOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885327; x=1704490127; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=v6UWy5Kz/mx3PpYWESm1flcywcYJB9sUPeJQepdOHfY=; b=j5sGK0CqgCtEz8TvE0oIyfxSle2tTaTDutrqtV20t3txQRJNpzkcH4fOOcrfH2IAek wjOeUroXrqNeAsWcLsoDeM4EpYvu8ocHh6VbzT77oM291DStten7YtPfx4d1WwAGfOtN vGT1uV4rWRYRV8YVTDT3i3XPum1xvtQ5on70tU2hphtaKrLVT2BNwkRO+j6ZZZm4tr3M I5LGUs4/VqPuIva49iMGqx8KpgnzURLoIA3E2P/5xXMhDvfuzUcHYrEh0Y+kkdivtT7q UlLn1p6QbPOeN09/0UI2ofqFMi48RS+oBmcWKc7UZTf/1RpvEf4GGzsTGE+DUy87oP+Z 4YVg== X-Gm-Message-State: AOJu0Yw10sCDLsYuNVn5OSqz5UUzolsmJzVVZs5pDTfF+pqCsLsPWurv TuQfvYYI0MDdl8PScuP5s7+Mb78hmnB9FN8daUb0w5iccA0QLg== X-Received: by 2002:a05:6a20:748b:b0:196:6b10:f3f4 with SMTP id p11-20020a056a20748b00b001966b10f3f4mr2830626pzd.74.1703885327542; Fri, 29 Dec 2023 13:28:47 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:47 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Alistair Francis Subject: [PULL 48/71] hw/riscv: Constify VMState Date: Sat, 30 Dec 2023 08:23:23 +1100 Message-Id: <20231229212346.147149-49-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::531; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x531.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Acked-by: Alistair Francis Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-49-richard.henderson@linaro.org> --- hw/riscv/virt-acpi-build.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/riscv/virt-acpi-build.c b/hw/riscv/virt-acpi-build.c index 7331248f59..d3bfaf502e 100644 --- a/hw/riscv/virt-acpi-build.c +++ b/hw/riscv/virt-acpi-build.c @@ -374,7 +374,7 @@ static const VMStateDescription vmstate_virt_acpi_build = { .name = "virt_acpi_build", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(patched, AcpiBuildState), VMSTATE_END_OF_LIST() }, From patchwork Fri Dec 29 21:23:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758858 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4673011wrw; Fri, 29 Dec 2023 13:33:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IHBb0fV920SBL3qY9R2CygFOHQ5EqnKqgfbJZ/Eu+q3qDePO2Yp+t0N17V3t8+w7J7tVwZL X-Received: by 2002:a05:6808:3025:b0:3bb:dd1d:a567 with SMTP id ay37-20020a056808302500b003bbdd1da567mr2133392oib.26.1703885630712; Fri, 29 Dec 2023 13:33:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885630; cv=none; d=google.com; s=arc-20160816; b=q2xg4rGcPA3lER5CtP7SB4EBk/AE75svMcFR5Z+ujNQW2uO4Zd0klzJ9z7X7hNqz45 f1h2B+jWgE1RJKGy3uq2HylTfRPE5DIyB4Dg5ocIo1u5yj2vp5PgrjAEFQSHdUgBIGGe EHXe17H7jc5Q9p62VXTslDGX1pglG7I+DncLioisT3haNdonh0OZqPsvgxkHBJ7UoJhY UQ166yovRtsQ/Ca7T5XRJXsow3/unbR4uKYBIUer3taJVssQX9J3eHMIMxSrzWZ8EGti fenpFdSQkPWqa3GiHi2HAJbwRdht7KTT7jo82XVxXXWHkGySYKQaCR8UoN8t2nuZO9Fw Bsng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=9J/A+VixeAwxo6Ne2AUmiugi6IsxWFbARnpr5oEGiSE=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=gBjG1vODzc1AhC2rliWqVR7cTsAi0wlOr0rx+cnLPFByB6Rlz6oVu9FGxB7jj0duv9 UbahI9zegk6yTuCu6VizLUUN3Cf/e8eQ4Ugx/8mBvYtGyZlpUEFbEaJrw7VQLFyDZ8pI P4YytflCMy9HrWcHB3PA1R3qBRHVxCuVQoa4TM9xhRYehF0Mku3Smo/mFz+Fecl/Zn/3 xFP+wVQV+ut2RmPKUeJ7/6a12ewOZfWlTxnlN+VW+Jn09UC17HaVw8TRTmWZhMG4Vilz LfKHxYNVTQY5Setkzy7yUDa21qa22Er5ZhNi5yyJNDgIgdliy9u+/Z8nOBRufPKMyZqn xzlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=b3Mig2qJ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j7-20020a05622a038700b004280951ce31si1460450qtx.645.2023.12.29.13.33.50 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:33:50 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=b3Mig2qJ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPZ-0005zK-7h; Fri, 29 Dec 2023 16:28:57 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPU-0005XL-VH for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:54 -0500 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPT-0000LG-0p for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:52 -0500 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-6d9bf6f24f3so1670832b3a.2 for ; Fri, 29 Dec 2023 13:28:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885330; x=1704490130; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=9J/A+VixeAwxo6Ne2AUmiugi6IsxWFbARnpr5oEGiSE=; b=b3Mig2qJV0FEtQxXKT7dPH6cipfsQerCBeLYaNZrOQr+g1nyWVtneSAPvTQ46wbuVR mJS6CZwunDL3ALS+H75hudiIl5aBZptVgI3IhtCaxpcIeFeVHl+jD9t8TkACdYREq4FX MbET7doXQtYUSutoKR/GwGblvBj4319fVNxufHSvDo6ILIbpzIPGM28KYZp1Yt6lJtpT LYTkDWd27tbCpE0pDafGJaICx5WUdEDKrgkme4kCwHU1oZHXX5HboyLYFZarHFJpiMYD nU3Z+8a3+DAjMzKIe/dbKTc/t/BH9B1Ue9lcBfAtChuC8/5I/yHvS70Qu3/s2Q/Fcbzb Au7A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885330; x=1704490130; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=9J/A+VixeAwxo6Ne2AUmiugi6IsxWFbARnpr5oEGiSE=; b=JjogdvfN22iQ5S1o3KVCbyRUJuq8S2SddW+clX14XIgr3OLDZpLB1bQJCUUIMU1OeL jkFS0A471NMO0v2+b3kwrLFsbZ/HUGx1VYiu16FsvN0sTLh9fmL3PtX1nognapLc+66Z sNLH6MFsfy7tvh0+Ru6SirE8dJGYdlrF3kWnyc1Rnq+Euq5zPj+EoM8qAFAAxZGwWMWr BfWuHVkbb+cIDXBy1micQ+NxHvyeEbZirgzn7JACEG9qOuNY0Wmi4PesZCretI84EbpM Ntbu6xgkzXtplaY5NmXdyISRCKpTwsaT6myov7M3vAR1iJlpf4Yf2h6LqxIpuyJgOrH4 iDiw== X-Gm-Message-State: AOJu0Yw2ISfuLDLDUQtcRCAsctadjGr70rLa/rJEH6wMQ7jAxms4zZn5 ZkMqFciLs+6sGdDlyolBWxPCvvoMMMNGrLUjQqYA9XlliYgUfw== X-Received: by 2002:a05:6a00:3249:b0:6d9:999b:3786 with SMTP id bn9-20020a056a00324900b006d9999b3786mr4603735pfb.57.1703885329696; Fri, 29 Dec 2023 13:28:49 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:49 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 49/71] hw/rtc: Constify VMState Date: Sat, 30 Dec 2023 08:23:24 +1100 Message-Id: <20231229212346.147149-50-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::434; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x434.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-50-richard.henderson@linaro.org> --- hw/rtc/allwinner-rtc.c | 2 +- hw/rtc/aspeed_rtc.c | 2 +- hw/rtc/ds1338.c | 2 +- hw/rtc/exynos4210_rtc.c | 2 +- hw/rtc/goldfish_rtc.c | 2 +- hw/rtc/ls7a_rtc.c | 2 +- hw/rtc/m48t59.c | 2 +- hw/rtc/mc146818rtc.c | 6 +++--- hw/rtc/pl031.c | 6 +++--- hw/rtc/twl92230.c | 4 ++-- hw/rtc/xlnx-zynqmp-rtc.c | 2 +- 11 files changed, 16 insertions(+), 16 deletions(-) diff --git a/hw/rtc/allwinner-rtc.c b/hw/rtc/allwinner-rtc.c index 7e493f0e79..2ac50b30cb 100644 --- a/hw/rtc/allwinner-rtc.c +++ b/hw/rtc/allwinner-rtc.c @@ -305,7 +305,7 @@ static const VMStateDescription allwinner_rtc_vmstate = { .name = "allwinner-rtc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AwRtcState, AW_RTC_REGS_NUM), VMSTATE_END_OF_LIST() } diff --git a/hw/rtc/aspeed_rtc.c b/hw/rtc/aspeed_rtc.c index fa861e2d49..589d9a5a7a 100644 --- a/hw/rtc/aspeed_rtc.c +++ b/hw/rtc/aspeed_rtc.c @@ -137,7 +137,7 @@ static const MemoryRegionOps aspeed_rtc_ops = { static const VMStateDescription vmstate_aspeed_rtc = { .name = TYPE_ASPEED_RTC, .version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg, AspeedRtcState, 0x18), VMSTATE_INT64(offset, AspeedRtcState), VMSTATE_END_OF_LIST() diff --git a/hw/rtc/ds1338.c b/hw/rtc/ds1338.c index 36d8121ddd..e479661c39 100644 --- a/hw/rtc/ds1338.c +++ b/hw/rtc/ds1338.c @@ -46,7 +46,7 @@ static const VMStateDescription vmstate_ds1338 = { .name = "ds1338", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(parent_obj, DS1338State), VMSTATE_INT64(offset, DS1338State), VMSTATE_UINT8_V(wday_offset, DS1338State, 2), diff --git a/hw/rtc/exynos4210_rtc.c b/hw/rtc/exynos4210_rtc.c index cc7101c530..319371f97d 100644 --- a/hw/rtc/exynos4210_rtc.c +++ b/hw/rtc/exynos4210_rtc.c @@ -122,7 +122,7 @@ static const VMStateDescription vmstate_exynos4210_rtc_state = { .name = "exynos4210.rtc", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(reg_intp, Exynos4210RTCState), VMSTATE_UINT32(reg_rtccon, Exynos4210RTCState), VMSTATE_UINT32(reg_ticcnt, Exynos4210RTCState), diff --git a/hw/rtc/goldfish_rtc.c b/hw/rtc/goldfish_rtc.c index 19a56402a0..01acf30b27 100644 --- a/hw/rtc/goldfish_rtc.c +++ b/hw/rtc/goldfish_rtc.c @@ -242,7 +242,7 @@ static const VMStateDescription goldfish_rtc_vmstate = { .version_id = 2, .pre_save = goldfish_rtc_pre_save, .post_load = goldfish_rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(tick_offset_vmstate, GoldfishRTCState), VMSTATE_UINT64(alarm_next, GoldfishRTCState), VMSTATE_UINT32(alarm_running, GoldfishRTCState), diff --git a/hw/rtc/ls7a_rtc.c b/hw/rtc/ls7a_rtc.c index 1f9e38a735..ac28c1165b 100644 --- a/hw/rtc/ls7a_rtc.c +++ b/hw/rtc/ls7a_rtc.c @@ -454,7 +454,7 @@ static const VMStateDescription vmstate_ls7a_rtc = { .minimum_version_id = 1, .pre_save = ls7a_rtc_pre_save, .post_load = ls7a_rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(offset_toy, LS7ARtcState), VMSTATE_INT64(offset_rtc, LS7ARtcState), VMSTATE_UINT32_ARRAY(toymatch, LS7ARtcState, TIMER_NUMS), diff --git a/hw/rtc/m48t59.c b/hw/rtc/m48t59.c index 2e2c849985..aa44c4b20c 100644 --- a/hw/rtc/m48t59.c +++ b/hw/rtc/m48t59.c @@ -526,7 +526,7 @@ static const VMStateDescription vmstate_m48t59 = { .name = "m48t59", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(lock, M48t59State), VMSTATE_UINT16(addr, M48t59State), VMSTATE_VBUFFER_UINT32(buffer, M48t59State, 0, NULL, size), diff --git a/hw/rtc/mc146818rtc.c b/hw/rtc/mc146818rtc.c index 2d391a8396..f4c1869232 100644 --- a/hw/rtc/mc146818rtc.c +++ b/hw/rtc/mc146818rtc.c @@ -817,7 +817,7 @@ static const VMStateDescription vmstate_rtc_irq_reinject_on_ack_count = { .version_id = 1, .minimum_version_id = 1, .needed = rtc_irq_reinject_on_ack_count_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(irq_reinject_on_ack_count, MC146818RtcState), VMSTATE_END_OF_LIST() } @@ -829,7 +829,7 @@ static const VMStateDescription vmstate_rtc = { .minimum_version_id = 1, .pre_save = rtc_pre_save, .post_load = rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(cmos_data, MC146818RtcState), VMSTATE_UINT8(cmos_index, MC146818RtcState), VMSTATE_UNUSED(7*4), @@ -845,7 +845,7 @@ static const VMStateDescription vmstate_rtc = { VMSTATE_UINT64_V(next_alarm_time, MC146818RtcState, 3), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_rtc_irq_reinject_on_ack_count, NULL } diff --git a/hw/rtc/pl031.c b/hw/rtc/pl031.c index b01d0e75d1..837b0bdf9b 100644 --- a/hw/rtc/pl031.c +++ b/hw/rtc/pl031.c @@ -290,7 +290,7 @@ static const VMStateDescription vmstate_pl031_tick_offset = { .minimum_version_id = 1, .needed = pl031_tick_offset_needed, .post_load = pl031_tick_offset_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tick_offset, PL031State), VMSTATE_END_OF_LIST() } @@ -303,7 +303,7 @@ static const VMStateDescription vmstate_pl031 = { .pre_save = pl031_pre_save, .pre_load = pl031_pre_load, .post_load = pl031_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tick_offset_vmstate, PL031State), VMSTATE_UINT32(mr, PL031State), VMSTATE_UINT32(lr, PL031State), @@ -312,7 +312,7 @@ static const VMStateDescription vmstate_pl031 = { VMSTATE_UINT32(is, PL031State), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_pl031_tick_offset, NULL } diff --git a/hw/rtc/twl92230.c b/hw/rtc/twl92230.c index 64c61c3dae..efd19a76e6 100644 --- a/hw/rtc/twl92230.c +++ b/hw/rtc/twl92230.c @@ -768,7 +768,7 @@ static const VMStateDescription vmstate_menelaus_tm = { .name = "menelaus_tm", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16_HACK(tm_sec, struct tm), VMSTATE_UINT16_HACK(tm_min, struct tm), VMSTATE_UINT16_HACK(tm_hour, struct tm), @@ -810,7 +810,7 @@ static const VMStateDescription vmstate_menelaus = { .minimum_version_id = 0, .pre_save = menelaus_pre_save, .post_load = menelaus_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(firstbyte, MenelausState), VMSTATE_UINT8(reg, MenelausState), VMSTATE_UINT8_ARRAY(vcore, MenelausState, 5), diff --git a/hw/rtc/xlnx-zynqmp-rtc.c b/hw/rtc/xlnx-zynqmp-rtc.c index 3e7d61a41c..613c6407a6 100644 --- a/hw/rtc/xlnx-zynqmp-rtc.c +++ b/hw/rtc/xlnx-zynqmp-rtc.c @@ -244,7 +244,7 @@ static const VMStateDescription vmstate_rtc = { .minimum_version_id = 1, .pre_save = rtc_pre_save, .post_load = rtc_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, XlnxZynqMPRTC, XLNX_ZYNQMP_RTC_R_MAX), VMSTATE_UINT32(tick_offset, XlnxZynqMPRTC), VMSTATE_END_OF_LIST(), From patchwork Fri Dec 29 21:23:25 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758832 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672193wrw; Fri, 29 Dec 2023 13:30:57 -0800 (PST) X-Google-Smtp-Source: AGHT+IHNR3TqwMoYQz2b5AxfZ0qlrwQYsigwPtMVilY67oc4G9+J+m0X5yUmbXNcPoDUUYrk+9Vv X-Received: by 2002:a05:6214:5691:b0:67f:bc1e:d4f8 with SMTP id qm17-20020a056214569100b0067fbc1ed4f8mr9816802qvb.33.1703885456977; Fri, 29 Dec 2023 13:30:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885456; cv=none; d=google.com; s=arc-20160816; b=0xRux4x52VFU13GyXGZZo/gW4SgPGE7mdbTczw5lGiuPGVXze0QnuLBMz5/aNPOXRy rbw7VdfXVNLiipOcwBq0tWrMruem1taK/Ude7Q4mpmFEYsHUYY0Yps+1b9+S2DivIbHh 0m8O2A8XQce0Gr2itLcxwzj2TsTVNvm9Srx+lXY19g4fAxx3XPUAs+Sy0Db208l7Uhlx XFOeUQ93VvoIYwoSSSRCAdz0UWpV0oUJkdeFnrbKdc3PpwniI5wl+QGsvFq9pujXkfvL 5lu5ooP/0PQanSvE0JkVGYwv2SJwLBXiEqeHmFlfIhrnMe/JW53daBvWUiTGclrFaxNe kbcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=OqU6sg9g0ESWhn8ACzHLMCxFbvZWow6DbzojmlPanzM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=r3liqa4Hf8DnBvXEjUUAaDaGmhJqcehNQAnQLRcIqU5DEIxGKa7Uwl0b/9Sf3q2rCN P2EbE6/xuvzMGf9CG3lhuhxCklpgXXRELzb7eXvzBZKBVukBXEe2/vOhIW73lYcWPPGd jdoJ85X353rgtkvglpAnQpRn96EzxUyJ7um0rM/XlOjSS56frVmYuXdGTIrdG6tvhWio PsrF8jT0oXtJgcmcHslXMtpzxRkwqoC3AeQeA7QF4UQiXQeuvSzAklkXKNGJgERBOSWk lUj+jdHYTah/AJxgansAtC52WDvAWymiH8dtFqstLD1We2hXDbJR5sZzaEom3LdCEudJ aoHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=o7yW7E00; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g7-20020a05620a40c700b007815e8d7d9bsi6960116qko.408.2023.12.29.13.30.56 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:56 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=o7yW7E00; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPa-00068l-98; Fri, 29 Dec 2023 16:28:58 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPX-0005j0-C8 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:55 -0500 Received: from mail-pf1-x430.google.com ([2607:f8b0:4864:20::430]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPV-0000Lp-3u for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:55 -0500 Received: by mail-pf1-x430.google.com with SMTP id d2e1a72fcca58-6d9f94b9186so2216034b3a.0 for ; Fri, 29 Dec 2023 13:28:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885332; x=1704490132; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=OqU6sg9g0ESWhn8ACzHLMCxFbvZWow6DbzojmlPanzM=; b=o7yW7E00YXeiSyNsUzcFSMpJ5M5fIPQ7FQN4gav5Wp8bxUT97piLO8nETifu/5TV9i SnN54R4genxiUc/LGyFyZJwSougcQTQsL6F0xnY8WVXLc0fONDxM6HG+Cn6X3ud7cFxy BAYZoDN8Ai8EfL+YJ0Irc/aF50C2SUoLn59G/6Vwt6SQjWtBY4//h3VVk8D7PQ2+7YKy BbkgVkrJT+N0FgICQrcGCnJ006Zcvkf4CipChOAHhLeK91sddLOEdOUThSfnPwxsrPxK j7OYozSZlorYsVAS81QUOqeXtI9b6w4BTisQCHytoCPOCjI87btvEiQn81gKhauLIFBO wvjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885332; x=1704490132; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OqU6sg9g0ESWhn8ACzHLMCxFbvZWow6DbzojmlPanzM=; b=fDP+n+m6MMoeA7gC0TjALfQIVBgGg6Z3g7e97EkYdhdN2SyddyOC16IFgemEqmkyUN lolh3aSdwJ8Q+uqFFv87AR/Ib/7/wM9ec9UGVG2KJS9TeZXUnHTMNR1J7XggAZfnCdoc 8HDUbsoO5RAUadcQfFY4qMSqW/WjzmPIpopjPvD42DiK15ZOJVgJK3CSGilYmCmHWy7L Bvlvs1rW5IBMIF0hlCNFlYSmmEls6S17GizznH6OC2OUEuBjFzB11S3sWp+P6ye5c9Tz zxOwKrqp1O5+XlqmHAr4I8b4KR7s/ANWAHQQq0oojOjWgWhE9+L2M5RGAh6r1e8GmIzW 7/Xg== X-Gm-Message-State: AOJu0YzYmqCTBS9c5EwgcYtGYeX/vIPM3RelvqfCukbXlEAXlsrmP68j V3O7aLfMKcIQr1k1rpLNvsM1EA2YWVcbYAYxpgkSXzU27gQHqw== X-Received: by 2002:a05:6a00:464a:b0:6d9:396d:730b with SMTP id kp10-20020a056a00464a00b006d9396d730bmr13614192pfb.27.1703885331738; Fri, 29 Dec 2023 13:28:51 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:51 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 50/71] hw/s390x: Constify VMState Date: Sat, 30 Dec 2023 08:23:25 +1100 Message-Id: <20231229212346.147149-51-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::430; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x430.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-51-richard.henderson@linaro.org> --- hw/s390x/ccw-device.c | 2 +- hw/s390x/css.c | 36 ++++++++++++++++++------------------ hw/s390x/event-facility.c | 8 ++++---- hw/s390x/ipl.c | 8 ++++---- hw/s390x/sclpquiesce.c | 2 +- hw/s390x/virtio-ccw.c | 4 ++-- 6 files changed, 30 insertions(+), 30 deletions(-) diff --git a/hw/s390x/ccw-device.c b/hw/s390x/ccw-device.c index 95f269ab44..fb8c1acc64 100644 --- a/hw/s390x/ccw-device.c +++ b/hw/s390x/ccw-device.c @@ -66,7 +66,7 @@ const VMStateDescription vmstate_ccw_dev = { .name = "s390_ccw_dev", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER(sch, CcwDevice, vmstate_subch_dev, SubchDev), VMSTATE_END_OF_LIST() } diff --git a/hw/s390x/css.c b/hw/s390x/css.c index bcedec2fc8..295530963a 100644 --- a/hw/s390x/css.c +++ b/hw/s390x/css.c @@ -32,7 +32,7 @@ static const VMStateDescription vmstate_crw = { .name = "s390_crw", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(flags, CRW), VMSTATE_UINT16(rsid, CRW), VMSTATE_END_OF_LIST() @@ -43,7 +43,7 @@ static const VMStateDescription vmstate_crw_container = { .name = "s390_crw_container", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(crw, CrwContainer, 0, vmstate_crw, CRW), VMSTATE_END_OF_LIST() }, @@ -59,7 +59,7 @@ static const VMStateDescription vmstate_chp_info = { .name = "s390_chp_info", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(in_use, ChpInfo), VMSTATE_UINT8(type, ChpInfo), VMSTATE_UINT8(is_virtual, ChpInfo), @@ -77,7 +77,7 @@ static const VMStateDescription vmstate_scsw = { .name = "s390_scsw", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(flags, SCSW), VMSTATE_UINT16(ctrl, SCSW), VMSTATE_UINT32(cpa, SCSW), @@ -92,7 +92,7 @@ static const VMStateDescription vmstate_pmcw = { .name = "s390_pmcw", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(intparm, PMCW), VMSTATE_UINT16(flags, PMCW), VMSTATE_UINT16(devno, PMCW), @@ -113,7 +113,7 @@ static const VMStateDescription vmstate_schib = { .name = "s390_schib", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(pmcw, SCHIB, 0, vmstate_pmcw, PMCW), VMSTATE_STRUCT(scsw, SCHIB, 0, vmstate_scsw, SCSW), VMSTATE_UINT64(mba, SCHIB), @@ -127,7 +127,7 @@ static const VMStateDescription vmstate_ccw1 = { .name = "s390_ccw1", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(cmd_code, CCW1), VMSTATE_UINT8(flags, CCW1), VMSTATE_UINT16(count, CCW1), @@ -140,7 +140,7 @@ static const VMStateDescription vmstate_ciw = { .name = "s390_ciw", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(type, CIW), VMSTATE_UINT8(command, CIW), VMSTATE_UINT16(count, CIW), @@ -152,7 +152,7 @@ static const VMStateDescription vmstate_sense_id = { .name = "s390_sense_id", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(reserved, SenseId), VMSTATE_UINT16(cu_type, SenseId), VMSTATE_UINT8(cu_model, SenseId), @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_orb = { .name = "s390_orb", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(intparm, ORB), VMSTATE_UINT16(ctrl0, ORB), VMSTATE_UINT8(lpm, ORB), @@ -188,7 +188,7 @@ static const VMStateDescription vmstate_schdev_orb = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_schdev_orb_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(orb, SubchDev, 1, vmstate_orb, ORB), VMSTATE_END_OF_LIST() } @@ -207,7 +207,7 @@ const VMStateDescription vmstate_subch_dev = { .minimum_version_id = 1, .post_load = subch_dev_post_load, .pre_save = subch_dev_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_EQUAL(cssid, SubchDev, "Bug!"), VMSTATE_UINT8_EQUAL(ssid, SubchDev, "Bug!"), VMSTATE_UINT16(migrated_schid, SubchDev), @@ -223,7 +223,7 @@ const VMStateDescription vmstate_subch_dev = { VMSTATE_UINT8(ccw_no_data_cnt, SubchDev), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_schdev_orb, NULL } @@ -264,12 +264,12 @@ static int pre_save_ind_addr(void *opaque) return 0; } -const VMStateDescription vmstate_ind_addr_tmp = { +static const VMStateDescription vmstate_ind_addr_tmp = { .name = "s390_ind_addr_tmp", .pre_save = pre_save_ind_addr, .post_load = post_load_ind_addr, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(len, IndAddrPtrTmp), VMSTATE_UINT64(addr, IndAddrPtrTmp), VMSTATE_END_OF_LIST() @@ -278,7 +278,7 @@ const VMStateDescription vmstate_ind_addr_tmp = { const VMStateDescription vmstate_ind_addr = { .name = "s390_ind_addr_tmp", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP(IndAddr*, IndAddrPtrTmp, vmstate_ind_addr_tmp), VMSTATE_END_OF_LIST() } @@ -293,7 +293,7 @@ static const VMStateDescription vmstate_css_img = { .name = "s390_css_img", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* Subchannel sets have no relevant state. */ VMSTATE_STRUCT_ARRAY(chpids, CssImage, MAX_CHPID + 1, 0, vmstate_chp_info, ChpInfo), @@ -330,7 +330,7 @@ static const VMStateDescription vmstate_css = { .name = "s390_css", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_QTAILQ_V(pending_crws, ChannelSubSys, 1, vmstate_crw_container, CrwContainer, sibling), VMSTATE_BOOL(sei_pending, ChannelSubSys), diff --git a/hw/s390x/event-facility.c b/hw/s390x/event-facility.c index 6891e3cd73..f9829de953 100644 --- a/hw/s390x/event-facility.c +++ b/hw/s390x/event-facility.c @@ -367,7 +367,7 @@ static const VMStateDescription vmstate_event_facility_mask64 = { .version_id = 0, .minimum_version_id = 0, .needed = vmstate_event_facility_mask64_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(receive_mask_pieces[RECV_MASK_LOWER], SCLPEventFacility), VMSTATE_END_OF_LIST() } @@ -378,7 +378,7 @@ static const VMStateDescription vmstate_event_facility_mask_length = { .version_id = 0, .minimum_version_id = 0, .needed = vmstate_event_facility_mask_length_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(mask_length, SCLPEventFacility), VMSTATE_END_OF_LIST() } @@ -388,11 +388,11 @@ static const VMStateDescription vmstate_event_facility = { .name = "vmstate-event-facility", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(receive_mask_pieces[RECV_MASK_UPPER], SCLPEventFacility), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_event_facility_mask64, &vmstate_event_facility_mask_length, NULL diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c index 62182d81a0..76110e8f58 100644 --- a/hw/s390x/ipl.c +++ b/hw/s390x/ipl.c @@ -59,7 +59,7 @@ static const VMStateDescription vmstate_iplb_extended = { .version_id = 0, .minimum_version_id = 0, .needed = iplb_extended_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(reserved_ext, IplParameterBlock, 4096 - 200), VMSTATE_END_OF_LIST() } @@ -69,13 +69,13 @@ static const VMStateDescription vmstate_iplb = { .name = "ipl/iplb", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(reserved1, IplParameterBlock, 110), VMSTATE_UINT16(devno, IplParameterBlock), VMSTATE_UINT8_ARRAY(reserved2, IplParameterBlock, 88), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_iplb_extended, NULL } @@ -85,7 +85,7 @@ static const VMStateDescription vmstate_ipl = { .name = "ipl", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(compat_start_addr, S390IPLState), VMSTATE_UINT64(compat_bios_start_addr, S390IPLState), VMSTATE_STRUCT(iplb, S390IPLState, 0, vmstate_iplb, IplParameterBlock), diff --git a/hw/s390x/sclpquiesce.c b/hw/s390x/sclpquiesce.c index a641089929..14936aa94b 100644 --- a/hw/s390x/sclpquiesce.c +++ b/hw/s390x/sclpquiesce.c @@ -72,7 +72,7 @@ static const VMStateDescription vmstate_sclpquiesce = { .name = TYPE_SCLP_QUIESCE, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(event_pending, SCLPEvent), VMSTATE_END_OF_LIST() } diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c index 80453718a3..b4676909dd 100644 --- a/hw/s390x/virtio-ccw.c +++ b/hw/s390x/virtio-ccw.c @@ -87,7 +87,7 @@ const VMStateDescription vmstate_virtio_ccw_dev_tmp = { .name = "s390_virtio_ccw_dev_tmp", .pre_save = virtio_ccw_dev_tmp_pre_save, .post_load = virtio_ccw_dev_tmp_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(config_vector, VirtioCcwDeviceTmp), VMSTATE_END_OF_LIST() } @@ -98,7 +98,7 @@ const VMStateDescription vmstate_virtio_ccw_dev = { .version_id = 1, .minimum_version_id = 1, .post_load = virtio_ccw_dev_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CCW_DEVICE(parent_obj, VirtioCcwDevice), VMSTATE_PTR_TO_IND_ADDR(indicators, VirtioCcwDevice), VMSTATE_PTR_TO_IND_ADDR(indicators2, VirtioCcwDevice), From patchwork Fri Dec 29 21:23:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758823 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4671849wrw; Fri, 29 Dec 2023 13:29:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IGV5RdPfWqsLkWdOvs3eKJAdW56QZSEEW5oHbPwh4nDJKHMf3UAQib+uIo5Eusu4tdyLlk1 X-Received: by 2002:a05:6358:4327:b0:174:f06b:3358 with SMTP id r39-20020a056358432700b00174f06b3358mr3028263rwc.38.1703885382911; Fri, 29 Dec 2023 13:29:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885382; cv=none; d=google.com; s=arc-20160816; b=wJeWbmF/8r2VBMypZE7Rb6Z3ISicYYwieRaR/EnuA+15If5GdBEh9W/ZFfvq6NZ8eQ OFRfzKseK8oUk03bzv+MyL/FqTfbAhy7kw0pJaqj0UbHD9p7MXMF2Oy6brR99MFbdUF4 ERM54W3syDyfJ45+e8hwRBVfmw8p0W0bsqBbH8GXlAzVcIHuRxFEnEPJhDO207lNx1R6 47vNwPiXPOFDtUVt2yziEEGci4unOxFsyuh3RgKdOlg67dPfnj4P+4IRYhwtsLZoOGFr DJLZbSm4NWzy6y9cIVb7GsHxBRBOKwXLueaRJTIgPHx8SO0arkTPFgPIa/oiMPFjC5iF xfhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=uWYrugkHEWBc6Cby1jqzi6Op/DM/ZQDlsHv8VnjupHU=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=i84/wm5qsrIfl+LeixoJ7PyxbQVQI3ukSq2eyC2l3aZRFBnoasXGNcTvwQhIawu7lO 8+Ilky3K/sXbec19o224x7Nsb3vkYmM8ktkMzJQ+0gWgED2WoJtRQ9xFOiS3xtDAHXXH wfwy/MLAnbKGAEsAc/kd9bqU33r/lCbIsW43PoZx4J6LwwE35fBVq0eJY8ldipq7dzDU KsrTCuZ4XhQhvg7wJi1Yvzr3l/UQwNSmSL8LxHBdg0d+PGoW91/V5qHir6nitP/0Aq7q NtXcuFQ9C2G/gCMh/MnOeeU5Lihqsvi1I1oqsRbp20DvF5Dc9pLuZV7q2LPYj/9KEhon BBHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="bfu9xg/s"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b3-20020a05622a020300b00423e44445fbsi19965360qtx.689.2023.12.29.13.29.42 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:29:42 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="bfu9xg/s"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPk-0007IM-Eg; Fri, 29 Dec 2023 16:29:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPj-0007HX-6R for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:07 -0500 Received: from mail-pg1-x531.google.com ([2607:f8b0:4864:20::531]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPX-0000M4-5t for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:06 -0500 Received: by mail-pg1-x531.google.com with SMTP id 41be03b00d2f7-5bdbe2de25fso5599891a12.3 for ; Fri, 29 Dec 2023 13:28:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885334; x=1704490134; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=uWYrugkHEWBc6Cby1jqzi6Op/DM/ZQDlsHv8VnjupHU=; b=bfu9xg/siLNpFFfa0qrFl5lGjRTvyRoIHk0C4ELNEtFFNHjML4purtYA5N6G6Dob4T vuF4ZozcxbuIZCbc7xTq+dJZp4+Gyapn1tttOWNCBT8kvabBCk6QfZbcwlmC5E4KHf7k DAWoLml+Up/YD2PyuG8zyw3fJvAaqlrVfxFgfYHOKL9NINwhYUCyE8xTm9xG75ec14ZX UheYSOTFdTNyM8sQAc5bDZgz900I+Na/OwjQhPsrpkAjMVE9Bhh3/2Q5FevyMd1jV26M tg5BFzZx1ia3GHMw8uGyxdOrO/J0fINC+H+V00eG783liXeRVNMxSpc6gUsokPhl/Tpw KDUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885334; x=1704490134; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=uWYrugkHEWBc6Cby1jqzi6Op/DM/ZQDlsHv8VnjupHU=; b=EOjKnYpxXfu+Gfk6iNqEXYezeMuQtH0cDv3q2fF2O3cy48Y3GrNsau9lKvGveQ70JJ qSLmwjHU1YMsRrHXg2bjqMycEzZzlP9vyWFFeZYkhuDTCuEbrv+MWsv4RiS2pfPhZnBj AanChblKtX65yWkvvuj3VddNLO96fDK1jddrwzjeVi/TqZ17REKAl7aHuUBvmaGIM1TJ KTWsOWMv+shUMZsg2skPx8wPlU8jSRLfwNGUfRjV732T40vuZxd3XjfGfa47+EQ3RU/7 6oUXZoqELmr2t/YT2jSAbo04gswLqGIOV8+/L0iN/7ZusZUU7C1JKBkMpRa4UjLPKI3B z1Cg== X-Gm-Message-State: AOJu0Yzj65hZCwmZxW7Rity1Uebu6f05odC8yrQNxUfk+Zu6/n0pwkTO v0Nvbp2jpxrhxIzYl2pB3pB0qcNtV5fdjzJYy86nWdtQpkU1GQ== X-Received: by 2002:a05:6a20:471b:b0:18f:97c:8a43 with SMTP id ek27-20020a056a20471b00b0018f097c8a43mr14316517pzb.110.1703885333881; Fri, 29 Dec 2023 13:28:53 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:53 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 51/71] hw/scsi: Constify VMState Date: Sat, 30 Dec 2023 08:23:26 +1100 Message-Id: <20231229212346.147149-52-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::531; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x531.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-52-richard.henderson@linaro.org> --- hw/scsi/esp-pci.c | 2 +- hw/scsi/esp.c | 8 ++++---- hw/scsi/lsi53c895a.c | 2 +- hw/scsi/megasas.c | 4 ++-- hw/scsi/mptsas.c | 2 +- hw/scsi/scsi-bus.c | 6 +++--- hw/scsi/scsi-disk.c | 2 +- hw/scsi/spapr_vscsi.c | 4 ++-- hw/scsi/vhost-scsi.c | 2 +- hw/scsi/vhost-user-scsi.c | 2 +- hw/scsi/virtio-scsi.c | 2 +- hw/scsi/vmw_pvscsi.c | 6 +++--- 12 files changed, 21 insertions(+), 21 deletions(-) diff --git a/hw/scsi/esp-pci.c b/hw/scsi/esp-pci.c index 4e890db0e2..93b3429e0f 100644 --- a/hw/scsi/esp-pci.c +++ b/hw/scsi/esp-pci.c @@ -333,7 +333,7 @@ static const VMStateDescription vmstate_esp_pci_scsi = { .version_id = 2, .minimum_version_id = 1, .pre_save = esp_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PCIESPState), VMSTATE_BUFFER_UNSAFE(dma_regs, PCIESPState, 0, 8 * sizeof(uint32_t)), VMSTATE_UINT8_V(esp.mig_version_id, PCIESPState, 2), diff --git a/hw/scsi/esp.c b/hw/scsi/esp.c index 9b11d8c573..ff90572830 100644 --- a/hw/scsi/esp.c +++ b/hw/scsi/esp.c @@ -1237,7 +1237,7 @@ static const VMStateDescription vmstate_esp_pdma = { .version_id = 0, .minimum_version_id = 0, .needed = esp_pdma_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(pdma_cb, ESPState), VMSTATE_END_OF_LIST() } @@ -1248,7 +1248,7 @@ const VMStateDescription vmstate_esp = { .version_id = 6, .minimum_version_id = 3, .post_load = esp_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(rregs, ESPState), VMSTATE_BUFFER(wregs, ESPState), VMSTATE_INT32(ti_size, ESPState), @@ -1277,7 +1277,7 @@ const VMStateDescription vmstate_esp = { VMSTATE_UINT8_TEST(lun, ESPState, esp_is_version_6), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_esp_pdma, NULL } @@ -1448,7 +1448,7 @@ static const VMStateDescription vmstate_sysbus_esp_scsi = { .version_id = 2, .minimum_version_id = 1, .pre_save = esp_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_V(esp.mig_version_id, SysBusESPState, 2), VMSTATE_STRUCT(esp, SysBusESPState, 0, vmstate_esp, ESPState), VMSTATE_END_OF_LIST() diff --git a/hw/scsi/lsi53c895a.c b/hw/scsi/lsi53c895a.c index 634ed49c2e..34e3b89287 100644 --- a/hw/scsi/lsi53c895a.c +++ b/hw/scsi/lsi53c895a.c @@ -2205,7 +2205,7 @@ static const VMStateDescription vmstate_lsi_scsi = { .minimum_version_id = 0, .pre_save = lsi_pre_save, .post_load = lsi_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, LSIState), VMSTATE_INT32(carry, LSIState), diff --git a/hw/scsi/megasas.c b/hw/scsi/megasas.c index 32c70c9e99..2d0c607177 100644 --- a/hw/scsi/megasas.c +++ b/hw/scsi/megasas.c @@ -2299,7 +2299,7 @@ static const VMStateDescription vmstate_megasas_gen1 = { .name = "megasas", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, MegasasState), VMSTATE_MSIX(parent_obj, MegasasState), @@ -2317,7 +2317,7 @@ static const VMStateDescription vmstate_megasas_gen2 = { .name = "megasas-gen2", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, MegasasState), VMSTATE_MSIX(parent_obj, MegasasState), diff --git a/hw/scsi/mptsas.c b/hw/scsi/mptsas.c index 75d3ab8bd1..c5d3138c93 100644 --- a/hw/scsi/mptsas.c +++ b/hw/scsi/mptsas.c @@ -1366,7 +1366,7 @@ static const VMStateDescription vmstate_mptsas = { .version_id = 0, .minimum_version_id = 0, .post_load = mptsas_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, MPTSASState), VMSTATE_BOOL(msi_in_use, MPTSASState), VMSTATE_UINT32(state, MPTSASState), diff --git a/hw/scsi/scsi-bus.c b/hw/scsi/scsi-bus.c index 5b08cbf60a..0a2eb11c56 100644 --- a/hw/scsi/scsi-bus.c +++ b/hw/scsi/scsi-bus.c @@ -1893,7 +1893,7 @@ static const VMStateDescription vmstate_scsi_sense_state = { .version_id = 1, .minimum_version_id = 1, .needed = scsi_sense_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_SUB_ARRAY(sense, SCSIDevice, SCSI_SENSE_BUF_SIZE_OLD, SCSI_SENSE_BUF_SIZE - SCSI_SENSE_BUF_SIZE_OLD), @@ -1905,7 +1905,7 @@ const VMStateDescription vmstate_scsi_device = { .name = "SCSIDevice", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(unit_attention.key, SCSIDevice), VMSTATE_UINT8(unit_attention.asc, SCSIDevice), VMSTATE_UINT8(unit_attention.ascq, SCSIDevice), @@ -1923,7 +1923,7 @@ const VMStateDescription vmstate_scsi_device = { }, VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_scsi_sense_state, NULL } diff --git a/hw/scsi/scsi-disk.c b/hw/scsi/scsi-disk.c index 2e7e1e9a1c..4bd7af9d0c 100644 --- a/hw/scsi/scsi-disk.c +++ b/hw/scsi/scsi-disk.c @@ -3137,7 +3137,7 @@ static const VMStateDescription vmstate_scsi_disk_state = { .name = "scsi-disk", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SCSI_DEVICE(qdev, SCSIDiskState), VMSTATE_BOOL(media_changed, SCSIDiskState), VMSTATE_BOOL(media_event, SCSIDiskState), diff --git a/hw/scsi/spapr_vscsi.c b/hw/scsi/spapr_vscsi.c index 5bbbef64ef..c75a6c8807 100644 --- a/hw/scsi/spapr_vscsi.c +++ b/hw/scsi/spapr_vscsi.c @@ -605,7 +605,7 @@ static const VMStateDescription vmstate_spapr_vscsi_req = { .name = "spapr_vscsi_req", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(crq.raw, vscsi_req), VMSTATE_BUFFER(viosrp_iu_buf, vscsi_req), VMSTATE_UINT32(qtag, vscsi_req), @@ -1259,7 +1259,7 @@ static const VMStateDescription vmstate_spapr_vscsi = { .name = "spapr_vscsi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SPAPR_VIO(vdev, VSCSIState), /* VSCSI state */ /* ???? */ diff --git a/hw/scsi/vhost-scsi.c b/hw/scsi/vhost-scsi.c index 6159eb6fec..58a00336c2 100644 --- a/hw/scsi/vhost-scsi.c +++ b/hw/scsi/vhost-scsi.c @@ -158,7 +158,7 @@ static const VMStateDescription vmstate_virtio_vhost_scsi = { .name = "virtio-vhost_scsi", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/scsi/vhost-user-scsi.c b/hw/scsi/vhost-user-scsi.c index af18c4f3d3..a63b1f4948 100644 --- a/hw/scsi/vhost-user-scsi.c +++ b/hw/scsi/vhost-user-scsi.c @@ -379,7 +379,7 @@ static const VMStateDescription vmstate_vhost_scsi = { .name = "virtio-scsi", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/scsi/virtio-scsi.c b/hw/scsi/virtio-scsi.c index ca365a70e9..690aceec45 100644 --- a/hw/scsi/virtio-scsi.c +++ b/hw/scsi/virtio-scsi.c @@ -1305,7 +1305,7 @@ static const VMStateDescription vmstate_virtio_scsi = { .name = "virtio-scsi", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/scsi/vmw_pvscsi.c b/hw/scsi/vmw_pvscsi.c index 4de34536e9..cd7bf6aa01 100644 --- a/hw/scsi/vmw_pvscsi.c +++ b/hw/scsi/vmw_pvscsi.c @@ -1249,7 +1249,7 @@ static bool pvscsi_vmstate_test_pci_device(void *opaque, int version_id) static const VMStateDescription vmstate_pvscsi_pcie_device = { .name = "pvscsi/pcie", .needed = pvscsi_vmstate_need_pcie_device, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, PVSCSIState), VMSTATE_END_OF_LIST() } @@ -1261,7 +1261,7 @@ static const VMStateDescription vmstate_pvscsi = { .minimum_version_id = 0, .pre_save = pvscsi_pre_save, .post_load = pvscsi_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_TEST(parent_obj, PVSCSIState, pvscsi_vmstate_test_pci_device, 0, vmstate_pci_device, PCIDevice), @@ -1290,7 +1290,7 @@ static const VMStateDescription vmstate_pvscsi = { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_pvscsi_pcie_device, NULL } From patchwork Fri Dec 29 21:23:27 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758846 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672438wrw; Fri, 29 Dec 2023 13:31:41 -0800 (PST) X-Google-Smtp-Source: AGHT+IGYIHaNDCL/Ht7iwVAn6Z0ewFJ7rYOqFk8cT31bGqhtmPsP5YScXLQX653laaS9o0sP1J2D X-Received: by 2002:a05:620a:856:b0:781:5a5d:e8bb with SMTP id u22-20020a05620a085600b007815a5de8bbmr5356198qku.35.1703885501219; Fri, 29 Dec 2023 13:31:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885501; cv=none; d=google.com; s=arc-20160816; b=WqTFb25nU6dSE3I92LNq5tv7nyHL9ybS4B2wqKlRRCeKMDzcpHPJOgs6RHgCJFrBUa 2h/cXjuN1UhgPUJvaYsbDtGhReqYwpjPBUea04fm3DlAOLIa/qsqqYvws3kuCdRHFb4R YsOa+ifwyGrQpwxsqTahNkjp0Rvv11ijvQqOS2SA0eCANMFCEmFB+/56et6j+0r+JyiI 2R4RSJKKBCV7F396La/v6h8NNcCyRTHUBsKpasE7d9R1xTUNySmaeZoJ88dNoY7tL4Dm sVjVfMFpwvEJ4Em8nqjE7I0/JbTi887mWekHCog/LtIZe4OsfoaUEwnVRUIlGtsDH0iB 3/Zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ulGshSwG5KHuqNPfmNZqzOuiQN00QPV+I4fAymtm0Pc=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=yki8KJho5LjELROWSYBK1TunniEn/GAe9m/G9L2qvfw/PUgu0dvZkw10YB1enjAgVf BBnFCKg0nStaIRZPgLf42v3ah8YDIE8BVHTEEANnwzBtC2cI9UK4iKj/IvB4mnxmA36K r9G6JDFyyJbxqXoOjJNGHhICQcoHmWDN5bxolp3zmVzX/OgxRT29FttDR/Q0hhpQJ2+V ZLDU3Xw4M7BZWtsu+uc9TimZDWd520Y9TA4bI480CvF9GKkhndZSNcvb/xNLVUsvgPz2 20w5ohFGXht16HG4Ngd9RKmtcYO6bCfuB/akRuVbYuzqyz9/upZp2hvB+E/D+8dkQi0C p7pw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MCZPp4NR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id g20-20020a05620a40d400b0078139fa96besi14764570qko.773.2023.12.29.13.31.40 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:41 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=MCZPp4NR; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPe-0006gR-3j; Fri, 29 Dec 2023 16:29:02 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPc-0006Q9-5a for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:00 -0500 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPa-0000MF-6R for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:28:59 -0500 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6d9f94b9186so2216063b3a.0 for ; Fri, 29 Dec 2023 13:28:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885337; x=1704490137; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ulGshSwG5KHuqNPfmNZqzOuiQN00QPV+I4fAymtm0Pc=; b=MCZPp4NRqBWfQOeSywjQMElpH0CZVmLpW2Gk5OH0b1d2VIR4Nk1N87G1iMkVcWYqeF U5reXuVIIGLeeC0wXfG4j4d8EL6cfuLkXQnp+7+dNsqtNB8UpJvwqmi37YOYNuP1ynMP bVi842fgwxbSYI+3hXU7TYGnCcKtgIZrZJ6vaF6fG53DmLiDLI5YBwORnZmr8FQzYqjP zBPAKS4BhKSkSm62LlCFoy3u6HfpijP19ZFhxp+4fmGIa7aV0+7W1+fvt6xIkzlvrlgA 6zNh/95ZobFO9hAJYN6hhck4pjKxYVA/DZzqBQ62EiJSoArhKl4Om5J1v5uCP04ork9T FE1g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885337; x=1704490137; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ulGshSwG5KHuqNPfmNZqzOuiQN00QPV+I4fAymtm0Pc=; b=IW4DPs7cci1rbviNXVEWXa2d8PeZJFupKhW93UqWLg/Heh1mq0Pk426CXV/6gk/wdx 5tyE85yZf89t6HOPhmIQHOpzGexQfiE/yCOsxxUTg0kuizyrv6U8rBXF6v1fcMjSorI0 w2EtuY2GVMdtxNZb0+GbUHY79RsXdauyRpyVie0T+CDycxTCRS9xzgnIArH3dI/+RGIx YmqiIRIvhMnYyr3UmdP4/0D+4AftpqBZ+yrr0YeiIotq/KjdVW2yoqrn/3d1eKATqeXo dfDbTDthxXOnKEsQyNdDjUoDX3JaUs6WXEkRcBlwdrrrK/D+hotJ/TM8k86ma1gli3Bi t/Yw== X-Gm-Message-State: AOJu0Yxoq6HDBAutF+16mxOPMBGUczlxRf8duQa2SfubpNqQgngyK3S8 x5W4ODv//EhrcHvynJbZ+7DK3rtcAy2i18nxILVCGN1mbRLd5A== X-Received: by 2002:a05:6a00:4b8a:b0:6da:13b9:629f with SMTP id ks10-20020a056a004b8a00b006da13b9629fmr3570904pfb.11.1703885336815; Fri, 29 Dec 2023 13:28:56 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:56 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 52/71] hw/sd: Constify VMState Date: Sat, 30 Dec 2023 08:23:27 +1100 Message-Id: <20231229212346.147149-53-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x432.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-53-richard.henderson@linaro.org> --- hw/sd/allwinner-sdhost.c | 2 +- hw/sd/aspeed_sdhci.c | 2 +- hw/sd/bcm2835_sdhost.c | 2 +- hw/sd/cadence_sdhci.c | 2 +- hw/sd/npcm7xx_sdhci.c | 2 +- hw/sd/pl181.c | 2 +- hw/sd/pxa2xx_mmci.c | 2 +- hw/sd/sd.c | 6 +++--- hw/sd/sdhci.c | 6 +++--- hw/sd/ssi-sd.c | 2 +- 10 files changed, 14 insertions(+), 14 deletions(-) diff --git a/hw/sd/allwinner-sdhost.c b/hw/sd/allwinner-sdhost.c index 1a576d62ae..a1b7230633 100644 --- a/hw/sd/allwinner-sdhost.c +++ b/hw/sd/allwinner-sdhost.c @@ -773,7 +773,7 @@ static const VMStateDescription vmstate_allwinner_sdhost = { .name = "allwinner-sdhost", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(global_ctl, AwSdHostState), VMSTATE_UINT32(clock_ctl, AwSdHostState), VMSTATE_UINT32(timeout, AwSdHostState), diff --git a/hw/sd/aspeed_sdhci.c b/hw/sd/aspeed_sdhci.c index e53206d959..3b63926c3a 100644 --- a/hw/sd/aspeed_sdhci.c +++ b/hw/sd/aspeed_sdhci.c @@ -177,7 +177,7 @@ static void aspeed_sdhci_reset(DeviceState *dev) static const VMStateDescription vmstate_aspeed_sdhci = { .name = TYPE_ASPEED_SDHCI, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedSDHCIState, ASPEED_SDHCI_NUM_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/sd/bcm2835_sdhost.c b/hw/sd/bcm2835_sdhost.c index a600cf39e2..11c54dd4a7 100644 --- a/hw/sd/bcm2835_sdhost.c +++ b/hw/sd/bcm2835_sdhost.c @@ -381,7 +381,7 @@ static const VMStateDescription vmstate_bcm2835_sdhost = { .name = TYPE_BCM2835_SDHOST, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cmd, BCM2835SDHostState), VMSTATE_UINT32(cmdarg, BCM2835SDHostState), VMSTATE_UINT32(status, BCM2835SDHostState), diff --git a/hw/sd/cadence_sdhci.c b/hw/sd/cadence_sdhci.c index ef4e0d74e3..7c8bc5464b 100644 --- a/hw/sd/cadence_sdhci.c +++ b/hw/sd/cadence_sdhci.c @@ -159,7 +159,7 @@ static void cadence_sdhci_realize(DeviceState *dev, Error **errp) static const VMStateDescription vmstate_cadence_sdhci = { .name = TYPE_CADENCE_SDHCI, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, CadenceSDHCIState, CADENCE_SDHCI_NUM_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/sd/npcm7xx_sdhci.c b/hw/sd/npcm7xx_sdhci.c index 9958680090..e93dab8dbd 100644 --- a/hw/sd/npcm7xx_sdhci.c +++ b/hw/sd/npcm7xx_sdhci.c @@ -142,7 +142,7 @@ static void npcm7xx_sdhci_reset(DeviceState *dev) static const VMStateDescription vmstate_npcm7xx_sdhci = { .name = TYPE_NPCM7XX_SDHCI, .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(regs.boottoctrl, NPCM7xxSDHCIState), VMSTATE_END_OF_LIST(), }, diff --git a/hw/sd/pl181.c b/hw/sd/pl181.c index 2b33814d83..e3633c2e6f 100644 --- a/hw/sd/pl181.c +++ b/hw/sd/pl181.c @@ -63,7 +63,7 @@ static const VMStateDescription vmstate_pl181 = { .name = "pl181", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(clock, PL181State), VMSTATE_UINT32(power, PL181State), VMSTATE_UINT32(cmdarg, PL181State), diff --git a/hw/sd/pxa2xx_mmci.c b/hw/sd/pxa2xx_mmci.c index 5e8ea69188..82529708c8 100644 --- a/hw/sd/pxa2xx_mmci.c +++ b/hw/sd/pxa2xx_mmci.c @@ -84,7 +84,7 @@ static const VMStateDescription vmstate_pxa2xx_mmci = { .name = "pxa2xx-mmci", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(status, PXA2xxMMCIState), VMSTATE_UINT32(clkrt, PXA2xxMMCIState), VMSTATE_UINT32(spi, PXA2xxMMCIState), diff --git a/hw/sd/sd.c b/hw/sd/sd.c index 1106ff7d78..807b5d3de3 100644 --- a/hw/sd/sd.c +++ b/hw/sd/sd.c @@ -681,7 +681,7 @@ static const VMStateDescription sd_ocr_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = sd_ocr_vmstate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ocr, SDState), VMSTATE_TIMER_PTR(ocr_power_timer, SDState), VMSTATE_END_OF_LIST() @@ -706,7 +706,7 @@ static const VMStateDescription sd_vmstate = { .version_id = 2, .minimum_version_id = 2, .pre_load = sd_vmstate_pre_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(mode, SDState), VMSTATE_INT32(state, SDState), VMSTATE_UINT8_ARRAY(cid, SDState, 16), @@ -733,7 +733,7 @@ static const VMStateDescription sd_vmstate = { VMSTATE_BOOL(enable, SDState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &sd_ocr_vmstate, NULL }, diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c index 40473b0db0..c5e0bc018b 100644 --- a/hw/sd/sdhci.c +++ b/hw/sd/sdhci.c @@ -1457,7 +1457,7 @@ static const VMStateDescription sdhci_pending_insert_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = sdhci_pending_insert_vmstate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(pending_insert_state, SDHCIState), VMSTATE_END_OF_LIST() }, @@ -1467,7 +1467,7 @@ const VMStateDescription sdhci_vmstate = { .name = "sdhci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(sdmasysad, SDHCIState), VMSTATE_UINT16(blksize, SDHCIState), VMSTATE_UINT16(blkcnt, SDHCIState), @@ -1498,7 +1498,7 @@ const VMStateDescription sdhci_vmstate = { VMSTATE_TIMER_PTR(transfer_timer, SDHCIState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &sdhci_pending_insert_vmstate, NULL }, diff --git a/hw/sd/ssi-sd.c b/hw/sd/ssi-sd.c index a6cc1ad6c8..2dd070f978 100644 --- a/hw/sd/ssi-sd.c +++ b/hw/sd/ssi-sd.c @@ -350,7 +350,7 @@ static const VMStateDescription vmstate_ssi_sd = { .version_id = 7, .minimum_version_id = 7, .post_load = ssi_sd_post_load, - .fields = (VMStateField []) { + .fields = (const VMStateField []) { VMSTATE_UINT32(mode, ssi_sd_state), VMSTATE_INT32(cmd, ssi_sd_state), VMSTATE_UINT8_ARRAY(cmdarg, ssi_sd_state, 4), From patchwork Fri Dec 29 21:23:28 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758834 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672226wrw; Fri, 29 Dec 2023 13:31:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IGWlgwKzPtpz0a8hjbqmXD0Fqgr6N9UVyJDe5YPBaNSKNTqSSd5b8ijmzDtlYS2eTm61S9C X-Received: by 2002:a05:6808:6487:b0:3bb:d6e7:154f with SMTP id fh7-20020a056808648700b003bbd6e7154fmr3901032oib.40.1703885462907; Fri, 29 Dec 2023 13:31:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885462; cv=none; d=google.com; s=arc-20160816; b=WPTfqsFaNlqR0c8+/N4Eh9TfH+88kn752MrtACSd/orNdox1wp8omcNAWSnGRUa1U6 0OZdU7HRBz/iV6zNiZMBi0x7UCnYgkFYvRVKbU+yd/k08CvjX5ZXG6R8ukjRvxVrTtsA neM8kmaPMknhSW+4Msh+tcxNijr/J4icpHhEJ7+9TWeyJZdR/+k6AdgWlSR61gKZxmfH lwzee6PmAMDGLH5gCZJSq84ja/V9geAKKaTYqEHJ2xciOkwfODOT+3QJAHDEDoUreah8 zL3PkhDzx0pR3Uu3Yd4RgY10nAO3/R/FFwGLnOAZPWDQxC5K9XSe3kwOYBFd0mvYvwen udOw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=dhfGylU0tZW2Dh+UHioxT5DQ6oaJb1b9JbJR4l6mL0Y=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=Rk7O13LzibZ75coSnG3/staabc+P68gIa1Gk01k9PJWcFxWj05gkCsJwapBKzxNEgf b2EJ9hAZHwkFmoLhMT458tYbx/kru/HJ8DJjGuWbM4pjpm4+tcFA/dfpbvttHxxzlmXt k45+/zTwL13KJK9GwgJ1PXOijG1/dHhejv7cL0nRz2mzwSwpoRFZEUTf9tSfGJZLjtyC FiLUQRZipYDG3xqVQutgiVNtOPEdgH9oHX34IMXjUCYusAI2ZXPlF0T5LRbY6uxsXR2O NUtpAJ3ov2pjhuXUtFYDOuHMyLK333rs/yhvBHAxDA6RYRDowEcpP5D/YmlFENgKRWOJ LabQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=UyPUJzbQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id u18-20020a05622a14d200b00407dd1bbbf5si20217551qtx.368.2023.12.29.13.31.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:02 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=UyPUJzbQ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPg-00072B-FK; Fri, 29 Dec 2023 16:29:04 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPe-0006jl-GQ for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:02 -0500 Received: from mail-ot1-x335.google.com ([2607:f8b0:4864:20::335]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPc-0000MK-C2 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:02 -0500 Received: by mail-ot1-x335.google.com with SMTP id 46e09a7af769-6dc02727c62so1747797a34.1 for ; Fri, 29 Dec 2023 13:28:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885339; x=1704490139; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dhfGylU0tZW2Dh+UHioxT5DQ6oaJb1b9JbJR4l6mL0Y=; b=UyPUJzbQVDcjyvgR6KxcNCreYvicIqeXvmnSJAYFZyCDLxxROfQcWogNIe0HiCDvQq ZAytVUpTYJ/XL//jjqg03VxCmLmpZBUZndMmMkGbg1I0tVOJhsX/kav6xaFvxKh0O9FB EibJB3x8pQIoEQVb2d/AcwkUj4Cfr05/5pzuwdh8Q4qD7VqmXCrWg3BEQ9YJPvvsLiC+ jlhtSf8xhP6OEIVa5Rm4/yN+dQ1/3jdzqUo53Df2BXEgZfLixe1Jnty5At1WQtopy8zv NftEqnG1D7KcPnXSwJOS81JG0LYSiacfCXlSyRzxC5mBx1Ce1smJCjy8rl9R7v/Kj/V8 uC9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885339; x=1704490139; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dhfGylU0tZW2Dh+UHioxT5DQ6oaJb1b9JbJR4l6mL0Y=; b=dy1NguSJKR8WEoHHImzwvdWHk7QWmwaGbL4nW1S+oP1qpc8rlPRlh2coxClrgZG0vB XQxqut7LFo01mSPmayyasYhqsMQuEN1C/kF9tR1iRPBAj14/tsAyqxHHT7o2YNcNtES+ 2SI5ttuk60ZRmSOiinjMQBhZesIhZGMORPosslnrOiL+JAbWtwBAzG4H18JDzPPL9XFi CMWObA4BS0Sg4VlAGO4SJNCmgw2BtmfObXwf+LQPYRTt5N+Q0TIwiJmagk0D0b1/JXGJ nuYse+Rm8FH4ZtwKhgYvrcws/oBkRLmN7/sIyOuDUXL+uyeu1vv7wMcQR6olfVJMpa2l BiOA== X-Gm-Message-State: AOJu0Yy07aQKrJIBuAJmladbJ3P3CESmpfOq1VD3k+BRUkLR1KHA5lu6 nx2CWWpTmpYfqlam+nH5o6yeNAgdA+rbTqZ0RC7EMbAlL4OhzA== X-Received: by 2002:a05:6830:85:b0:6db:a64e:f25e with SMTP id a5-20020a056830008500b006dba64ef25emr9276876oto.50.1703885339123; Fri, 29 Dec 2023 13:28:59 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:28:58 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 53/71] hw/sensor: Constify VMState Date: Sat, 30 Dec 2023 08:23:28 +1100 Message-Id: <20231229212346.147149-54-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::335; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x335.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-54-richard.henderson@linaro.org> --- hw/sensor/adm1266.c | 2 +- hw/sensor/adm1272.c | 2 +- hw/sensor/dps310.c | 2 +- hw/sensor/emc141x.c | 2 +- hw/sensor/lsm303dlhc_mag.c | 2 +- hw/sensor/max31785.c | 2 +- hw/sensor/max34451.c | 2 +- hw/sensor/tmp105.c | 6 +++--- hw/sensor/tmp421.c | 2 +- 9 files changed, 11 insertions(+), 11 deletions(-) diff --git a/hw/sensor/adm1266.c b/hw/sensor/adm1266.c index 5ae4f82ba1..5454b73a63 100644 --- a/hw/sensor/adm1266.c +++ b/hw/sensor/adm1266.c @@ -202,7 +202,7 @@ static const VMStateDescription vmstate_adm1266 = { .name = "ADM1266", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_PMBUS_DEVICE(parent, ADM1266State), VMSTATE_END_OF_LIST() } diff --git a/hw/sensor/adm1272.c b/hw/sensor/adm1272.c index 8f4a1c2cd4..1f7c8abb83 100644 --- a/hw/sensor/adm1272.c +++ b/hw/sensor/adm1272.c @@ -457,7 +457,7 @@ static const VMStateDescription vmstate_adm1272 = { .name = "ADM1272", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_PMBUS_DEVICE(parent, ADM1272State), VMSTATE_UINT64(ein_ext, ADM1272State), VMSTATE_UINT32(pin_ext, ADM1272State), diff --git a/hw/sensor/dps310.c b/hw/sensor/dps310.c index addee99b19..01c776dd7a 100644 --- a/hw/sensor/dps310.c +++ b/hw/sensor/dps310.c @@ -188,7 +188,7 @@ static const VMStateDescription vmstate_dps310 = { .name = "DPS310", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(len, DPS310State), VMSTATE_UINT8_ARRAY(regs, DPS310State, NUM_REGISTERS), VMSTATE_UINT8(pointer, DPS310State), diff --git a/hw/sensor/emc141x.c b/hw/sensor/emc141x.c index 7ce8f4e979..95079558e8 100644 --- a/hw/sensor/emc141x.c +++ b/hw/sensor/emc141x.c @@ -228,7 +228,7 @@ static const VMStateDescription vmstate_emc141x = { .name = "EMC141X", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(len, EMC141XState), VMSTATE_UINT8(data, EMC141XState), VMSTATE_UINT8(pointer, EMC141XState), diff --git a/hw/sensor/lsm303dlhc_mag.c b/hw/sensor/lsm303dlhc_mag.c index bb8d48b2fd..343ff98990 100644 --- a/hw/sensor/lsm303dlhc_mag.c +++ b/hw/sensor/lsm303dlhc_mag.c @@ -442,7 +442,7 @@ static const VMStateDescription vmstate_lsm303dlhc_mag = { .name = "LSM303DLHC_MAG", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_I2C_SLAVE(parent_obj, LSM303DLHCMagState), VMSTATE_UINT8(len, LSM303DLHCMagState), diff --git a/hw/sensor/max31785.c b/hw/sensor/max31785.c index 8b95e32481..916ed4d457 100644 --- a/hw/sensor/max31785.c +++ b/hw/sensor/max31785.c @@ -487,7 +487,7 @@ static const VMStateDescription vmstate_max31785 = { .name = TYPE_MAX31785, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_PMBUS_DEVICE(parent, MAX31785State), VMSTATE_UINT16_ARRAY(mfr_mode, MAX31785State, MAX31785_TOTAL_NUM_PAGES), diff --git a/hw/sensor/max34451.c b/hw/sensor/max34451.c index 9db52ef677..031ae53f59 100644 --- a/hw/sensor/max34451.c +++ b/hw/sensor/max34451.c @@ -654,7 +654,7 @@ static const VMStateDescription vmstate_max34451 = { .name = TYPE_MAX34451, .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_PMBUS_DEVICE(parent, MAX34451State), VMSTATE_UINT16_ARRAY(power_good_on, MAX34451State, MAX34451_NUM_PWR_DEVICES), diff --git a/hw/sensor/tmp105.c b/hw/sensor/tmp105.c index 2056449489..a8730d0b7f 100644 --- a/hw/sensor/tmp105.c +++ b/hw/sensor/tmp105.c @@ -238,7 +238,7 @@ static const VMStateDescription vmstate_tmp105_detect_falling = { .version_id = 1, .minimum_version_id = 1, .needed = detect_falling_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(detect_falling, TMP105State), VMSTATE_END_OF_LIST() } @@ -249,7 +249,7 @@ static const VMStateDescription vmstate_tmp105 = { .version_id = 0, .minimum_version_id = 0, .post_load = tmp105_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(len, TMP105State), VMSTATE_UINT8_ARRAY(buf, TMP105State, 2), VMSTATE_UINT8(pointer, TMP105State), @@ -260,7 +260,7 @@ static const VMStateDescription vmstate_tmp105 = { VMSTATE_I2C_SLAVE(i2c, TMP105State), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_tmp105_detect_falling, NULL } diff --git a/hw/sensor/tmp421.c b/hw/sensor/tmp421.c index a3db57dcb5..b6f0b62ab1 100644 --- a/hw/sensor/tmp421.c +++ b/hw/sensor/tmp421.c @@ -290,7 +290,7 @@ static const VMStateDescription vmstate_tmp421 = { .name = "TMP421", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(len, TMP421State), VMSTATE_UINT8_ARRAY(buf, TMP421State, 2), VMSTATE_UINT8(pointer, TMP421State), From patchwork Fri Dec 29 21:23:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758844 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672417wrw; Fri, 29 Dec 2023 13:31:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IGOeiuTW/PRXfGWlqhP4Q8UDl2Chigz86NHkslLahoA9HjHevVkqlEOuT3Nz45JDtvQU3/x X-Received: by 2002:a05:620a:260a:b0:781:2d7c:1332 with SMTP id z10-20020a05620a260a00b007812d7c1332mr16987139qko.18.1703885496685; Fri, 29 Dec 2023 13:31:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885496; cv=none; d=google.com; s=arc-20160816; b=e5zHhAuqTjYGKBS2RICqljVNatjj63r4QfQ9GP+xpQas0kGvfGUjbgQvtIzlCN3XRs xRBPVaxOpe2pHewTj56rqcXQ1sBtDOjsTAjvlUHh5U8MK/O4t3BhK5Xk+0bVv3Jgfexn SFwZAM1M7QyiLSuOmPw1InCFE8lUZqBjtVTlbZ7TcXePeUtz8ddn3fYSVYWzGtmZhad1 cO9th++cd7WNUdGIicHEb7gCP9QnNZXEMmZsgXtykg4hsoWlZo2YqBpKvCGG6blmuXc7 51p74/+9U0XXxxcLezGXbQjL5gHS77tVUR9KiV7pYBeWH+RMPD+ALE6RnsMCsHcGylW8 ZI+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=aNh1yh21I+GB6YiRXDF7E0H7kYf0QvfrR1nWFgKbksM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=QK+NJGBmrciNlOmHfKLnTiiivK+a6Ls1ERM/JLJl84JhbCPi7jhOoqqxOoTKuv/5ZF aU5Y9gbiA2fnCq/GlFGmC4LqpnO+QY2N7wDoxtJ/GZilrGi78WKVaP/8bfSvC/ncU+Wu ZprnizDAZ5fdo6osNW+ti26O54U7rzCNLuQfbfBejo8+ZekmOngyD5zQTGktkmvIf8tk fOekpOuDM3eCQkSS9PXFvwfTfovDKSiRsPfYGwglSOyeVKhYWfzlGRrNuEvx4Uy3UJaw 4gZCoe0NwVga732u7/Mpk+LmMmef1mP1Z2yui+MpTv+96z6irCw69TpvezuhATOvB2aD khew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Qvd4mDic; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id vu19-20020a05620a561300b0077d9accf19fsi19108004qkn.352.2023.12.29.13.31.36 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:36 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Qvd4mDic; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPm-0007Qm-H5; Fri, 29 Dec 2023 16:29:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPk-0007ID-8o for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:08 -0500 Received: from mail-ot1-x330.google.com ([2607:f8b0:4864:20::330]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPf-0000MU-C4 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:08 -0500 Received: by mail-ot1-x330.google.com with SMTP id 46e09a7af769-6dc076e9e59so1478170a34.2 for ; Fri, 29 Dec 2023 13:29:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885341; x=1704490141; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=aNh1yh21I+GB6YiRXDF7E0H7kYf0QvfrR1nWFgKbksM=; b=Qvd4mDicmxBEif2vOlXfGSRfunKUV3hj60ek6kTa3iruemahC36Z5pqyzcBsFlR9ne qauXgmaCrxMDVCobHwsx3Tb57H1uZMoMTFN0DylXmUlboGkqfqMrC7dGS6FLHJJUdXU7 BcjCwd9CL+kpaZSHexJk3d3oL7Xyfv6SxB96Rs7AlTRTQtHh0tC8qSzbp7AO3xyjUm6h AkLs+BUr37D2lG+8uAIJe/usTzkULmlowEBxgAnn03DrVqXiHqv/AfW1InXul58OSnJo 23nrJbA3LOTcuhnprtQ5Emktnnlq+rFDjDtVR951Gt7fAeuqXliVuViSHjtaYyWnCNmN 2PTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885341; x=1704490141; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=aNh1yh21I+GB6YiRXDF7E0H7kYf0QvfrR1nWFgKbksM=; b=NepfsGJR703BpdD0LyXLBVU2PLQHCnj4+OhqkwXZ9xN81IAGNSQ9ZOELL5XzcUdypt H9ng72KL9N20WV6zWgDF60YDFXyapVhzJ24ttvT7p1npcX0qFee8jufiENfLGXQirWDw yyHzJTFmPhuI0XLaBKhXDilnMFMDl+WYmB6e8cBm/GgjUC1q43Tms6zwPI8S2iGqyOjs U1WdvNOTa2yfEjW3L8RPH2YPAAIWKnj5GWdSTPYvHJzzxWilJm6pCbM8Xa8+4RhaCo5T K+f2lkGZ0fc9N5PpXwrHX81FMeoSOuotQHUxe/Mo8hUvDbjX6jomzUMU0cyWCc5Y16Ap xncw== X-Gm-Message-State: AOJu0Yz3nQMadDF+0C4N6pUEqjMqCC965q4axzvnQbcDG1Kplncr5aSE h+C420YF7rPCm99SbdCjBo2I955quxtTNszMu4O5ayVWZAj+bg== X-Received: by 2002:a05:6870:63a1:b0:203:e9cc:4878 with SMTP id t33-20020a05687063a100b00203e9cc4878mr14659108oap.46.1703885341178; Fri, 29 Dec 2023 13:29:01 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.28.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:00 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 54/71] hw/sparc: Constify VMState Date: Sat, 30 Dec 2023 08:23:29 +1100 Message-Id: <20231229212346.147149-55-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::330; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-55-richard.henderson@linaro.org> --- hw/sparc/sun4m_iommu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/sparc/sun4m_iommu.c b/hw/sparc/sun4m_iommu.c index eb40f9377c..06703b1d96 100644 --- a/hw/sparc/sun4m_iommu.c +++ b/hw/sparc/sun4m_iommu.c @@ -331,7 +331,7 @@ static const VMStateDescription vmstate_iommu = { .name = "iommu", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IOMMUState, IOMMU_NREGS), VMSTATE_UINT64(iostart, IOMMUState), VMSTATE_END_OF_LIST() From patchwork Fri Dec 29 21:23:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758838 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672305wrw; Fri, 29 Dec 2023 13:31:18 -0800 (PST) X-Google-Smtp-Source: AGHT+IHcLMdvk58YgZy3zqwsGWIHO5ERi+ujhX5eofw11HQ9MjZvbAYg/2cgkDeKStuT0c4DjPj1 X-Received: by 2002:a05:6830:45a:b0:6db:a3c1:8f7 with SMTP id d26-20020a056830045a00b006dba3c108f7mr9964284otc.35.1703885478308; Fri, 29 Dec 2023 13:31:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885478; cv=none; d=google.com; s=arc-20160816; b=IqgjYByu2e9u4h1H5xuqDKF7lgo4mzeWPMzJsthbWYZ7K0tS7KBSZte4J/XiepbMTS R2LlGK0SaTEBNr5rmoNf8jX6HrfScYcmk4H81y7aRbPnNiFAaN9EL6LKxAdqDMQobDN0 fCS3G+WIhvL9hcJGeYVSvEctFhMMBH5J86IhCqvQXKap2eWvB7SOiaRhI+5APOb0DNbk s2nMQMATJVDi3UHcnO7wpAfCF6kbF3hPmNnr3XjfFkP9Z9XewGVmJht0pK/lUrCTa/C2 MYOgW/QQShyQuJpIlLAv8Q7fC4wiZGMHyckOEJt+NSzNmfTjQSZWGuU2esMJFcHLoW36 IfgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=HTmpw0MQad52gS7rP7XqCUxFlfy+t9AtuwDtiqTIOjM=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=keURhgOuW5i9hQhWpPzG9BnUyq90S46oKtDOT6TsxTW8LTsCts78ovwpi2saOxxfW1 7jdBrpU6fxz6w0Q34K+mjo5NT2aNaHIjGtRfQaqZYbUYNRlSyp72XePtXlZkaIgNEovL ep70K2BiYLXX46D3tYLoY22aHIlL4T7IFDEIiNxm5t8qCO2CMnCux/HQ7MhDlR6VUnlQ rmiJvxiTBJrK78/k1cc82pWLKp7NkO55bp2c4sYq3nZaizBJ2I4DtZltwxll1iqdtZCk E2ZiXsDGQGoXNVA0flrnE3yAnH2sp4Tanq0vjJOYHs8MiwYhs07kBMvOslXtJklVxEiT 1kFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vzDuVpB9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id x1-20020a05622a000100b0042583ddd457si19498588qtw.305.2023.12.29.13.31.18 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:18 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vzDuVpB9; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPm-0007Nj-31; Fri, 29 Dec 2023 16:29:10 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPk-0007Iv-RE for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:08 -0500 Received: from mail-ot1-x329.google.com ([2607:f8b0:4864:20::329]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPg-0000Mh-Dh for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:08 -0500 Received: by mail-ot1-x329.google.com with SMTP id 46e09a7af769-6dbca115636so4323313a34.2 for ; Fri, 29 Dec 2023 13:29:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885343; x=1704490143; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=HTmpw0MQad52gS7rP7XqCUxFlfy+t9AtuwDtiqTIOjM=; b=vzDuVpB9YheOF9OH0ceSyfCO1eip7H+h30drOznMO5SBvHXNxu5ugSXCp6kPAwAKSC lwcj4bdqPRhXSAsyBdkBkabrwNUn3tNCHlWmycDkvoTFv9c7fcv2kI65/Et/p5tp+Y1P LfbA3S5Bar9osaJgXC+p3aCh2sec2RZLkHsE6jeeSEwXS2RpjzI8IWNlqpbE7YiSxp6w KMES6jFNWZ5jXJs67HO/AcXV3mZEHPtelqgL1ZQb9PixgwkIXHuf87ig8ilKaKTT1wMW EljD2w1cEEenUOX+8C/vAGfZ/bdPq3SN3RLQy1s7gWXfZhQlsscgs5cmZRzzc4uOcSkR BoiA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885343; x=1704490143; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HTmpw0MQad52gS7rP7XqCUxFlfy+t9AtuwDtiqTIOjM=; b=snt7mqIyHp0hOMW2ZL7leLygIdFm1Z1TxAs+2rcKkfs6x9sJ2osg0nhGz6oHup68HH mCI3s/+x5XQhHDM7Ok8XwPOQf8BujtIgxE3opOjoLoEL4zI/WrrqqVU2bidMIyqkR/Ve t0kcimwx7UOj5tnnoU7eUrX+JwMQwt5Mkz5WGRqsFcu9ZjcLhfLm7aihZOvGvshFCzkh 6zwoeQTolP014zvJuzh7H7G+rkdpYG+wDluMOfAKmDM4ZGMgEZvW1P0ooomVyOFWsBRn yhSlpm64U6XqgzWPevnJrKGiYypo6idxXQSVMjgisZ2B64HxZuE2GKgZMTmD/jgRjQKg fVjw== X-Gm-Message-State: AOJu0YyC8g12MCJ6WVha3wO6G9u4w9rXDUhdkaOHP/ETaR4Z3WUbMDEo hhXBfSCmVdvBg14H0t+4iT5iZJgFfxPkh8OZ4yFrkPWaNPJrNg== X-Received: by 2002:a05:6870:ac26:b0:203:7dc:6f26 with SMTP id kw38-20020a056870ac2600b0020307dc6f26mr14632786oab.63.1703885343207; Fri, 29 Dec 2023 13:29:03 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:02 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 55/71] hw/ssi: Constify VMState Date: Sat, 30 Dec 2023 08:23:30 +1100 Message-Id: <20231229212346.147149-56-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::329; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x329.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-56-richard.henderson@linaro.org> --- hw/ssi/aspeed_smc.c | 2 +- hw/ssi/ibex_spi_host.c | 2 +- hw/ssi/imx_spi.c | 2 +- hw/ssi/mss-spi.c | 2 +- hw/ssi/npcm7xx_fiu.c | 2 +- hw/ssi/npcm_pspi.c | 2 +- hw/ssi/pl022.c | 2 +- hw/ssi/ssi.c | 2 +- hw/ssi/stm32f2xx_spi.c | 2 +- hw/ssi/xilinx_spi.c | 2 +- hw/ssi/xilinx_spips.c | 6 +++--- hw/ssi/xlnx-versal-ospi.c | 4 ++-- 12 files changed, 15 insertions(+), 15 deletions(-) diff --git a/hw/ssi/aspeed_smc.c b/hw/ssi/aspeed_smc.c index 2a4001b774..3c93936fd1 100644 --- a/hw/ssi/aspeed_smc.c +++ b/hw/ssi/aspeed_smc.c @@ -1201,7 +1201,7 @@ static const VMStateDescription vmstate_aspeed_smc = { .name = "aspeed.smc", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, AspeedSMCState, ASPEED_SMC_R_MAX), VMSTATE_UINT8(snoop_index, AspeedSMCState), VMSTATE_UINT8(snoop_dummies, AspeedSMCState), diff --git a/hw/ssi/ibex_spi_host.c b/hw/ssi/ibex_spi_host.c index c300ec294d..863b5fd60e 100644 --- a/hw/ssi/ibex_spi_host.c +++ b/hw/ssi/ibex_spi_host.c @@ -570,7 +570,7 @@ static const VMStateDescription vmstate_ibex = { .name = TYPE_IBEX_SPI_HOST, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, IbexSPIHostState, IBEX_SPI_HOST_MAX_REGS), VMSTATE_VARRAY_UINT32(config_opts, IbexSPIHostState, num_cs, 0, vmstate_info_uint32, uint32_t), diff --git a/hw/ssi/imx_spi.c b/hw/ssi/imx_spi.c index 189423bb3a..d8a7583ff3 100644 --- a/hw/ssi/imx_spi.c +++ b/hw/ssi/imx_spi.c @@ -62,7 +62,7 @@ static const VMStateDescription vmstate_imx_spi = { .name = TYPE_IMX_SPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO32(tx_fifo, IMXSPIState), VMSTATE_FIFO32(rx_fifo, IMXSPIState), VMSTATE_INT16(burst_length, IMXSPIState), diff --git a/hw/ssi/mss-spi.c b/hw/ssi/mss-spi.c index b2432c5a13..1d25ba23aa 100644 --- a/hw/ssi/mss-spi.c +++ b/hw/ssi/mss-spi.c @@ -390,7 +390,7 @@ static const VMStateDescription vmstate_mss_spi = { .name = TYPE_MSS_SPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO32(tx_fifo, MSSSpiState), VMSTATE_FIFO32(rx_fifo, MSSSpiState), VMSTATE_UINT32_ARRAY(regs, MSSSpiState, R_SPI_MAX), diff --git a/hw/ssi/npcm7xx_fiu.c b/hw/ssi/npcm7xx_fiu.c index 4eedb2927e..81dd972ee8 100644 --- a/hw/ssi/npcm7xx_fiu.c +++ b/hw/ssi/npcm7xx_fiu.c @@ -534,7 +534,7 @@ static const VMStateDescription vmstate_npcm7xx_fiu = { .name = "npcm7xx-fiu", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(active_cs, NPCM7xxFIUState), VMSTATE_UINT32_ARRAY(regs, NPCM7xxFIUState, NPCM7XX_FIU_NR_REGS), VMSTATE_END_OF_LIST(), diff --git a/hw/ssi/npcm_pspi.c b/hw/ssi/npcm_pspi.c index 3fb935043a..41a5323530 100644 --- a/hw/ssi/npcm_pspi.c +++ b/hw/ssi/npcm_pspi.c @@ -192,7 +192,7 @@ static const VMStateDescription vmstate_npcm_pspi = { .name = "npcm-pspi", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16_ARRAY(regs, NPCMPSPIState, NPCM_PSPI_NR_REGS), VMSTATE_END_OF_LIST(), }, diff --git a/hw/ssi/pl022.c b/hw/ssi/pl022.c index 8954ffebb1..b8be8ddf0e 100644 --- a/hw/ssi/pl022.c +++ b/hw/ssi/pl022.c @@ -249,7 +249,7 @@ static const VMStateDescription vmstate_pl022 = { .version_id = 1, .minimum_version_id = 1, .post_load = pl022_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cr0, PL022State), VMSTATE_UINT32(cr1, PL022State), VMSTATE_UINT32(bitmask, PL022State), diff --git a/hw/ssi/ssi.c b/hw/ssi/ssi.c index 1f3e540ab8..3f357e8f16 100644 --- a/hw/ssi/ssi.c +++ b/hw/ssi/ssi.c @@ -172,7 +172,7 @@ const VMStateDescription vmstate_ssi_peripheral = { .name = "SSISlave", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(cs, SSIPeripheral), VMSTATE_END_OF_LIST() } diff --git a/hw/ssi/stm32f2xx_spi.c b/hw/ssi/stm32f2xx_spi.c index cd6e8443db..a37139fe5a 100644 --- a/hw/ssi/stm32f2xx_spi.c +++ b/hw/ssi/stm32f2xx_spi.c @@ -174,7 +174,7 @@ static const VMStateDescription vmstate_stm32f2xx_spi = { .name = TYPE_STM32F2XX_SPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(spi_cr1, STM32F2XXSPIState), VMSTATE_UINT32(spi_cr2, STM32F2XXSPIState), VMSTATE_UINT32(spi_sr, STM32F2XXSPIState), diff --git a/hw/ssi/xilinx_spi.c b/hw/ssi/xilinx_spi.c index d4de2e7aab..2e0687ac90 100644 --- a/hw/ssi/xilinx_spi.c +++ b/hw/ssi/xilinx_spi.c @@ -353,7 +353,7 @@ static const VMStateDescription vmstate_xilinx_spi = { .name = "xilinx_spi", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO8(tx_fifo, XilinxSPI), VMSTATE_FIFO8(rx_fifo, XilinxSPI), VMSTATE_UINT32_ARRAY(regs, XilinxSPI, R_MAX), diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi/xilinx_spips.c index 0bdfad7e2e..71952a410d 100644 --- a/hw/ssi/xilinx_spips.c +++ b/hw/ssi/xilinx_spips.c @@ -1369,7 +1369,7 @@ static const VMStateDescription vmstate_xilinx_spips = { .version_id = 2, .minimum_version_id = 2, .post_load = xilinx_spips_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO8(tx_fifo, XilinxSPIPS), VMSTATE_FIFO8(rx_fifo, XilinxSPIPS), VMSTATE_UINT32_ARRAY(regs, XilinxSPIPS, XLNX_SPIPS_R_MAX), @@ -1395,7 +1395,7 @@ static const VMStateDescription vmstate_xilinx_qspips = { .name = "xilinx_qspips", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, XilinxQSPIPS, 0, vmstate_xilinx_spips, XilinxSPIPS), VMSTATE_END_OF_LIST() @@ -1407,7 +1407,7 @@ static const VMStateDescription vmstate_xlnx_zynqmp_qspips = { .version_id = 1, .minimum_version_id = 1, .post_load = xlnx_zynqmp_qspips_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(parent_obj, XlnxZynqMPQSPIPS, 0, vmstate_xilinx_qspips, XilinxQSPIPS), VMSTATE_FIFO8(tx_fifo_g, XlnxZynqMPQSPIPS), diff --git a/hw/ssi/xlnx-versal-ospi.c b/hw/ssi/xlnx-versal-ospi.c index 1a61679c2f..c7b95b1f37 100644 --- a/hw/ssi/xlnx-versal-ospi.c +++ b/hw/ssi/xlnx-versal-ospi.c @@ -1787,7 +1787,7 @@ static const VMStateDescription vmstate_ind_op = { .name = "OSPIIndOp", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(flash_addr, IndOp), VMSTATE_UINT32(num_bytes, IndOp), VMSTATE_UINT32(done_bytes, IndOp), @@ -1800,7 +1800,7 @@ static const VMStateDescription vmstate_xlnx_versal_ospi = { .name = TYPE_XILINX_VERSAL_OSPI, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_FIFO8(rx_fifo, XlnxVersalOspi), VMSTATE_FIFO8(tx_fifo, XlnxVersalOspi), VMSTATE_FIFO8(rx_sram, XlnxVersalOspi), From patchwork Fri Dec 29 21:23:31 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758840 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672318wrw; Fri, 29 Dec 2023 13:31:19 -0800 (PST) X-Google-Smtp-Source: AGHT+IF01ArI14f+TqRsQJ718IFxpjxOMD4PoYf6PI810lZ0c7T5+NSXU3MvxrvkovrpAsPYQJCB X-Received: by 2002:a05:6214:2604:b0:67a:3ad4:9978 with SMTP id gu4-20020a056214260400b0067a3ad49978mr24052101qvb.10.1703885479509; Fri, 29 Dec 2023 13:31:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885479; cv=none; d=google.com; s=arc-20160816; b=Tpl2cfg1Lcqlcb6BH3ewtDPxtinvGCbao6Wu6Vd4tIpMO3Y71eco3D5ddmWcdz2vh+ MwikTdd8iYPP+W58sDUCrZeiVUCOd/h4MnlPcKOhObLRMF5tSxNnBCcyPpa3rgVug2oZ 0OX7CiiXJkxBXIToa8c5be3hOoQzTgF6Jjbs1FuuMTudaAIQ3ROC2Yqz+EaO5Ln4DK+g Vx6JPYwOtnz9wxCVx8XCfzfxcbkIzJy1fivkUc4Cv1TpN2JvrUoYrIe6Qe5BHmiQtkq2 LLUj1GEDtz7EgT05jy5y+NPGZUkDyraM/v17qhT0LNQLmG9xX+lZhs7EBAicKkYxHqob ELaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=J5UHmsO1he3KEAA2w5u7UCSmsFV99hNVQ8n2drCdabk=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=K5lbh4QCZx7ugTIbxCquZL3ypw4Y3KM/FoVfBOkQdBjTYq996YHCPtI32F5Wh25Aqv uUAbFKLDjFuHaBLoEXDQ//2ZyDoTd14UnWdIIrFl3vfLp3pvdPfZ6yjDZ0MJ3yD1Uw1T RjK2ZLUFWDczyjllcloyyXQ4tBgE2qWvWD4lrueaYbBNHgSiAMNWSqp0c+7Q3BcJjElL WK59DgRJ5XsTeCbtiKiPSXzDaFYHMFQtafBMz3RDNj0KZH8kA5Fvf9y4/iVry66cOny8 WtqReMmgcm5RA3PI1mGEP8+1KOzLEwYnjVqlxmYhrHT1xP+cFKGjRSHyf/3ZZ2zqhQNp qoOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Z1bz2wts; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id t10-20020a0cf98a000000b0067f81bb73bbsi19154089qvn.569.2023.12.29.13.31.19 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:19 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Z1bz2wts; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKPp-0007q3-Kh; Fri, 29 Dec 2023 16:29:13 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPm-0007TX-Nv for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:10 -0500 Received: from mail-pg1-x529.google.com ([2607:f8b0:4864:20::529]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPj-0000Mx-3b for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:10 -0500 Received: by mail-pg1-x529.google.com with SMTP id 41be03b00d2f7-5bdbe2de25fso5599943a12.3 for ; Fri, 29 Dec 2023 13:29:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885346; x=1704490146; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=J5UHmsO1he3KEAA2w5u7UCSmsFV99hNVQ8n2drCdabk=; b=Z1bz2wts8vMOQkOVWV6q7vnnpUi3lo8cY2yVC7pxDclIwuhSWp58fyrSKfeTtLrMGO pUWjEWYvLeii8FAvX0oe5lUunMSDq/kkC/HQTe9DQPX5ggC5Vig4kw+MprpKD+dpLlte ljJ0wRSeomRfL9mXeKKtvWvlXd+Yzsfdd8SLqGzU+qwongyAhJSi35r84FpJjgAWGEZ0 GXpEoE9EhTsg5OXvj0PdCtspkwmefUptijm4YbUEQM89y79F9uE43bpY21m2q9OdM57G loFSQ2A1R+FMTdAt2rtExfdGfVzOAPLHuyF5xPoXA2MSxS3op+qeuBRb75HkyyLE1Uht cDqA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885346; x=1704490146; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=J5UHmsO1he3KEAA2w5u7UCSmsFV99hNVQ8n2drCdabk=; b=DZXE5HEE2d5VPeFdJCjGaUeyIXbfy/VVC3Hu4tIbt2Fav0mt82x0oTDKRjRZT7ltX4 8foSUhg84kePcosF2ubL5OY+hlNj5XpviaXBxFjTYAFMnIwqqrwuATJXxNYAMc99dNcy rpsVQ6x/M0rfhNo41XGGXY47xyzFhPb470VmZXvqrPHzKj3tp+b4liQgk4QBiqrpzC+c jyjwps84sr8kvCWpb2yvdZm9ZWES5VE6rNiv/sOJrN6SrNhrnKyVYb5atbqAiSQ7n4JV 0LnqdE3guY2ZOIfYcxqVs/enTpISvAInugx7qyzO8mhP5ExkXtHnJAMEVEcukVX1KWEH 9Jnw== X-Gm-Message-State: AOJu0YyRx4JAMMfB+acgICNbuHU7PO5oJSqc2JQDioroGc0O5Ihv7XI0 ulJAfncsXX1VNzdvKWaQfMhtW+y2jB1L5W4LwLLEGCqLY9n8gQ== X-Received: by 2002:a05:6a20:42a0:b0:196:949e:63c with SMTP id o32-20020a056a2042a000b00196949e063cmr1398005pzj.40.1703885345597; Fri, 29 Dec 2023 13:29:05 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:05 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 56/71] hw/timer: Constify VMState Date: Sat, 30 Dec 2023 08:23:31 +1100 Message-Id: <20231229212346.147149-57-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::529; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x529.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-57-richard.henderson@linaro.org> --- hw/timer/a9gtimer.c | 8 ++++---- hw/timer/allwinner-a10-pit.c | 2 +- hw/timer/arm_mptimer.c | 4 ++-- hw/timer/arm_timer.c | 4 ++-- hw/timer/armv7m_systick.c | 2 +- hw/timer/aspeed_timer.c | 4 ++-- hw/timer/bcm2835_systmr.c | 2 +- hw/timer/cadence_ttc.c | 4 ++-- hw/timer/cmsdk-apb-dualtimer.c | 4 ++-- hw/timer/cmsdk-apb-timer.c | 2 +- hw/timer/digic-timer.c | 2 +- hw/timer/etraxfs_timer.c | 2 +- hw/timer/exynos4210_mct.c | 12 ++++++------ hw/timer/exynos4210_pwm.c | 4 ++-- hw/timer/hpet.c | 10 +++++----- hw/timer/i8254_common.c | 4 ++-- hw/timer/ibex_timer.c | 2 +- hw/timer/imx_epit.c | 2 +- hw/timer/imx_gpt.c | 2 +- hw/timer/mss-timer.c | 4 ++-- hw/timer/npcm7xx_timer.c | 8 ++++---- hw/timer/nrf51_timer.c | 2 +- hw/timer/pxa2xx_timer.c | 6 +++--- hw/timer/renesas_cmt.c | 2 +- hw/timer/renesas_tmr.c | 2 +- hw/timer/sifive_pwm.c | 2 +- hw/timer/slavio_timer.c | 4 ++-- hw/timer/sse-counter.c | 2 +- hw/timer/sse-timer.c | 2 +- hw/timer/stellaris-gptm.c | 2 +- hw/timer/stm32f2xx_timer.c | 2 +- 31 files changed, 57 insertions(+), 57 deletions(-) diff --git a/hw/timer/a9gtimer.c b/hw/timer/a9gtimer.c index 5e959b6d09..a2ac5bdfb9 100644 --- a/hw/timer/a9gtimer.c +++ b/hw/timer/a9gtimer.c @@ -328,7 +328,7 @@ static const VMStateDescription vmstate_a9_gtimer_per_cpu = { .name = "arm.cortex-a9-global-timer.percpu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, A9GTimerPerCPU), VMSTATE_UINT64(compare, A9GTimerPerCPU), VMSTATE_UINT32(status, A9GTimerPerCPU), @@ -342,7 +342,7 @@ static const VMStateDescription vmstate_a9_gtimer_control = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_a9_gtimer_control_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, A9GTimerState), VMSTATE_END_OF_LIST() } @@ -352,7 +352,7 @@ static const VMStateDescription vmstate_a9_gtimer = { .name = "arm.cortex-a9-global-timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, A9GTimerState), VMSTATE_UINT64(counter, A9GTimerState), VMSTATE_UINT64(ref_counter, A9GTimerState), @@ -362,7 +362,7 @@ static const VMStateDescription vmstate_a9_gtimer = { A9GTimerPerCPU), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_a9_gtimer_control, NULL } diff --git a/hw/timer/allwinner-a10-pit.c b/hw/timer/allwinner-a10-pit.c index 971f78462a..a524de1381 100644 --- a/hw/timer/allwinner-a10-pit.c +++ b/hw/timer/allwinner-a10-pit.c @@ -200,7 +200,7 @@ static const VMStateDescription vmstate_a10_pit = { .name = "a10.pit", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(irq_enable, AwA10PITState), VMSTATE_UINT32(irq_status, AwA10PITState), VMSTATE_UINT32_ARRAY(control, AwA10PITState, AW_A10_PIT_TIMER_NR), diff --git a/hw/timer/arm_mptimer.c b/hw/timer/arm_mptimer.c index cdfca3000b..bca4cee0e4 100644 --- a/hw/timer/arm_mptimer.c +++ b/hw/timer/arm_mptimer.c @@ -281,7 +281,7 @@ static const VMStateDescription vmstate_timerblock = { .name = "arm_mptimer_timerblock", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, TimerBlock), VMSTATE_UINT32(status, TimerBlock), VMSTATE_PTIMER(timer, TimerBlock), @@ -293,7 +293,7 @@ static const VMStateDescription vmstate_arm_mptimer = { .name = "arm_mptimer", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_UINT32(timerblock, ARMMPTimerState, num_cpu, 3, vmstate_timerblock, TimerBlock), VMSTATE_END_OF_LIST() diff --git a/hw/timer/arm_timer.c b/hw/timer/arm_timer.c index 9afe8da831..0940e03f1d 100644 --- a/hw/timer/arm_timer.c +++ b/hw/timer/arm_timer.c @@ -163,7 +163,7 @@ static const VMStateDescription vmstate_arm_timer = { .name = "arm_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(control, arm_timer_state), VMSTATE_UINT32(limit, arm_timer_state), VMSTATE_INT32(int_level, arm_timer_state), @@ -282,7 +282,7 @@ static const VMStateDescription vmstate_sp804 = { .name = "sp804", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32_ARRAY(level, SP804State, 2), VMSTATE_END_OF_LIST() } diff --git a/hw/timer/armv7m_systick.c b/hw/timer/armv7m_systick.c index 5dfe39afe3..f6b1acef27 100644 --- a/hw/timer/armv7m_systick.c +++ b/hw/timer/armv7m_systick.c @@ -275,7 +275,7 @@ static const VMStateDescription vmstate_systick = { .name = "armv7m_systick", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(refclk, SysTickState), VMSTATE_CLOCK(cpuclk, SysTickState), VMSTATE_UINT32(control, SysTickState), diff --git a/hw/timer/aspeed_timer.c b/hw/timer/aspeed_timer.c index 72161f07bb..fc5c94bdf3 100644 --- a/hw/timer/aspeed_timer.c +++ b/hw/timer/aspeed_timer.c @@ -645,7 +645,7 @@ static const VMStateDescription vmstate_aspeed_timer = { .name = "aspeed.timer", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(id, AspeedTimer), VMSTATE_INT32(level, AspeedTimer), VMSTATE_TIMER(timer, AspeedTimer), @@ -659,7 +659,7 @@ static const VMStateDescription vmstate_aspeed_timer_state = { .name = "aspeed.timerctrl", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctrl, AspeedTimerCtrlState), VMSTATE_UINT32(ctrl2, AspeedTimerCtrlState), VMSTATE_UINT32(ctrl3, AspeedTimerCtrlState), diff --git a/hw/timer/bcm2835_systmr.c b/hw/timer/bcm2835_systmr.c index 67669a57ff..3ec64604ee 100644 --- a/hw/timer/bcm2835_systmr.c +++ b/hw/timer/bcm2835_systmr.c @@ -146,7 +146,7 @@ static const VMStateDescription bcm2835_systmr_vmstate = { .name = "bcm2835_sys_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(reg.ctrl_status, BCM2835SystemTimerState), VMSTATE_UINT32_ARRAY(reg.compare, BCM2835SystemTimerState, BCM2835_SYSTIMER_COUNT), diff --git a/hw/timer/cadence_ttc.c b/hw/timer/cadence_ttc.c index e57a0f5f09..54dbd4c564 100644 --- a/hw/timer/cadence_ttc.c +++ b/hw/timer/cadence_ttc.c @@ -425,7 +425,7 @@ static const VMStateDescription vmstate_cadence_timer = { .minimum_version_id = 1, .pre_save = cadence_timer_pre_save, .post_load = cadence_timer_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(reg_clock, CadenceTimerState), VMSTATE_UINT32(reg_count, CadenceTimerState), VMSTATE_UINT32(reg_value, CadenceTimerState), @@ -443,7 +443,7 @@ static const VMStateDescription vmstate_cadence_ttc = { .name = "cadence_TTC", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(timer, CadenceTTCState, 3, 0, vmstate_cadence_timer, CadenceTimerState), diff --git a/hw/timer/cmsdk-apb-dualtimer.c b/hw/timer/cmsdk-apb-dualtimer.c index d4a509c798..ddf9070c3c 100644 --- a/hw/timer/cmsdk-apb-dualtimer.c +++ b/hw/timer/cmsdk-apb-dualtimer.c @@ -508,7 +508,7 @@ static const VMStateDescription cmsdk_dualtimermod_vmstate = { .name = "cmsdk-apb-dualtimer-module", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(timer, CMSDKAPBDualTimerModule), VMSTATE_UINT32(load, CMSDKAPBDualTimerModule), VMSTATE_UINT32(value, CMSDKAPBDualTimerModule), @@ -522,7 +522,7 @@ static const VMStateDescription cmsdk_apb_dualtimer_vmstate = { .name = "cmsdk-apb-dualtimer", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(timclk, CMSDKAPBDualTimer), VMSTATE_STRUCT_ARRAY(timermod, CMSDKAPBDualTimer, CMSDK_APB_DUALTIMER_NUM_MODULES, diff --git a/hw/timer/cmsdk-apb-timer.c b/hw/timer/cmsdk-apb-timer.c index 68aa1a7636..814545c783 100644 --- a/hw/timer/cmsdk-apb-timer.c +++ b/hw/timer/cmsdk-apb-timer.c @@ -250,7 +250,7 @@ static const VMStateDescription cmsdk_apb_timer_vmstate = { .name = "cmsdk-apb-timer", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(timer, CMSDKAPBTimer), VMSTATE_CLOCK(pclk, CMSDKAPBTimer), VMSTATE_UINT32(ctrl, CMSDKAPBTimer), diff --git a/hw/timer/digic-timer.c b/hw/timer/digic-timer.c index 973eab4386..9fc5c1d8a4 100644 --- a/hw/timer/digic-timer.c +++ b/hw/timer/digic-timer.c @@ -39,7 +39,7 @@ static const VMStateDescription vmstate_digic_timer = { .name = "digic.timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(ptimer, DigicTimerState), VMSTATE_UINT32(control, DigicTimerState), VMSTATE_UINT32(relvalue, DigicTimerState), diff --git a/hw/timer/etraxfs_timer.c b/hw/timer/etraxfs_timer.c index f035b74560..da7c946af5 100644 --- a/hw/timer/etraxfs_timer.c +++ b/hw/timer/etraxfs_timer.c @@ -88,7 +88,7 @@ static const VMStateDescription vmstate_etraxfs = { .name = "etraxfs", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(ptimer_t0, ETRAXTimerState), VMSTATE_PTIMER(ptimer_t1, ETRAXTimerState), VMSTATE_PTIMER(ptimer_wd, ETRAXTimerState), diff --git a/hw/timer/exynos4210_mct.c b/hw/timer/exynos4210_mct.c index 446bbd2b96..75098cdb55 100644 --- a/hw/timer/exynos4210_mct.c +++ b/hw/timer/exynos4210_mct.c @@ -264,7 +264,7 @@ static const VMStateDescription vmstate_tick_timer = { .name = "exynos4210.mct.tick_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cnt_run, struct tick_timer), VMSTATE_UINT32(int_run, struct tick_timer), VMSTATE_UINT32(last_icnto, struct tick_timer), @@ -283,7 +283,7 @@ static const VMStateDescription vmstate_lregs = { .name = "exynos4210.mct.lregs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(cnt, struct lregs, L_REG_CNT_AMOUNT), VMSTATE_UINT32(tcon, struct lregs), VMSTATE_UINT32(int_cstat, struct lregs), @@ -297,7 +297,7 @@ static const VMStateDescription vmstate_exynos4210_mct_lt = { .name = "exynos4210.mct.lt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(id, Exynos4210MCTLT), VMSTATE_STRUCT(tick_timer, Exynos4210MCTLT, 0, vmstate_tick_timer, @@ -314,7 +314,7 @@ static const VMStateDescription vmstate_gregs = { .name = "exynos4210.mct.lregs", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(cnt, struct gregs), VMSTATE_UINT32(cnt_wstat, struct gregs), VMSTATE_UINT32(tcon, struct gregs), @@ -332,7 +332,7 @@ static const VMStateDescription vmstate_exynos4210_mct_gt = { .name = "exynos4210.mct.lt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(reg, Exynos4210MCTGT, 0, vmstate_gregs, struct gregs), VMSTATE_UINT64(count, Exynos4210MCTGT), @@ -346,7 +346,7 @@ static const VMStateDescription vmstate_exynos4210_mct_state = { .name = "exynos4210.mct", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(reg_mct_cfg, Exynos4210MCTState), VMSTATE_STRUCT_ARRAY(l_timer, Exynos4210MCTState, 2, 0, vmstate_exynos4210_mct_lt, Exynos4210MCTLT), diff --git a/hw/timer/exynos4210_pwm.c b/hw/timer/exynos4210_pwm.c index 3528d0f33a..ca330e9446 100644 --- a/hw/timer/exynos4210_pwm.c +++ b/hw/timer/exynos4210_pwm.c @@ -123,7 +123,7 @@ static const VMStateDescription vmstate_exynos4210_pwm = { .name = "exynos4210.pwm.pwm", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, Exynos4210PWM), VMSTATE_UINT32(freq, Exynos4210PWM), VMSTATE_PTIMER(ptimer, Exynos4210PWM), @@ -137,7 +137,7 @@ static const VMStateDescription vmstate_exynos4210_pwm_state = { .name = "exynos4210.pwm", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(reg_tcfg, Exynos4210PWMState, 2), VMSTATE_UINT32(reg_tcon, Exynos4210PWMState), VMSTATE_UINT32(reg_tint_cstat, Exynos4210PWMState), diff --git a/hw/timer/hpet.c b/hw/timer/hpet.c index 6998094233..f2f1580f81 100644 --- a/hw/timer/hpet.c +++ b/hw/timer/hpet.c @@ -296,7 +296,7 @@ static const VMStateDescription vmstate_hpet_rtc_irq_level = { .version_id = 1, .minimum_version_id = 1, .needed = hpet_rtc_irq_level_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(rtc_irq_level, HPETState), VMSTATE_END_OF_LIST() } @@ -307,7 +307,7 @@ static const VMStateDescription vmstate_hpet_offset = { .version_id = 1, .minimum_version_id = 1, .needed = hpet_offset_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(hpet_offset, HPETState), VMSTATE_END_OF_LIST() } @@ -317,7 +317,7 @@ static const VMStateDescription vmstate_hpet_timer = { .name = "hpet_timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(tn, HPETTimer), VMSTATE_UINT64(config, HPETTimer), VMSTATE_UINT64(cmp, HPETTimer), @@ -336,7 +336,7 @@ static const VMStateDescription vmstate_hpet = { .pre_save = hpet_pre_save, .pre_load = hpet_pre_load, .post_load = hpet_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(config, HPETState), VMSTATE_UINT64(isr, HPETState), VMSTATE_UINT64(hpet_counter, HPETState), @@ -346,7 +346,7 @@ static const VMStateDescription vmstate_hpet = { vmstate_hpet_timer, HPETTimer), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_hpet_rtc_irq_level, &vmstate_hpet_offset, NULL diff --git a/hw/timer/i8254_common.c b/hw/timer/i8254_common.c index b25da448c8..28fdabc321 100644 --- a/hw/timer/i8254_common.c +++ b/hw/timer/i8254_common.c @@ -180,7 +180,7 @@ static const VMStateDescription vmstate_pit_channel = { .name = "pit channel", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(count, PITChannelState), VMSTATE_UINT16(latched_count, PITChannelState), VMSTATE_UINT8(count_latched, PITChannelState), @@ -228,7 +228,7 @@ static const VMStateDescription vmstate_pit_common = { .minimum_version_id = 2, .pre_save = pit_dispatch_pre_save, .post_load = pit_dispatch_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_V(channels[0].irq_disabled, PITCommonState, 3), VMSTATE_STRUCT_ARRAY(channels, PITCommonState, 3, 2, vmstate_pit_channel, PITChannelState), diff --git a/hw/timer/ibex_timer.c b/hw/timer/ibex_timer.c index d8b8e4e1f6..4917388d45 100644 --- a/hw/timer/ibex_timer.c +++ b/hw/timer/ibex_timer.c @@ -252,7 +252,7 @@ static const VMStateDescription vmstate_ibex_timer = { .version_id = 2, .minimum_version_id = 2, .post_load = ibex_timer_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(timer_ctrl, IbexTimerState), VMSTATE_UINT32(timer_cfg0, IbexTimerState), VMSTATE_UINT32(timer_compare_lower0, IbexTimerState), diff --git a/hw/timer/imx_epit.c b/hw/timer/imx_epit.c index 640e4399c2..bd625203aa 100644 --- a/hw/timer/imx_epit.c +++ b/hw/timer/imx_epit.c @@ -383,7 +383,7 @@ static const VMStateDescription vmstate_imx_timer_epit = { .name = TYPE_IMX_EPIT, .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cr, IMXEPITState), VMSTATE_UINT32(sr, IMXEPITState), VMSTATE_UINT32(lr, IMXEPITState), diff --git a/hw/timer/imx_gpt.c b/hw/timer/imx_gpt.c index 7222b1b387..a8edaec867 100644 --- a/hw/timer/imx_gpt.c +++ b/hw/timer/imx_gpt.c @@ -63,7 +63,7 @@ static const VMStateDescription vmstate_imx_timer_gpt = { .name = TYPE_IMX_GPT, .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(cr, IMXGPTState), VMSTATE_UINT32(pr, IMXGPTState), VMSTATE_UINT32(sr, IMXGPTState), diff --git a/hw/timer/mss-timer.c b/hw/timer/mss-timer.c index ee7438f168..b66aed56ea 100644 --- a/hw/timer/mss-timer.c +++ b/hw/timer/mss-timer.c @@ -260,7 +260,7 @@ static const VMStateDescription vmstate_timers = { .name = "mss-timer-block", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(ptimer, struct Msf2Timer), VMSTATE_UINT32_ARRAY(regs, struct Msf2Timer, R_TIM1_MAX), VMSTATE_END_OF_LIST() @@ -271,7 +271,7 @@ static const VMStateDescription vmstate_mss_timer = { .name = TYPE_MSS_TIMER, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(freq_hz, MSSTimerState), VMSTATE_STRUCT_ARRAY(timers, MSSTimerState, NUM_TIMERS, 0, vmstate_timers, struct Msf2Timer), diff --git a/hw/timer/npcm7xx_timer.c b/hw/timer/npcm7xx_timer.c index a8bd93aeb2..779c6049fa 100644 --- a/hw/timer/npcm7xx_timer.c +++ b/hw/timer/npcm7xx_timer.c @@ -637,7 +637,7 @@ static const VMStateDescription vmstate_npcm7xx_base_timer = { .name = "npcm7xx-base-timer", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER(qtimer, NPCM7xxBaseTimer), VMSTATE_INT64(expires_ns, NPCM7xxBaseTimer), VMSTATE_INT64(remaining_ns, NPCM7xxBaseTimer), @@ -649,7 +649,7 @@ static const VMStateDescription vmstate_npcm7xx_timer = { .name = "npcm7xx-timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(base_timer, NPCM7xxTimer, 0, vmstate_npcm7xx_base_timer, NPCM7xxBaseTimer), @@ -663,7 +663,7 @@ static const VMStateDescription vmstate_npcm7xx_watchdog_timer = { .name = "npcm7xx-watchdog-timer", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(base_timer, NPCM7xxWatchdogTimer, 0, vmstate_npcm7xx_base_timer, NPCM7xxBaseTimer), @@ -676,7 +676,7 @@ static const VMStateDescription vmstate_npcm7xx_timer_ctrl = { .name = "npcm7xx-timer-ctrl", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(tisr, NPCM7xxTimerCtrlState), VMSTATE_CLOCK(clock, NPCM7xxTimerCtrlState), VMSTATE_STRUCT_ARRAY(timer, NPCM7xxTimerCtrlState, diff --git a/hw/timer/nrf51_timer.c b/hw/timer/nrf51_timer.c index 50c6772383..a33166a881 100644 --- a/hw/timer/nrf51_timer.c +++ b/hw/timer/nrf51_timer.c @@ -361,7 +361,7 @@ static const VMStateDescription vmstate_nrf51_timer = { .name = TYPE_NRF51_TIMER, .version_id = 1, .post_load = nrf51_timer_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER(timer, NRF51TimerState), VMSTATE_INT64(timer_start_ns, NRF51TimerState), VMSTATE_INT64(update_counter_ns, NRF51TimerState), diff --git a/hw/timer/pxa2xx_timer.c b/hw/timer/pxa2xx_timer.c index 2ae5ae3212..6a7d5551f4 100644 --- a/hw/timer/pxa2xx_timer.c +++ b/hw/timer/pxa2xx_timer.c @@ -501,7 +501,7 @@ static const VMStateDescription vmstate_pxa2xx_timer0_regs = { .name = "pxa2xx_timer0", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(value, PXA2xxTimer0), VMSTATE_END_OF_LIST(), }, @@ -511,7 +511,7 @@ static const VMStateDescription vmstate_pxa2xx_timer4_regs = { .name = "pxa2xx_timer4", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(tm, PXA2xxTimer4, 1, vmstate_pxa2xx_timer0_regs, PXA2xxTimer0), VMSTATE_INT32(oldclock, PXA2xxTimer4), @@ -533,7 +533,7 @@ static const VMStateDescription vmstate_pxa2xx_timer_regs = { .version_id = 1, .minimum_version_id = 1, .post_load = pxa25x_timer_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(clock, PXA2xxTimerInfo), VMSTATE_INT32(oldclock, PXA2xxTimerInfo), VMSTATE_UINT64(lastload, PXA2xxTimerInfo), diff --git a/hw/timer/renesas_cmt.c b/hw/timer/renesas_cmt.c index 69eabc678a..08832932d2 100644 --- a/hw/timer/renesas_cmt.c +++ b/hw/timer/renesas_cmt.c @@ -242,7 +242,7 @@ static const VMStateDescription vmstate_rcmt = { .name = "rx-cmt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(cmstr, RCMTState), VMSTATE_UINT16_ARRAY(cmcr, RCMTState, CMT_CH), VMSTATE_UINT16_ARRAY(cmcnt, RCMTState, CMT_CH), diff --git a/hw/timer/renesas_tmr.c b/hw/timer/renesas_tmr.c index 43b31213bc..1d47d0615a 100644 --- a/hw/timer/renesas_tmr.c +++ b/hw/timer/renesas_tmr.c @@ -447,7 +447,7 @@ static const VMStateDescription vmstate_rtmr = { .name = "rx-tmr", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(tick, RTMRState), VMSTATE_UINT8_ARRAY(tcnt, RTMRState, TMR_CH), VMSTATE_UINT8_ARRAY(tcora, RTMRState, TMR_CH), diff --git a/hw/timer/sifive_pwm.c b/hw/timer/sifive_pwm.c index c664480ccf..e8610c37dd 100644 --- a/hw/timer/sifive_pwm.c +++ b/hw/timer/sifive_pwm.c @@ -395,7 +395,7 @@ static const VMStateDescription vmstate_sifive_pwm = { .name = TYPE_SIFIVE_PWM, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_ARRAY(timer, SiFivePwmState, 4), VMSTATE_UINT64(tick_offset, SiFivePwmState), VMSTATE_UINT32(pwmcfg, SiFivePwmState), diff --git a/hw/timer/slavio_timer.c b/hw/timer/slavio_timer.c index 8c4f6eb06b..5507b0145b 100644 --- a/hw/timer/slavio_timer.c +++ b/hw/timer/slavio_timer.c @@ -344,7 +344,7 @@ static const VMStateDescription vmstate_timer = { .name ="timer", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(limit, CPUTimerState), VMSTATE_UINT32(count, CPUTimerState), VMSTATE_UINT32(counthigh, CPUTimerState), @@ -359,7 +359,7 @@ static const VMStateDescription vmstate_slavio_timer = { .name ="slavio_timer", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(cputimer, SLAVIO_TIMERState, MAX_CPUS + 1, 3, vmstate_timer, CPUTimerState), VMSTATE_END_OF_LIST() diff --git a/hw/timer/sse-counter.c b/hw/timer/sse-counter.c index 16c0e8ad15..daceedf964 100644 --- a/hw/timer/sse-counter.c +++ b/hw/timer/sse-counter.c @@ -442,7 +442,7 @@ static const VMStateDescription sse_counter_vmstate = { .name = "sse-counter", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(clk, SSECounter), VMSTATE_END_OF_LIST() } diff --git a/hw/timer/sse-timer.c b/hw/timer/sse-timer.c index e92e83747d..cb20a9eb79 100644 --- a/hw/timer/sse-timer.c +++ b/hw/timer/sse-timer.c @@ -428,7 +428,7 @@ static const VMStateDescription sse_timer_vmstate = { .name = "sse-timer", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER(timer, SSETimer), VMSTATE_UINT32(cntfrq, SSETimer), VMSTATE_UINT32(cntp_ctl, SSETimer), diff --git a/hw/timer/stellaris-gptm.c b/hw/timer/stellaris-gptm.c index fd71c79be4..f28958cefc 100644 --- a/hw/timer/stellaris-gptm.c +++ b/hw/timer/stellaris-gptm.c @@ -250,7 +250,7 @@ static const VMStateDescription vmstate_stellaris_gptm = { .name = "stellaris_gptm", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(config, gptm_state), VMSTATE_UINT32_ARRAY(mode, gptm_state, 2), VMSTATE_UINT32(control, gptm_state), diff --git a/hw/timer/stm32f2xx_timer.c b/hw/timer/stm32f2xx_timer.c index ba8694dcd3..de4208b1a6 100644 --- a/hw/timer/stm32f2xx_timer.c +++ b/hw/timer/stm32f2xx_timer.c @@ -274,7 +274,7 @@ static const VMStateDescription vmstate_stm32f2xx_timer = { .name = TYPE_STM32F2XX_TIMER, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(tick_offset, STM32F2XXTimerState), VMSTATE_UINT32(tim_cr1, STM32F2XXTimerState), VMSTATE_UINT32(tim_cr2, STM32F2XXTimerState), From patchwork Fri Dec 29 21:23:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758847 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672444wrw; Fri, 29 Dec 2023 13:31:43 -0800 (PST) X-Google-Smtp-Source: AGHT+IFpbRFkFk7uS3xbaFlenqfGhXs9ti9+5HOvHXa1cXPgZHQHQQX0g6YQMtGXfjj2U4D3/z22 X-Received: by 2002:a05:6214:769:b0:67a:9649:4229 with SMTP id f9-20020a056214076900b0067a96494229mr20203111qvz.65.1703885502948; Fri, 29 Dec 2023 13:31:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885502; cv=none; d=google.com; s=arc-20160816; b=feWAhFvVs+N05uwiqTufyBf2vUMl7KDMOxyS2JAy1c4/t2d/eEGylL0miQ3gk6ZAIz C0fWz60ZPf30D8isNAtFJcMrH+KOfxIbXugP/ZwLdppsA5owS6rd18Jfca8RqfIgIYkG JJomGGgCjY7HaMokU0//V0627YTo2KtIJ8aBFVzKJoFUQOGhRnyStPfW+QqVC4X43x4J OFC1noJFN5HcJA1UuVvEEqZpW3Y1WqeBRrNHboO/3f6vkX7iZGjygZODOFN3olash44b 7dzEanvAYCfwNh7EoIskSIuIVAZIvVH4AAtGwj5z3WJnr95yR9IHUt6uouIXbmSRFPgm gBAw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=vt60Tnr4DqLoORHWhbTyoaC4aknKVapk9I6rFjWSbFY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=sBPlLbcgIwgj+igPoUVXpB7L8dGQFapnwlrG5YGzXWIUAGM90/D228qbO8DFCKjzW6 QFIhj2xiwXNmsWsA1i3xw/isnnsCPPgj8tRPm2/NhsHMrh+WVBQOuGiMcoeHAXbhUyOq roDfkYkColOitnSR1vx1J4tO4/c7d1O8tbX2NN8H+y1lUZc2g8AvloLaLKToHeE6TGp9 iM4Dip+8+EzkVlGtNmL/dtqNf3AOv2NFtr+WcXCmYH6ODx/s+J9XNBEngTyyfPU9dtL/ b+x1EUmQSTGfsNHO0i29FanL1nTk+i2GqXe3LPcVUkfGjYdLm48lje6OocuITRXBnocW qf9w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r9JozAFP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a18-20020a0cca92000000b0067f4f8cc986si19825601qvk.274.2023.12.29.13.31.42 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:42 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r9JozAFP; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQ9-0008R6-0P; Fri, 29 Dec 2023 16:29:33 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPu-0008Ef-Ii for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:18 -0500 Received: from mail-pf1-x433.google.com ([2607:f8b0:4864:20::433]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPl-0000NK-1n for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:13 -0500 Received: by mail-pf1-x433.google.com with SMTP id d2e1a72fcca58-6d98ce84e18so5160941b3a.3 for ; Fri, 29 Dec 2023 13:29:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885348; x=1704490148; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=vt60Tnr4DqLoORHWhbTyoaC4aknKVapk9I6rFjWSbFY=; b=r9JozAFP3HZdhWC8TBQmwRBg2HhFx2fgrl9ttYw3BWpmOyBKxyCYbiNXV5lxK6nAOJ FJQiu8qhuRSyA9lVSAs8/jrQSqnlaPcLgpCjtOqiy4pgdPd7BQWBEYa+zB/4+y+wD1Uo sbfWBhO3AdF19EWikWJ/Rt1TO7uGRJStpol35DqwBU3R3/AJPLHzI+ZDB3eQJ94KHwZc Hz7E/spLLrrlWUUGBCtfoFDaBc9ykNKPO4a/qH3RVhtnecXffIa68MyYfYZOSpwmg7v9 fbEN+KrDRTtCMBa79WtEoHy579/R0uXm1eWZmDZTV8Y7oZcuuhQlOT9Ehql8PviyVDyf aewQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885348; x=1704490148; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vt60Tnr4DqLoORHWhbTyoaC4aknKVapk9I6rFjWSbFY=; b=YWJDwPyywXYk3NYb9jS5SJU99T+ApmGiE2Jy5qL7nrGAFfUOvImCv2TtqC8HIEPTCh 300YE4DTsDiawFryOwFs/qyMvI9aQHOxsczrFJ3Tm9qxsTbXGBSJr7BzyCskO3zsEn4Q 80md4SAPkosfmXEagqsfu7I+A9WeSDQko1BH1fN6N+KpUfRkhaPUsdgio05gPDh6O1DY /oLeg6XEZlIuRK7Iz+FRCrM2CIBeIkNg/V4Lp5jCQsgyvDAP8VHy55ZnxU/9IzWyxkOB Pp1qK5PIbaIhnlsY+UfDZIODMub/nNQxFn/kQ6OBzCOxND4RMuB29Ihx94JKC2AKeuKG BuXw== X-Gm-Message-State: AOJu0Yxrcx70pHVLwXni0LSq7sS/4gOqqoQDXMNGBW1s04wHrUMYyRXI SCXkK7Ai/FIRCWCLaLCidGqRdHRdVOpMw+xHMOJTz1fbflreUg== X-Received: by 2002:aa7:8504:0:b0:6d9:b187:b176 with SMTP id v4-20020aa78504000000b006d9b187b176mr10404928pfn.13.1703885347722; Fri, 29 Dec 2023 13:29:07 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:07 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 57/71] hw/tpm: Constify VMState Date: Sat, 30 Dec 2023 08:23:32 +1100 Message-Id: <20231229212346.147149-58-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::433; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x433.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, T_SCC_BODY_TEXT_LINE=-0.01, T_SPF_TEMPERROR=0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-58-richard.henderson@linaro.org> --- hw/tpm/tpm_crb.c | 2 +- hw/tpm/tpm_spapr.c | 2 +- hw/tpm/tpm_tis_common.c | 2 +- hw/tpm/tpm_tis_i2c.c | 2 +- hw/tpm/tpm_tis_isa.c | 2 +- hw/tpm/tpm_tis_sysbus.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/tpm/tpm_crb.c b/hw/tpm/tpm_crb.c index ea930da545..5cd5a2533b 100644 --- a/hw/tpm/tpm_crb.c +++ b/hw/tpm/tpm_crb.c @@ -220,7 +220,7 @@ static int tpm_crb_pre_save(void *opaque) static const VMStateDescription vmstate_tpm_crb = { .name = "tpm-crb", .pre_save = tpm_crb_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, CRBState, TPM_CRB_R_MAX), VMSTATE_END_OF_LIST(), } diff --git a/hw/tpm/tpm_spapr.c b/hw/tpm/tpm_spapr.c index dea7b1333b..e084e987e6 100644 --- a/hw/tpm/tpm_spapr.c +++ b/hw/tpm/tpm_spapr.c @@ -353,7 +353,7 @@ static const VMStateDescription vmstate_spapr_vtpm = { .name = "tpm-spapr", .pre_save = tpm_spapr_pre_save, .post_load = tpm_spapr_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_SPAPR_VIO(vdev, SpaprTpmState), VMSTATE_UINT8(state, SpaprTpmState), diff --git a/hw/tpm/tpm_tis_common.c b/hw/tpm/tpm_tis_common.c index 279ce436b5..1bfa28bfd9 100644 --- a/hw/tpm/tpm_tis_common.c +++ b/hw/tpm/tpm_tis_common.c @@ -879,7 +879,7 @@ int tpm_tis_pre_save(TPMState *s) const VMStateDescription vmstate_locty = { .name = "tpm-tis/locty", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(state, TPMLocality), VMSTATE_UINT32(inte, TPMLocality), VMSTATE_UINT32(ints, TPMLocality), diff --git a/hw/tpm/tpm_tis_i2c.c b/hw/tpm/tpm_tis_i2c.c index 4ecea7fa3e..4bb09655b4 100644 --- a/hw/tpm/tpm_tis_i2c.c +++ b/hw/tpm/tpm_tis_i2c.c @@ -115,7 +115,7 @@ static const VMStateDescription vmstate_tpm_tis_i2c = { .version_id = 0, .pre_save = tpm_tis_i2c_pre_save, .post_load = tpm_tis_i2c_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(state.buffer, TPMStateI2C), VMSTATE_UINT16(state.rw_offset, TPMStateI2C), VMSTATE_UINT8(state.active_locty, TPMStateI2C), diff --git a/hw/tpm/tpm_tis_isa.c b/hw/tpm/tpm_tis_isa.c index 0367401586..8887b3c9c4 100644 --- a/hw/tpm/tpm_tis_isa.c +++ b/hw/tpm/tpm_tis_isa.c @@ -53,7 +53,7 @@ static const VMStateDescription vmstate_tpm_tis_isa = { .name = "tpm-tis", .version_id = 0, .pre_save = tpm_tis_pre_save_isa, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(state.buffer, TPMStateISA), VMSTATE_UINT16(state.rw_offset, TPMStateISA), VMSTATE_UINT8(state.active_locty, TPMStateISA), diff --git a/hw/tpm/tpm_tis_sysbus.c b/hw/tpm/tpm_tis_sysbus.c index 2fc550f119..941f7f7f62 100644 --- a/hw/tpm/tpm_tis_sysbus.c +++ b/hw/tpm/tpm_tis_sysbus.c @@ -52,7 +52,7 @@ static const VMStateDescription vmstate_tpm_tis_sysbus = { .name = "tpm-tis", .version_id = 0, .pre_save = tpm_tis_pre_save_sysbus, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(state.buffer, TPMStateSysBus), VMSTATE_UINT16(state.rw_offset, TPMStateSysBus), VMSTATE_UINT8(state.active_locty, TPMStateSysBus), From patchwork Fri Dec 29 21:23:33 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758851 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672522wrw; Fri, 29 Dec 2023 13:31:58 -0800 (PST) X-Google-Smtp-Source: AGHT+IENjbDVU47Xbt1ptOEvV+Kbc+FCrAODk/Y/m8qz+kuv7HbOTHom0MkR0h40avp9NpiO72FJ X-Received: by 2002:a05:6214:1626:b0:680:59c1:e0cb with SMTP id e6-20020a056214162600b0068059c1e0cbmr4520614qvw.98.1703885518670; Fri, 29 Dec 2023 13:31:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885518; cv=none; d=google.com; s=arc-20160816; b=1JYsICCl+Bv0eLqyKB8CR3w5DLYFHsJ2HBPqIr3B/4H+4ypsOyYzV044q0YuFqLNjR 3LeiFB6nQnv7fbu1DdD0b1S3TtD2xZEI4q/JQce02i964SUYqvvttuSBLFZp5Du/VzGv PiFWe/xdHqEa1UgkXGZioPAomvH1G6GWnTl1PL0WpHQuQ378nmY4PiLxv5WlukI5dl8m W/8xg/5shX+xntrb0w+yWRACWjtOMbNcp6K64EHVQ/9n4vgc+6kyZN2YKxH6NuK+RcnY TAvChX/RuqouAqSvl4WW3ail+pPvok/3bFTYs1HBC2VMvtZAFYqD27/pC1AnLh1s7NHL ByMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=gliKhbzw7mYK+Gx2clBOd8jJ7bUN9rjvGSg1S1YFMZA=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=TiZ+t6T1CFOGflcYJd9MOMm4S78gUEjH0kygkz42AkxuBG9rg1p99Uv4CYIFcBeH8o dTQILbXe9GPyYHq5Pb3XL0EduQVHBenj0BCgL4jcKrBe62OElmfrO2zcCwDMB2tDo4Bz HOsf5TcpAaq0/1Ww58bTbkR2WAaC1fANYyaOyxZHFR6lORXTgMKexT+zDZs3PYHYMWeU 57rSo4GuAU5uCZgH087htLZ/a8kB30IZA4UMR2MQ6+SeKGTo8b5O6aGk3pP4ybXbvtSy n0jIx+ozypAlX9THoXZepOMjIgwRjo9RK9aKypIKooSqtmli6JKnWQIIAYbtNROo/OR4 Ywaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=f9ot8awZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id j6-20020a0cab86000000b0067f68fb505fsi19428783qvb.577.2023.12.29.13.31.58 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:58 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=f9ot8awZ; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQ9-0008Si-4A; Fri, 29 Dec 2023 16:29:36 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPu-0008EJ-FI for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:18 -0500 Received: from mail-ot1-x32a.google.com ([2607:f8b0:4864:20::32a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPn-0000Nd-3L for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:14 -0500 Received: by mail-ot1-x32a.google.com with SMTP id 46e09a7af769-6dbc4675749so3312419a34.3 for ; Fri, 29 Dec 2023 13:29:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885350; x=1704490150; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=gliKhbzw7mYK+Gx2clBOd8jJ7bUN9rjvGSg1S1YFMZA=; b=f9ot8awZrrFFFUBj+mzJ13tEWzfUI9vwumkVAlKve70JNF57Z/oWd6RC5FzYlPHWdW c5oy2Mz1jkSXe/O6g/W6bI8oka7/dnZ6Ah22bdXNJZIKnYaD7A0jpQ4IZ2OfV7p+hEbj d2DzYeWOzaEyaxhBtEDKC+U+UcsMb4SCUyzeOJdrGddWPK59R9Ud3AIymxQfZ94hmWag NuPb3HpoRO/ksqbAC6O2mGT0u9PSe307HWQVDoEppssAlJKNgXZlysTbyMIKUBRIvBzA pxgd9WGzm9nWFOLhcrMa37HHHIkXax1bH1e/tlYE3S8Df0D9S1X5GY8n/+DBQf9MghZ3 SFZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885350; x=1704490150; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gliKhbzw7mYK+Gx2clBOd8jJ7bUN9rjvGSg1S1YFMZA=; b=utRq5zHGzW9Qxstg+kSU3oNnwq1xUiZ8kTJWr7RWnKgLHocxFWsxabH7vUBokT6x3O zcHJTy1uoW2t2VwGsN9janjM8vUfsuS755faBcTO5YG3RTpqhV7y8EiKir18YNgvLYY+ XMZjBdvX4SdTor8TpUgVp0m0gQdXXd/eBwyA5MRxl148rfTkK0JY6rYruwtLdoJbT7UD HM6YX+tkDTSNLqJ4pBz4dIRV3jxLXuip6RAcTT1z5l8Qn+fDqgjIpMpoMGMq82yOONxG rCqpXluIm0RH2EJHf5rpNzMx41v3vScwc0NFkVjtdVen5gZX2owV0464m9iuWKUbd63E jOQw== X-Gm-Message-State: AOJu0YwWORuourZsfpb7Wo7yqneH03Y5OQ+DC4qRTrjXahFS4lbogi8I UKjCuf5eOuTWUCZ3/62edIydLdKwrzEOpfrPH2Hy+Fi6zENPfA== X-Received: by 2002:a05:6830:488a:b0:6dc:9c6:b060 with SMTP id en10-20020a056830488a00b006dc09c6b060mr3609985otb.13.1703885349750; Fri, 29 Dec 2023 13:29:09 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.08 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:09 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 58/71] hw/usb: Constify VMState Date: Sat, 30 Dec 2023 08:23:33 +1100 Message-Id: <20231229212346.147149-59-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::32a; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x32a.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-59-richard.henderson@linaro.org> --- hw/usb/bus.c | 2 +- hw/usb/ccid-card-passthru.c | 2 +- hw/usb/dev-hid.c | 4 ++-- hw/usb/dev-hub.c | 8 ++++---- hw/usb/dev-mtp.c | 2 +- hw/usb/dev-smartcard-reader.c | 8 ++++---- hw/usb/dev-storage.c | 2 +- hw/usb/dev-uas.c | 2 +- hw/usb/hcd-dwc2.c | 4 ++-- hw/usb/hcd-dwc3.c | 2 +- hw/usb/hcd-ehci-pci.c | 2 +- hw/usb/hcd-ehci-sysbus.c | 2 +- hw/usb/hcd-ehci.c | 2 +- hw/usb/hcd-ohci-pci.c | 2 +- hw/usb/hcd-ohci.c | 8 ++++---- hw/usb/hcd-uhci.c | 4 ++-- hw/usb/hcd-xhci-pci.c | 2 +- hw/usb/hcd-xhci-sysbus.c | 2 +- hw/usb/hcd-xhci.c | 12 ++++++------ hw/usb/host-libusb.c | 2 +- hw/usb/imx-usb-phy.c | 2 +- hw/usb/redirect.c | 16 ++++++++-------- hw/usb/u2f-passthru.c | 2 +- hw/usb/u2f.c | 2 +- hw/usb/xlnx-versal-usb2-ctrl-regs.c | 2 +- 25 files changed, 49 insertions(+), 49 deletions(-) diff --git a/hw/usb/bus.c b/hw/usb/bus.c index 92d6ed5626..59c39945dd 100644 --- a/hw/usb/bus.c +++ b/hw/usb/bus.c @@ -69,7 +69,7 @@ const VMStateDescription vmstate_usb_device = { .version_id = 1, .minimum_version_id = 1, .post_load = usb_device_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(addr, USBDevice), VMSTATE_INT32(state, USBDevice), VMSTATE_INT32(remote_wakeup, USBDevice), diff --git a/hw/usb/ccid-card-passthru.c b/hw/usb/ccid-card-passthru.c index 07ee42f304..a515703904 100644 --- a/hw/usb/ccid-card-passthru.c +++ b/hw/usb/ccid-card-passthru.c @@ -378,7 +378,7 @@ static const VMStateDescription passthru_vmstate = { .name = "ccid-card-passthru", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(vscard_in_data, PassthruState), VMSTATE_UINT32(vscard_in_pos, PassthruState), VMSTATE_UINT32(vscard_in_hdr, PassthruState), diff --git a/hw/usb/dev-hid.c b/hw/usb/dev-hid.c index bdd6d1ffaf..9e358c934e 100644 --- a/hw/usb/dev-hid.c +++ b/hw/usb/dev-hid.c @@ -756,7 +756,7 @@ static const VMStateDescription vmstate_usb_ptr = { .version_id = 1, .minimum_version_id = 1, .post_load = usb_ptr_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, USBHIDState), VMSTATE_HID_POINTER_DEVICE(hid, USBHIDState), VMSTATE_END_OF_LIST() @@ -767,7 +767,7 @@ static const VMStateDescription vmstate_usb_kbd = { .name = "usb-kbd", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, USBHIDState), VMSTATE_HID_KEYBOARD_DEVICE(hid, USBHIDState), VMSTATE_END_OF_LIST() diff --git a/hw/usb/dev-hub.c b/hw/usb/dev-hub.c index 5703e0e826..06e9537d03 100644 --- a/hw/usb/dev-hub.c +++ b/hw/usb/dev-hub.c @@ -623,7 +623,7 @@ static const VMStateDescription vmstate_usb_hub_port = { .name = "usb-hub-port", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(wPortStatus, USBHubPort), VMSTATE_UINT16(wPortChange, USBHubPort), VMSTATE_END_OF_LIST() @@ -642,7 +642,7 @@ static const VMStateDescription vmstate_usb_hub_port_timer = { .version_id = 1, .minimum_version_id = 1, .needed = usb_hub_port_timer_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(port_timer, USBHubState), VMSTATE_END_OF_LIST() }, @@ -652,13 +652,13 @@ static const VMStateDescription vmstate_usb_hub = { .name = "usb-hub", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, USBHubState), VMSTATE_STRUCT_ARRAY(ports, USBHubState, MAX_PORTS, 0, vmstate_usb_hub_port, USBHubPort), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_usb_hub_port_timer, NULL } diff --git a/hw/usb/dev-mtp.c b/hw/usb/dev-mtp.c index 1cac1cd435..7e4a0765ae 100644 --- a/hw/usb/dev-mtp.c +++ b/hw/usb/dev-mtp.c @@ -2072,7 +2072,7 @@ static const VMStateDescription vmstate_usb_mtp = { .unmigratable = 1, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, MTPState), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/dev-smartcard-reader.c b/hw/usb/dev-smartcard-reader.c index be0a4fc3bc..c0d63e0425 100644 --- a/hw/usb/dev-smartcard-reader.c +++ b/hw/usb/dev-smartcard-reader.c @@ -1367,7 +1367,7 @@ static const VMStateDescription bulk_in_vmstate = { .name = "CCID BulkIn state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BUFFER(data, BulkIn), VMSTATE_UINT32(len, BulkIn), VMSTATE_UINT32(pos, BulkIn), @@ -1379,7 +1379,7 @@ static const VMStateDescription answer_vmstate = { .name = "CCID Answer state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(slot, Answer), VMSTATE_UINT8(seq, Answer), VMSTATE_END_OF_LIST() @@ -1390,7 +1390,7 @@ static const VMStateDescription usb_device_vmstate = { .name = "usb_device", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(addr, USBDevice), VMSTATE_BUFFER(setup_buf, USBDevice), VMSTATE_BUFFER(data_buf, USBDevice), @@ -1404,7 +1404,7 @@ static const VMStateDescription ccid_vmstate = { .minimum_version_id = 1, .post_load = ccid_post_load, .pre_save = ccid_pre_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(dev, USBCCIDState, 1, usb_device_vmstate, USBDevice), VMSTATE_UINT8(debug, USBCCIDState), VMSTATE_BUFFER(bulk_out_data, USBCCIDState), diff --git a/hw/usb/dev-storage.c b/hw/usb/dev-storage.c index a496c811a7..341e505bd0 100644 --- a/hw/usb/dev-storage.c +++ b/hw/usb/dev-storage.c @@ -572,7 +572,7 @@ static const VMStateDescription vmstate_usb_msd = { .name = "usb-storage", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, MSDState), VMSTATE_UINT32(mode, MSDState), VMSTATE_UINT32(scsi_len, MSDState), diff --git a/hw/usb/dev-uas.c b/hw/usb/dev-uas.c index f013ded91e..1804cb6799 100644 --- a/hw/usb/dev-uas.c +++ b/hw/usb/dev-uas.c @@ -947,7 +947,7 @@ static void usb_uas_realize(USBDevice *dev, Error **errp) static const VMStateDescription vmstate_usb_uas = { .name = "usb-uas", .unmigratable = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, UASDevice), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/hcd-dwc2.c b/hw/usb/hcd-dwc2.c index a0c4e782b2..222eef82a5 100644 --- a/hw/usb/hcd-dwc2.c +++ b/hw/usb/hcd-dwc2.c @@ -1391,7 +1391,7 @@ static const VMStateDescription vmstate_dwc2_state_packet = { .name = "dwc2/packet", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(devadr, DWC2Packet), VMSTATE_UINT32(epnum, DWC2Packet), VMSTATE_UINT32(epdir, DWC2Packet), @@ -1411,7 +1411,7 @@ const VMStateDescription vmstate_dwc2_state = { .name = "dwc2", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(glbreg, DWC2State, DWC2_GLBREG_SIZE / sizeof(uint32_t)), VMSTATE_UINT32_ARRAY(fszreg, DWC2State, diff --git a/hw/usb/hcd-dwc3.c b/hw/usb/hcd-dwc3.c index 279263489e..09d8e25b97 100644 --- a/hw/usb/hcd-dwc3.c +++ b/hw/usb/hcd-dwc3.c @@ -648,7 +648,7 @@ static void usb_dwc3_init(Object *obj) static const VMStateDescription vmstate_usb_dwc3 = { .name = "usb-dwc3", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, USBDWC3, USB_DWC3_R_MAX), VMSTATE_UINT8(cfg.mode, USBDWC3), VMSTATE_UINT32(cfg.dwc_usb3_user, USBDWC3), diff --git a/hw/usb/hcd-ehci-pci.c b/hw/usb/hcd-ehci-pci.c index 345444a573..0b26db74d8 100644 --- a/hw/usb/hcd-ehci-pci.c +++ b/hw/usb/hcd-ehci-pci.c @@ -144,7 +144,7 @@ static const VMStateDescription vmstate_ehci_pci = { .name = "ehci", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pcidev, EHCIPCIState), VMSTATE_STRUCT(ehci, EHCIPCIState, 2, vmstate_ehci, EHCIState), VMSTATE_END_OF_LIST() diff --git a/hw/usb/hcd-ehci-sysbus.c b/hw/usb/hcd-ehci-sysbus.c index a12e218848..bfb774504c 100644 --- a/hw/usb/hcd-ehci-sysbus.c +++ b/hw/usb/hcd-ehci-sysbus.c @@ -25,7 +25,7 @@ static const VMStateDescription vmstate_ehci_sysbus = { .name = "ehci-sysbus", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(ehci, EHCISysBusState, 2, vmstate_ehci, EHCIState), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/hcd-ehci.c b/hw/usb/hcd-ehci.c index 19b4534c20..a8dcfe373a 100644 --- a/hw/usb/hcd-ehci.c +++ b/hw/usb/hcd-ehci.c @@ -2473,7 +2473,7 @@ const VMStateDescription vmstate_ehci = { .minimum_version_id = 1, .pre_save = usb_ehci_pre_save, .post_load = usb_ehci_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* mmio registers */ VMSTATE_UINT32(usbcmd, EHCIState), VMSTATE_UINT32(usbsts, EHCIState), diff --git a/hw/usb/hcd-ohci-pci.c b/hw/usb/hcd-ohci-pci.c index 6b630d35a7..33ed9b6f5a 100644 --- a/hw/usb/hcd-ohci-pci.c +++ b/hw/usb/hcd-ohci-pci.c @@ -120,7 +120,7 @@ static const VMStateDescription vmstate_ohci = { .name = "ohci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, OHCIPCIState), VMSTATE_STRUCT(state, OHCIPCIState, 1, vmstate_ohci_state, OHCIState), VMSTATE_END_OF_LIST() diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index 7ff1b65ced..d73b53f33c 100644 --- a/hw/usb/hcd-ohci.c +++ b/hw/usb/hcd-ohci.c @@ -1984,7 +1984,7 @@ static const VMStateDescription vmstate_ohci_state_port = { .name = "ohci-core/port", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(ctrl, OHCIPort), VMSTATE_END_OF_LIST() }, @@ -2002,7 +2002,7 @@ static const VMStateDescription vmstate_ohci_eof_timer = { .version_id = 1, .minimum_version_id = 1, .needed = ohci_eof_timer_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(eof_timer, OHCIState), VMSTATE_END_OF_LIST() }, @@ -2012,7 +2012,7 @@ const VMStateDescription vmstate_ohci_state = { .name = "ohci-core", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(sof_time, OHCIState), VMSTATE_UINT32(ctl, OHCIState), VMSTATE_UINT32(status, OHCIState), @@ -2049,7 +2049,7 @@ const VMStateDescription vmstate_ohci_state = { VMSTATE_BOOL(async_complete, OHCIState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_ohci_eof_timer, NULL } diff --git a/hw/usb/hcd-uhci.c b/hw/usb/hcd-uhci.c index 77baaa7a6b..7d3c026dae 100644 --- a/hw/usb/hcd-uhci.c +++ b/hw/usb/hcd-uhci.c @@ -339,7 +339,7 @@ static const VMStateDescription vmstate_uhci_port = { .name = "uhci port", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(ctrl, UHCIPort), VMSTATE_END_OF_LIST() } @@ -361,7 +361,7 @@ static const VMStateDescription vmstate_uhci = { .version_id = 3, .minimum_version_id = 1, .post_load = uhci_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, UHCIState), VMSTATE_UINT8_EQUAL(num_ports_vmstate, UHCIState, NULL), VMSTATE_STRUCT_ARRAY(ports, UHCIState, NB_PORTS, 1, diff --git a/hw/usb/hcd-xhci-pci.c b/hw/usb/hcd-xhci-pci.c index 643d4643e4..4423983308 100644 --- a/hw/usb/hcd-xhci-pci.c +++ b/hw/usb/hcd-xhci-pci.c @@ -178,7 +178,7 @@ static const VMStateDescription vmstate_xhci_pci = { .name = "xhci", .version_id = 1, .post_load = xhci_pci_vmstate_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj, XHCIPciState), VMSTATE_MSIX(parent_obj, XHCIPciState), VMSTATE_STRUCT(xhci, XHCIPciState, 1, vmstate_xhci, XHCIState), diff --git a/hw/usb/hcd-xhci-sysbus.c b/hw/usb/hcd-xhci-sysbus.c index faf57b4797..d93bae31f9 100644 --- a/hw/usb/hcd-xhci-sysbus.c +++ b/hw/usb/hcd-xhci-sysbus.c @@ -91,7 +91,7 @@ static Property xhci_sysbus_props[] = { static const VMStateDescription vmstate_xhci_sysbus = { .name = "xhci-sysbus", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(xhci, XHCISysbusState, 1, vmstate_xhci, XHCIState), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c index 4b60114207..ad40232eb6 100644 --- a/hw/usb/hcd-xhci.c +++ b/hw/usb/hcd-xhci.c @@ -3522,7 +3522,7 @@ static int usb_xhci_post_load(void *opaque, int version_id) static const VMStateDescription vmstate_xhci_ring = { .name = "xhci-ring", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(dequeue, XHCIRing), VMSTATE_BOOL(ccs, XHCIRing), VMSTATE_END_OF_LIST() @@ -3532,7 +3532,7 @@ static const VMStateDescription vmstate_xhci_ring = { static const VMStateDescription vmstate_xhci_port = { .name = "xhci-port", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(portsc, XHCIPort), VMSTATE_END_OF_LIST() } @@ -3541,7 +3541,7 @@ static const VMStateDescription vmstate_xhci_port = { static const VMStateDescription vmstate_xhci_slot = { .name = "xhci-slot", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(enabled, XHCISlot), VMSTATE_BOOL(addressed, XHCISlot), VMSTATE_END_OF_LIST() @@ -3551,7 +3551,7 @@ static const VMStateDescription vmstate_xhci_slot = { static const VMStateDescription vmstate_xhci_event = { .name = "xhci-event", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(type, XHCIEvent), VMSTATE_UINT32(ccode, XHCIEvent), VMSTATE_UINT64(ptr, XHCIEvent), @@ -3571,7 +3571,7 @@ static bool xhci_er_full(void *opaque, int version_id) static const VMStateDescription vmstate_xhci_intr = { .name = "xhci-intr", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { /* registers */ VMSTATE_UINT32(iman, XHCIInterrupter), VMSTATE_UINT32(imod, XHCIInterrupter), @@ -3604,7 +3604,7 @@ const VMStateDescription vmstate_xhci = { .name = "xhci-core", .version_id = 1, .post_load = usb_xhci_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_UINT32(ports, XHCIState, numports, 1, vmstate_xhci_port, XHCIPort), VMSTATE_STRUCT_VARRAY_UINT32(slots, XHCIState, numslots, 1, diff --git a/hw/usb/host-libusb.c b/hw/usb/host-libusb.c index d7060a42d5..80122b4125 100644 --- a/hw/usb/host-libusb.c +++ b/hw/usb/host-libusb.c @@ -1753,7 +1753,7 @@ static const VMStateDescription vmstate_usb_host = { .version_id = 1, .minimum_version_id = 1, .post_load = usb_host_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(parent_obj, USBHostDevice), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/imx-usb-phy.c b/hw/usb/imx-usb-phy.c index 1a97b36a11..18917d7599 100644 --- a/hw/usb/imx-usb-phy.c +++ b/hw/usb/imx-usb-phy.c @@ -20,7 +20,7 @@ static const VMStateDescription vmstate_imx_usbphy = { .name = TYPE_IMX_USBPHY, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(usbphy, IMXUSBPHYState, USBPHY_MAX), VMSTATE_END_OF_LIST() }, diff --git a/hw/usb/redirect.c b/hw/usb/redirect.c index c9893df867..636eb98e41 100644 --- a/hw/usb/redirect.c +++ b/hw/usb/redirect.c @@ -2373,7 +2373,7 @@ static const VMStateDescription usbredir_bulk_receiving_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = usbredir_bulk_receiving_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(bulk_receiving_started, struct endp_data), VMSTATE_END_OF_LIST() } @@ -2391,7 +2391,7 @@ static const VMStateDescription usbredir_stream_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = usbredir_stream_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(max_streams, struct endp_data), VMSTATE_END_OF_LIST() } @@ -2401,7 +2401,7 @@ static const VMStateDescription usbredir_ep_vmstate = { .name = "usb-redir-ep", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(type, struct endp_data), VMSTATE_UINT8(interval, struct endp_data), VMSTATE_UINT8(interface, struct endp_data), @@ -2424,7 +2424,7 @@ static const VMStateDescription usbredir_ep_vmstate = { VMSTATE_INT32(bufpq_target_size, struct endp_data), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &usbredir_bulk_receiving_vmstate, &usbredir_stream_vmstate, NULL @@ -2481,7 +2481,7 @@ static const VMStateDescription usbredir_ep_packet_id_queue_vmstate = { .name = "usb-redir-packet-id-queue", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { { .name = "queue", .version_id = 0, @@ -2501,7 +2501,7 @@ static const VMStateDescription usbredir_device_info_vmstate = { .name = "usb-redir-device-info", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(speed, struct usb_redir_device_connect_header), VMSTATE_UINT8(device_class, struct usb_redir_device_connect_header), VMSTATE_UINT8(device_subclass, struct usb_redir_device_connect_header), @@ -2520,7 +2520,7 @@ static const VMStateDescription usbredir_interface_info_vmstate = { .name = "usb-redir-interface-info", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(interface_count, struct usb_redir_interface_info_header), VMSTATE_UINT8_ARRAY(interface, @@ -2543,7 +2543,7 @@ static const VMStateDescription usbredir_vmstate = { .minimum_version_id = 1, .pre_save = usbredir_pre_save, .post_load = usbredir_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, USBRedirDevice), VMSTATE_TIMER_PTR(attach_timer, USBRedirDevice), { diff --git a/hw/usb/u2f-passthru.c b/hw/usb/u2f-passthru.c index fc93429c9c..b7025d303d 100644 --- a/hw/usb/u2f-passthru.c +++ b/hw/usb/u2f-passthru.c @@ -512,7 +512,7 @@ static const VMStateDescription u2f_passthru_vmstate = { .version_id = 1, .minimum_version_id = 1, .post_load = u2f_passthru_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_U2F_KEY(base, U2FPassthruState), VMSTATE_END_OF_LIST() } diff --git a/hw/usb/u2f.c b/hw/usb/u2f.c index 56001249a4..1fb59cf404 100644 --- a/hw/usb/u2f.c +++ b/hw/usb/u2f.c @@ -305,7 +305,7 @@ const VMStateDescription vmstate_u2f_key = { .name = "u2f-key", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_USB_DEVICE(dev, U2FKeyState), VMSTATE_UINT8(idle, U2FKeyState), VMSTATE_UINT8_2DARRAY(pending_in, U2FKeyState, diff --git a/hw/usb/xlnx-versal-usb2-ctrl-regs.c b/hw/usb/xlnx-versal-usb2-ctrl-regs.c index 1c094aa1a6..6fc453817e 100644 --- a/hw/usb/xlnx-versal-usb2-ctrl-regs.c +++ b/hw/usb/xlnx-versal-usb2-ctrl-regs.c @@ -196,7 +196,7 @@ static const VMStateDescription vmstate_usb2_ctrl_regs = { .name = TYPE_XILINX_VERSAL_USB2_CTRL_REGS, .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, VersalUsb2CtrlRegs, USB2_REGS_R_MAX), VMSTATE_END_OF_LIST(), } From patchwork Fri Dec 29 21:23:34 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758830 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672110wrw; Fri, 29 Dec 2023 13:30:42 -0800 (PST) X-Google-Smtp-Source: AGHT+IFgb2g0eO7zG4nJ07MUauW0CjytvUYIA1gC9SV7qirQkC5JDaBlIBDbosfhKxDEW7tumqXl X-Received: by 2002:ad4:5aa1:0:b0:67e:f470:d21b with SMTP id u1-20020ad45aa1000000b0067ef470d21bmr20737403qvg.62.1703885441820; Fri, 29 Dec 2023 13:30:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885441; cv=none; d=google.com; s=arc-20160816; b=UQjzkq5L+J8vj1hkV2toHL31STgVix1GLtQv97RAwm0/A3ssb5uPwAH91RvvaV3/nB /TcuRQ3r8jszfvByqaN+MY4R9EC+Y4EVTojuSbcZWwFYEIO2ghij4rnWReGZHf83CATt 34O9ZrqsJEfxuEDCQN6GHfZnCD89l0/47QsIEHy1CgGb/obn1IcOmVQI3CykX61sutEp Btt1ZU51k6k2MIBuwTMMBpdZUjj5C0UPbFG9K0LAvowy41M9s0V14mVqznynJ/zfyned zQvt+Qz/uMU3mc74kS6TLCPi7K9BDca+3eslwuMvGGsYQF6tumwpXRS08hVixdSLWxGt DOtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=MzNGhzq81QTlaN12LzVhmURoRRihF1DCyuym+umxPGo=; fh=NcEKupijVbuTDhnhlzqYpQuzvQnl3BPVBgmTPqOUdUw=; b=EGTF0bKpl9iA/Hr18mNTD4Abjv32LCVqgsUFxfBtOeBLVKMxG++35a6OdfzUHJisyG jtriBU4Pb3E2xCP+4XBuAQ6/eumXI93Ulz4o0Oa+cWUj8wO/V1sDQItMwT7s3n3jtYPG aW5IZxHfODJ2NTGV+nWXOUsh4TBPngk0dt3+U2dfUx2+g/Sp1ZsfBIF8Q5cgj/oWmvz3 S/SVvEDITHQJ+WuCaKRpgzDDCZ33VIuFGmLDp+ChswXUT+aIba8y539CoPM5wvSGRhf9 QON1ZFcdrUKuIqkaGJMomgAl35bSHSJ2fB2jx4S+v2GGn3XEis5c41PrCMO0IQc8ch8s lraQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fn8AvMqq; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id l16-20020a056214105000b0067fc77296a5si14005613qvr.472.2023.12.29.13.30.41 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:41 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=fn8AvMqq; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQH-0000TN-2n; Fri, 29 Dec 2023 16:29:41 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPz-0008QK-J1 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:25 -0500 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPu-0000Nw-7D for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:19 -0500 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-6d9b37f4804so2673100b3a.1 for ; Fri, 29 Dec 2023 13:29:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885352; x=1704490152; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=MzNGhzq81QTlaN12LzVhmURoRRihF1DCyuym+umxPGo=; b=fn8AvMqqQ1y8K0uGGdmD4hKlZIzraw9gSnavPjdk8B3zSFIujqm4V0+k/f0LeNhlzb 2UuEwvV5anvtb4c7QMrVa50EwDbttCsb9T8Cdt7rizf86Mt+1/gxu/RZxgtzNP2h4sni gGkISTseIxbGGavmN7x2/84GCGTgYYbUgu+rxQqGNPWkmObp+fEtRwRqmrIEfFqm9eAg awgXPOLDDRh4xfW8wpPFLeVjaUixTZM71WivnYbkemjgVCJiG6PiTgFjscN4VsQvm8AH rakVQeXQBaPJVWrEPme/vYz/2h7Nl0iZqaLyhT7UipsP2A0/iaXN3j1ZVzFl+tdFpIkk c1Sg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885352; x=1704490152; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=MzNGhzq81QTlaN12LzVhmURoRRihF1DCyuym+umxPGo=; b=D22m+NRyPT4OF1mEAJZ+KyhpdQrfUPfUePjupy2CuaSqgmj+NMzKKrZZRdCW58Ak5H lzYhIikz7rhUIQQC/ad8ZDS1a2GbxJEcu8BCFNcSmxJK4/r26czy35+Cr2rf2s/tRQDO m25MYDl9P6TbGNtJAIcwAnlATGpm4PnP4Fh4j1+ItNHt/I8UXUeZeEYF5HQ7KQ+XtJ4j u/7YNzh9RDMc2mvWW6CgDjTDYm39FqktU3GNu2h862XIrw2HpQyrgrVfEm+UxT7gSq9R mi9bltHVnPLYwJM2PpeNo50gyMyzF1cDhAXiF9UuniFu8BUqH6Z886juh617YRjyFnND vF0Q== X-Gm-Message-State: AOJu0YwgoQAx7aCFALCmMqSR/uHNEZ1xaj9Jqw7nQR+bRfBntpgNRi6V 3ao+7arDIgR49i+6aVaVzJF6eeLk5W7zsvyjGhRc1mQ8ufMHeA== X-Received: by 2002:a05:6a20:e127:b0:196:2550:d6d6 with SMTP id kr39-20020a056a20e12700b001962550d6d6mr5702899pzb.13.1703885352053; Fri, 29 Dec 2023 13:29:12 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:11 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?C=C3=A9dric_Le_Goater?= Subject: [PULL 59/71] hw/vfio: Constify VMState Date: Sat, 30 Dec 2023 08:23:34 +1100 Message-Id: <20231229212346.147149-60-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::434; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x434.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Reviewed-by: Cédric Le Goater Message-Id: <20231221031652.119827-60-richard.henderson@linaro.org> --- hw/vfio/display.c | 2 +- hw/vfio/pci.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/vfio/display.c b/hw/vfio/display.c index 7a10fa8604..1aa440c663 100644 --- a/hw/vfio/display.c +++ b/hw/vfio/display.c @@ -560,7 +560,7 @@ const VMStateDescription vfio_display_vmstate = { .version_id = 1, .minimum_version_id = 1, .needed = migrate_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_POINTER(ramfb, VFIODisplay, ramfb_vmstate, RAMFBState), VMSTATE_END_OF_LIST(), } diff --git a/hw/vfio/pci.c b/hw/vfio/pci.c index 1874ec1aba..9f838978be 100644 --- a/hw/vfio/pci.c +++ b/hw/vfio/pci.c @@ -2561,7 +2561,7 @@ const VMStateDescription vmstate_vfio_display = { .version_id = 1, .minimum_version_id = 1, .needed = vfio_display_migration_needed, - .fields = (VMStateField[]){ + .fields = (const VMStateField[]){ VMSTATE_STRUCT_POINTER(dpy, VFIOPCIDevice, vfio_display_vmstate, VFIODisplay), VMSTATE_END_OF_LIST() @@ -2572,12 +2572,12 @@ const VMStateDescription vmstate_vfio_pci_config = { .name = "VFIOPCIDevice", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(pdev, VFIOPCIDevice), VMSTATE_MSIX_TEST(pdev, VFIOPCIDevice, vfio_msix_present), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_vfio_display, NULL } From patchwork Fri Dec 29 21:23:35 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758850 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672497wrw; Fri, 29 Dec 2023 13:31:54 -0800 (PST) X-Google-Smtp-Source: AGHT+IFGk6poEejgEcS/oZ37Y4MGPRzxdqLi2lZXE9ddjSsQP4uP3dVLiXGLLTrkyp7oopiGxt2W X-Received: by 2002:a05:6214:20cd:b0:67f:666b:ada2 with SMTP id 13-20020a05621420cd00b0067f666bada2mr22000989qve.28.1703885514236; Fri, 29 Dec 2023 13:31:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885514; cv=none; d=google.com; s=arc-20160816; b=VwmWu5/AyMwvLw3n/Rp/Md3hK10QcXjRmCsPDo7bZHbDIPNIu6DUtE8uquw4NZCSJs g+n9hXyJpQMNzLI//Kly1uk76Lf3hWaC+gusRfrQTOeUGqd61UWGhd7ARsjMHoPGAW45 A5BHjxwoYLj5Cg2XEX9BbD2s9HbiiyHM84XQ9sDafHZxm6jGaquxB/fE7HGQyCRZ+alC JS+riOoVbOtMnm3SvRCgtZVSRKQGOhOwIkm6rw6fKb7WfQNypx0dw5DI2ffkvN8xw2uC 0UQ8EkhfrA7+xitMlPGhTlsjbSze/0E0gLbC6Jpn2hKbxjHVmUh8925TBs1MpPOhvhKv ReEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=8bYRcHjoz0xLssPgIP2+lQxpAxmoUhsvUahD+2ZYGyY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=ruAZhcuT90tyLh486MDuSjdhQ6Wl36KLi5oID3KvB2lNGDEqFUFY7nlfHsSTwD1b5j vHIZK8pb25Np+GQZImADHJYXSocvy335DZCJB+Xw/WMhPkudWiC+jHby+z2mLiQIKDJI gW1DjcdurjBdO7RQ+/KE9nI6Xk0XYP9ArRV1G2Iss+Kyklmor3H1pUMuyXvDYF7MeG1S A8gR380aS57nwLkk56MkQtyEBgYtgZ9OQl5kxMVsQI98lAtW2fqxOwS506o0zlBCT95I NIIh5ov4nMqesSnVeCzPTC99Un3fVX//oS30BrC8x3v/C4ATyJTLj6lIy33PH+akcuS4 2DSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SNagU2gy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id s25-20020a05620a031900b0077896ff4c24si18874820qkm.585.2023.12.29.13.31.54 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:54 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=SNagU2gy; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQG-0000NO-ES; Fri, 29 Dec 2023 16:29:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPz-0008Qt-KC for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:25 -0500 Received: from mail-pf1-x435.google.com ([2607:f8b0:4864:20::435]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPu-0000O2-8v for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:21 -0500 Received: by mail-pf1-x435.google.com with SMTP id d2e1a72fcca58-6d9bba6d773so3238145b3a.1 for ; Fri, 29 Dec 2023 13:29:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885354; x=1704490154; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=8bYRcHjoz0xLssPgIP2+lQxpAxmoUhsvUahD+2ZYGyY=; b=SNagU2gykkr6VE6+tm6U7OqoMaHcWwboylSJ6RBhrqmqKsEQEL21EiGr9nQppKF6ef In7uz1cNualFSW77Xs0wvQCBS5u8IaFRta5FVt01BmTGCYCiFLNpRl5gafOHIlQANyCo dIuPSeR4/ihkX2pXQNqhXgE/0D6APlvZe+zw5Xh3P77Z5oxy4+0SwmhSZknGVP9kb5pS /kvPNIlnDUoXD+HAxCKwKXOLf/Zwxt/htLoYNHAErXBY1ZZzh7swGkx763PzLJZMBG84 808yfLOmNiu0ORqlwAhOmXquK4IvALjGHVidgjbjYnhy9rwEBsdtHbnMqnBpGr6MEdrg EKoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885354; x=1704490154; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8bYRcHjoz0xLssPgIP2+lQxpAxmoUhsvUahD+2ZYGyY=; b=iJ85VCgUXX4+iE5HUGMRxTlJ3ejUqpqp/YMC0lRHOXyXjAu6+cD40N7HBmV0rUcL+m mPOH8jROMcUgxDU3NIn+RJaIeCH3yVCa8AmbjN3JLLvSn+nZAiCnbe2S60N2bGY45QWr sfc8gNWRqOu3fDI+++eDGwV/LAWlRp0okyMyvHpYTodAmdmECF/LLLgW7QF3RNKCYLEp ds2AzJVo/nlhunfy4OeZQbycpmG4cb1uJX4K2xhaBbvccr08BYjRTdj0BD2FDJZfyVFI zpVUwvDFWGXGOPQ7tuoCaBj9GlduQ+YS9sqRzpqXtUaKN9eCV79GCkR5eC/qG5VCfNDe 0Ccg== X-Gm-Message-State: AOJu0Yz8FX4m1kmJNdeGQo6KVNbjBj4pHpWiyn+K6vb9siXcK2NyTPtH 3MTLuLtRQdYB8M8+1u5jwXdm6td3WRt47FORoatkgbMg/GHT4w== X-Received: by 2002:a05:6a00:17a4:b0:6d9:ba6f:54ac with SMTP id s36-20020a056a0017a400b006d9ba6f54acmr10694547pfg.54.1703885354027; Fri, 29 Dec 2023 13:29:14 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:13 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 60/71] hw/virtio: Constify VMState Date: Sat, 30 Dec 2023 08:23:35 +1100 Message-Id: <20231229212346.147149-61-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::435; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x435.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-61-richard.henderson@linaro.org> --- hw/virtio/vdpa-dev.c | 2 +- hw/virtio/vhost-user-fs.c | 6 +++--- hw/virtio/vhost-vsock.c | 2 +- hw/virtio/virtio-balloon.c | 10 +++++----- hw/virtio/virtio-crypto.c | 2 +- hw/virtio/virtio-iommu.c | 12 ++++++------ hw/virtio/virtio-mem.c | 8 ++++---- hw/virtio/virtio-mmio.c | 8 ++++---- hw/virtio/virtio-pci.c | 8 ++++---- hw/virtio/virtio-rng.c | 2 +- hw/virtio/virtio.c | 28 ++++++++++++++-------------- 11 files changed, 44 insertions(+), 44 deletions(-) diff --git a/hw/virtio/vdpa-dev.c b/hw/virtio/vdpa-dev.c index 8774986571..eb9ecea83b 100644 --- a/hw/virtio/vdpa-dev.c +++ b/hw/virtio/vdpa-dev.c @@ -344,7 +344,7 @@ static const VMStateDescription vmstate_vhost_vdpa_device = { .unmigratable = 1, .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/vhost-user-fs.c b/hw/virtio/vhost-user-fs.c index eb91723855..cca2cd41be 100644 --- a/hw/virtio/vhost-user-fs.c +++ b/hw/virtio/vhost-user-fs.c @@ -373,11 +373,11 @@ static const VMStateDescription vuf_backend_vmstate; static const VMStateDescription vuf_vmstate = { .name = "vhost-user-fs", .version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vuf_backend_vmstate, NULL, } @@ -389,7 +389,7 @@ static const VMStateDescription vuf_backend_vmstate = { .needed = vuf_is_internal_migration, .pre_load = vuf_check_migration_support, .pre_save = vuf_check_migration_support, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { { .name = "back-end", .info = &(const VMStateInfo) { diff --git a/hw/virtio/vhost-vsock.c b/hw/virtio/vhost-vsock.c index aa16d584ee..d5ca0b5a10 100644 --- a/hw/virtio/vhost-vsock.c +++ b/hw/virtio/vhost-vsock.c @@ -111,7 +111,7 @@ static const VMStateDescription vmstate_virtio_vhost_vsock = { .name = "virtio-vhost_vsock", .minimum_version_id = VHOST_VSOCK_SAVEVM_VERSION, .version_id = VHOST_VSOCK_SAVEVM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio-balloon.c b/hw/virtio/virtio-balloon.c index d004cf29d2..486fe3da32 100644 --- a/hw/virtio/virtio-balloon.c +++ b/hw/virtio/virtio-balloon.c @@ -817,7 +817,7 @@ static const VMStateDescription vmstate_virtio_balloon_free_page_hint = { .version_id = 1, .minimum_version_id = 1, .needed = virtio_balloon_free_page_support, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(free_page_hint_cmd_id, VirtIOBalloon), VMSTATE_UINT32(free_page_hint_status, VirtIOBalloon), VMSTATE_END_OF_LIST() @@ -829,7 +829,7 @@ static const VMStateDescription vmstate_virtio_balloon_page_poison = { .version_id = 1, .minimum_version_id = 1, .needed = virtio_balloon_page_poison_support, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(poison_val, VirtIOBalloon), VMSTATE_END_OF_LIST() } @@ -840,12 +840,12 @@ static const VMStateDescription vmstate_virtio_balloon_device = { .version_id = 1, .minimum_version_id = 1, .post_load = virtio_balloon_post_load_device, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(num_pages, VirtIOBalloon), VMSTATE_UINT32(actual, VirtIOBalloon), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_balloon_free_page_hint, &vmstate_virtio_balloon_page_poison, NULL @@ -996,7 +996,7 @@ static const VMStateDescription vmstate_virtio_balloon = { .name = "virtio-balloon", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio-crypto.c b/hw/virtio/virtio-crypto.c index 0e2cc8d5a8..fe1313f2ad 100644 --- a/hw/virtio/virtio-crypto.c +++ b/hw/virtio/virtio-crypto.c @@ -1122,7 +1122,7 @@ static const VMStateDescription vmstate_virtio_crypto = { .unmigratable = 1, .minimum_version_id = VIRTIO_CRYPTO_VM_VERSION, .version_id = VIRTIO_CRYPTO_VM_VERSION, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio-iommu.c b/hw/virtio/virtio-iommu.c index 9d463efc52..8a4bd933c6 100644 --- a/hw/virtio/virtio-iommu.c +++ b/hw/virtio/virtio-iommu.c @@ -1399,7 +1399,7 @@ static void virtio_iommu_instance_init(Object *obj) .name = "interval", \ .version_id = 1, \ .minimum_version_id = 1, \ - .fields = (VMStateField[]) { \ + .fields = (const VMStateField[]) { \ VMSTATE_UINT64(low, VirtIOIOMMUInterval), \ VMSTATE_UINT64(high, VirtIOIOMMUInterval), \ VMSTATE_END_OF_LIST() \ @@ -1411,7 +1411,7 @@ static void virtio_iommu_instance_init(Object *obj) .name = "mapping", \ .version_id = 1, \ .minimum_version_id = 1, \ - .fields = (VMStateField[]) { \ + .fields = (const VMStateField[]) { \ VMSTATE_UINT64(phys_addr, VirtIOIOMMUMapping),\ VMSTATE_UINT32(flags, VirtIOIOMMUMapping), \ VMSTATE_END_OF_LIST() \ @@ -1436,7 +1436,7 @@ static const VMStateDescription vmstate_endpoint = { .name = "endpoint", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, VirtIOIOMMUEndpoint), VMSTATE_END_OF_LIST() } @@ -1447,7 +1447,7 @@ static const VMStateDescription vmstate_domain = { .version_id = 2, .minimum_version_id = 2, .pre_load = domain_preload, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, VirtIOIOMMUDomain), VMSTATE_GTREE_V(mappings, VirtIOIOMMUDomain, 1, vmstate_interval_mapping, @@ -1499,7 +1499,7 @@ static const VMStateDescription vmstate_virtio_iommu_device = { .minimum_version_id = 2, .version_id = 2, .post_load = iommu_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_GTREE_DIRECT_KEY_V(domains, VirtIOIOMMU, 2, &vmstate_domain, VirtIOIOMMUDomain), VMSTATE_UINT8_V(config.bypass, VirtIOIOMMU, 2), @@ -1512,7 +1512,7 @@ static const VMStateDescription vmstate_virtio_iommu = { .minimum_version_id = 2, .priority = MIG_PRI_IOMMU, .version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio-mem.c b/hw/virtio/virtio-mem.c index 75ee38aa46..dc4709790f 100644 --- a/hw/virtio/virtio-mem.c +++ b/hw/virtio/virtio-mem.c @@ -1370,7 +1370,7 @@ static const VMStateDescription vmstate_virtio_mem_sanity_checks = { .name = "virtio-mem-device/sanity-checks", .pre_save = virtio_mem_mig_sanity_checks_pre_save, .post_load = virtio_mem_mig_sanity_checks_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(addr, VirtIOMEMMigSanityChecks), VMSTATE_UINT64(region_size, VirtIOMEMMigSanityChecks), VMSTATE_UINT64(block_size, VirtIOMEMMigSanityChecks), @@ -1393,7 +1393,7 @@ static const VMStateDescription vmstate_virtio_mem_device = { .version_id = 1, .priority = MIG_PRI_VIRTIO_MEM, .post_load = virtio_mem_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP_TEST(VirtIOMEM, virtio_mem_vmstate_field_exists, VirtIOMEMMigSanityChecks, vmstate_virtio_mem_sanity_checks), @@ -1423,7 +1423,7 @@ static const VMStateDescription vmstate_virtio_mem_device_early = { .version_id = 1, .early_setup = true, .post_load = virtio_mem_post_load_early, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_WITH_TMP(VirtIOMEM, VirtIOMEMMigSanityChecks, vmstate_virtio_mem_sanity_checks), VMSTATE_UINT64(size, VirtIOMEM), @@ -1436,7 +1436,7 @@ static const VMStateDescription vmstate_virtio_mem = { .name = "virtio-mem", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio-mmio.c b/hw/virtio/virtio-mmio.c index 22f15e1e02..22f9fbcf5a 100644 --- a/hw/virtio/virtio-mmio.c +++ b/hw/virtio/virtio-mmio.c @@ -565,7 +565,7 @@ static const VMStateDescription vmstate_virtio_mmio_queue_state = { .name = "virtio_mmio/queue_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(num, VirtIOMMIOQueue), VMSTATE_BOOL(enabled, VirtIOMMIOQueue), VMSTATE_UINT32_ARRAY(desc, VirtIOMMIOQueue, 2), @@ -579,7 +579,7 @@ static const VMStateDescription vmstate_virtio_mmio_state_sub = { .name = "virtio_mmio/state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(guest_features, VirtIOMMIOProxy, 2), VMSTATE_STRUCT_ARRAY(vqs, VirtIOMMIOProxy, VIRTIO_QUEUE_MAX, 0, vmstate_virtio_mmio_queue_state, @@ -592,10 +592,10 @@ static const VMStateDescription vmstate_virtio_mmio = { .name = "virtio_mmio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_mmio_state_sub, NULL } diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index e433879542..1a7039fb0c 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/virtio-pci.c @@ -97,7 +97,7 @@ static const VMStateDescription vmstate_virtio_pci_modern_queue_state = { .name = "virtio_pci/modern_queue_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(num, VirtIOPCIQueue), VMSTATE_UNUSED(1), /* enabled was stored as be16 */ VMSTATE_BOOL(enabled, VirtIOPCIQueue), @@ -120,7 +120,7 @@ static const VMStateDescription vmstate_virtio_pci_modern_state_sub = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_pci_modern_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(dfselect, VirtIOPCIProxy), VMSTATE_UINT32(gfselect, VirtIOPCIProxy), VMSTATE_UINT32_ARRAY(guest_features, VirtIOPCIProxy, 2), @@ -135,10 +135,10 @@ static const VMStateDescription vmstate_virtio_pci = { .name = "virtio_pci", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_pci_modern_state_sub, NULL } diff --git a/hw/virtio/virtio-rng.c b/hw/virtio/virtio-rng.c index 7e12fc03bf..f74efffef7 100644 --- a/hw/virtio/virtio-rng.c +++ b/hw/virtio/virtio-rng.c @@ -242,7 +242,7 @@ static const VMStateDescription vmstate_virtio_rng = { .name = "virtio-rng", .minimum_version_id = 1, .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VIRTIO_DEVICE, VMSTATE_END_OF_LIST() }, diff --git a/hw/virtio/virtio.c b/hw/virtio/virtio.c index 3a160f86ed..7549094154 100644 --- a/hw/virtio/virtio.c +++ b/hw/virtio/virtio.c @@ -2594,7 +2594,7 @@ static const VMStateDescription vmstate_virtqueue = { .name = "virtqueue_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(vring.avail, struct VirtQueue), VMSTATE_UINT64(vring.used, struct VirtQueue), VMSTATE_END_OF_LIST() @@ -2605,7 +2605,7 @@ static const VMStateDescription vmstate_packed_virtqueue = { .name = "packed_virtqueue_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(last_avail_idx, struct VirtQueue), VMSTATE_BOOL(last_avail_wrap_counter, struct VirtQueue), VMSTATE_UINT16(used_idx, struct VirtQueue), @@ -2620,7 +2620,7 @@ static const VMStateDescription vmstate_virtio_virtqueues = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_virtqueue_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_KNOWN(vq, struct VirtIODevice, VIRTIO_QUEUE_MAX, 0, vmstate_virtqueue, VirtQueue), VMSTATE_END_OF_LIST() @@ -2632,7 +2632,7 @@ static const VMStateDescription vmstate_virtio_packed_virtqueues = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_packed_virtqueue_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_KNOWN(vq, struct VirtIODevice, VIRTIO_QUEUE_MAX, 0, vmstate_packed_virtqueue, VirtQueue), VMSTATE_END_OF_LIST() @@ -2643,7 +2643,7 @@ static const VMStateDescription vmstate_ringsize = { .name = "ringsize_state", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(vring.num_default, struct VirtQueue), VMSTATE_END_OF_LIST() } @@ -2654,7 +2654,7 @@ static const VMStateDescription vmstate_virtio_ringsize = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_ringsize_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_VARRAY_POINTER_KNOWN(vq, struct VirtIODevice, VIRTIO_QUEUE_MAX, 0, vmstate_ringsize, VirtQueue), VMSTATE_END_OF_LIST() @@ -2697,7 +2697,7 @@ static const VMStateDescription vmstate_virtio_extra_state = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_extra_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { { .name = "extra_state", .version_id = 0, @@ -2716,7 +2716,7 @@ static const VMStateDescription vmstate_virtio_device_endian = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_device_endian_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(device_endian, VirtIODevice), VMSTATE_END_OF_LIST() } @@ -2727,7 +2727,7 @@ static const VMStateDescription vmstate_virtio_64bit_features = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_64bit_features_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(guest_features, VirtIODevice), VMSTATE_END_OF_LIST() } @@ -2738,7 +2738,7 @@ static const VMStateDescription vmstate_virtio_broken = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_broken_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(broken, VirtIODevice), VMSTATE_END_OF_LIST() } @@ -2749,7 +2749,7 @@ static const VMStateDescription vmstate_virtio_started = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_started_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(started, VirtIODevice), VMSTATE_END_OF_LIST() } @@ -2760,7 +2760,7 @@ static const VMStateDescription vmstate_virtio_disabled = { .version_id = 1, .minimum_version_id = 1, .needed = &virtio_disabled_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(disabled, VirtIODevice), VMSTATE_END_OF_LIST() } @@ -2770,10 +2770,10 @@ static const VMStateDescription vmstate_virtio = { .name = "virtio", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_virtio_device_endian, &vmstate_virtio_64bit_features, &vmstate_virtio_virtqueues, From patchwork Fri Dec 29 21:23:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758843 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672414wrw; Fri, 29 Dec 2023 13:31:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IGitMS4i31rT2b7ipTNo03mgXdXjgOh3BZDeLUFElSLwz+6R6l2xGztj9Y+cCP1fXbJIG4O X-Received: by 2002:ac8:5896:0:b0:425:4043:189d with SMTP id t22-20020ac85896000000b004254043189dmr18947509qta.80.1703885496389; Fri, 29 Dec 2023 13:31:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885496; cv=none; d=google.com; s=arc-20160816; b=bRxw17YhqA3VOAxRqTVwxnyAuhWn9OwR561wyONcV2A3MTmREZOTTAcjSocZlaqTw8 iViL5uGWX05SHDy8d45fbHlvlXwTH/InviTVZghts2wuuq6HVcbZyWQbzbKbLOJSCj64 uSWczkA+xg5YoRTpvYh7AGUQDIJt91Y1s3F/vQc5yqF+QC9ii+UYx00pSmiXq5oTtbLv cZLgOCKlSuJNC8aHmljhHvmxRlG3MdhIGEX0L2s5ltfz6fK8p6f3YNE0AxxmQZiz84aI xkfjOaXdvasmMY1+4iGO7eEjDxvOGdUaWuj6J/IA0vwXjrgqaY9B5OEYLYMX5P8yczQ+ BXOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=t/iLSJsvUNqGmwk21ef6qw5I/mGLsPK8yQVUTzDeYUY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=G+KGxZgy9tsq0O+WxhHy7Rj1gc8QOofS3wOpCdnqyzik3e8MMiDPU+bCVQGHW+1wH2 DOVn79E6NkQVLyTgCQxNHOStTJfzQ+Akwo0OQke7c7+seBekzQ12gFxbEwfnov3HftWr 4PDBmU8/0J/3buMEHsfBASxNSK6RR45uUAASr4Kb5lQo869Jr/TsyN8QBR0PFZ+A7Q96 UKSozVpttBDToh2f/BPoDb9fxYZGsMQ8QUaXospmslk23PBELyEtcwu3OmyTyvcb1ZdI Qxelzja9WSIUjHfjQj7rFWMVbjueCuAD2XaoDJ6CO16CLvBrFTCpmAdlWM8pUKRwIcKP dk+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=S+MPuuUU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id bz18-20020a05622a1e9200b004280d858cbasi650757qtb.412.2023.12.29.13.31.36 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:36 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=S+MPuuUU; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQI-0000kS-OH; Fri, 29 Dec 2023 16:29:42 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKPz-0008QI-J1 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:25 -0500 Received: from mail-oi1-x230.google.com ([2607:f8b0:4864:20::230]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPu-0000O6-7G for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:19 -0500 Received: by mail-oi1-x230.google.com with SMTP id 5614622812f47-3bbc648bed4so2175764b6e.3 for ; Fri, 29 Dec 2023 13:29:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885356; x=1704490156; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=t/iLSJsvUNqGmwk21ef6qw5I/mGLsPK8yQVUTzDeYUY=; b=S+MPuuUUGb32+OfHpN6EfgOgAqOFvrJdt6a+7mH2i/W9z+iFXhfhu0IiTkvX4jQMY0 h9moJGZrJL/RLB5bBu9RwfzXA3FRf81fMAKGF/u56uhfrxLk4DjJr6c20kn1cRj0L9ss 6JCH3VhPEOptO3aP+vyM8D1VfCrp9esUvIQ66tVjEVv8Osj+DCTpmNXrQZhBFQCJHTrs V+PowtDckjdpUu71SlwoWLkjb47EIqULaQiC4Dhv0x0ycIY+06IrqjbqwKP+l3JFMoay WQoOoQ7VbBhJinbUkBNYsbDB476YX+9baMRTQveBp5rCiEMcaJz31z3VtuWEBO8TniYv 4EWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885356; x=1704490156; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=t/iLSJsvUNqGmwk21ef6qw5I/mGLsPK8yQVUTzDeYUY=; b=JZVFob8Ud+0CJ9SXuegYlXi3FPjOsRhQNFruRFqdlRrTWkwfIoKc4sjeE8qcxqFzk9 hk2P6oes92X8/ndsaP5Y5z3BZfebfXLP5cLtcgAtJi/ltRoFQyz5EQaMQt0+A/2HIClv e1S4aKcm3aUbQl3ynsT2cuPcVCG64wlYfKACgGYQDVsClEmk/fJ5XlMfXwvCYom9rcvt gq3LG2PB41f/WzG3RUhzkdkJHJcvpZ7m5lL/4PxzcvHraHBV6TmypjIu1mPgGMntaQ3w T/WPmf37Wih31dIEWp4fsSXcwIieYCSo5yXiA7f7uXkpMho9gt917KlLAXXBT1nm1ERQ QcUg== X-Gm-Message-State: AOJu0YzomSlBnvASmaBdhXAM248H6trcwyB/3NdioY+f5fu3MFLmECOQ 6boRk7XG0jmAEFT96egAhJyGEMR6eDRlD8ReL6EpX2Dimz5Bvg== X-Received: by 2002:a05:6808:338b:b0:3bb:c774:565e with SMTP id ce11-20020a056808338b00b003bbc774565emr4852067oib.24.1703885356114; Fri, 29 Dec 2023 13:29:16 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:15 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 61/71] hw/watchdog: Constify VMState Date: Sat, 30 Dec 2023 08:23:36 +1100 Message-Id: <20231229212346.147149-62-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::230; envelope-from=richard.henderson@linaro.org; helo=mail-oi1-x230.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-62-richard.henderson@linaro.org> --- hw/watchdog/allwinner-wdt.c | 2 +- hw/watchdog/cmsdk-apb-watchdog.c | 2 +- hw/watchdog/sbsa_gwdt.c | 2 +- hw/watchdog/spapr_watchdog.c | 2 +- hw/watchdog/wdt_aspeed.c | 2 +- hw/watchdog/wdt_diag288.c | 2 +- hw/watchdog/wdt_i6300esb.c | 2 +- hw/watchdog/wdt_ib700.c | 2 +- hw/watchdog/wdt_imx2.c | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/hw/watchdog/allwinner-wdt.c b/hw/watchdog/allwinner-wdt.c index 6205765efe..d35711c7c5 100644 --- a/hw/watchdog/allwinner-wdt.c +++ b/hw/watchdog/allwinner-wdt.c @@ -313,7 +313,7 @@ static const VMStateDescription allwinner_wdt_vmstate = { .name = "allwinner-wdt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(timer, AwWdtState), VMSTATE_UINT32_ARRAY(regs, AwWdtState, AW_WDT_REGS_NUM), VMSTATE_END_OF_LIST() diff --git a/hw/watchdog/cmsdk-apb-watchdog.c b/hw/watchdog/cmsdk-apb-watchdog.c index 5a2cd46eb7..3091e5c3d5 100644 --- a/hw/watchdog/cmsdk-apb-watchdog.c +++ b/hw/watchdog/cmsdk-apb-watchdog.c @@ -361,7 +361,7 @@ static const VMStateDescription cmsdk_apb_watchdog_vmstate = { .name = "cmsdk-apb-watchdog", .version_id = 2, .minimum_version_id = 2, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_CLOCK(wdogclk, CMSDKAPBWatchdog), VMSTATE_PTIMER(timer, CMSDKAPBWatchdog), VMSTATE_UINT32(control, CMSDKAPBWatchdog), diff --git a/hw/watchdog/sbsa_gwdt.c b/hw/watchdog/sbsa_gwdt.c index 7aa57a8c51..96895d7636 100644 --- a/hw/watchdog/sbsa_gwdt.c +++ b/hw/watchdog/sbsa_gwdt.c @@ -28,7 +28,7 @@ static const VMStateDescription vmstate_sbsa_gwdt = { .name = "sbsa-gwdt", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, SBSA_GWDTState), VMSTATE_UINT32(wcs, SBSA_GWDTState), VMSTATE_UINT32(worl, SBSA_GWDTState), diff --git a/hw/watchdog/spapr_watchdog.c b/hw/watchdog/spapr_watchdog.c index 55ff1f03c1..2bb1d3c532 100644 --- a/hw/watchdog/spapr_watchdog.c +++ b/hw/watchdog/spapr_watchdog.c @@ -226,7 +226,7 @@ static const VMStateDescription vmstate_wdt = { .version_id = 1, .minimum_version_id = 1, .needed = watchdog_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER(timer, SpaprWatchdog), VMSTATE_UINT8(action, SpaprWatchdog), VMSTATE_UINT8(leave_others, SpaprWatchdog), diff --git a/hw/watchdog/wdt_aspeed.c b/hw/watchdog/wdt_aspeed.c index 273a49d360..d70b656f8e 100644 --- a/hw/watchdog/wdt_aspeed.c +++ b/hw/watchdog/wdt_aspeed.c @@ -218,7 +218,7 @@ static const VMStateDescription vmstate_aspeed_wdt = { .name = "vmstate_aspeed_wdt", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, AspeedWDTState), VMSTATE_UINT32_ARRAY(regs, AspeedWDTState, ASPEED_WDT_REGS_MAX), VMSTATE_END_OF_LIST() diff --git a/hw/watchdog/wdt_diag288.c b/hw/watchdog/wdt_diag288.c index 76d89fbf78..1b73b16fb3 100644 --- a/hw/watchdog/wdt_diag288.c +++ b/hw/watchdog/wdt_diag288.c @@ -23,7 +23,7 @@ static const VMStateDescription vmstate_diag288 = { .name = "vmstate_diag288", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, DIAG288State), VMSTATE_BOOL(enabled, DIAG288State), VMSTATE_END_OF_LIST() diff --git a/hw/watchdog/wdt_i6300esb.c b/hw/watchdog/wdt_i6300esb.c index 54c167cd35..8bce0509cd 100644 --- a/hw/watchdog/wdt_i6300esb.c +++ b/hw/watchdog/wdt_i6300esb.c @@ -418,7 +418,7 @@ static const VMStateDescription vmstate_i6300esb = { */ .version_id = 10000, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(dev, I6300State), VMSTATE_INT32(reboot_enabled, I6300State), VMSTATE_INT32(clock_scale, I6300State), diff --git a/hw/watchdog/wdt_ib700.c b/hw/watchdog/wdt_ib700.c index a1750a4957..eea8da6059 100644 --- a/hw/watchdog/wdt_ib700.c +++ b/hw/watchdog/wdt_ib700.c @@ -95,7 +95,7 @@ static const VMStateDescription vmstate_ib700 = { .name = "ib700_wdt", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(timer, IB700State), VMSTATE_END_OF_LIST() } diff --git a/hw/watchdog/wdt_imx2.c b/hw/watchdog/wdt_imx2.c index 891d7beb2a..6452fc4721 100644 --- a/hw/watchdog/wdt_imx2.c +++ b/hw/watchdog/wdt_imx2.c @@ -234,7 +234,7 @@ static const MemoryRegionOps imx2_wdt_ops = { static const VMStateDescription vmstate_imx2_wdt = { .name = "imx2.wdt", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PTIMER(timer, IMX2WdtState), VMSTATE_PTIMER(itimer, IMX2WdtState), VMSTATE_BOOL(wicr_locked, IMX2WdtState), From patchwork Fri Dec 29 21:23:37 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758829 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672069wrw; Fri, 29 Dec 2023 13:30:30 -0800 (PST) X-Google-Smtp-Source: AGHT+IHWzf9W/7mh61944datkaw800hXXDdks2+7rq72wYyDxrcT6kepgNY4UrP90GfQrLcQ4YKm X-Received: by 2002:a05:622a:1745:b0:425:9bac:caae with SMTP id l5-20020a05622a174500b004259baccaaemr19986926qtk.99.1703885430191; Fri, 29 Dec 2023 13:30:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885430; cv=none; d=google.com; s=arc-20160816; b=NIy0JvAam1FOT7ri9c8IXSkgNEX354JXfloRJPcFMtcxosA97yQIy5YwEbZgZXTpLR taWyk32tcdfJiFYvuF9Gc4hfvgx5qeSMio/Jhr0Wpa59NwJJz9+SJOg1BkBujGy0USFy Px4dpQ0moA3uvubR81gmzTa3UFiSpYAMjZWgzJssaYrAdU0NdlVH4/+YkjzbPv4JV5SS VusLEPlWyqeosNPmvzTCoG4Sgi6EJyB3l5X32TKXuCHTIVriGJR2lx0+2Pk9cfYeYlM4 Rfi9x9O7qF9O2SCEXD+oLRYxfRroagZhB309VeEvCSomFZK4ure4564NrDQNmIQKpCMP 7O8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=yMiyXLSoDy5ZHKBGF4zdLgoSUDciZZMKn07QJW7rkcw=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=xFcKHkdTEnL0h4N1ahuz7J+x1DPGBPhJ/Nr7VAmV4hk/ek0wVFIBSV9H4mBV5BITaW H+QXN159l0X8VrMmxdT7zySYrp58gvdCR2iXOfQvzyaMbqHjbYSKCqPd8jBjt17tnB+w tMrFqm9kTKQvYRuxH0V0CzkfgU7sRLAax03TNn4o9LISdVwMKp4wf0cBsjFiVtcExCgj kwsezbN2S/0iGXBbwZAlDGUgwM5QbR/EPSDADdwAh5jqZ0ZPfcN5YF1TXoMK5BVr+VE5 K9zsXpLsGma7NH/YLfr0DN2a78Iklxsu0lpFCBM/mF8ToFl8I7eT1bcMeFIN90uvoL5+ iuUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="NU2uL2j/"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c22-20020ac87dd6000000b004280957e09dsi1509404qte.298.2023.12.29.13.30.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:30:30 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="NU2uL2j/"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQF-0000IZ-RW; Fri, 29 Dec 2023 16:29:39 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQ3-0008RZ-GL for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:32 -0500 Received: from mail-ot1-x32b.google.com ([2607:f8b0:4864:20::32b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPx-0000OZ-Nl for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:25 -0500 Received: by mail-ot1-x32b.google.com with SMTP id 46e09a7af769-6dbfdb41a63so2432553a34.0 for ; Fri, 29 Dec 2023 13:29:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885358; x=1704490158; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=yMiyXLSoDy5ZHKBGF4zdLgoSUDciZZMKn07QJW7rkcw=; b=NU2uL2j/VxUsTC4Fnq33gPRnn+UUjwGv3WsibgZ9+2IhJNf5ttusqVj8aHBtGfNuT6 8rwB8KaJ4sUNdDCi7RI0VWjC6HeMzBIEO/JKg1U22SEY+A7uzNaG68e2O9nYSAMeR488 WJUQLHoBdXoKZ4eEMTFZVW1EM/VMtroVwHrlIHkBH0mjNIfi3MJrN/uINeg1CLX7S5vU /qlwrlYS9vi0VFw5yjXr748UGEtaia4onAJxUUGp96BjpRSaDVksH7XEf92KxUX/lqhy QsqLQ3MxtuYSZqVi1G9NVfXb3pZ71oKVquAsM35YGqvKsqgmePErrU+wxivNlZ+L4A4B UNvw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885358; x=1704490158; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yMiyXLSoDy5ZHKBGF4zdLgoSUDciZZMKn07QJW7rkcw=; b=LaZuDNVBh3lUWT9+IhswROXJfd/eR1HYWe0f9btPlHs6L9YHC7ASEksYun6oy/ZR/u JiVnUInelPKaNpvdKQKG7+o/Er+vOPckTH1OlWV1pHclZH3UDl3QlqaYT7j/xKTMPc9f NZKKJ7Vmy4CDLIXIECACS2owNw+vaVPq/5Ymw9f1v4E9XGmIELzFIrtZDtWVpVdYu5uu rByIh376/9koT9kGNsUGlDucA00P1o8la1UDrzwBoWIbfVKds0OPBr+VzpDMiPsRY6WO gg2HK0OXFPL7BIMZ2/oEzSRvFD4uHOkE9CSK4fpgOefURk968JN1OH46du3Jm/zw9+7Z zzfQ== X-Gm-Message-State: AOJu0YwHbrprFKkjEJstYuvbGKrC6jQDLTHcIHgG4wgaY0YaGnMIAT+R pMnI82KwxK7aBWqT8vKA6yCJlUphbtLoHqJ2l1y5pEdW5RAIrg== X-Received: by 2002:a9d:7412:0:b0:6db:b1b1:769f with SMTP id n18-20020a9d7412000000b006dbb1b1769fmr9665672otk.27.1703885358383; Fri, 29 Dec 2023 13:29:18 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.16 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:17 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 62/71] hw/misc/macio: Constify VMState Date: Sat, 30 Dec 2023 08:23:37 +1100 Message-Id: <20231229212346.147149-63-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::32b; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x32b.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-63-richard.henderson@linaro.org> --- hw/misc/macio/cuda.c | 2 +- hw/misc/macio/gpio.c | 2 +- hw/misc/macio/mac_dbdma.c | 8 ++++---- hw/misc/macio/macio.c | 4 ++-- hw/misc/macio/pmu.c | 6 +++--- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/hw/misc/macio/cuda.c b/hw/misc/macio/cuda.c index 6336dcb194..41934e2cf8 100644 --- a/hw/misc/macio/cuda.c +++ b/hw/misc/macio/cuda.c @@ -487,7 +487,7 @@ static const VMStateDescription vmstate_cuda = { .name = "cuda", .version_id = 6, .minimum_version_id = 6, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(mos6522_cuda.parent_obj, CUDAState, 0, vmstate_mos6522, MOS6522State), VMSTATE_UINT8(last_b, CUDAState), diff --git a/hw/misc/macio/gpio.c b/hw/misc/macio/gpio.c index 4deb330471..549563747d 100644 --- a/hw/misc/macio/gpio.c +++ b/hw/misc/macio/gpio.c @@ -168,7 +168,7 @@ static const VMStateDescription vmstate_macio_gpio = { .name = "macio_gpio", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY(gpio_levels, MacIOGPIOState, 8), VMSTATE_UINT8_ARRAY(gpio_regs, MacIOGPIOState, 36), VMSTATE_END_OF_LIST() diff --git a/hw/misc/macio/mac_dbdma.c b/hw/misc/macio/mac_dbdma.c index 80a789f32b..2a528ea08c 100644 --- a/hw/misc/macio/mac_dbdma.c +++ b/hw/misc/macio/mac_dbdma.c @@ -807,7 +807,7 @@ static const VMStateDescription vmstate_dbdma_io = { .name = "dbdma_io", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(addr, struct DBDMA_io), VMSTATE_INT32(len, struct DBDMA_io), VMSTATE_INT32(is_last, struct DBDMA_io), @@ -821,7 +821,7 @@ static const VMStateDescription vmstate_dbdma_cmd = { .name = "dbdma_cmd", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16(req_count, dbdma_cmd), VMSTATE_UINT16(command, dbdma_cmd), VMSTATE_UINT32(phy_addr, dbdma_cmd), @@ -836,7 +836,7 @@ static const VMStateDescription vmstate_dbdma_channel = { .name = "dbdma_channel", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_ARRAY(regs, struct DBDMA_channel, DBDMA_REGS), VMSTATE_STRUCT(io, struct DBDMA_channel, 0, vmstate_dbdma_io, DBDMA_io), VMSTATE_STRUCT(current, struct DBDMA_channel, 0, vmstate_dbdma_cmd, @@ -849,7 +849,7 @@ static const VMStateDescription vmstate_dbdma = { .name = "dbdma", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT_ARRAY(channels, DBDMAState, DBDMA_CHANNELS, 1, vmstate_dbdma_channel, DBDMA_channel), VMSTATE_END_OF_LIST() diff --git a/hw/misc/macio/macio.c b/hw/misc/macio/macio.c index 265c0bbd8d..c9f22f8515 100644 --- a/hw/misc/macio/macio.c +++ b/hw/misc/macio/macio.c @@ -376,7 +376,7 @@ static const VMStateDescription vmstate_macio_oldworld = { .name = "macio-oldworld", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent, OldWorldMacIOState), VMSTATE_END_OF_LIST() } @@ -396,7 +396,7 @@ static const VMStateDescription vmstate_macio_newworld = { .name = "macio-newworld", .version_id = 0, .minimum_version_id = 0, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_PCI_DEVICE(parent_obj.parent, NewWorldMacIOState), VMSTATE_END_OF_LIST() } diff --git a/hw/misc/macio/pmu.c b/hw/misc/macio/pmu.c index 58316d1871..e9a90da88f 100644 --- a/hw/misc/macio/pmu.c +++ b/hw/misc/macio/pmu.c @@ -668,7 +668,7 @@ static const VMStateDescription vmstate_pmu_adb = { .version_id = 1, .minimum_version_id = 1, .needed = pmu_adb_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(adb_reply_size, PMUState), VMSTATE_BUFFER(adb_reply, PMUState), VMSTATE_END_OF_LIST() @@ -679,7 +679,7 @@ static const VMStateDescription vmstate_pmu = { .name = "pmu", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_STRUCT(mos6522_pmu.parent_obj, PMUState, 0, vmstate_mos6522, MOS6522State), VMSTATE_UINT8(last_b, PMUState), @@ -698,7 +698,7 @@ static const VMStateDescription vmstate_pmu = { VMSTATE_INT64(one_sec_target, PMUState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &vmstate_pmu_adb, NULL } From patchwork Fri Dec 29 21:23:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758855 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672866wrw; Fri, 29 Dec 2023 13:33:18 -0800 (PST) X-Google-Smtp-Source: AGHT+IHTFhCA6C4BD6iRjoXq3L230x7wsWPtlMgIdx1RUaEvPMYdrRJE4VkKCXQcx4lWEumgU3lF X-Received: by 2002:a05:6808:f16:b0:3bb:d1ba:e7d0 with SMTP id m22-20020a0568080f1600b003bbd1bae7d0mr3690150oiw.96.1703885598012; Fri, 29 Dec 2023 13:33:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885597; cv=none; d=google.com; s=arc-20160816; b=q/S6DCpVy/6CbgQ5733IBNZF2y6Rms/t62JqgS2ZxRE6gmLkd2598cCTCF9p6tj6pD CYaDwpbwb4I/jRHfzluMWghAQvWScFmLYFMlbhstwL73dWdp5RMgH1Znsyq9aGkRQN1O ngPWYJ7x/197/gp4asI3qOVs8V7uzHPdhk2EiGcrlNthMFYf/RGLvRt2MO33Hw/K9Nv6 vlVpw4VwnYXQZvwYq/ZoKGGfTdNgLh7j/ZxDNOxNfo+lMxeSL8xqNh6IAb+uXBn6zeeS w3aDjGpEs61C+cuJnncrSBYK1vGGCtl+40gT7BPbx4Yp0tgnfHgv9fcu1TrNvsJ3aJuJ guJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=ygcgPh+qdF+j3UM+Oeu3tve2dul26F15sx2+x6giXog=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=XLR3oCVEwWnJPCrYGWmginHHF9z2wBIcIQj7mepdpI9Cm3cyAieT5B+uhNe+3N20G/ ft+vP6e8SXrEwS1MqBWJj/LO0sGfE2NKtpPfiGmBw6i9gbZx+BZUYV+sr/9LS3UIuvKC MVtpso80AiX9Vb3EcCVacl5IGNseGHvYflv/+WhxoxV0dJW+TL9euIBGM6SP8mArQagH vcTQ4wLSfi1b9XE5HKT/+2KeUxq0uZYIRlk2em2LuFu/eFN1CdJPYtHb1bIgLMoy2K7g C1icd+XxviuHuJly00OlXiG5tmqMbf9nK2nT7FuGob4/bOb8+3n6bdM76FC6fXO2kIuO ce5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Z8VjfRxM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id a18-20020a0cb352000000b0067fab51ad01si16053680qvf.186.2023.12.29.13.33.17 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:33:17 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Z8VjfRxM; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQJ-0000ug-Un; Fri, 29 Dec 2023 16:29:43 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQD-0000BZ-Si for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:38 -0500 Received: from mail-oa1-x32.google.com ([2001:4860:4864:20::32]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKPz-0000QA-Bf for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:37 -0500 Received: by mail-oa1-x32.google.com with SMTP id 586e51a60fabf-2046dee3c14so2357689fac.1 for ; Fri, 29 Dec 2023 13:29:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885360; x=1704490160; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=ygcgPh+qdF+j3UM+Oeu3tve2dul26F15sx2+x6giXog=; b=Z8VjfRxM1+1PkLu4vyjI1ZsF9WSk17/rBE/Kld3rVku3CbBtJNsxpX7JS5FGeCiqGm 4IQxcUaFUkNDMrI6HKofzvg5YL0a/i/a9qGGiV+9eZOFRRJO67dhCpqKXHoS0js744vx XjY++KoVLRID4Ve4gAGQ8XOOHOOuAO0HiVuIoXQS/J3ThYC6INrBmkCrzigeqC+5zqRp yZG0kRgOvFAIOBtsPE85sbcmPXHNb9HeLh+kcPv5LxX25IFbT6UlmOdj0xunbiJtVYaA WkJW2LxTD+58A4cJV2JbbOY5uYQAq/YCJaoCAANsVFG+GMJZ3HNv1/fwdEZvN85QSELy l9AA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885360; x=1704490160; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ygcgPh+qdF+j3UM+Oeu3tve2dul26F15sx2+x6giXog=; b=amsolLofWPxZiDxkID0UNwD6ZYpqriuQ92uY8MeHfALoYkvhbo0K/hrkd2pghgOc9O O/fs62UI7KUD5Dh8qJp4yPvYSGcv2wdzqrOPJ5+rFgdZKG7Tt8prxDeOpKw5BGPvfCPv L7novQqZBt5nmL892T1E8l5/FA40Frzph17LJUECcqOavuQcNJbYld4Vazv9dsAoeQti jCIFyrOaMlyTbTBeHoumdBRRRkJKcmhcZvBYBE/K+UqnfrBKiCDk0CQm0sFpXa2Fn7dk sUqdFYS94wHvxPsfAXDFLQV0QAO0WFi7im7GHmlH/VnK4zUZJppYpmiR2mwBheBg407C MkFA== X-Gm-Message-State: AOJu0YxHo00pmB+HRbkGwK9jHWfacRyqNNV+V+OmL1gaN2Ov73wyiLVS UURAEkTAFUVklLQBu/yyFyBa4mYEMW393VH17Ylybx2GhEsMYg== X-Received: by 2002:a05:6871:588:b0:204:8d0:9993 with SMTP id u8-20020a056871058800b0020408d09993mr11150045oan.77.1703885360429; Fri, 29 Dec 2023 13:29:20 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:20 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 63/71] audio: Constify VMState Date: Sat, 30 Dec 2023 08:23:38 +1100 Message-Id: <20231229212346.147149-64-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::32; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x32.google.com X-Spam_score_int: -16 X-Spam_score: -1.7 X-Spam_bar: - X-Spam_report: (-1.7 / 5.0 requ) BAYES_00=-1.9, DKIM_INVALID=0.1, DKIM_SIGNED=0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-64-richard.henderson@linaro.org> --- audio/audio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/audio/audio.c b/audio/audio.c index 8d1e4ad922..a1097bb016 100644 --- a/audio/audio.c +++ b/audio/audio.c @@ -1683,7 +1683,7 @@ static const VMStateDescription vmstate_audio = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_audio_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_END_OF_LIST() } }; From patchwork Fri Dec 29 21:23:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758852 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672563wrw; Fri, 29 Dec 2023 13:32:09 -0800 (PST) X-Google-Smtp-Source: AGHT+IGVCMBHSO1jIRXvFCPtWJcmKlCRXQuEhuAm3TpiTKAA7OBddwSFkJlkNxMS1Yo1n/tA/Aji X-Received: by 2002:ac8:574e:0:b0:428:9d1:4046 with SMTP id 14-20020ac8574e000000b0042809d14046mr1240776qtx.95.1703885529255; Fri, 29 Dec 2023 13:32:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885529; cv=none; d=google.com; s=arc-20160816; b=fR1EFbrT+scFO6IZYpHTH9qQOKENefs07qE626Ex93tVpWWSiR+7tDx2uCiHtkodRl I13sT0jXxa9qEYhPZ8VUTKJtL6j6sGonMjEpYiDT5bcMt/f1hb+obBxF0SItWK5FUaKz PX7VRZleEbYU+DJM5wyuGLir6RVapwITMgFQOPN4SJt1DK0cq6ruPgJQG/f2O+XgKpMb iGxDux7GE9e1PJF02kj7BN87KQMf1lJSvczxojWxUuI1418ox5KACkh3GXrpl05ErthG pPeMzSvrZ4G3YbuWCDfP0UVJ4YIRUUWvmSNUzWO1Hdi+3168gaRl3oousjeWwSGHN4vw p3IA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=fgC12UagrksFWuSMkuP25mZZ0t/ZqvQsDdnKNN0TPhA=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=EbAfnEAaWwagtDgJscdEjipg7LEi99wVwdWPOgR4h56R2GtqatPEhqbJA5CygjstCj SaC4GOU7CF9NEj+wnxRuO6eMgd3uqi64b1332RPfeIxpE/QK+51A1wSWW7SYtACcBUbV XD1wPOlsmii7ZP8tOQ3VoWhZTrpKz3ULlZHFpM2wtrmcSFyQIJnU1dNQFDLdDIQetHVF o6Msw3aPRvZGk0S6So9dg1dSL1MThgipI1o736ni+oLry2csOQYSPADwvxkpa2hpyMVi bHNIFN4YRBz5rkCpCHMfCmdF0Xu3TWDWYQyzkXB4LRCstMTiC0wQQXgtQgYZDI6f3LoM 1RHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BRoOhXpH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id v9-20020a05622a188900b00427fbbc380bsi3895545qtc.560.2023.12.29.13.32.09 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:32:09 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=BRoOhXpH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQI-0000fB-5o; Fri, 29 Dec 2023 16:29:42 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQ3-0008Ra-GW for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:32 -0500 Received: from mail-pf1-x434.google.com ([2607:f8b0:4864:20::434]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQ0-0000QI-20 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:27 -0500 Received: by mail-pf1-x434.google.com with SMTP id d2e1a72fcca58-6d9aef87d44so1519464b3a.0 for ; Fri, 29 Dec 2023 13:29:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885362; x=1704490162; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=fgC12UagrksFWuSMkuP25mZZ0t/ZqvQsDdnKNN0TPhA=; b=BRoOhXpHRovmbqCFZardOMWC3OpJkyi8x3upaXOFYzDSFL5RMDu5nam9mzMMluOvtw E6Vf9gsePRCdx+/PiC3C6LJApBZWlrOZcya+PIQaInUL+SjQ8jzzD3wDeCFLJdfCHmjy jM+tkab6BZeEI9wohGQuqQQkQ+Pmkt9ityqV4x0QM43l8TmiJa6yTHkFsxA2b+PXW+Vh 2e57gBcLUCDWxhkZwsDGly5IQAsjLkQZY1j6uHgL37rvBnRTw3yX+DRYkIfoILE8fHIb 2VGwwWraWrpftdtRdEQmbw3S+53QdYnOvv5Gx97qsclPSoFmYV2HWNwhl2712VSNA54+ Ow+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885362; x=1704490162; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fgC12UagrksFWuSMkuP25mZZ0t/ZqvQsDdnKNN0TPhA=; b=txjgqzN7J4hhVBMGlrR6Das4dTP74tWeUTLhSxuQ70ZB7GALYltpu+HPnoGAsyN9H6 2Hn6dXWakfqOQvfdxog3F3GvR1FCiTAggbIGuby1egpQOfKBBho/5TkyMXwKpw6mgBTy Qg337Y3GBUy0MeGbj4aAy+DXQlkN9XYLI+2K27eWbFYu+ytlyV/fsA6nP2VYQCN0UtmH Xe94Vd9+mjZTq1Nsr3YeXeievMyRXHa1EYIDNaucyhN7TX9ufNIQhzPIdbqIOw64K/ji koS8t8S5DLg6DhZiVdAwrvNYVTiQCzQ9BV0uZW8+uAnu/pmO0UrmjPlKornqqKTk5GDn ONIA== X-Gm-Message-State: AOJu0Yw6nBxmztksiN/KcrfCgCSniFjJJlgKSgl18p2VmjT4J6wq6Lcb P94MMPqJatLhcD6b4Tq951UUGbHLYh4bL+bZsIIm0lkljl6awA== X-Received: by 2002:a05:6a00:22ce:b0:6d9:e9ea:cfc8 with SMTP id f14-20020a056a0022ce00b006d9e9eacfc8mr4713639pfj.16.1703885362693; Fri, 29 Dec 2023 13:29:22 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:22 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 64/71] backends: Constify VMState Date: Sat, 30 Dec 2023 08:23:39 +1100 Message-Id: <20231229212346.147149-65-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::434; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x434.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-65-richard.henderson@linaro.org> --- backends/dbus-vmstate.c | 2 +- backends/tpm/tpm_emulator.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/backends/dbus-vmstate.c b/backends/dbus-vmstate.c index a9d8cb0acd..be6c4d8e0a 100644 --- a/backends/dbus-vmstate.c +++ b/backends/dbus-vmstate.c @@ -393,7 +393,7 @@ static const VMStateDescription dbus_vmstate = { .version_id = 0, .pre_save = dbus_vmstate_pre_save, .post_load = dbus_vmstate_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(data_size, DBusVMState), VMSTATE_VBUFFER_ALLOC_UINT32(data, DBusVMState, 0, 0, data_size), VMSTATE_END_OF_LIST() diff --git a/backends/tpm/tpm_emulator.c b/backends/tpm/tpm_emulator.c index f7f1b4ad7a..ebdd2e0a69 100644 --- a/backends/tpm/tpm_emulator.c +++ b/backends/tpm/tpm_emulator.c @@ -939,7 +939,7 @@ static const VMStateDescription vmstate_tpm_emulator = { .version_id = 0, .pre_save = tpm_emulator_pre_save, .post_load = tpm_emulator_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(state_blobs.permanent_flags, TPMEmulator), VMSTATE_UINT32(state_blobs.permanent.size, TPMEmulator), VMSTATE_VBUFFER_ALLOC_UINT32(state_blobs.permanent.buffer, From patchwork Fri Dec 29 21:23:40 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758835 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672228wrw; Fri, 29 Dec 2023 13:31:03 -0800 (PST) X-Google-Smtp-Source: AGHT+IHE7Wq+/mDJxzSDQaOP8OZNKAlzFTI+bO+wlsA1L1gKbqawyxP7FUy4Vu53UKgRr4jbqe+1 X-Received: by 2002:a05:622a:14cf:b0:425:8fb6:5f74 with SMTP id u15-20020a05622a14cf00b004258fb65f74mr18942041qtx.34.1703885463089; Fri, 29 Dec 2023 13:31:03 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885463; cv=none; d=google.com; s=arc-20160816; b=xcT4m7KePI4rENZoCpOqXriRY6NIqwbpaDXMSRgpz26s4zrFbB3U4FRKY/BZIhHeP3 Sz9InBgSlF+7jbzMIhKO94PqGujBxPmhUord+IHYVPnnsSYfWVeh2IxOZhN5HdScTA7V pFolwwqPes/kiTlCIXD/b0V4mLsTd1NkMzuind0LV2wubKY4q90f3ZyMECc+Uvxt/QIN DiwqNkQqOZYuWJnpmrBcfgd15+2xiJTqvPAan4fvIPn2bSWeUfXB5HgBA2QljQwBUxi3 ZjEtGpHfHyybXU55KDakl6OqPIEP8ulMI+XVruwvDNK/f0pJEyUqMsWfuTbvdVdgaYnk FHOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=hi1W/QRtc07jh63VGtl4+gPGbFgx4yL88GoyzHH2HjY=; fh=50e5w3+W6SHHNE+06M/ShWWkYgFcpUwndl6hLiFb1X0=; b=qTQDvCQdy0bgvnFCJRlMxz8tOqImVaAtjgifEMJnO/s6b6hryE9JQhMp800dzCh8ZQ X44TfBsr79aTdlQYXf8cp0e/2IFFhpbZgL1gbQcEU9zaDkpNGDfU3hdCHfCwqSmjUyeo R1K+eQmMkxXHcF73ztbixfmwiTTw1bLph06oeB9Q2iInM5JhuQnVqrHBqm37RApAc+6e Ukio0R/FYe7y2ocezcOPBo2heMQD4rYbVVS+FSGn4frQ1R+3YGep3ZATs6p7coumuzyK Yw3PVq83PvtZ2q5HkIMjZDWrAuuxGmluN13S8ASdE2z/L4lip0ODWUcBcJhMMdsFk7Kr 1yGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=OBCITQaH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c20-20020a05622a059400b00427e7974452si7562209qtb.719.2023.12.29.13.31.02 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:03 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=OBCITQaH; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQG-0000Qv-OJ; Fri, 29 Dec 2023 16:29:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQ5-0008Rb-CV for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:32 -0500 Received: from mail-oa1-x30.google.com ([2001:4860:4864:20::30]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQ3-0000QZ-8l for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:28 -0500 Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-204f50f305cso1240900fac.3 for ; Fri, 29 Dec 2023 13:29:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885365; x=1704490165; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=hi1W/QRtc07jh63VGtl4+gPGbFgx4yL88GoyzHH2HjY=; b=OBCITQaHTc8rHRDQa4p7NZWESC+VdVq9J4MEX1osJBzz7uY3gr00dsriqUbIktyB0K xpMNwda2pxhXWSxWvJ38XS6sJWgoWLm9i6q4ufSuHKj5yV/FgJUFZVPfNArv53t9NYnW FW+K+PwTkkvk46rAPS5eOOTdDwQgY9g+NURRrdgtCTK+SQSisPOLcM7/8m28d5JFJDun 1UpDFocu9ECbEleXKPijaBQrqlnSXenXMfjajvZTr3XD3x0tbWRUK8socQEEK38Q+7F4 wsPmWsd6vBehQtKywmUxFSXhhxd/784mTwAfQJl0A6BNOWmDoYn5Ljq2lwwl4zTpCmS3 jUbA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885365; x=1704490165; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hi1W/QRtc07jh63VGtl4+gPGbFgx4yL88GoyzHH2HjY=; b=c5KgCt5Dix2qNUlOOeGz5LRVkNtbHxfss4bInrZwKfXOtE2yoPh2h0XkPZRqEsZF9S KXTslUqPZIvRcYwKSy2HLDesK1GPp29J0LjgFLROyH3LWSp8zFmA8Tivi6aQlM059N7t nZrRkdCISTfa8LxirQqM9hi62FKYpHZB5GAcARVFf5BjC01Ntu+96+k0dLcWEPAO58xb nIbKGNcG/b5RfJFTxPaj+Tv4pAb6btgZ89LGkazsSnSUMisitmTUsCyx2MP8p0KXhzw0 20p0uQfVYPoPxWkjqWZzbSovN7hnpw7uGcRz98Kukkc0YZz6fVCQlcyAOXsutvNkk+7Y xIhA== X-Gm-Message-State: AOJu0YwX/b0vvj5tRrKkAUZwUqoS4Qwu+yD0En/wc52Z5oAIypfDpQc5 u/yNBuJ6SmeYVnbh7Ull02bPCYhJx4doCd1KYmyESNfrxDAJdA== X-Received: by 2002:a05:6871:588:b0:204:3f62:a8a0 with SMTP id u8-20020a056871058800b002043f62a8a0mr13359299oan.71.1703885365255; Fri, 29 Dec 2023 13:29:25 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:24 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Zhao Liu Subject: [PULL 65/71] cpu-target: Constify VMState Date: Sat, 30 Dec 2023 08:23:40 +1100 Message-Id: <20231229212346.147149-66-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2001:4860:4864:20::30; envelope-from=richard.henderson@linaro.org; helo=mail-oa1-x30.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Reviewed-by: Zhao Liu Message-Id: <20231221031652.119827-66-richard.henderson@linaro.org> --- cpu-target.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cpu-target.c b/cpu-target.c index 508013e23d..430dc53566 100644 --- a/cpu-target.c +++ b/cpu-target.c @@ -87,7 +87,7 @@ static const VMStateDescription vmstate_cpu_common_exception_index = { .version_id = 1, .minimum_version_id = 1, .needed = cpu_common_exception_index_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(exception_index, CPUState), VMSTATE_END_OF_LIST() } @@ -105,7 +105,7 @@ static const VMStateDescription vmstate_cpu_common_crash_occurred = { .version_id = 1, .minimum_version_id = 1, .needed = cpu_common_crash_occurred_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(crash_occurred, CPUState), VMSTATE_END_OF_LIST() } @@ -117,12 +117,12 @@ const VMStateDescription vmstate_cpu_common = { .minimum_version_id = 1, .pre_load = cpu_common_pre_load, .post_load = cpu_common_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(halted, CPUState), VMSTATE_UINT32(interrupt_request, CPUState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_cpu_common_exception_index, &vmstate_cpu_common_crash_occurred, NULL From patchwork Fri Dec 29 21:23:41 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758841 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672333wrw; Fri, 29 Dec 2023 13:31:23 -0800 (PST) X-Google-Smtp-Source: AGHT+IH6vLAENEvs+7bI2/m6LVZUqkrUx8fecWkH7u+BhLEzkRQZaJdmCXpFU3ysUzUlos0o/0s2 X-Received: by 2002:a05:622a:202:b0:425:78fc:446d with SMTP id b2-20020a05622a020200b0042578fc446dmr17705804qtx.29.1703885482969; Fri, 29 Dec 2023 13:31:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885482; cv=none; d=google.com; s=arc-20160816; b=Aw+2r2PiDZsRNnlZTWS4gYz1QjMi1qbmb1CQTb1Alf5FOaAHh0BXCF7GpCHYGf/5My oogkgxZhEh1TKDutNyW720fQ93wt+hgkYStfr0bpJbIdvaLd1WpiZaOd1qYvJ0Ed/v6I OD1M2z9Vob2BiM+dJmuGDUlzXCXZdybom6jY+wt4O5PNRKjkwgdFDJjmZwjbq9owx/cR PMZZUcSZXO54VNK65vNgbpryhws3nVT4erE0GkdHH7Pap3sLpTAIKH03miCL5ZhrYpbH PHRtghBa24L3Aclv/DBac4Yr9XEvFiODJlqxdjr0AmUyJWZEttJY6FlLuZzZynH0F7ST 2Ogw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=K5Dr0gvZkgxAFIFd99X2103QipE5kAtlXBBE09Dt2kw=; fh=mwvDHFN5agD7OubUR/beMfLQeIMTgcU04wMZItNAU1M=; b=dACpZaI21dzf9lbehS47NiCGoKZ+xJrkrwSzKnPKv6qwfBg2f88WPJyjNnrch0WyPh uUgKm4bmoMEc18p3RR+x0LbtG65UCAVgmeeebctOay4ajOgSdATbT/LWkBV5+wU4ypq3 GxPgxfpJySjjjIvmq3Mh/4Itb200Sd8zL4OjddyDSQCVY+27G17EKHnz3tEbRiqilTR6 msjOfoqwsVRIJ3iiOdYJGYHOxSJ+Hs+Kgs5uZk0TBTyCZegn1u0drqyxQsSOBHPPIRLZ 0P6eV2DHxt3YoAIQALsRBZF8P8Y1BGykJLEVhW81hMTeCK6z5+KFPkhgxvwNmvFBn/4U 4qpA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=arRmigMo; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id r13-20020a05622a034d00b004280329c06bsi2558806qtw.118.2023.12.29.13.31.22 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:22 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=arRmigMo; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQF-0000FW-2Q; Fri, 29 Dec 2023 16:29:39 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQ9-0008Tp-7Y for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:37 -0500 Received: from mail-ot1-x333.google.com ([2607:f8b0:4864:20::333]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQ5-0000Qp-KV for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:31 -0500 Received: by mail-ot1-x333.google.com with SMTP id 46e09a7af769-6dbff975a2aso2216254a34.2 for ; Fri, 29 Dec 2023 13:29:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885368; x=1704490168; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=K5Dr0gvZkgxAFIFd99X2103QipE5kAtlXBBE09Dt2kw=; b=arRmigMo2ANGmQj9Na/5HTFJL3myNhe96LTSK7+S2npekjxWN1VKmeEXire8cxZMJU WcogBwGcyHDbhuoPJlUZLu675uSn9sDVjxmZ/iv4xlggU3lH9N9hn/AycAmcLXozjWgF QCyVyAPku0GgN48OrLI870OUfRPXIz4EypGHZCKdYChEnI0JfXSzhIw58iuHvC3laOA7 d1YBv2AYY/7KKEYUk2rGc5vbF84t8XQWYylysD9EJyCjJuHd2hWyftDTgxDrgPkHbRkf xxOlK0im+Wzx9e7/uQA2/dzQDzdl9DhPo18hL/Uj9M2rjFHEg3cQyvegfRRTA0Vgedrk iXYA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885368; x=1704490168; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=K5Dr0gvZkgxAFIFd99X2103QipE5kAtlXBBE09Dt2kw=; b=PlwkJdM5Iutwfz5yoCQWkJr7P6evGgzpZqMh9raiRf4NIPMVOjNYJuvwqDH7Mn5B77 gf9peF3evFDXFZ5km8stYTgiGVfpxftUNJSHwwrPs3PuydmsDPHg8dA2wEN4ibBP4/R3 zFQOUj7zCOBmw+WsRkd7rp8sEPsX+r1mqQvtPsb+Xm/3vWSmQOv5On+7FcBAKheZPTmO O2SsUXhy0AlrJOozeJPdNFJGVXJFck3EFSj9K70SAUDTu9/XOgQ2mFUoEZoFROksdc9m y47G1IZjOLhpQDPcG/O5c3bKg0L0Y7705T6sWaJsFqeevOE7fiypA24IGHNbefBy9TEN XkZw== X-Gm-Message-State: AOJu0YwjBoK7pn/pfwWAp8AorgqPwIVErevO2pjw08cS0H/x1HxzCcSf baqYHxmE9QII96oKRWgOQ0zP4U/Xw3lU2jleY0vd09u9d+4Vpw== X-Received: by 2002:a9d:63c6:0:b0:6dc:386:a263 with SMTP id e6-20020a9d63c6000000b006dc0386a263mr4415143otl.51.1703885368601; Fri, 29 Dec 2023 13:29:28 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:28 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Juan Quintela Subject: [PULL 66/71] migration: Constify VMState Date: Sat, 30 Dec 2023 08:23:41 +1100 Message-Id: <20231229212346.147149-67-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::333; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x333.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Juan Quintela Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-67-richard.henderson@linaro.org> --- migration/global_state.c | 2 +- migration/savevm.c | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/migration/global_state.c b/migration/global_state.c index 4e2a9d8ec0..8ee15dbb06 100644 --- a/migration/global_state.c +++ b/migration/global_state.c @@ -131,7 +131,7 @@ static const VMStateDescription vmstate_globalstate = { .post_load = global_state_post_load, .pre_save = global_state_pre_save, .needed = global_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(size, GlobalState), VMSTATE_BUFFER(runstate, GlobalState), VMSTATE_END_OF_LIST() diff --git a/migration/savevm.c b/migration/savevm.c index eab62330b6..c8d08fa079 100644 --- a/migration/savevm.c +++ b/migration/savevm.c @@ -438,7 +438,7 @@ static const VMStateDescription vmstate_target_page_bits = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_target_page_bits_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(target_page_bits, SaveState), VMSTATE_END_OF_LIST() } @@ -454,7 +454,7 @@ static const VMStateDescription vmstate_capabilites = { .version_id = 1, .minimum_version_id = 1, .needed = vmstate_capabilites_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32_V(caps_count, SaveState, 1), VMSTATE_VARRAY_UINT32_ALLOC(capabilities, SaveState, caps_count, 1, vmstate_info_capability, @@ -499,7 +499,7 @@ static const VMStateDescription vmstate_uuid = { .minimum_version_id = 1, .needed = vmstate_uuid_needed, .post_load = vmstate_uuid_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8_ARRAY_V(uuid.data, SaveState, sizeof(QemuUUID), 1), VMSTATE_END_OF_LIST() } @@ -512,12 +512,12 @@ static const VMStateDescription vmstate_configuration = { .post_load = configuration_post_load, .pre_save = configuration_pre_save, .post_save = configuration_post_save, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(len, SaveState), VMSTATE_VBUFFER_ALLOC_UINT32(name, SaveState, 0, NULL, len), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription *[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_target_page_bits, &vmstate_capabilites, &vmstate_uuid, From patchwork Fri Dec 29 21:23:42 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758839 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672310wrw; Fri, 29 Dec 2023 13:31:19 -0800 (PST) X-Google-Smtp-Source: AGHT+IFGn52rwwq8+5+Q9rjKiVhdrdZ5UX8KaN1zLZCQSk4kO45SmXwbdQpBobky9Nk0BGRSelp5 X-Received: by 2002:a05:620a:45a0:b0:781:37b7:edf0 with SMTP id bp32-20020a05620a45a000b0078137b7edf0mr13603680qkb.5.1703885478807; Fri, 29 Dec 2023 13:31:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885478; cv=none; d=google.com; s=arc-20160816; b=wmxGbGuUKInICClAH297KsTV2mZ+OtnmlWVTXWseIlBSwFGNoin4DI2kzbGzYKFYtV iKuKeJo4HDB7HwK0YWLI5uFHIqIPS8Dg1WKp36EqQA2NcHhaQBGYFt6PelYnsvsR8jbG DsYQXDgf3J79MHg7XaKbko/tmg0J0ZHSQutjmv9fBMJDKRxNP756Xc1/IHvKNt7HVLNn B5GQ00lFq+v4hv32JcJ4PUUPi2Ry+vvAiVVwy53EQz4szjpugdrkt1/A2Y8BF4PZcU6I thk1trO+Q7T1qu5k+wnoCgSvxUf1DuODxyj7Cnme5bTht7RtHFDxnNR88Bc/cmpyXD5l bjqQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=2Y5DZJN4hv2XQe15PGcXdVWgl56bQTxp89hl5EeXrWM=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=U457VAFmhyYH6vIxYX3TgqfvLlO2j9lmg2f9nzCPUfdi8pkLtJXx5LU6mOKOjxxm3h caELA2r+1yJpI05IDwhj4xBwIzx4uHr3xkZQECg5oNhV7NBHM3I8DjJWzuEne7x8H2wh EeL4JykbZ5PJumxY7hIC6zOYLzsDrZItw4kFoxNs2po3WQisGhcrF8xY2xoiawPJzQxP m7n9Y1TgqfBgPhiMEFby2bM2ogsmdL696duj+8ZSeKtsagLSVY1lDyUNs7U2Lnuq6bmn WkVi6DginKSSEuhMU0F8O7R7OzRSphyl143wiS+dNpAK7zjYZh5q77Rebju2ZKWShaRs C/Xw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=K6AnqXvh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i14-20020a05620a248e00b0078137b394e3si15444727qkn.641.2023.12.29.13.31.18 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:18 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=K6AnqXvh; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQJ-0000nW-47; Fri, 29 Dec 2023 16:29:43 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQD-0000AD-M0 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:38 -0500 Received: from mail-oi1-x22e.google.com ([2607:f8b0:4864:20::22e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQ8-0000R1-V4 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:34 -0500 Received: by mail-oi1-x22e.google.com with SMTP id 5614622812f47-3bbd6e37a9bso1280079b6e.0 for ; Fri, 29 Dec 2023 13:29:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885371; x=1704490171; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=2Y5DZJN4hv2XQe15PGcXdVWgl56bQTxp89hl5EeXrWM=; b=K6AnqXvh/GpqgphPu9NCTzz+qgBI9KQV244O0KPOO2RZfrcMAjoBz+ErtfgA6EjgdX hD/W7hKauLZbzJy7j+k/6fxX9AoUU521QTkimBIhs8OxW0WtwOei30J3h6S1fzeb53/7 r1xDAu8OGf2h98VF8YITqqGIrxyWtFM+sp4EmMIeIIricDTY9ph8RuY4qaLL8pAFYhcK SNsfyju62bYlD7+cO/jqJg8XMV8y1BrK/ElFIfpgG17gpcb2Xtu3h+XLtYNRaE44Ri4O dFnbyqbl7tFvvvv6LC0HSbX283QjkajQmJ7/c4UtBfd9vbNTQSTmWisEQd1qVK1mkfDO QhHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885371; x=1704490171; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2Y5DZJN4hv2XQe15PGcXdVWgl56bQTxp89hl5EeXrWM=; b=luHO+1YQCgo+y3+9uEuuklqt8Z9oiCfvoWD4H9xHJlgSjgIh3ldZFo2oeg2ZK5nmlp DUxX86P/nxgo2p2nsWy9H53ywE+RsRsgqerWQNUmriVDRjiVlMmDWRUwK1OrVgcSmMiF GlfSn69EiUF35GVkVW3NygDXP2aS6E1ID9DCYYMTJS5iZqiEfomOWz8Qfp+OZRxJT0oS iPfu9HLCjzNVG23KLaOcekYwymtquu2D3SfFopd0+GUxnDesWY4uAFf+hz8T00RH672Z 7DO8y21IHXeJ9MtYPFNDXo2NbmixlmueaSzo1FuMemS6gUjt28fKpviS2oKacL73u2jx kywg== X-Gm-Message-State: AOJu0Yyph7foD7Zmhz/wRzpLJMyG5olJUEjPXSHQPZSU08WKXQ4C0qYo jXi1mXdy2zDrluKOsDPc94ATVVeduf3RkRK4eMRMC6xVp0CNxA== X-Received: by 2002:a05:6808:f0e:b0:3bb:ce11:5d3c with SMTP id m14-20020a0568080f0e00b003bbce115d3cmr4828044oiw.73.1703885371598; Fri, 29 Dec 2023 13:29:31 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:31 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 67/71] system: Constify VMState Date: Sat, 30 Dec 2023 08:23:42 +1100 Message-Id: <20231229212346.147149-68-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::22e; envelope-from=richard.henderson@linaro.org; helo=mail-oi1-x22e.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Tested-by: Philippe Mathieu-Daudé Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-68-richard.henderson@linaro.org> --- system/cpu-timers.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/system/cpu-timers.c b/system/cpu-timers.c index 7452d97b67..bdf3a41dcb 100644 --- a/system/cpu-timers.c +++ b/system/cpu-timers.c @@ -165,7 +165,7 @@ static const VMStateDescription icount_vmstate_warp_timer = { .version_id = 1, .minimum_version_id = 1, .needed = warp_timer_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(vm_clock_warp_start, TimersState), VMSTATE_TIMER_PTR(icount_warp_timer, TimersState), VMSTATE_END_OF_LIST() @@ -177,7 +177,7 @@ static const VMStateDescription icount_vmstate_adjust_timers = { .version_id = 1, .minimum_version_id = 1, .needed = adjust_timers_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_TIMER_PTR(icount_rt_timer, TimersState), VMSTATE_TIMER_PTR(icount_vm_timer, TimersState), VMSTATE_END_OF_LIST() @@ -189,7 +189,7 @@ static const VMStateDescription icount_vmstate_shift = { .version_id = 2, .minimum_version_id = 2, .needed = icount_shift_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT16(icount_time_shift, TimersState), VMSTATE_INT64(last_delta, TimersState), VMSTATE_END_OF_LIST() @@ -204,12 +204,12 @@ static const VMStateDescription icount_vmstate_timers = { .version_id = 1, .minimum_version_id = 1, .needed = icount_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(qemu_icount_bias, TimersState), VMSTATE_INT64(qemu_icount, TimersState), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &icount_vmstate_warp_timer, &icount_vmstate_adjust_timers, &icount_vmstate_shift, @@ -221,13 +221,13 @@ static const VMStateDescription vmstate_timers = { .name = "timer", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(cpu_ticks_offset, TimersState), VMSTATE_UNUSED(8), VMSTATE_INT64_V(cpu_clock_offset, TimersState, 2), VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription * []) { + .subsections = (const VMStateDescription * const []) { &icount_vmstate_timers, NULL } From patchwork Fri Dec 29 21:23:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758845 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672418wrw; Fri, 29 Dec 2023 13:31:37 -0800 (PST) X-Google-Smtp-Source: AGHT+IGeMoZkqNo0PL3r5ASxUGp65BsnT9aK87ibWCF6zzHGTbMAVAA1SS8sPZf/BcnbdP+uVfBt X-Received: by 2002:a05:620a:3913:b0:781:2a9f:6193 with SMTP id qr19-20020a05620a391300b007812a9f6193mr16093512qkn.48.1703885496765; Fri, 29 Dec 2023 13:31:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885496; cv=none; d=google.com; s=arc-20160816; b=rzLeqFPhxB3y6McSEM7oNpNOZ1ifJsSd++RKOZTkEQZyE4R6sQ/HOa63OKmOvDVtZA wBDYD5qc99wE7xV5vdab7gCMNVIa4m04Phh5e6jUTP4YeRhezwVs85eYVvAzr2gzlNyP ZVx5gVdQL7l5M08N2guq4cvdV6I7i3w3l07tCPTl79QILqFtAjJ8lreuulUCyroQhQfE ZntrIVrxQm59wchJRt6wMIkgwAk6DSLQZm5DGLfQ2tm/ozSf6V0cYfc16Mrkw3ADxa0G ZTvrT9lf9ymtr1HHcF/5EaS0azFMkqMiNETqKpV7CEwd0mwpGpWlgD2DNHca6VHP369I vWCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:to:from :dkim-signature; bh=tC/HddNi5BEccgo2j6UmM0509lK7SEFQpZ6hYE5pDdY=; fh=PnYt+qEB9tAfMKoqBm2xjKOFpYyFFGPudh5cVIoieJM=; b=R7BC3y8C20ipQoEdFFO/JAkDZZIiFMHb1gr+9rOJ3vjh+85GwlQiLkdTKFR/dKlWFA afU/pDVe+Tx4M9+JJFDMN97ixlPxtShEwMWJryOnYF1opQr93GpbUvrIH6q8Hr9Ml1u1 rcQFT5L+qr7xrJaT2MkQF84PVlq2HkUoTIySLRxZS+KiD3OPc9UAAaQ6ZivKAT6Ct0Gz c1NYEn9DqlCHrF5QfbFPVuLlkA05lF/49WuKSZcq9rG5eEUlttgjVjyjm9E3YuZhEXPJ K/psqCeAxpejXS/7hGSacanWSB+xjrZYg4hn3iyqfj+HoGSO4rIwVn6VC06fTyN2cpoS taBg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZZJTk34X; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id i19-20020a05620a405300b007815e79ec74si7199318qko.367.2023.12.29.13.31.36 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:36 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZZJTk34X; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQK-00011X-P6; Fri, 29 Dec 2023 16:29:44 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQF-0000Gj-25 for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:39 -0500 Received: from mail-pg1-x52d.google.com ([2607:f8b0:4864:20::52d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQC-0000RE-Mu for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:38 -0500 Received: by mail-pg1-x52d.google.com with SMTP id 41be03b00d2f7-5ca29c131ebso5612980a12.0 for ; Fri, 29 Dec 2023 13:29:34 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885373; x=1704490173; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=tC/HddNi5BEccgo2j6UmM0509lK7SEFQpZ6hYE5pDdY=; b=ZZJTk34XenuhspuYRQ5XCpCpenlUpSwjg5/7WSn25MFpQSuv6FfkTRnzuCbM30zfrn Q+eJWBjzT9ql1bbNQt9qr7nCm8W687MiJgMavU6pLRLbVxTr0o0IEsovDf5CFhCDMnZ9 IHTYP3GHk/xXwqY8F6OAGLcYNpBrMRfh9njF2w4L8ONrME06t8n/E57e3st59cr2DYhg wAN7alIRKU8zpmO0+pu+ZzdyvpLpZTw9/CUUeMR3unPVUJOnBQhLsfA7YlkwGv7M/EbD kN1qpIdJfml9Aby4g0WFtghYilEbBG4rS29CbqTPyEfZOf5zgY5Ms+Vn/ocWeYjjLedO RxMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885373; x=1704490173; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=tC/HddNi5BEccgo2j6UmM0509lK7SEFQpZ6hYE5pDdY=; b=B90+JmRrdyoSYdztXXTlbwAnUJtyEyGfe1OGjkU2Wh1Hz0OdTR3iYv8fX6C3YaB3qg Cz9q2MLcLcez1p3UgsrKtnkds6dh60YnUQyU0sEM6aPWUSeVAs1OgnC9nOHdPuOWDULg VXGmm4+Ed32HpqQwcu+0WRtSUUWRmp8Zyu4o7oxpvOA5anCAs5ES+Q9UJxhF73467Q+8 A8kEHLue1E4x67F0QSDBeD+01erGKBTx7PyFG4P3Bezma38/4/JrbX6lpx7g7x6U9+Fg kq3K28/9t/KGaDZnaykbFogEnxBachmqelNnOSF6XiXqGlkwvFqqD6yPe2mzIcSmhu+J wC6A== X-Gm-Message-State: AOJu0Yzt6YA0qo/j43lmHGi54CbU46X3LEYCh/cDuDbxLcg+lJQVtb3M ftl/n33A8s9s4lZjhsKK5U5H/Ky3fe9pT74VR8AqZuh2wkulXw== X-Received: by 2002:a05:6a20:4d84:b0:196:3544:c3b8 with SMTP id gj4-20020a056a204d8400b001963544c3b8mr3832102pzb.45.1703885373703; Fri, 29 Dec 2023 13:29:33 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:33 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Subject: [PULL 68/71] replay: Constify VMState Date: Sat, 30 Dec 2023 08:23:43 +1100 Message-Id: <20231229212346.147149-69-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::52d; envelope-from=richard.henderson@linaro.org; helo=mail-pg1-x52d.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-69-richard.henderson@linaro.org> --- replay/replay-snapshot.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/replay/replay-snapshot.c b/replay/replay-snapshot.c index 10a7cf7992..e5e39161e3 100644 --- a/replay/replay-snapshot.c +++ b/replay/replay-snapshot.c @@ -51,7 +51,7 @@ static const VMStateDescription vmstate_replay = { .minimum_version_id = 2, .pre_save = replay_pre_save, .post_load = replay_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64_ARRAY(cached_clock, ReplayState, REPLAY_CLOCK_COUNT), VMSTATE_UINT64(current_icount, ReplayState), VMSTATE_INT32(instruction_count, ReplayState), From patchwork Fri Dec 29 21:23:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758857 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672900wrw; Fri, 29 Dec 2023 13:33:28 -0800 (PST) X-Google-Smtp-Source: AGHT+IEzRCsP+Yv8i65V58u3UySi4FMKT9cD2AXDOcayi7Gc6XimGm1NajG1umqjeKAIV/GlvHzw X-Received: by 2002:ac8:7d51:0:b0:427:8c57:598d with SMTP id h17-20020ac87d51000000b004278c57598dmr16253707qtb.118.1703885607765; Fri, 29 Dec 2023 13:33:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885607; cv=none; d=google.com; s=arc-20160816; b=mdmHmkj+63QEURhpUsVZNdSL6Jj3wwr6jqM3p2L7DvAOG42dyanrRq7NxdSTUfRcQE g93QdqMNayKnA7DbCyXrbBs0YVwF6hRzsEkiXI8m/92s+bv7zavm583V4SGnTi3fWG// oKm1jjvJHONtF17FEg0sHrVzVMHVyuPnYi5rOntweOM6cJAnb8ZW5U34hN1Ga7Uil9kp 0vkTzN688zEK5wjondjL2jv/diZc5NxNNCcBRa0uFPm0wirORzuLiIil51ipFjgy7Ujk dTk4Mhx2zXQfbkA/sHOdYqbRjABhcehfAvR4NJfm1slAinj9MX5/xbmmfhRvtszeLCfK AP7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=M7Lza5D+iII9yK1P5GdP5roYCy14hxv1Hja38xdJAFg=; fh=kQadAhxV42GJ3cd2VUw1RyURv/zJQGvmUdF7iLEVTtc=; b=dwP6yrIMY3KdKWUISMZcveoM91AIiqrb6soOkGj6SMVTXgwfrmJUoE/52IgNM7IMuF 5fTdlWXVcCY91ZxsC1wnR6jxjJF8TY/lBa8148rJadp8iU9M//rhNcfdGf1iHt3mOLZJ 36vSiKgXXNh11kS0oTqrhymutrizueznvUX1AX3lGiZ5H3OhbAvJwpuxjQjeOdOf/jGw L08gZVi/VLy8UeceXHQQKT+KjgEqxeBbmuFXt3IudcJZUJaTQc6bBLIKTKwXivhed6yf Jw+HTyxDVVmKIdJeiGGp/FMCTk0nDhS3FCS2igqOpiSrxjFMaOp6H2okH/LXUvfpSbHz tntQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=M920ShM6; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id b9-20020ac85bc9000000b00427e8500c52si7376357qtb.613.2023.12.29.13.33.27 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:33:27 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=M920ShM6; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQK-0000yA-Cn; Fri, 29 Dec 2023 16:29:44 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQF-0000IB-6L for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:39 -0500 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQD-0000RQ-DD for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:38 -0500 Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-6da47688fd9so327941b3a.0 for ; Fri, 29 Dec 2023 13:29:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885376; x=1704490176; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=M7Lza5D+iII9yK1P5GdP5roYCy14hxv1Hja38xdJAFg=; b=M920ShM67Zm25lSY72bvOWMEHjqT9eWE1TcN651XZINtQe+OPYCaRKNZwWdWgJaPi/ Ht9g/LnLFz86LMLXx68v5MTCkmrnQbM4qZfg2K4Eb7/vux/Wg4ExnSb5fq/RNSTUTf/v WZRYxAxv/kG25S3EykNOY2OFj+oL9Ekqe5h7d+n4wWySOrn79Bqr/aWT/mBP9rPI4dmR JgnW9gOTYz4w+Mt81qnKMORNp1mz5OeI9ZHvTZaCL+eb/kRP2/c2eljXnv9VgtENJ3k8 VRtUHG3sX6Df1gs5D51Z+pF9XX56rM/D5xs/UBene3UDfuFZPwzNVLTVa8hfbYg8davf kAqw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885376; x=1704490176; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=M7Lza5D+iII9yK1P5GdP5roYCy14hxv1Hja38xdJAFg=; b=blbdICtu7sCGwyT9lz/7HBoQqFnLg6fC5Nymvg/g+rEJSA0ZFRn211/e3cIYDL+HdV qHmz9lFKyCu8djD2PUmZeQJsqSs1rNnMHk363i3IMEopPm26f2C1R4jGZ6VXBiEePYHD eEilLpS904QJ/Kg1fimU0fOUNkGD4yO3IbpdWuua4lHN5vgWIXr9ove1xI50z28aBYLQ 9vfpXZ4L86BZ/Qhita+iYTLug7fQfFsyFKFf+CRuiWVn10r8lm87kmCVusjo0HLMhqR8 pm/2zBZFmQeMurs/hFjFxauPFgxeQHJDryc3nnuCPxLHnzsFpjcmRpBLrqq0DRbfkbSF 4V8g== X-Gm-Message-State: AOJu0YzjN14bQrCgOtRJqxOgA9QF9lxYuow5xxenYJ2Uj/E/GMew8uNm q3TBHfnFhRC2mFFjbhAHEhDHbQL09tFNaAbnXaftUIvt0tKlwg== X-Received: by 2002:a05:6a00:2355:b0:6d9:b95c:6608 with SMTP id j21-20020a056a00235500b006d9b95c6608mr4468410pfj.41.1703885375950; Fri, 29 Dec 2023 13:29:35 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:35 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PULL 69/71] util/fifo8: Constify VMState Date: Sat, 30 Dec 2023 08:23:44 +1100 Message-Id: <20231229212346.147149-70-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::436; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x436.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-70-richard.henderson@linaro.org> --- util/fifo8.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/fifo8.c b/util/fifo8.c index d4d1c135e0..de8fd0f1c5 100644 --- a/util/fifo8.c +++ b/util/fifo8.c @@ -109,7 +109,7 @@ const VMStateDescription vmstate_fifo8 = { .name = "Fifo8", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_VBUFFER_UINT32(data, Fifo8, 1, NULL, capacity), VMSTATE_UINT32(head, Fifo8), VMSTATE_UINT32(num, Fifo8), From patchwork Fri Dec 29 21:23:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758849 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672495wrw; Fri, 29 Dec 2023 13:31:54 -0800 (PST) X-Google-Smtp-Source: AGHT+IF+6KCv98ZNgAMwGgNal+yb8IHOZ46F28j6qHMQRZgpHovnm5gqNbrOzCLPBBQuzfTa2vyp X-Received: by 2002:a05:622a:429b:b0:427:93cd:95cc with SMTP id cr27-20020a05622a429b00b0042793cd95ccmr15899235qtb.105.1703885514111; Fri, 29 Dec 2023 13:31:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885514; cv=none; d=google.com; s=arc-20160816; b=Q3Zp9LXhjOPxBJB6Jh89dJZkMub+vamUWRMp42TBZUeANea8tpzNXanCf/T4RoqXOL 27kd1vwR/GgjzST3u82kjzDoaK7oM3cTlVZa+T+NsIv+sYWbubmqP5g1XexVzHUqEArG q/QO9cOtxBK4fxXH9X4/OQYuoMgsXc1VJjK+aZR5N4uuoZHGQCuCPkrmlN1qkv1LRtYJ HB58iZ1iK0G3u2AFiESjxhiLGlog4ecDP8F84TF7kzvEUxg5sy/1HPqMzGQ7dUftMzbs mOxtVNoen5tovuEHpFCMLG6oKbB8HzzXphMsSt7p3bEASwZu2JLE0IaTCZAvwsk27pRd MjgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=mzgKa1/pA1ntGqiY+yagzdj2Mu5EMKX54fTMIwsuDpQ=; fh=mwvDHFN5agD7OubUR/beMfLQeIMTgcU04wMZItNAU1M=; b=SPF/Nknk6r8DWsaTtil51OwLOZB+5HYLViIk1F1rTIx7AkHQh1HEhPId8l+p5BJfux dyMYYCDv2o2kPAeEWl/mtdb7cBnNOaqCxMj6KS+e4ZH0yYu55mPz6Mm4IHfrz8wL6/q3 +xEiHLqGPpIqa8V8Ukw+DGsKKz2sSHL6rwzjQ/H8FqiuUbjjz1gOHGMf64i58OlK8RRa zi1dHIhNv8MmOWINoI8E/787PozS7xi5apt/RWzsvhgL1I5Jli7ugHf+VnxbzCOH9vv0 zw5caxmpUm3JvySLMBIK/w1gqii5pepTxhW73XB5dynInqEr9wxkFmNCzgZ5xRln+shH htWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=CSkohnfO; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id n1-20020a05622a11c100b0041985eb503csi20186783qtk.693.2023.12.29.13.31.53 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:54 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=CSkohnfO; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQJ-0000ud-Tb; Fri, 29 Dec 2023 16:29:43 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQH-0000bT-Ls for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:41 -0500 Received: from mail-ot1-x32a.google.com ([2607:f8b0:4864:20::32a]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQF-0000Rk-Mb for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:41 -0500 Received: by mail-ot1-x32a.google.com with SMTP id 46e09a7af769-6dc20b4595bso985912a34.0 for ; Fri, 29 Dec 2023 13:29:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885378; x=1704490178; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=mzgKa1/pA1ntGqiY+yagzdj2Mu5EMKX54fTMIwsuDpQ=; b=CSkohnfOc4UtpzlBPKRFFYZcjpbgD6j+kZqSIFYbICpjc//Af2GwvLXq81jhWYqK4b UbLzGdU8ts9jS+zSnUXbAX+9RpPEFHZ5A8l5NkLEpbubfPypmlPkOqgCK0HSOeGvTlnb Npwm+d5Yc/WF3ZmEScYR8oAYPCti8RJp4+DlqwDje6dGb1SwoTSWNR82eLVMkL4ihz8t /2zRYsBCuvdpsk0N1OhzlJSBm5CGgszSSlOcWQDepR0BLWog2bQfQ0wN6PpsOSmjr7sH kGm/wmXpH1cU5BIlLjaZYMU7fXqP3CBPyc64XwYYYUWMWFb2SD7I8wthMxo5PcC+8lDv Pmxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885378; x=1704490178; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mzgKa1/pA1ntGqiY+yagzdj2Mu5EMKX54fTMIwsuDpQ=; b=pi8M+IeWMpXNtcpS8eBRSojPqczplcaiT3tSK69l5Hct30xv8CeiimqVeLgwa8pA4J cGgTYgCShYpnf+MDzD6USXGlInhQGtGFi4NBP0TLoeI8AZl7EUknkGLE4VXIwEvEiymq ueQPDxyD4DrCj9CoofsrXsHKocrApeoMxwex24xVpcrGaSDHklUtZObW46zc4bVCpMbI nBgp9F2BKMSC3LycfkFKAcVf+nvM1UMdpwV1NFvr8eq3ekJ4ceknyEi/WpjPL0buYfQs Q6yyuUOhuH+7jW3K9EYk2vl6A3d/+J9+EhjYw62ylQJvGZfZQXiHySSiNP+o73wH2oyc O5lQ== X-Gm-Message-State: AOJu0YzgS1UrGikeO8deUWzwMXnpfYnzQV9eD7peW+sSXcHw84gxVn07 l+/cx3fUXhgMo7yNs/gel/8F5iIic9L2TbeWjr0ms6wqclJbhQ== X-Received: by 2002:a9d:7d86:0:b0:6dc:379:b3f with SMTP id j6-20020a9d7d86000000b006dc03790b3fmr4972489otn.46.1703885378500; Fri, 29 Dec 2023 13:29:38 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:38 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Juan Quintela Subject: [PULL 70/71] tests/unit/test-vmstate: Constify VMState Date: Sat, 30 Dec 2023 08:23:45 +1100 Message-Id: <20231229212346.147149-71-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::32a; envelope-from=richard.henderson@linaro.org; helo=mail-ot1-x32a.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org While const data in tests is not particularly important, this makes a grep test clear across the tree. Reviewed-by: Juan Quintela Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-71-richard.henderson@linaro.org> --- tests/unit/test-vmstate.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/tests/unit/test-vmstate.c b/tests/unit/test-vmstate.c index 0b7d5ecd68..c4f9faa273 100644 --- a/tests/unit/test-vmstate.c +++ b/tests/unit/test-vmstate.c @@ -197,7 +197,7 @@ static const VMStateDescription vmstate_simple_primitive = { .name = "simple/primitive", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(b_1, TestSimple), VMSTATE_BOOL(b_2, TestSimple), VMSTATE_UINT8(u8_1, TestSimple), @@ -299,7 +299,7 @@ static const VMStateDescription vmstate_simple_arr = { .name = "simple/array", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT16_ARRAY(u16_1, TestSimpleArray, 3), VMSTATE_END_OF_LIST() } @@ -341,7 +341,7 @@ static const VMStateDescription vmstate_versioned = { .name = "test/versioned", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(a, TestStruct), VMSTATE_UINT32_V(b, TestStruct, 2), /* Versioned field in the middle, so * we catch bugs more easily. @@ -412,7 +412,7 @@ static const VMStateDescription vmstate_skipping = { .name = "test/skip", .version_id = 2, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(a, TestStruct), VMSTATE_UINT32(b, TestStruct), VMSTATE_UINT32_TEST(c, TestStruct, test_skip), @@ -524,7 +524,7 @@ const VMStateDescription vmsd_tst = { .name = "test/tst", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(i, TestStructTriv), VMSTATE_END_OF_LIST() } @@ -542,7 +542,7 @@ const VMStateDescription vmsd_arps = { .name = "test/arps", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_ARRAY_OF_POINTER_TO_STRUCT(ar, TestArrayOfPtrToStuct, AR_SIZE, 0, vmsd_tst, TestStructTriv), VMSTATE_END_OF_LIST() @@ -630,7 +630,7 @@ const VMStateDescription vmsd_arpp = { .name = "test/arps", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_ARRAY_OF_POINTER(ar, TestArrayOfPtrToInt, AR_SIZE, 0, vmstate_info_int32, int32_t*), VMSTATE_END_OF_LIST() @@ -685,7 +685,7 @@ static const VMStateDescription vmstate_q_element = { .name = "test/queue-element", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_BOOL(b, TestQtailqElement), VMSTATE_UINT8(u8, TestQtailqElement), VMSTATE_END_OF_LIST() @@ -696,7 +696,7 @@ static const VMStateDescription vmstate_q = { .name = "test/queue", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT16(i16, TestQtailq), VMSTATE_QTAILQ_V(q, TestQtailq, 1, vmstate_q_element, TestQtailqElement, next), @@ -821,7 +821,7 @@ typedef struct TestGTreeInterval { .name = "interval", \ .version_id = 1, \ .minimum_version_id = 1, \ - .fields = (VMStateField[]) { \ + .fields = (const VMStateField[]) { \ VMSTATE_UINT64(low, TestGTreeInterval), \ VMSTATE_UINT64(high, TestGTreeInterval), \ VMSTATE_END_OF_LIST() \ @@ -839,7 +839,7 @@ typedef struct TestGTreeMapping { .name = "mapping", \ .version_id = 1, \ .minimum_version_id = 1, \ - .fields = (VMStateField[]) { \ + .fields = (const VMStateField[]) { \ VMSTATE_UINT64(phys_addr, TestGTreeMapping), \ VMSTATE_UINT32(flags, TestGTreeMapping), \ VMSTATE_END_OF_LIST() \ @@ -915,7 +915,7 @@ static const VMStateDescription vmstate_domain = { .version_id = 1, .minimum_version_id = 1, .pre_load = domain_preload, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(id, TestGTreeDomain), VMSTATE_GTREE_V(mappings, TestGTreeDomain, 1, vmstate_interval_mapping, @@ -940,7 +940,7 @@ static const VMStateDescription vmstate_qlist_element = { .name = "test/queue list", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, TestQListElement), VMSTATE_END_OF_LIST() } @@ -951,7 +951,7 @@ static const VMStateDescription vmstate_iommu = { .version_id = 1, .minimum_version_id = 1, .pre_load = iommu_preload, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(id, TestGTreeIOMMU), VMSTATE_GTREE_DIRECT_KEY_V(domains, TestGTreeIOMMU, 1, &vmstate_domain, TestGTreeDomain), @@ -963,7 +963,7 @@ static const VMStateDescription vmstate_container = { .name = "test/container/qlist", .version_id = 1, .minimum_version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(id, TestQListContainer), VMSTATE_QLIST_V(list, TestQListContainer, 1, vmstate_qlist_element, TestQListElement, next), @@ -1414,7 +1414,7 @@ static int tmp_child_post_load(void *opaque, int version_id) static const VMStateDescription vmstate_tmp_back_to_parent = { .name = "test/tmp_child_parent", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT64(f, TestStruct), VMSTATE_END_OF_LIST() } @@ -1424,7 +1424,7 @@ static const VMStateDescription vmstate_tmp_child = { .name = "test/tmp_child", .pre_save = tmp_child_pre_save, .post_load = tmp_child_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT64(diff, TmpTestStruct), VMSTATE_STRUCT_POINTER(parent, TmpTestStruct, vmstate_tmp_back_to_parent, TestStruct), @@ -1435,7 +1435,7 @@ static const VMStateDescription vmstate_tmp_child = { static const VMStateDescription vmstate_with_tmp = { .name = "test/with_tmp", .version_id = 1, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT32(a, TestStruct), VMSTATE_UINT64(d, TestStruct), VMSTATE_WITH_TMP(TestStruct, TmpTestStruct, vmstate_tmp_child), From patchwork Fri Dec 29 21:23:46 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Richard Henderson X-Patchwork-Id: 758837 Delivered-To: patch@linaro.org Received: by 2002:a5d:67c6:0:b0:336:6142:bf13 with SMTP id n6csp4672263wrw; Fri, 29 Dec 2023 13:31:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IGDB4QLZ++odPAxdAOAjLl+YzTWV7xLwj/Wk1i0NbG/iL9YlaxjswoVcsQK7lsLNYxMTYMS X-Received: by 2002:ad4:5ec6:0:b0:67a:9cbc:951a with SMTP id jm6-20020ad45ec6000000b0067a9cbc951amr15720981qvb.13.1703885470976; Fri, 29 Dec 2023 13:31:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703885470; cv=none; d=google.com; s=arc-20160816; b=bRAo8hEDEsaXY7USxheAcQPR3Jv1K0ZKjy2MM9p1O777k1GBsyyiU1OS9YuoemOdj7 jky1/5WYL7TC1fV43IzGYfQK7paoIUQIT0ehtr9VtwdTG+K47eGTVl3ZWl1ZdaBct9f1 SDMhkMT6pf0MAU4PnZn6HqN2pbHyvm8mKOkyr9gZhndk4jpj0tDUmRa3f0IXv0DjhE0y 2dP6fzBnZFiW3H+5AodVWnLmPWRMVj7lFSaqN0mA2jhoeA9GoTx/QINkVBzPnGdHBHiV IIWDjJaaPOJmvyDl88oVNBY1DQAbX2CCMGBqDe5ZUca3l+GFD8g3jtscrfUP79EmzbOw 1nmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=M2Xo1Swghl855R8AX0ytJsmYmGWmMhQtAvSG9IogLkE=; fh=tLS9ksVGLzGUvgBW33OjWlONz93+3L41TNK5IzdHefk=; b=xC3Foh72bx3kB2YYVyEpo5H1Iij620fWHvgBH9AveuzPnTar0Tvn1+UQpRFKm8Kjdp I0m13s1ko10PQeO6US28VtZP9xPrgGNMZgbGdQJZG2w+IN1lQpYT/hde+PbYJJjGn+x8 N9u1+lyEWuAMH6pQ/4oP3X7/gKoanQvk8Fsh5xWbY4sb/6lI4XxTag1lWZonMCr6UdkH xrWNEss5/I1dXB5ZIg4fgLRerd3o3iJbUtcSG+QitPD6/IU5gZo0WQ/6dMCX35e1K70i /Fr0W19vzshUaxqgEId8Z1ke8vyhn9JDMV1STYQQh1R6Ry3wt9Aj9aXj6YJIpy6HC5sy jWmw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jS4tDVXT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id c18-20020a056214071200b0067f827316e6si19277197qvz.83.2023.12.29.13.31.10 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 29 Dec 2023 13:31:10 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jS4tDVXT; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rJKQO-0001bU-Rx; Fri, 29 Dec 2023 16:29:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rJKQK-0000yt-Dp for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:44 -0500 Received: from mail-pf1-x431.google.com ([2607:f8b0:4864:20::431]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rJKQI-0000S4-Nf for qemu-devel@nongnu.org; Fri, 29 Dec 2023 16:29:44 -0500 Received: by mail-pf1-x431.google.com with SMTP id d2e1a72fcca58-6d9e62ff056so2713906b3a.1 for ; Fri, 29 Dec 2023 13:29:42 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1703885381; x=1704490181; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=M2Xo1Swghl855R8AX0ytJsmYmGWmMhQtAvSG9IogLkE=; b=jS4tDVXTWQagODUMNPxbosJTnHS4kqt+xcATcHKrJq+eLjOj5M0rxy0ya664K0rxCf kLP9yGGZddN3QVH0QgDGiQshHveFxDLnbaLoBwmOYD393P+sPqSObtlrWnVjP0ZFGU8m iRMAxZAbt078fE1N3+sAKbYLAR+9P6lqLkDo0YwS/9qxgEiz/KfWVGkUASLECf1GfzC3 7evPUJUt/Hkqz1fms8dpXxWSkneSRSMuRfBuSM0M7RMF6IPQYlncEBFFwWAv0sUWtRLT gex5u7WBgrmpw5bonDHV8kXjypgLG1PpWPbhPwci78ZEM9V69aAeLW1gd0bUNxfvd2oo 3A+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703885381; x=1704490181; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=M2Xo1Swghl855R8AX0ytJsmYmGWmMhQtAvSG9IogLkE=; b=kguplRSkhHZ+JARtV4b7q1KNpzSfWsBcnd6OTWjf5WDC7GtLqMIlu23ta5XU0YoRDC GngbNs3kNlkbDdW/FjlboY2CoMFhv3lFKdCw7eGm9hWg9bBDty4WgEy7qUpR3IPzoImp FzG8F+hLBeF8iu5hIgFqBTYSpIwJuAfJtJFQvCcsXdWwk1HO/oX9bGZTG28IpzoltBH4 XsPwOBPPnEu7ep3IXRn+dDLRqvBzEuHBBo7fYdMNc33UkyPmIaAs6d7v6i+zuTamDmLQ 5us2yzmpck3wbwQiOUC38YRt2H1IZyngXc8KYKCdr5hoT8wixkXxtStZNXLMNLuM5c8w Qq4A== X-Gm-Message-State: AOJu0YwCZDUJOlGnQAbRMs8RGinXMicZKPRNc8pY1AWhdQgpDSHlZa4Q Vk0JJOtI5tMCP6Ma36SWUlm4bw2AXGIcmcQjJfvAKjxcQTQFKQ== X-Received: by 2002:a05:6a00:84e:b0:6d9:bd17:1653 with SMTP id q14-20020a056a00084e00b006d9bd171653mr8840496pfk.37.1703885381277; Fri, 29 Dec 2023 13:29:41 -0800 (PST) Received: from stoup.lan (203-217-28-32.perm.iinet.net.au. [203.217.28.32]) by smtp.gmail.com with ESMTPSA id bd33-20020a056a0027a100b006d9a96b7d0dsm11285396pfb.208.2023.12.29.13.29.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 29 Dec 2023 13:29:40 -0800 (PST) From: Richard Henderson To: qemu-devel@nongnu.org Cc: Juan Quintela , =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= Subject: [PULL 71/71] docs: Constify VMstate in examples Date: Sat, 30 Dec 2023 08:23:46 +1100 Message-Id: <20231229212346.147149-72-richard.henderson@linaro.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20231229212346.147149-1-richard.henderson@linaro.org> References: <20231229212346.147149-1-richard.henderson@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2607:f8b0:4864:20::431; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x431.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, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org Reviewed-by: Juan Quintela Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Richard Henderson Message-Id: <20231221031652.119827-72-richard.henderson@linaro.org> --- docs/devel/clocks.rst | 2 +- docs/devel/migration.rst | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/devel/clocks.rst b/docs/devel/clocks.rst index 675fbeb6ab..c4d14bde04 100644 --- a/docs/devel/clocks.rst +++ b/docs/devel/clocks.rst @@ -502,7 +502,7 @@ This is typically used to migrate an input clock state. For example: VMStateDescription my_device_vmstate = { .name = "my_device", - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { [...], /* other migrated fields */ VMSTATE_CLOCK(clk, MyDeviceState), VMSTATE_END_OF_LIST() diff --git a/docs/devel/migration.rst b/docs/devel/migration.rst index ec55089b25..95351ba51f 100644 --- a/docs/devel/migration.rst +++ b/docs/devel/migration.rst @@ -158,7 +158,7 @@ An example (from hw/input/pckbd.c) .name = "pckbd", .version_id = 3, .minimum_version_id = 3, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_UINT8(write_cmd, KBDState), VMSTATE_UINT8(status, KBDState), VMSTATE_UINT8(mode, KBDState), @@ -294,7 +294,7 @@ Example: .pre_save = ide_drive_pio_pre_save, .post_load = ide_drive_pio_post_load, .needed = ide_drive_pio_state_needed, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { VMSTATE_INT32(req_nb_sectors, IDEState), VMSTATE_VARRAY_INT32(io_buffer, IDEState, io_buffer_total_len, 1, vmstate_info_uint8, uint8_t), @@ -312,11 +312,11 @@ Example: .version_id = 3, .minimum_version_id = 0, .post_load = ide_drive_post_load, - .fields = (VMStateField[]) { + .fields = (const VMStateField[]) { .... several fields .... VMSTATE_END_OF_LIST() }, - .subsections = (const VMStateDescription*[]) { + .subsections = (const VMStateDescription * const []) { &vmstate_ide_drive_pio_state, NULL }