From nobody Tue Nov 26 22:13:31 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=linaro.org ARC-Seal: i=1; a=rsa-sha256; t=1703885457; cv=none; d=zohomail.com; s=zohoarc; b=aHDwfqEEdo0Kozb/ArIY4chlnQcG/SY2yaffSp1ZxVbVy/i4SH6fCdHzGZbSK7pd0YBi2zwLWLDb9Dhm2CDJeLpFKqC2tgQnrPyq1BV2FSRuXgHMAE92LSnTfwYK5a292ivYJ3TMEQMCFMW3TDq4Q9+wn2cVvowKuS6SozRtE/4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1703885457; h=Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To:Cc; bh=OqU6sg9g0ESWhn8ACzHLMCxFbvZWow6DbzojmlPanzM=; b=cksvzXJeUHbXd+ftsKo1FqSMblVdFHUD91o2dVSV7ar9m1YozVHzEwOt1/2T2RFUJ+JYutN/B45SinDvESOVTud0lyAzVJOK1tllbbL/M+d/6zUWZ2XsfFYGWTFyPJlPmlzOf2mRh+Ap9nMwGoiGWgB01oO2MTXOVfY0yCxH3sM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1703885457330794.3048946383855; Fri, 29 Dec 2023 13:30:57 -0800 (PST) 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) 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) 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-Google-Smtp-Source: AGHT+IHQjzYwx78PPReg0DB+9MdFcHFrnrgYN/XVhFGAGSPh2OBoz91V7SjxAw7c/rhAbO9xeeQ+Zw== 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) 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 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @linaro.org) X-ZM-MESSAGEID: 1703885458741100003 Content-Type: text/plain; charset="utf-8" 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 =3D { .name =3D "s390_ccw_dev", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_crw", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT16(flags, CRW), VMSTATE_UINT16(rsid, CRW), VMSTATE_END_OF_LIST() @@ -43,7 +43,7 @@ static const VMStateDescription vmstate_crw_container =3D= { .name =3D "s390_crw_container", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_STRUCT(crw, CrwContainer, 0, vmstate_crw, CRW), VMSTATE_END_OF_LIST() }, @@ -59,7 +59,7 @@ static const VMStateDescription vmstate_chp_info =3D { .name =3D "s390_chp_info", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_scsw", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT16(flags, SCSW), VMSTATE_UINT16(ctrl, SCSW), VMSTATE_UINT32(cpa, SCSW), @@ -92,7 +92,7 @@ static const VMStateDescription vmstate_pmcw =3D { .name =3D "s390_pmcw", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT32(intparm, PMCW), VMSTATE_UINT16(flags, PMCW), VMSTATE_UINT16(devno, PMCW), @@ -113,7 +113,7 @@ static const VMStateDescription vmstate_schib =3D { .name =3D "s390_schib", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_ccw1", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT8(cmd_code, CCW1), VMSTATE_UINT8(flags, CCW1), VMSTATE_UINT16(count, CCW1), @@ -140,7 +140,7 @@ static const VMStateDescription vmstate_ciw =3D { .name =3D "s390_ciw", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT8(type, CIW), VMSTATE_UINT8(command, CIW), VMSTATE_UINT16(count, CIW), @@ -152,7 +152,7 @@ static const VMStateDescription vmstate_sense_id =3D { .name =3D "s390_sense_id", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_orb", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT32(intparm, ORB), VMSTATE_UINT16(ctrl0, ORB), VMSTATE_UINT8(lpm, ORB), @@ -188,7 +188,7 @@ static const VMStateDescription vmstate_schdev_orb =3D { .version_id =3D 1, .minimum_version_id =3D 1, .needed =3D vmstate_schdev_orb_needed, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_STRUCT(orb, SubchDev, 1, vmstate_orb, ORB), VMSTATE_END_OF_LIST() } @@ -207,7 +207,7 @@ const VMStateDescription vmstate_subch_dev =3D { .minimum_version_id =3D 1, .post_load =3D subch_dev_post_load, .pre_save =3D subch_dev_pre_save, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { VMSTATE_UINT8(ccw_no_data_cnt, SubchDev), VMSTATE_END_OF_LIST() }, - .subsections =3D (const VMStateDescription * []) { + .subsections =3D (const VMStateDescription * const []) { &vmstate_schdev_orb, NULL } @@ -264,12 +264,12 @@ static int pre_save_ind_addr(void *opaque) return 0; } =20 -const VMStateDescription vmstate_ind_addr_tmp =3D { +static const VMStateDescription vmstate_ind_addr_tmp =3D { .name =3D "s390_ind_addr_tmp", .pre_save =3D pre_save_ind_addr, .post_load =3D post_load_ind_addr, =20 - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_INT32(len, IndAddrPtrTmp), VMSTATE_UINT64(addr, IndAddrPtrTmp), VMSTATE_END_OF_LIST() @@ -278,7 +278,7 @@ const VMStateDescription vmstate_ind_addr_tmp =3D { =20 const VMStateDescription vmstate_ind_addr =3D { .name =3D "s390_ind_addr_tmp", - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_css_img", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_css", .version_id =3D 1, .minimum_version_id =3D 1, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_QTAILQ_V(pending_crws, ChannelSubSys, 1, vmstate_crw_conta= iner, 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 =3D { .version_id =3D 0, .minimum_version_id =3D 0, .needed =3D vmstate_event_facility_mask64_needed, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT32(receive_mask_pieces[RECV_MASK_LOWER], SCLPEventFaci= lity), VMSTATE_END_OF_LIST() } @@ -378,7 +378,7 @@ static const VMStateDescription vmstate_event_facility_= mask_length =3D { .version_id =3D 0, .minimum_version_id =3D 0, .needed =3D vmstate_event_facility_mask_length_needed, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT16(mask_length, SCLPEventFacility), VMSTATE_END_OF_LIST() } @@ -388,11 +388,11 @@ static const VMStateDescription vmstate_event_facilit= y =3D { .name =3D "vmstate-event-facility", .version_id =3D 0, .minimum_version_id =3D 0, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT32(receive_mask_pieces[RECV_MASK_UPPER], SCLPEventFaci= lity), VMSTATE_END_OF_LIST() }, - .subsections =3D (const VMStateDescription * []) { + .subsections =3D (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 =3D= { .version_id =3D 0, .minimum_version_id =3D 0, .needed =3D iplb_extended_needed, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT8_ARRAY(reserved_ext, IplParameterBlock, 4096 - 200), VMSTATE_END_OF_LIST() } @@ -69,13 +69,13 @@ static const VMStateDescription vmstate_iplb =3D { .name =3D "ipl/iplb", .version_id =3D 0, .minimum_version_id =3D 0, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT8_ARRAY(reserved1, IplParameterBlock, 110), VMSTATE_UINT16(devno, IplParameterBlock), VMSTATE_UINT8_ARRAY(reserved2, IplParameterBlock, 88), VMSTATE_END_OF_LIST() }, - .subsections =3D (const VMStateDescription*[]) { + .subsections =3D (const VMStateDescription * const []) { &vmstate_iplb_extended, NULL } @@ -85,7 +85,7 @@ static const VMStateDescription vmstate_ipl =3D { .name =3D "ipl", .version_id =3D 0, .minimum_version_id =3D 0, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT64(compat_start_addr, S390IPLState), VMSTATE_UINT64(compat_bios_start_addr, S390IPLState), VMSTATE_STRUCT(iplb, S390IPLState, 0, vmstate_iplb, IplParameterBl= ock), 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 =3D { .name =3D TYPE_SCLP_QUIESCE, .version_id =3D 0, .minimum_version_id =3D 0, - .fields =3D (VMStateField[]) { + .fields =3D (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 =3D { .name =3D "s390_virtio_ccw_dev_tmp", .pre_save =3D virtio_ccw_dev_tmp_pre_save, .post_load =3D virtio_ccw_dev_tmp_post_load, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_UINT16(config_vector, VirtioCcwDeviceTmp), VMSTATE_END_OF_LIST() } @@ -98,7 +98,7 @@ const VMStateDescription vmstate_virtio_ccw_dev =3D { .version_id =3D 1, .minimum_version_id =3D 1, .post_load =3D virtio_ccw_dev_post_load, - .fields =3D (VMStateField[]) { + .fields =3D (const VMStateField[]) { VMSTATE_CCW_DEVICE(parent_obj, VirtioCcwDevice), VMSTATE_PTR_TO_IND_ADDR(indicators, VirtioCcwDevice), VMSTATE_PTR_TO_IND_ADDR(indicators2, VirtioCcwDevice), --=20 2.34.1