This is the mail archive of the ecos-patches@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

EB40a reset code fix


Reset external circuits as well....

Index: hal/arm/at91/var/current/src/at91_misc.c
===================================================================
RCS file: /cvs/ecos/ecos/packages/hal/arm/at91/var/current/src/at91_misc.c,v
retrieving revision 1.10
diff -a -w -u -r1.10 at91_misc.c
--- hal/arm/at91/var/current/src/at91_misc.c	25 Sep 2004 09:44:10 -0000	1.10
+++ hal/arm/at91/var/current/src/at91_misc.c	26 Oct 2004 08:12:56 -0000
@@ -284,7 +284,10 @@
    HAL_WRITE_UINT32(AT91_WD + AT91_WD_OMR, AT91_WD_OMR_OKEY);
    HAL_WRITE_UINT32(AT91_WD + AT91_WD_CMR, AT91_WD_CMR_CKEY);
    HAL_WRITE_UINT32(AT91_WD + AT91_WD_CR, AT91_WD_CR_RSTKEY);
-    HAL_WRITE_UINT32(AT91_WD + AT91_WD_OMR, AT91_WD_OMR_OKEY |
AT91_WD_OMR_RSTEN | AT91_WD_OMR_WDEN);
+    /* we're using AT91_WD_OMR_EXTEN in order to get an external reset,
+       such that the flash chip is reset as well.
+ */
+    HAL_WRITE_UINT32(AT91_WD + AT91_WD_OMR, AT91_WD_OMR_OKEY |
AT91_WD_OMR_EXTEN | AT91_WD_OMR_WDEN);
    while(1) CYG_EMPTY_STATEMENT;
}



--
Øyvind Harboe
http://www.zylin.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]