mirror of
https://github.com/Proxmark/proxmark3.git
synced 2025-07-16 02:03:00 -07:00
Eradicate all occurences of hardcoded memory addresses from all sources files, except for the FPGA bitstream fallback
This commit is contained in:
parent
52b3d184ce
commit
e3ae025783
7 changed files with 26 additions and 13 deletions
|
@ -1,11 +1,13 @@
|
|||
#include <proxmark3.h>
|
||||
|
||||
extern char __bootphase2_src_start__, __bootphase2_start__, __bootphase2_end__;
|
||||
void __attribute__((section(".bootphase1"))) CopyBootToRAM(void)
|
||||
{
|
||||
int i;
|
||||
|
||||
volatile DWORD *s = (volatile DWORD *)0x200;
|
||||
volatile DWORD *d = (volatile DWORD *)0x200000;
|
||||
volatile DWORD *s = (volatile DWORD *)&__bootphase2_src_start__;
|
||||
volatile DWORD *d = (volatile DWORD *)&__bootphase2_start__;
|
||||
unsigned int l = (int)&__bootphase2_end__ - (int)&__bootphase2_start__;
|
||||
|
||||
for(i = 0; i < 1024; i++) *d++ = *s++;
|
||||
for(i = 0; i < l/sizeof(DWORD); i++) *d++ = *s++;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue