From patchwork Fri Mar 22 16:28:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 781862 Delivered-To: patch@linaro.org Received: by 2002:ab3:6391:0:b0:25b:6002:2155 with SMTP id h17csp4372lte; Fri, 22 Mar 2024 09:28:50 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCXLgLIkS3Qf3Rk0U+QcNXdrpgz8kKgYb//OeJrJJbVVj+mUvs2ulT4ymrKNun/ZCBAkdhhKt82sQZ8WsfiLoc9p X-Google-Smtp-Source: AGHT+IESf0NFIR4wtpQAcjW0epqf7yro7YA7/qhoF1kmYo0nS3xqea275T8nxaM7jfWXJxvCw0x6 X-Received: by 2002:a05:620a:889:b0:789:f0e3:d8a9 with SMTP id b9-20020a05620a088900b00789f0e3d8a9mr96401qka.13.1711124929796; Fri, 22 Mar 2024 09:28:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1711124929; cv=none; d=google.com; s=arc-20160816; b=tiv/5ySXUWX0YSxkz6wLIMcMAX88YV5AvThB/v1TyrMKk4WKoTvq/IYKx8o243282U 3b/aEehrIerGo4qHMnqsF1WJJvrm9gGB5tsnPUJBZINya//EeUDLLJPhloeomJ5P05+y IOkKjae+0UU8FZMy/6epKIFgBh4WFJcjnUercPp+wqy4Eo71DucKzH3Ghaa4UoW1QxIt Td0hT8lnWUWH/WJHiV8yDVs+R4GVmgMYwFFdgkp4A4MZF2jihPnyphsxslCKi1N7L8Zi gg9gFLqRo1rVG96ZDQc4MLKPaYQIU+Vn+1BSHbOZESGc03l43pZcRyQIRahdakkePBuo mi+g== 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:message-id:date:subject:cc:to:from:dkim-signature; bh=7QdAIBvFnVQkIHc7ZXX6yGjuUKjHY2VoM4j0omCFJVI=; fh=nC1mvzOaFZhFt7/Qy3RRFlfcdX3OfPUcYsJiLuZhiGk=; b=sfcgJnlv9B4eHZmzHtvDh2PRX3Q9cPAd1z9e3u3yeQVdnYgX32uf1CH2nk/fTj+njL gbK2fmTuLCfvKAwS8skCFm1lRW5/fryigS7PHnUs6p/AduQvO4CkOfqQu+y5P+6B2AzF YylI43U1f1fmMsAQPEReNnDjSWDzcnhe1QTCvlVRgWxY2rxyHtFzQea+7dk9gp+gzwSG cijReaJaVmPSlh57PIS+hosk+02F3za/J8L7pGutE7Jvp/daPgtB6Yx3eQWoHi43xVhK Oi9t96IkFD1UAIXGv24HHyUtc4qFrKq/thvOcvKMOOumSbP1le7KuX64ZXHc73W0DKfK /6VA==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="kK/7B6v3"; 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 wk24-20020a05620a579800b00789e6ace0basi2236899qkn.408.2024.03.22.09.28.49 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 22 Mar 2024 09:28:49 -0700 (PDT) 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="kK/7B6v3"; 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 1rnhkt-0002tq-5j; Fri, 22 Mar 2024 12:28:31 -0400 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 1rnhkr-0002tY-To for qemu-devel@nongnu.org; Fri, 22 Mar 2024 12:28:29 -0400 Received: from mail-wm1-x32f.google.com ([2a00:1450:4864:20::32f]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rnhkp-0003UN-A3 for qemu-devel@nongnu.org; Fri, 22 Mar 2024 12:28:29 -0400 Received: by mail-wm1-x32f.google.com with SMTP id 5b1f17b1804b1-4140aadfe2eso17361285e9.1 for ; Fri, 22 Mar 2024 09:28:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1711124905; x=1711729705; darn=nongnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=7QdAIBvFnVQkIHc7ZXX6yGjuUKjHY2VoM4j0omCFJVI=; b=kK/7B6v31BXRDgCol18Ej57kO4zj6yrKNQ6EWtwZNj14hWoQ7+AJ/Xgb50tyXww/EP jclLsCItyTQXpfjI7WKoS1YEsCJgAef3l3J+glz7dqEyA7x71/bFUZBhYMZrOn12fgjw 6KaFltra4tlld8nk2m0EGX+lV8ifIxW5t+96RPXz6Rw+Mt8Z214XSTqeYI+OpiP/up5j VYVyQwTsVJlu4+cZ7Y9f5VB3F5fd07ty8y/c3DCrBNrtzMB8oY1kAedE+Gaehy1TEFu1 WDjPnqUbrCjv/ue0OcAMDHkNMkO4b5Hr7V4VUth8R0Zii2gktRHGuZfi9rnXp21zPD20 R1jQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711124905; x=1711729705; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=7QdAIBvFnVQkIHc7ZXX6yGjuUKjHY2VoM4j0omCFJVI=; b=LBMUB8ntK+AJlHVwudVvKOMiwWFWCf9JcZC+z68eNmHHWwdj5bbB2bjU4+T7SOBrqB qf6vqAfrq9prbGw7HloG0R/4DhXCyw6gPurFeyJA/J7kCFd3fSsaIi9lFFe0dIOcIeI/ WLoihdKf3s1ObcU/vfjboYaSJaL60b3fCbSSiaZN+iMoIz9cjsjrkIfr28CTD0tjb2YV ikDt67fE6FtWI1NX47bcRg++E9FNszdGYsbcbz+h4/9goadAmBdX6S7ZLl1BYNasKwg+ n2dHf4+b9A5LsuOiYwRQdOoV24CVwBMDi35GGT7YejbEX/rf+G19tng4Sn4YkcolcmI4 z7Yw== X-Gm-Message-State: AOJu0Yy7iGaLToR1v+kYdnZqAC5XkS3xHTTPwmWcHatqmpltHVrWv9Mo sGlCUG8NzJ3JtnsUA0ukG2+URW6q6hyHetnzzzxoblI8Fv5TxTKvgJH+t+4513cmpHej3lyPStK 8 X-Received: by 2002:adf:cb13:0:b0:33e:652b:d6db with SMTP id u19-20020adfcb13000000b0033e652bd6dbmr1655893wrh.23.1711124905395; Fri, 22 Mar 2024 09:28:25 -0700 (PDT) Received: from m1x-phil.lan ([176.176.178.251]) by smtp.gmail.com with ESMTPSA id p11-20020a056000018b00b0033e75e5f280sm2375905wrx.113.2024.03.22.09.28.23 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Fri, 22 Mar 2024 09:28:24 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: Ilya Leoshkevich , Thomas Huth , qemu-s390x@nongnu.org, Richard Henderson , Eric Farman , Christian Borntraeger , Halil Pasic , David Hildenbrand , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Subject: [PATCH] hw/s390x: Include missing 'cpu.h' header Date: Fri, 22 Mar 2024 17:28:22 +0100 Message-ID: <20240322162822.7391-1-philmd@linaro.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::32f; envelope-from=philmd@linaro.org; helo=mail-wm1-x32f.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 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 "cpu.h" is implicitly included. Include it explicitly to avoid the following error when refactoring headers: hw/s390x/s390-stattrib.c:86:40: error: use of undeclared identifier 'TARGET_PAGE_SIZE' len = sac->peek_stattr(sas, addr / TARGET_PAGE_SIZE, buflen, vals); ^ hw/s390x/s390-stattrib.c:94:58: error: use of undeclared identifier 'TARGET_PAGE_MASK' addr / TARGET_PAGE_SIZE, len, addr & ~TARGET_PAGE_MASK); ^ hw/s390x/s390-stattrib.c:224:40: error: use of undeclared identifier 'TARGET_PAGE_BITS' qemu_put_be64(f, (start_gfn << TARGET_PAGE_BITS) | STATTR_FLAG_MORE); ^ In file included from hw/s390x/s390-virtio-ccw.c:17: hw/s390x/s390-virtio-hcall.h:22:27: error: unknown type name 'CPUS390XState' int s390_virtio_hypercall(CPUS390XState *env); ^ Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth Acked-by: Eric Farman --- hw/s390x/s390-virtio-hcall.h | 2 ++ hw/s390x/s390-stattrib.c | 1 + 2 files changed, 3 insertions(+) diff --git a/hw/s390x/s390-virtio-hcall.h b/hw/s390x/s390-virtio-hcall.h index 9800c4b351..3ae6d6ae3a 100644 --- a/hw/s390x/s390-virtio-hcall.h +++ b/hw/s390x/s390-virtio-hcall.h @@ -13,6 +13,7 @@ #define HW_S390_VIRTIO_HCALL_H #include "standard-headers/asm-s390/virtio-ccw.h" +#include "cpu.h" /* The only thing that we need from the old kvm_virtio.h file */ #define KVM_S390_VIRTIO_NOTIFY 0 @@ -20,4 +21,5 @@ typedef int (*s390_virtio_fn)(const uint64_t *args); void s390_register_virtio_hypercall(uint64_t code, s390_virtio_fn fn); int s390_virtio_hypercall(CPUS390XState *env); + #endif /* HW_S390_VIRTIO_HCALL_H */ diff --git a/hw/s390x/s390-stattrib.c b/hw/s390x/s390-stattrib.c index c483b62a9b..aaf48ac73f 100644 --- a/hw/s390x/s390-stattrib.c +++ b/hw/s390x/s390-stattrib.c @@ -19,6 +19,7 @@ #include "exec/ram_addr.h" #include "qapi/error.h" #include "qapi/qmp/qdict.h" +#include "cpu.h" /* 512KiB cover 2GB of guest memory */ #define CMMA_BLOCK_SIZE (512 * KiB)