Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
qemu.313
0072-target-ppc-Set-the-correct-endianne.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0072-target-ppc-Set-the-correct-endianne.patch of Package qemu.313
From 38843e60d3df26db4c8ee4a1923e95f2d2c15679 Mon Sep 17 00:00:00 2001 From: Bharata B Rao <bharata@linux.vnet.ibm.com> Date: Mon, 19 May 2014 19:59:22 +0200 Subject: [PATCH] target-ppc: Set the correct endianness in ELF dump header Signed-off-by: Bharata B Rao <bharata@linux.vnet.ibm.com> Reviewed-by: Alexander Graf <agraf@suse.de> Signed-off-by: Greg Kurz <gkurz@linux.vnet.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de> (cherry picked from commit 1e6ed54ef84c5c131216bcef44930970eee8f687) --- target-ppc/arch_dump.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/target-ppc/arch_dump.c b/target-ppc/arch_dump.c index 5a3b40d..5acafc6 100644 --- a/target-ppc/arch_dump.c +++ b/target-ppc/arch_dump.c @@ -209,12 +209,16 @@ typedef struct NoteFuncDescStruct NoteFuncDesc; int cpu_get_dump_info(ArchDumpInfo *info, const struct GuestPhysBlockList *guest_phys_blocks) { - /* - * Currently only handling PPC64 big endian. - */ + PowerPCCPU *cpu = POWERPC_CPU(first_cpu); + PowerPCCPUClass *pcc = POWERPC_CPU_GET_CLASS(cpu); + info->d_machine = EM_PPC64; - info->d_endian = ELFDATA2MSB; info->d_class = ELFCLASS64; + if ((*pcc->interrupts_big_endian)(cpu)) { + info->d_endian = ELFDATA2MSB; + } else { + info->d_endian = ELFDATA2LSB; + } return 0; }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor