/[gxemul]/trunk/src/cpus/cpu_alpha_palcode.c
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/src/cpus/cpu_alpha_palcode.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 22 by dpavlin, Mon Oct 8 16:19:37 2007 UTC revision 24 by dpavlin, Mon Oct 8 16:19:56 2007 UTC
# Line 25  Line 25 
25   *  SUCH DAMAGE.   *  SUCH DAMAGE.
26   *   *
27   *   *
28   *  $Id: cpu_alpha_palcode.c,v 1.5 2006/01/14 13:15:32 debug Exp $   *  $Id: cpu_alpha_palcode.c,v 1.8 2006/06/02 18:11:38 debug Exp $
29   *   *
30   *  Alpha PALcode-related functionality.   *  Alpha PALcode-related functionality.
31   */   */
# Line 120  void alpha_prom_call(struct cpu *cpu) Line 120  void alpha_prom_call(struct cpu *cpu)
120                  /*  getenv  */                  /*  getenv  */
121                  fatal("[ Alpha PALcode: GXemul PROM call 0x22: TODO ]\n");                  fatal("[ Alpha PALcode: GXemul PROM call 0x22: TODO ]\n");
122                  break;                  break;
123          default:fatal("[ Alpha PALcode: GXemul PROM call, a0=0x%llx ]\n",          default:fatal("[ Alpha PALcode: GXemul PROM call, a0=0x%"PRIx64" ]\n",
124                      (long long)cpu->cd.alpha.r[ALPHA_A0]);                      (uint64_t) cpu->cd.alpha.r[ALPHA_A0]);
125                  cpu->running = 0;                  cpu->running = 0;
126          }          }
127    
# Line 149  void alpha_palcode(struct cpu *cpu, uint Line 149  void alpha_palcode(struct cpu *cpu, uint
149                  /*  Floating point enable: a0 = 1 or 0.  */                  /*  Floating point enable: a0 = 1 or 0.  */
150                  /*  TODO  */                  /*  TODO  */
151                  break;                  break;
152            case 0x2d:      /*  PAL_OSF1_wrvptptr  */
153                    /*  a0 = value  */
154                    cpu->cd.alpha.wrvptptr = cpu->cd.alpha.r[ALPHA_A0];
155                    break;
156            case 0x30:      /*  PAL_OSF1_swpctx  */
157                    /*  TODO  */
158                    /*  Swap context  */
159                    break;
160          case 0x31:      /*  PAL_OSF1_wrval  */          case 0x31:      /*  PAL_OSF1_wrval  */
161                  /*  a0 = value  */                  /*  a0 = value  */
162                  cpu->cd.alpha.sysvalue = cpu->cd.alpha.r[ALPHA_A0];                  cpu->cd.alpha.sysvalue = cpu->cd.alpha.r[ALPHA_A0];
# Line 159  void alpha_palcode(struct cpu *cpu, uint Line 167  void alpha_palcode(struct cpu *cpu, uint
167                  break;                  break;
168          case 0x33:      /*  PAL_OSF1_tbi  */          case 0x33:      /*  PAL_OSF1_tbi  */
169                  /*  a0 = op, a1 = vaddr  */                  /*  a0 = op, a1 = vaddr  */
170                  debug("[ Alpha PALcode: PAL_OSF1_tbi: a0=%lli a1=0x%llx ]\n",                  debug("[ Alpha PALcode: PAL_OSF1_tbi: a0=%"PRIi64" a1=0x%"
171                      (signed long long)cpu->cd.alpha.r[ALPHA_A0],                      PRIx64" ]\n", (int64_t)cpu->cd.alpha.r[ALPHA_A0],
172                      (long long)cpu->cd.alpha.r[ALPHA_A1]);                      (uint64_t)cpu->cd.alpha.r[ALPHA_A1]);
173                  /*  TODO  */                  /*  TODO  */
174                  break;                  break;
175          case 0x34:      /*  PAL_OSF1_wrent (Write System Entry Address)  */          case 0x34:      /*  PAL_OSF1_wrent (Write System Entry Address)  */
176                  /*  a0 = new vector, a1 = vector selector  */                  /*  a0 = new vector, a1 = vector selector  */
177                  debug("[ Alpha PALcode: PAL_OSF1_tbi: a0=%lli a1=0x%llx ]\n",                  debug("[ Alpha PALcode: PAL_OSF1_tbi: a0=%"PRIi64" a1=0x%"
178                      (signed long long)cpu->cd.alpha.r[ALPHA_A0],                      PRIx64" ]\n", (int64_t) cpu->cd.alpha.r[ALPHA_A0],
179                      (long long)cpu->cd.alpha.r[ALPHA_A1]);                      (uint64_t) cpu->cd.alpha.r[ALPHA_A1]);
180                  /*  TODO  */                  /*  TODO  */
181                  break;                  break;
182          case 0x35:      /*  PAL_OSF1_swpipl  */          case 0x35:      /*  PAL_OSF1_swpipl  */
# Line 205  void alpha_palcode(struct cpu *cpu, uint Line 213  void alpha_palcode(struct cpu *cpu, uint
213          case 0x86:      /*  PAL_OSF1_imb  */          case 0x86:      /*  PAL_OSF1_imb  */
214                  /*  TODO  */                  /*  TODO  */
215                  break;                  break;
216            case 0x3fffffd:
217                    fatal("[ Alpha PALcode: Fixup: TODO ]\n");
218                    /*  Return from the fixup call.  */
219                    cpu->cd.alpha.r[ALPHA_V0] = 0;  /*  Success?  */
220                    cpu->pc = cpu->cd.alpha.r[ALPHA_RA];
221                    break;
222          case 0x3fffffe:          case 0x3fffffe:
223                  alpha_prom_call(cpu);                  alpha_prom_call(cpu);
224                  break;                  break;

Legend:
Removed from v.22  
changed lines
  Added in v.24

  ViewVC Help
Powered by ViewVC 1.1.26