git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@295 35acf78f-673a-0410-8e92-d51de3d6d3f4

This commit is contained in:
gdisirio 2008-05-18 16:10:31 +00:00
parent 3787f5d2a5
commit 602cff4618
3 changed files with 7 additions and 4 deletions

View File

@ -102,7 +102,7 @@ TOPT = -mthumb -D THUMB
# chconf.h.
# NOTE: -falign-functions=16 may improve the performance, not always, but
# increases the code size.
OPT = -O2 -ggdb -fomit-frame-pointer -mabi=apcs-gnu
OPT = -ggdb -fomit-frame-pointer -mabi=apcs-gnu
#OPT += -ffixed-r7
#OPT += -falign-functions=16

View File

@ -21,7 +21,8 @@
#include <test.h>
#include "board.h"
#include "sam7x_serial.h"
#include <sam7x_serial.h>
#include <sam7x_emac.h>
static WorkingArea(waThread1, 64);
static msg_t Thread1(void *arg) {
@ -40,6 +41,8 @@ static msg_t Thread1(void *arg) {
*/
int main(int argc, char **argv) {
InitEMAC(AT91C_AIC_PRIOR_HIGHEST - 3);
/*
* The main() function becomes a thread here then the interrupts are
* enabled and ChibiOS/RT goes live.

View File

@ -246,9 +246,9 @@ void InitEMAC(int prio) {
AT91C_BASE_EMAC->EMAC_NCR |= AT91C_EMAC_MPE;
if ((phy_get(MII_PHYSID1) != (MII_MICREL_ID >> 16)) ||
(phy_get(MII_PHYSID2 & 0xFFF0) != (MII_MICREL_ID & 0xFFF0)))
chDbgPanic("Wrong PHY identifier");
chSysHalt();
if (!get_link_status())
chDbgPanic("No link");
chSysHalt();
AT91C_BASE_EMAC->EMAC_NCR &= ~AT91C_EMAC_MPE;
/*