This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Fix sparc-vxworks build failure
- From: Michael Snyder <msnyder at redhat dot com>
- To: "David S. Miller" <davem at redhat dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Tue, 23 Apr 2002 12:02:43 -0700
- Subject: Re: [RFA] Fix sparc-vxworks build failure
- Organization: Red Hat, Inc.
- References: <20020421.231928.100652835.davem@redhat.com>
"David S. Miller" wrote:
>
> I found this while trying to test build every sparc target.
>
> As an aside, any particular reason one is not allowed to
> cross build gdb for the sparc-*-sunos* target? :(
>
> The typo below is pretty obvious, I think. Trying to get the
> REGISTER_BYTES of "CORE_ADDR" is pretty bogus :-)
>
> Ok to install?
Yes, thanks.
>
> 2002-04-21 David S. Miller <davem@redhat.com>
>
> * remote-vxsparc.c (vx_read_register): Fix typo, we want
> REGISTER_RAW_SIZE of SP_REGNUM not CORE_ADDR.
> (vx_write_register): Likewise.
>
> --- remote-vxsparc.c.~1~ Wed Feb 28 17:39:21 2001
> +++ remote-vxsparc.c Sun Apr 21 23:18:00 2002
> @@ -102,7 +102,7 @@ vx_read_register (int regno)
> (FRAME_FIND_SAVED_REGS, in particular, depends on this). */
>
> sp = extract_address (®isters[REGISTER_BYTE (SP_REGNUM)],
> - REGISTER_RAW_SIZE (CORE_ADDR));
> + REGISTER_RAW_SIZE (SP_REGNUM));
> write_memory (sp, ®isters[REGISTER_BYTE (L0_REGNUM)],
> 16 * REGISTER_RAW_SIZE (L0_REGNUM));
>
> @@ -173,7 +173,7 @@ vx_write_register (int regno)
> if (regno < 0 || (L0_REGNUM <= regno && regno <= I7_REGNUM))
> {
> sp = extract_address (®isters[REGISTER_BYTE (SP_REGNUM)],
> - REGISTER_RAW_SIZE (CORE_ADDR));
> + REGISTER_RAW_SIZE (SP_REGNUM));
> write_memory (sp, ®isters[REGISTER_BYTE (L0_REGNUM)],
> 16 * REGISTER_RAW_SIZE (L0_REGNUM));
> }