⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 xtra.s

📁 Boot code for ADM5120 with serial console for Edimax router.
💻 S
字号:
/*****************************************************************************;;    Project : ADM5120;    Creator : Dan Everett;    File    : xtra.S;    Abstract: ;;*****************************************************************************/#include <mips.h>#include <mips4kc.h>#include <asm.h>#include <adm5120.h>#include <test_def.h>.text#if TEST_BOOTLOADER == 1LEAF(addr_test).set noreorder	move	t0, ra		// save return address	la		t1, 1f	sw		t1, 0(a0)	and		t1, ~MEM_SEG_MASK	or		t1, MEM_KSEG1_BASE	jr		t1	nop1:	/* Now in Kseg1 unmapped and uncached */	/* Get current position */	bal		_get_pc	nop	la		t1, 2f	jr		t1	nop2:	/* Now back in Kseg0 unmapped but cached */	/* Save result of _get_pc() */	sw		v0, 4(a0)	move	ra, t0		// restore return address	/* Get CP0 status register */	mfc0	t0, CP0_STATUS_REG	sw		t0, 8(a0)	/* Get CP0 configuration 0  register */	mfc0	t0, CP0_CONFIG0_REG, 0	sw		t0, 12(a0)	/* Get CP0 configuration 1  register */	mfc0	t0, CP0_CONFIG0_REG, 1	sw		t0, 16(a0)	/* Get $gp register */	sw		gp, 20(a0)	/* Get heap address */	lw		t0, _heap_h	sw		t0, 24(a0)	/* Get CP0 Processor ID register */	mfc0	t0, CP0_PRID_REG	sw		t0, 36(a0)	/* Done */	jr		ra	nop.set reorderEND(addr_test)#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -