From patchwork Tue Mar 11 19:57:49 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pierrick Bouvier X-Patchwork-Id: 14012618 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A4887C28B2F for ; Tue, 11 Mar 2025 19:59:02 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.908972.1316047 (Exim 4.92) (envelope-from ) id 1ts5k9-00084N-Cr; Tue, 11 Mar 2025 19:58:25 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 908972.1316047; Tue, 11 Mar 2025 19:58:25 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ts5k9-00083H-8e; Tue, 11 Mar 2025 19:58:25 +0000 Received: by outflank-mailman (input) for mailman id 908972; Tue, 11 Mar 2025 19:58:23 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ts5k7-0007Uu-J5 for xen-devel@lists.xenproject.org; Tue, 11 Mar 2025 19:58:23 +0000 Received: from mail-pl1-x62a.google.com (mail-pl1-x62a.google.com [2607:f8b0:4864:20::62a]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 2b1e613f-feb3-11ef-9898-31a8f345e629; Tue, 11 Mar 2025 20:58:15 +0100 (CET) Received: by mail-pl1-x62a.google.com with SMTP id d9443c01a7336-22401f4d35aso106632935ad.2 for ; Tue, 11 Mar 2025 12:58:15 -0700 (PDT) Received: from pc.. ([38.39.164.180]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-736a6e5c13asm9646981b3a.157.2025.03.11.12.58.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Mar 2025 12:58:13 -0700 (PDT) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 2b1e613f-feb3-11ef-9898-31a8f345e629 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1741723094; x=1742327894; darn=lists.xenproject.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=fcP4MFj0H7Fu3AxOxTbJlPG2KgbdJwiBtz5sSPdKZDU=; b=RjxedlZ+LW41z+BebQ4BXMVeF3VJ5Ei1rh961kAkVbOMN2hI83W/ET8I2lfir2hfsz aKIkH2Cq9h7pN5YVvGTkfqSrlcJuElxS8j/tbUbRHgy+8s5b1kL4x0qL66yPKF4djurI EOaqaeh9XNI2lKYJGs2S1LQJolhiUiMDsi+4SyubEY+3tBXqDiyq258G5Pdt1CkDNluG s0G+FA7XUdbyD8qx9/+5WV9GwpceU2LLo4UDn2UxJqtPkCM3yY4jD+xSzU8plkWa9fCW JfsMyJ30uepyxe1wFxHMnCQYbsvQw9ol20d/aor4aapLuB6dz2SLrZ0bFm7uNJxi0lX5 dcEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1741723094; x=1742327894; 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=fcP4MFj0H7Fu3AxOxTbJlPG2KgbdJwiBtz5sSPdKZDU=; b=oPxDILh1crm6Ta796d3j8QvgQhd4rl1/ssPFQUpVsCGU3dnAy8gESjjlQhox4qk6n0 /QF+9SkyaEYXFyv5P7ipYHvT6t9TVuvpmET3grux0SHW+KMGqmtApFiVwIvMqkBGbig1 bGIsWgI0KZ/51rDjFr70qD0TLtY6Jgq/q8g5vNbfxw9az1p8TuKGWsiovRCXXCsmpSC8 abL4tfjU9k4ilj07QFMf+fcoBa6KVwCf+3G4dhrqYeUX9UdhIKqTUoeclof07LYOA24f juLVYRDv1sz+2es1hj+0KBgIX3Tb9A+szEXwsYq33KLP2XIAvFwZpdYR9OAfnMd0A5JH 314w== X-Forwarded-Encrypted: i=1; AJvYcCVGUSZhEM1N+BZvWAq6PfCHWHMUsd4mhFJoE/dzHtwxlWAdE1L3ClJ1M4rQT9Y5bYfMqPaUoCilWDo=@lists.xenproject.org X-Gm-Message-State: AOJu0YwyozfjsNAGwjPXkinDmPhnxUgn6kODf6LiPouls4rec17R2n1l KMHB7Y9lOQOUtX0/7cObZ1DPVdWDZtsz/Gu/2EiR429GhExYP0cgihUpVFxOq/E= X-Gm-Gg: ASbGncuxmS2q1UEj0KMiS+Mmf8y4N5E4aOrll8xpaT6oiLTkEtcPILuCCyGVHQV9hXR Q99K8u4PuYvvf4EL2DBTmEB3wIMEbO6cHns3eazQ+1tNuDWlNxSKrZMFeU8mEeGujOKx8ELxI0M UXxC5Im1Bnl/sqzSmeGkinaE3uXdarlEFMDxVxFAQF2lZ1dhD8ntdQLWQLZT/EfZf/5XhwL0yA2 ea3qaMvJLMsgoTp1GDfkrwuCmZ6BLnyub6QnqG6EGRdyFLUYb+lopx4WYgsaAPYH+g32jWQVjwh wWjYCkJIr+eq8bKQCuOL5I5evFUmdzb/dntEV9Q/33L0 X-Google-Smtp-Source: AGHT+IHtn3wjueX80hXlhR3WWJLzlWQ/GjOadBaAC9ISUpU84/t/abdjw/+6bEkcmiHY0rapbw+ALA== X-Received: by 2002:a05:6a00:189b:b0:736:755b:8317 with SMTP id d2e1a72fcca58-736eb8a15femr7017121b3a.21.1741723094173; Tue, 11 Mar 2025 12:58:14 -0700 (PDT) From: Pierrick Bouvier To: qemu-devel@nongnu.org Cc: David Hildenbrand , Stefano Stabellini , "Edgar E. Iglesias" , Anthony PERARD , xen-devel@lists.xenproject.org, Nicholas Piggin , Richard Henderson , Weiwei Li , kvm@vger.kernel.org, Palmer Dabbelt , Paolo Bonzini , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Paul Durrant , Liu Zhiwei , Daniel Henrique Barboza , manos.pitsidianakis@linaro.org, Peter Xu , Harsh Prateek Bora , Alistair Francis , alex.bennee@linaro.org, Yoshinori Sato , qemu-riscv@nongnu.org, qemu-ppc@nongnu.org, Pierrick Bouvier Subject: [PATCH v3 03/17] exec/memory_ldst: extract memory_ldst declarations from cpu-all.h Date: Tue, 11 Mar 2025 12:57:49 -0700 Message-Id: <20250311195803.4115788-4-pierrick.bouvier@linaro.org> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20250311195803.4115788-1-pierrick.bouvier@linaro.org> References: <20250311195803.4115788-1-pierrick.bouvier@linaro.org> MIME-Version: 1.0 They are now accessible through exec/memory.h instead, and we make sure all variants are available for common or target dependent code. Reviewed-by: Richard Henderson Signed-off-by: Pierrick Bouvier --- include/exec/cpu-all.h | 12 ------------ include/exec/memory_ldst.h.inc | 4 ---- 2 files changed, 16 deletions(-) diff --git a/include/exec/cpu-all.h b/include/exec/cpu-all.h index e56c064d46f..0e8205818a4 100644 --- a/include/exec/cpu-all.h +++ b/include/exec/cpu-all.h @@ -44,18 +44,6 @@ #include "exec/hwaddr.h" -#define SUFFIX -#define ARG1 as -#define ARG1_DECL AddressSpace *as -#define TARGET_ENDIANNESS -#include "exec/memory_ldst.h.inc" - -#define SUFFIX _cached_slow -#define ARG1 cache -#define ARG1_DECL MemoryRegionCache *cache -#define TARGET_ENDIANNESS -#include "exec/memory_ldst.h.inc" - static inline void stl_phys_notdirty(AddressSpace *as, hwaddr addr, uint32_t val) { address_space_stl_notdirty(as, addr, val, diff --git a/include/exec/memory_ldst.h.inc b/include/exec/memory_ldst.h.inc index 92ad74e9560..7270235c600 100644 --- a/include/exec/memory_ldst.h.inc +++ b/include/exec/memory_ldst.h.inc @@ -19,7 +19,6 @@ * License along with this library; if not, see . */ -#ifdef TARGET_ENDIANNESS uint16_t glue(address_space_lduw, SUFFIX)(ARG1_DECL, hwaddr addr, MemTxAttrs attrs, MemTxResult *result); uint32_t glue(address_space_ldl, SUFFIX)(ARG1_DECL, @@ -34,7 +33,6 @@ void glue(address_space_stl, SUFFIX)(ARG1_DECL, hwaddr addr, uint32_t val, MemTxAttrs attrs, MemTxResult *result); void glue(address_space_stq, SUFFIX)(ARG1_DECL, hwaddr addr, uint64_t val, MemTxAttrs attrs, MemTxResult *result); -#else uint8_t glue(address_space_ldub, SUFFIX)(ARG1_DECL, hwaddr addr, MemTxAttrs attrs, MemTxResult *result); uint16_t glue(address_space_lduw_le, SUFFIX)(ARG1_DECL, @@ -63,9 +61,7 @@ void glue(address_space_stq_le, SUFFIX)(ARG1_DECL, hwaddr addr, uint64_t val, MemTxAttrs attrs, MemTxResult *result); void glue(address_space_stq_be, SUFFIX)(ARG1_DECL, hwaddr addr, uint64_t val, MemTxAttrs attrs, MemTxResult *result); -#endif #undef ARG1_DECL #undef ARG1 #undef SUFFIX -#undef TARGET_ENDIANNESS