zdump: Drop support of 32-bit dump architecture

- Initialize dump and dump-tool architecture to DFI_ARCH_64 at the start
  of dfi_init() and dt_init() respectively.
- Bail out if any dump architecture other than ARCH_64 has been detected
  in s390_ext or s390mv_ext DASD dump header.
- Remove redundant dfi_arch_set() and dt_arch_set() functions.
- Get rid of l.arch local variables in dfi* and dt* source files and
  drop dfi_arch() function.
- Drop the usage of DFI_ARCH_32 and compeletely remove DFI_ARCH_UNKNOWN.
- Drop special register and lowcore processing functions used
  for DFI_ARCH_32.
- Drop df_s390_from_dfi_arch() and df_s390_to_dfi_arch() funcitons.
- Update the man file for zgetdump.

Signed-off-by: Mikhail Zaslonko <zaslonko@linux.ibm.com>
Reviewed-by: Alexander Egorenkov <egorenar@linux.ibm.com>
Signed-off-by: Jan Höppner <hoeppner@linux.ibm.com>
This commit is contained in:
Mikhail Zaslonko
2024-11-04 12:05:52 +01:00
committed by Jan Höppner
parent ee4cb78dc2
commit f821a3c174
20 changed files with 29 additions and 204 deletions
+7 -8
View File
@@ -111,18 +111,16 @@ static int detect_mem_chunks(int check)
}
/*
* Return architecture of running system
* Verify architecture of running system
*/
static enum dfi_arch system_arch(void)
static void check_system_arch(void)
{
struct utsname utsname;
uname(&utsname);
if (memcmp(utsname.machine, "s390x", 5) == 0)
return DFI_ARCH_64;
if (memcmp(utsname.machine, "s390", 4) == 0)
return DFI_ARCH_32;
return DFI_ARCH_UNKNOWN;
if (memcmp(utsname.machine, "s390x", 5) != 0)
ERR_EXIT("Dump architecture \"%s\" is not supported",
utsname.machine);
}
/*
@@ -133,7 +131,8 @@ static int dfi_devmem_init(void)
if (strcmp(g.fh->path, "/dev/mem") != 0 &&
strcmp(g.fh->path, "/dev/crash") != 0)
return -ENODEV;
dfi_arch_set(system_arch());
check_system_arch();
dfi_cpu_info_init(DFI_CPU_CONTENT_NONE);
detect_mem_chunks(0);
dfi_attr_dump_method_set(DFI_DUMP_METHOD_LIVE);