Message ID | 20241204202602.58083-10-philmd@linaro.org |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 2002:a5d:434d:0:b0:385:e875:8a9e with SMTP id u13csp530112wrr; Wed, 4 Dec 2024 12:31:19 -0800 (PST) X-Forwarded-Encrypted: i=2; AJvYcCVLzq7TlTt5wrMLrq0ffQV1PTkpDzTh1j5eguN47LebE+Br8LW8Z54540PE3h7SfKzR6QspwA==@linaro.org X-Google-Smtp-Source: AGHT+IGw7BSgJgaDihJShd/3dhaApKHlKJxTlI1oWMgJZkeR3flA/6PzbqW7/E0Y7wkqgyQA3tCv X-Received: by 2002:a05:6102:f11:b0:4af:5682:975b with SMTP id ada2fe7eead31-4af973ef0cfmr10416706137.24.1733344279654; Wed, 04 Dec 2024 12:31:19 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1733344279; cv=none; d=google.com; s=arc-20240605; b=dpi7tNQ9FGyW1mwg/iq3j9nhX/w9eD5466QcKfFzF3UAEzvMV9azfRxkmceA9wthR9 SRWeutAEMB0PLyLT3C5YL8wTGSMQe7xJNwvjgFKtRCEHcEa7oKRoOKY55mowwr46L5VO AwVLFPdHeoO+2yIu/3yvTRPvy00qTFL+Ck4zwu3i6VNgWFrtUvffY/imr3u5woOIV/6v XJhnCPOaIxgstLzAff0C6BqfXftk1cWXvGcHx5DJhXrhCAEfYbt5K/Bnx6rpdwK0MQ3+ IWute/BVVDVPfWpsPCeRv07m25BQhLpjT6iNU76EBj/hkpBGPS79p7XF25AXC1H1gjNV MNCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; 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=0gEXG14yGHmTwK2PkgnJuKn3fmfO28N4tNUnsroDG+o=; fh=L8jp5KII9BO+EuE1/Uny/8be6w87XhXr9oO98kXieYU=; b=GUJNzyXAn46bL5NIdBuxtNBVvXnAMLVsfe1QDznAP/bcwF3yFxDNXDVNu2uR9y3Fph RXitqs4bKWstL9uMW5ePDn2vPsv4ytVUxE2Ez/RUY0Cq+BtxVeTubdTYbfjOsvHS22ci BIV/GeoxhZyEMgEhqVv+c0mFxlVS3LaVjt4J1EVOaDQaq0SJ2BpiTZqhG1q1QuP1GoSP JPRUvOscW8WTA/d5JoFVz6VUhf4N9xzJeknP6ofJGVHJifVNp9TRgQ0j0Mb836qQptP5 VbFY/qyhdf3bEA4BHebabuOZzrt2QT49boHDU+nRAyPB4qQs6cG6D/4lw1kY4ZhMCIXB 1QRg==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Glp+Z1yU; 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; dara=neutral header.i=@linaro.org Return-Path: <qemu-devel-bounces+patch=linaro.org@nongnu.org> Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id ada2fe7eead31-4afbc68fcf7si2628137.231.2024.12.04.12.31.19 for <patch@linaro.org> (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 04 Dec 2024 12: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=Glp+Z1yU; 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; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces@nongnu.org>) id 1tIvyN-0000ew-LZ; Wed, 04 Dec 2024 15:27:47 -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 <philmd@linaro.org>) id 1tIvyB-0000RM-8V for qemu-devel@nongnu.org; Wed, 04 Dec 2024 15:27:37 -0500 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from <philmd@linaro.org>) id 1tIvy8-0000OB-V3 for qemu-devel@nongnu.org; Wed, 04 Dec 2024 15:27:35 -0500 Received: by mail-wr1-x429.google.com with SMTP id ffacd0b85a97d-385dece873cso127814f8f.0 for <qemu-devel@nongnu.org>; Wed, 04 Dec 2024 12:27:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1733344051; x=1733948851; 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=0gEXG14yGHmTwK2PkgnJuKn3fmfO28N4tNUnsroDG+o=; b=Glp+Z1yU/0jga31NZn4x61NUaTQLfZabWAkdUbej0ntLhq01Qbg8L7rJYBeFC4S+s4 w1lZsmj15fGTG2Hhiput/kT/tkpeFmGEPUyxaEu0UJMNgmxpHj+sAAUJ58hARdlrAs6e sTTLvzt7tULHWHMwCHs3EtCbNAL4DNP8wRrb1M8Jmw8TKjpIMuiN3W7oFZ1le9vcA5mc xJYvkqdbWxjBHLdRQdLjJubx1zyxwT3YamIr3k+ZCZnUJrJRVHxzJqt2dsZFzBalyigJ e3liYxZX1yL2hhffiui1lOvLlvS8b4P9tLFikL3T8HU/4p/Oxm0d9aHdZnFisdmOIP5w 7NXw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1733344051; x=1733948851; 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=0gEXG14yGHmTwK2PkgnJuKn3fmfO28N4tNUnsroDG+o=; b=LsWeJ1+KTxk5c8OLW5LdIGIO81sMIucQkol2aptbB/Ct5PM01CujemZYU6Jl0WjqHY IqeBbvlMQraNMXnv2c1lEB2RxjcR2A8s2KHr2DRmbvmgZ5udTckoNTx9J0mTnjvFVVdp oGv1WqqiabTn2Rma7KlygibZnCUtbI3+3nwG9sTLlimhTi/++fNI3IQTT4bH/ZXNzu2s 4DoueA4YNcQ6AnWtUIvHmVniQUZZc0xgjsF2i6XBVow1ZPG/WcxH9LricRpYksGWSz4k iJzz32tBBudbnzYDm5PDJ/IgWGECf0COB6rJXgmxy51XClu4AUEqzP21OMT/WWRifwCn 6pOQ== X-Gm-Message-State: AOJu0YxG7ARGxM8NB+tl8u0Pri4Dkl1FmunO5ldwzJ9yY7V/dtifNYcT rlgQ+mRZSI991NSpkVKlVV5fQ3SNakzOpaX3U4zag5xNmjwP60yLW0apP42DSo24tR68yxFm0+z r X-Gm-Gg: ASbGnctZO+XQI6yM9RuAfMSbj72s6Iv/Nqg3Ueu8Q3dCyoa9zZlCfSTw2/B/2YtK9T0 gQFEyImC4KeX3TmiBiNnUkZBqkKziQpJkO8102q8Xui9d/gduuAHMEDTEORCcfkd+nDZMXR+a+m KpHPpV5jMYoAVnm/6Hjld2YzS5pwRt+8Nqat+EKG4s+ZQcK5uBTprXnRretMHUzQP/1H301q/+3 mRRHOZyy0x8nvJP9e0kmyPu5MSWvUIKTzrhLx4UMGVWOLdZEobkmD3eomQrULnJXrkg63peCBk+ pAy8egvIW0yMwnv6P3FJmGDL X-Received: by 2002:a05:6000:1885:b0:382:5010:c8de with SMTP id ffacd0b85a97d-38607c164f8mr4720969f8f.46.1733344051161; Wed, 04 Dec 2024 12:27:31 -0800 (PST) Received: from localhost.localdomain (88-187-86-199.subs.proxad.net. [88.187.86.199]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-385d80a77a0sm17412914f8f.58.2024.12.04.12.27.29 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Wed, 04 Dec 2024 12:27:30 -0800 (PST) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= <philmd@linaro.org> To: qemu-devel@nongnu.org Cc: Daniel Henrique Barboza <dbarboza@ventanamicro.com>, "Michael S. Tsirkin" <mst@redhat.com>, Peter Maydell <peter.maydell@linaro.org>, Laurent Vivier <lvivier@redhat.com>, Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>, Alistair Francis <alistair.francis@wdc.com>, Anton Johansson <anjo@rev.ng>, Zhao Liu <zhao1.liu@intel.com>, "Edgar E. Iglesias" <edgar.iglesias@gmail.com>, David Hildenbrand <david@redhat.com>, qemu-s390x@nongnu.org, Max Filippov <jcmvbkbc@gmail.com>, Paolo Bonzini <pbonzini@redhat.com>, Nicholas Piggin <npiggin@gmail.com>, qemu-arm@nongnu.org, Thomas Huth <thuth@redhat.com>, qemu-riscv@nongnu.org, Alistair Francis <alistair@alistair23.me>, qemu-ppc@nongnu.org, Richard Henderson <richard.henderson@linaro.org>, =?utf-8?q?Philippe_Mathie?= =?utf-8?q?u-Daud=C3=A9?= <philmd@linaro.org> Subject: [PATCH 09/20] target/sh4: Implement CPUClass::datapath_is_big_endian Date: Wed, 4 Dec 2024 21:25:51 +0100 Message-ID: <20241204202602.58083-10-philmd@linaro.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241204202602.58083-1-philmd@linaro.org> References: <20241204202602.58083-1-philmd@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2a00:1450:4864:20::429; envelope-from=philmd@linaro.org; helo=mail-wr1-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 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org |
Series |
target: Implement CPUClass::datapath_is_big_endian() handlers
|
expand
|
diff --git a/target/sh4/cpu.c b/target/sh4/cpu.c index f54005644c9..69108c1676e 100644 --- a/target/sh4/cpu.c +++ b/target/sh4/cpu.c @@ -29,6 +29,13 @@ #include "fpu/softfloat-helpers.h" #include "tcg/tcg.h" +static bool superh_cpu_datapath_is_big_endian(CPUState *cs) +{ + SuperHCPU *cpu = SUPERH_CPU(cs); + + return !cpu->env.little_endian; +} + static void superh_cpu_set_pc(CPUState *cs, vaddr value) { SuperHCPU *cpu = SUPERH_CPU(cs); @@ -283,6 +290,7 @@ static void superh_cpu_class_init(ObjectClass *oc, void *data) &scc->parent_phases); cc->class_by_name = superh_cpu_class_by_name; + cc->datapath_is_big_endian = superh_cpu_datapath_is_big_endian; cc->has_work = superh_cpu_has_work; cc->mmu_index = sh4_cpu_mmu_index; cc->dump_state = superh_cpu_dump_state;
Implement SH4 datapath_is_big_endian() helper, returning the 'little_endian' property set at reset. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> --- target/sh4/cpu.c | 8 ++++++++ 1 file changed, 8 insertions(+)