9
0
Fork 0

make memory display 64bit capable

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
Sascha Hauer 2011-10-18 17:26:17 +02:00
parent efa379f224
commit 7b65cb7567
2 changed files with 3 additions and 3 deletions

View File

@ -55,7 +55,7 @@ static char *DEVMEM = "/dev/mem";
*/
#define DISP_LINE_LEN 16
int memory_display(char *addr, ulong offs, ulong nbytes, int size)
int memory_display(char *addr, loff_t offs, ulong nbytes, int size)
{
ulong linebytes, i;
u_char *cp;
@ -72,7 +72,7 @@ int memory_display(char *addr, ulong offs, ulong nbytes, int size)
u_char *ucp = (u_char *)linebuf;
uint count = 52;
printf("%08lx:", offs);
printf("%08llx:", offs);
linebytes = (nbytes > DISP_LINE_LEN) ? DISP_LINE_LEN : nbytes;
for (i = 0; i < linebytes; i += size) {

View File

@ -229,7 +229,7 @@ int run_shell(void);
#define PAGE_SIZE 4096
#define PAGE_SHIFT 12
int memory_display(char *addr, ulong offs, ulong nbytes, int size);
int memory_display(char *addr, loff_t offs, ulong nbytes, int size);
extern const char version_string[];
#ifdef CONFIG_BANNER