[1/2] Nios2, libbfd: Support new coredump .reg section
Checks
Context |
Check |
Description |
linaro-tcwg-bot/tcwg_gdb_build--master-aarch64 |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_build--master-arm |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_check--master-arm |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gdb_check--master-aarch64 |
success
|
Testing passed
|
Commit Message
The coredumps of the current kernel are larger.
---
bfd/elf32-nios2.c | 11 +++++++++++
1 file changed, 11 insertions(+)
Comments
>>>>> "Moritz" == Moritz Strübe <moritz.struebe@siemens-energy.com> writes:
Moritz> The coredumps of the current kernel are larger.
Hi. BFD patches should go to the binutils list.
FWIW I'm a little surprised to see this given that nios2 was just
deprecated in GCC.
Tom
Hi,
I just spotted Sandra's message [1] about nios2 deprecation.
Do we have plans for deprecating such support in binutils/gdb as well, for the
sake of reducing future maintenance burden?
On 4/19/24 11:39, Moritz Strübe wrote:
> The coredumps of the current kernel are larger.
> ---
> bfd/elf32-nios2.c | 11 +++++++++++
> 1 file changed, 11 insertions(+)
>
> diff --git a/bfd/elf32-nios2.c b/bfd/elf32-nios2.c
> index 806ec314c82..3d0fa6fbf27 100644
> --- a/bfd/elf32-nios2.c
> +++ b/bfd/elf32-nios2.c
> @@ -1921,7 +1921,18 @@ nios2_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
> {
> default:
> return false;
> + case 272: /* Linux/Nios II */
> + /* pr_cursig */
> + elf_tdata (abfd)->core->signal = bfd_get_16 (abfd, note->descdata + 12);
> +
> + /* pr_pid */
> + elf_tdata (abfd)->core->pid = bfd_get_32 (abfd, note->descdata + 24);
>
> + /* pr_reg */
> + offset = 72;
> + size = 196;
> +
> + break;
> case 212: /* Linux/Nios II */
> /* pr_cursig */
> elf_tdata (abfd)->core->signal = bfd_get_16 (abfd, note->descdata + 12);
[1] https://gcc.gnu.org/pipermail/gcc/2024-April/243749.html
On 4/23/24 07:28, Luis Machado wrote:
> Hi,
>
> I just spotted Sandra's message [1] about nios2 deprecation.
>
> Do we have plans for deprecating such support in binutils/gdb as well, for the
> sake of reducing future maintenance burden?
Yes, I plan to take care of producing patches to remove the nios2 port
entirely from binutils/gdb, as well as from gcc, a little bit farther
down the line. I'm not sure of the best timing with respect to upcoming
releases, and at the moment I am swamped with other tasks anyway, but
it's definitely on my list of things to do -- I don't want to leave this
as a pointless maintenance burden for others.
-Sandra
On 2024-04-23 10:51, Sandra Loosemore wrote:
> On 4/23/24 07:28, Luis Machado wrote:
>> Hi,
>>
>> I just spotted Sandra's message [1] about nios2 deprecation.
>>
>> Do we have plans for deprecating such support in binutils/gdb as well, for the
>> sake of reducing future maintenance burden?
>
> Yes, I plan to take care of producing patches to remove the nios2 port entirely from binutils/gdb, as well as from gcc, a little bit farther down the line. I'm not sure of the best timing with respect to upcoming releases, and at the moment I am swamped with other tasks anyway, but it's definitely on my list of things to do -- I don't want to leave this as a pointless maintenance burden for others.
>
> -Sandra
Thanks a lot for being proactive with this.
Simon
On 4/23/24 15:51, Sandra Loosemore wrote:
> On 4/23/24 07:28, Luis Machado wrote:
>> Hi,
>>
>> I just spotted Sandra's message [1] about nios2 deprecation.
>>
>> Do we have plans for deprecating such support in binutils/gdb as well, for the
>> sake of reducing future maintenance burden?
>
> Yes, I plan to take care of producing patches to remove the nios2 port entirely from binutils/gdb, as well as from gcc, a little bit farther down the line. I'm not sure of the best timing with respect to upcoming releases, and at the moment I am swamped with other tasks anyway, but it's definitely on my list of things to do -- I don't want to leave this as a pointless maintenance burden for others.
>
> -Sandra
Great. Thanks for the update Sandra.
@@ -1921,7 +1921,18 @@ nios2_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
{
default:
return false;
+ case 272: /* Linux/Nios II */
+ /* pr_cursig */
+ elf_tdata (abfd)->core->signal = bfd_get_16 (abfd, note->descdata + 12);
+
+ /* pr_pid */
+ elf_tdata (abfd)->core->pid = bfd_get_32 (abfd, note->descdata + 24);
+ /* pr_reg */
+ offset = 72;
+ size = 196;
+
+ break;
case 212: /* Linux/Nios II */
/* pr_cursig */
elf_tdata (abfd)->core->signal = bfd_get_16 (abfd, note->descdata + 12);