[AArch64][5/6] Implement gdbarch_core_read_description

Yao Qi qiyaoltc@gmail.com
Wed Aug 9 14:22:00 GMT 2017


Jiong Wang <jiong.wang@foss.arm.com> writes:

> 2017-08-09  Jiong Wang<jiong.wang@arm.com>

Two spaces between your name and email address.

>
> 	* aarch64-linux-tdep.c (aarch64_linux_core_read_description): New
> 	function.
> 	(aarch64_linux_init_abi): Register gdbarch_core_read_description.
>
>
> diff --git a/gdb/aarch64-linux-tdep.c b/gdb/aarch64-linux-tdep.c
> index d2ca70a..ec6125a 100644
> --- a/gdb/aarch64-linux-tdep.c
> +++ b/gdb/aarch64-linux-tdep.c
> @@ -231,6 +231,20 @@ aarch64_linux_iterate_over_regset_sections (struct gdbarch *gdbarch,
>        NULL, cb_data);
>  }
>  
> +/* Determine target description from core file.  */

/* Implement the "core_read_description" gdbarch method.  */

> +
> +static const struct target_desc *
> +aarch64_linux_core_read_description (struct gdbarch *gdbarch,
> +				     struct target_ops *target, bfd *abfd)
> +{
> +  CORE_ADDR aarch64_hwcap = 0;
> +
> +  if (target_auxv_search (target, AT_HWCAP, &aarch64_hwcap) != 1)
> +    return NULL;
> +
> +  return tdesc_aarch64;
> +}

This patch doesn't depend on other patches, so it can go in now.

-- 
Yao (齐尧)



More information about the Gdb-patches mailing list