ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/cebix/SheepShaver/src/rom_patches.cpp
(Generate patch)

Comparing SheepShaver/src/rom_patches.cpp (file contents):
Revision 1.14 by gbeauche, 2003-10-06T21:00:48Z vs.
Revision 1.17 by gbeauche, 2003-10-07T19:28:09Z

# Line 58 | Line 58
58  
59  
60   // Other ROM addresses
61 < const uint32 CHECK_LOAD_PATCH_SPACE = 0x2f7f00;
62 < const uint32 PUT_SCRAP_PATCH_SPACE = 0x2f7f80;
63 < const uint32 GET_SCRAP_PATCH_SPACE = 0x2f7fc0;
64 < const uint32 ADDR_MAP_PATCH_SPACE = 0x2f8000;
61 > const uint32 CHECK_LOAD_PATCH_SPACE = 0x2fcf00;
62 > const uint32 PUT_SCRAP_PATCH_SPACE = 0x2fcf80;
63 > const uint32 GET_SCRAP_PATCH_SPACE = 0x2fcfc0;
64 > const uint32 ADDR_MAP_PATCH_SPACE = 0x2fd000;
65  
66   // Global variables
67   int ROMType;                            // ROM type
# Line 131 | Line 131 | void decode_parcels(const uint8 *src, ui
131                            (parcel_type >> 8) & 0xff, parcel_type & 0xff, &parcel_data[6]));
132                  if (parcel_type == FOURCC('r','o','m',' ')) {
133                          uint32 lzss_offset  = ntohl(parcel_data[2]);
134 <                        uint32 lzss_size = ((uint32)src + parcel_offset) - ((uint32)parcel_data + lzss_offset);
134 >                        uint32 lzss_size = ((uintptr)src + next_offset) - ((uintptr)parcel_data + lzss_offset);
135                          decode_lzss((uint8 *)parcel_data + lzss_offset, dest, lzss_size);
136                  }
137                  parcel_offset = next_offset;
# Line 726 | Line 726 | bool PatchROM(void)
726                  return false;
727  
728          // Check that other ROM addresses point to really free regions
729        printf("%08x\n", ntohl(*(uint32 *)(ROM_BASE + CHECK_LOAD_PATCH_SPACE)));
729          if (ntohl(*(uint32 *)(ROM_BASE + CHECK_LOAD_PATCH_SPACE)) != 0x6b636b63)
730                  return false;
731          if (ntohl(*(uint32 *)(ROM_BASE + PUT_SCRAP_PATCH_SPACE)) != 0x6b636b63)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines