Fri Jan 7 02:56:44 2011 UTC ()
Deal with the new trapframe


(matt)
diff -r1.2 -r1.2.28.1 src/gnu/dist/gdb6/gdb/ppcnbsd-nat.c

cvs diff -r1.2 -r1.2.28.1 src/gnu/dist/gdb6/gdb/Attic/ppcnbsd-nat.c (expand / switch to unified diff)

--- src/gnu/dist/gdb6/gdb/Attic/ppcnbsd-nat.c 2006/12/06 18:25:29 1.2
+++ src/gnu/dist/gdb6/gdb/Attic/ppcnbsd-nat.c 2011/01/07 02:56:44 1.2.28.1
@@ -147,40 +147,40 @@ ppcnbsd_store_inferior_registers (int re @@ -147,40 +147,40 @@ ppcnbsd_store_inferior_registers (int re
147static int 147static int
148ppcnbsd_supply_pcb (struct regcache *regcache, struct pcb *pcb) 148ppcnbsd_supply_pcb (struct regcache *regcache, struct pcb *pcb)
149{ 149{
150 struct switchframe sf; 150 struct switchframe sf;
151 struct callframe cf; 151 struct callframe cf;
152 struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch); 152 struct gdbarch_tdep *tdep = gdbarch_tdep (current_gdbarch);
153 int i; 153 int i;
154 154
155 /* The stack pointer shouldn't be zero. */ 155 /* The stack pointer shouldn't be zero. */
156 if (pcb->pcb_sp == 0) 156 if (pcb->pcb_sp == 0)
157 return 0; 157 return 0;
158 158
159 read_memory (pcb->pcb_sp, (gdb_byte *)&sf, sizeof sf); 159 read_memory (pcb->pcb_sp, (gdb_byte *)&sf, sizeof sf);
160 regcache_raw_supply (regcache, tdep->ppc_cr_regnum, &sf.cr); 160 regcache_raw_supply (regcache, tdep->ppc_cr_regnum, &sf.sf_cr);
161 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 2, &sf.fixreg2); 161 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 2, &sf.sf_fixreg2);
162 for (i = 0 ; i < 19 ; i++) 162 for (i = 0 ; i < 19 ; i++)
163 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 13 + i, 163 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 13 + i,
164 &sf.fixreg[i]); 164 &sf.sf_fixreg[i]);
165 165
166 read_memory(sf.sp, (gdb_byte *)&cf, sizeof(cf)); 166 read_memory(sf.sf_sp, (gdb_byte *)&cf, sizeof(cf));
167 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 30, &cf.r30); 167 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 30, &cf.cf_r30);
168 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 31, &cf.r31); 168 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 31, &cf.cf_r31);
169 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 1, &cf.sp); 169 regcache_raw_supply (regcache, tdep->ppc_gp0_regnum + 1, &cf.cf_sp);
170 170
171 read_memory(cf.sp, (gdb_byte *)&cf, sizeof(cf)); 171 read_memory(cf.cf_sp, (gdb_byte *)&cf, sizeof(cf));
172 regcache_raw_supply (regcache, tdep->ppc_lr_regnum, &cf.lr); 172 regcache_raw_supply (regcache, tdep->ppc_lr_regnum, &cf.cf_lr);
173 regcache_raw_supply (regcache, PC_REGNUM, &cf.lr); 173 regcache_raw_supply (regcache, PC_REGNUM, &cf.cf_lr);
174 174
175 return 1; 175 return 1;
176} 176}
177 177
178/* Provide a prototype to silence -Wmissing-prototypes. */ 178/* Provide a prototype to silence -Wmissing-prototypes. */
179void _initialize_ppcnbsd_nat (void); 179void _initialize_ppcnbsd_nat (void);
180 180
181void 181void
182_initialize_ppcnbsd_nat (void) 182_initialize_ppcnbsd_nat (void)
183{ 183{
184 struct target_ops *t; 184 struct target_ops *t;
185 185
186 /* Support debugging kernel virtual memory images. */ 186 /* Support debugging kernel virtual memory images. */