Ignore:
Timestamp:
Jan 14, 2013, 4:39:14 PM (11 years ago)
Author:
cfuguet
Message:

Fixing bug in boot_tty.c:

Use address of tty status when reading with the ioread32 function.

Makefile and ioc.c:
Introducing SYSCLK_FREQ environment variable to choose a clock frequency when
using FPGA platform. 50000000 Hz by default.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/softs/tsar_boot/boot_tty.c

    r280 r286  
    77in_reset int boot_getc(int *c)
    88{
    9         unsigned int* tty_address = (unsigned int*) TTY_BASE;
    10         if (ioread32(tty_address[TTY_STATUS]) == 0)
     9        unsigned int* tty_address = (unsigned int*) TTY_BASE;
     10        if (ioread32(&tty_address[TTY_STATUS]) == 0)
    1111                return 0;
    12         *c = ioread32(&tty_address[TTY_READ]);
     12
     13        *c = ioread32(&tty_address[TTY_READ]);
    1314        return 1;
    1415}
Note: See TracChangeset for help on using the changeset viewer.