This is the mail archive of the ecos-discuss@sources.redhat.com 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]

Re: Static RAM timings on Assabet/Neponset


I've now installed the patch (below), in your name.  Thanks. 

---------------------------- cut here ----------------------------------------------------
Index: hal/arm/sa11x0/assabet/current/ChangeLog
===================================================================
RCS file: /home/cvs/ecc/ecc/hal/arm/sa11x0/assabet/current/ChangeLog,v
retrieving revision 1.40
diff -u -5 -p -r1.40 ChangeLog
--- hal/arm/sa11x0/assabet/current/ChangeLog    2001/06/21 05:03:11     1.40
+++ hal/arm/sa11x0/assabet/current/ChangeLog    2001/07/28 14:15:56
@@ -1,5 +1,11 @@
+2001-07-28  Stefan Eletzhofer <schuehle@t-online.de>
+
+       * include/hal_platform_setup.h: 
+       * cdl/hal_arm_sa11x0_assabet.cdl: Support additional timing setup
+       when Neponset board is available.
+
 2001-06-21  Jonathan Larmour  <jlarmour@redhat.com>
 
        * images/redboot*: Remove. Don't bloat repository with things already
        on the web.
 
Index: hal/arm/sa11x0/assabet/current/cdl/hal_arm_sa11x0_assabet.cdl
===================================================================
RCS file: /home/cvs/ecc/ecc/hal/arm/sa11x0/assabet/current/cdl/hal_arm_sa11x0_assabet.cdl,v
retrieving revision 1.22
diff -u -5 -p -r1.22 hal_arm_sa11x0_assabet.cdl
--- hal/arm/sa11x0/assabet/current/cdl/hal_arm_sa11x0_assabet.cdl       2001/04/27 16:43:44     1.22
+++ hal/arm/sa11x0/assabet/current/cdl/hal_arm_sa11x0_assabet.cdl       2001/07/28 14:15:36
@@ -218,10 +218,20 @@ cdl_package CYGPKG_HAL_ARM_SA11X0_ASSABE
         description   "
            Package specific build options including control over
            compiler flags used only in building this package,
            and details of which tests are built."
 
+       cdl_option CYGSEM_HAL_ARM_SA11X0_ASSABET_NEPONSET_TIMINGS {
+            display       "Enable special timings for Neponset board"
+            flavor        bool
+            default_value 0
+            description   "
+                Enable this option to force initialization of memory timing
+                parameters suitable for use with the Neponset expansion board.
+                This is optional as it does not work for some versions of
+                Assabet without the board plugged in."
+        }
 
         cdl_option CYGPKG_HAL_ARM_SA11X0_ASSABET_CFLAGS_ADD {
             display "Additional compiler flags"
             flavor  data
             no_define
Index: hal/arm/sa11x0/assabet/current/include/hal_platform_setup.h
===================================================================
RCS file: /home/cvs/ecc/ecc/hal/arm/sa11x0/assabet/current/include/hal_platform_setup.h,v
retrieving revision 1.6
diff -u -5 -p -r1.6 hal_platform_setup.h
--- hal/arm/sa11x0/assabet/current/include/hal_platform_setup.h 2000/10/17 18:10:34     1.6
+++ hal/arm/sa11x0/assabet/current/include/hal_platform_setup.h 2001/07/28 14:13:15
@@ -196,18 +196,22 @@
 // DRAM controller initialization        
 dram_table:
         .word   SA11X0_DRAM0_CAS_0,           0xAAAAAA7F
         .word   SA11X0_DRAM0_CAS_1,           0xAAAAAAAA
         .word   SA11X0_DRAM0_CAS_2,           0xAAAAAAAA
-//        .word   SA11X0_STATIC_CONTROL_0,      0x4B384B38
-//        .word   SA11X0_STATIC_CONTROL_1,      0x22212419
+#ifdef CYGSEM_HAL_ARM_SA11X0_ASSABET_NEPONSET_TIMINGS
+        .word   SA11X0_STATIC_CONTROL_0,      0x4B384370
+        .word   SA11X0_STATIC_CONTROL_1,      0x22212419
+#endif
         .word   SA11X0_EXP_BUS_CONFIGURATION, 0x994A994A
         .word   SA11X0_REFRESH_CONFIGURATION, 0x49FC0327
         .word   SA11X0_DRAM2_CAS_0,           0xAAAAAA7F
         .word   SA11X0_DRAM2_CAS_1,           0xAAAAAAAA
         .word   SA11X0_DRAM2_CAS_2,           0xAAAAAAAA
-//        .word   SA11X0_STATIC_CONTROL_2,      0x42194449
+#ifdef CYGSEM_HAL_ARM_SA11X0_ASSABET_NEPONSET_TIMINGS
+        .word   SA11X0_STATIC_CONTROL_2,      0x42196669
+#endif
         .word   SA11X0_SMROM_CONFIGURATION,   0xAFCCAFCC
         .word   SA11X0_DRAM_CONFIGURATION,    0x72547254        // Disabled
         .word   0, 0
 19:
 
----------------------------------------------------------------------------------------

On 02-Jul-2001 Stefan Eletzhofer wrote:
> Hello,
> I just managed to get the MSCXX (Static Memory Timing) Values right to boot a
> Linux 2.4.5-rmk7-np1 kernel through RedBoot on my Assabet/Neponset dev Board.
> Works fine, detects the SA1111, PCMCIA Works (My CF Ethernet Network card does
> at last). By the way, the Values for the MSCXX Registers i used are (as in
> bootldr/boot-sa1100.S, with patches from John Dorsey). As bootlr works rather
> nicely, i wonder which problems old Assabet Boards have :^(, mine is a Rev 4
> Board.
> 
> msc0 = 4b384370
> msc1 = 22212419
> msc2 = 42196669
> mecr = 994a994a  (no change here)        
> 
> So, how do i now manage to get this CDL stuff right :), as I'm quite new to
> ecos at all. As I understand it CDL is just a new way to define config options,
> which then turn into #defines, right? I guess I'll have to throw in some sort
> of CYGXXX_CONFIG_NEPONSET, hmmm ...
> 
> Thank you,
>       Stefan
> 
>  Am Fre, 29 Jun 2001 schrieben Sie:
>> We have to be a bit careful here.  The current setup has those values commented
>> out because they caused problems when used with Assabet boards of different
>> vintages.  In particular, they work fine on my older board, but failed on some
>> newer ones we have in our test farm.
>> 
>> The actual values to be used seem to be higly dependent on the actual board
>> hardware (precisely which chips are installed, etc).  
>> 
>> I'd suggest that any changes be controlled by appropriate CDL options and the
>> default behaviour left as it currently is.  That way we won't end up breaking
>> existing, working albeit less than most perfectly, systems.
>> 
>> On 28-Jun-2001 Stefan Eletzhofer wrote:
>> > Am Don, 28 Jun 2001 schrieben Sie:
>> >> schuehle@t-online.de (Stefan Eletzhofer) writes:
>> >> > I am using an Assabet Dev Board with Neponset expansion board attached. I use
>> >> > RedBoot to boot Linux, Kernel 2.4.5-rmk6-np1. I use a precompiled version of
>> >> > Redboot, which works fine (TFTP over CF card etc.).
>> >> > 
>> >> > However, when the Kernel tries to detect the SA1111 companion Chip on the
>> >> > extension board, it cannot correctly read the chip id. People on the
>> >> > arm-kernel list have pointed me to the fact that static ram timings has
>> >> > to be set correctly to detect/use the sa1111. Using the BLOB bootloader
>> >> > the kernel was able to detect the sa1111, so my hardware is ok.
>> >> > 
>> >> > I searched a bit and found that in hal_platform_setup.h initialization of
>> >> > static memory control is disabled. Why? How do i best enable/change this?
>> >> > Or am I completely wrong here?
>> >> 
>> >> From my recollection of trying to get sense out of the Assabet's ethernet
>> >> device I would say you're right.  I don't recall why these might have been
>> >> disabled.
>> >> 
>> >> Best way would be to use a debugger to find out what values some working
>> >> code (eg. your BLOB bootloader?) placed in those registers.  Then uncomment
>> >> those lines with the values that you know are good and try it!
>> >> 
>> >> Let us know the patch, if it works?
>> >> 
>> >>      - Huge
>> >> 
>> >> 
>> >> > -----------[snip]--------------
>> >> > // DRAM controller initialization        
>> >> > dram_table:
>> >> >         .word   SA11X0_DRAM0_CAS_0,           0xAAAAAA7F
>> >> >         .word   SA11X0_DRAM0_CAS_1,           0xAAAAAAAA
>> >> >         .word   SA11X0_DRAM0_CAS_2,           0xAAAAAAAA
>> >> > //        .word   SA11X0_STATIC_CONTROL_0,      0x4B384B38
>> >> > //        .word   SA11X0_STATIC_CONTROL_1,      0x22212419
>> >> >         .word   SA11X0_EXP_BUS_CONFIGURATION, 0x994A994A
>> >> >         .word   SA11X0_REFRESH_CONFIGURATION, 0x49FC0327
>> >> >         .word   SA11X0_DRAM2_CAS_0,           0xAAAAAA7F
>> >> >         .word   SA11X0_DRAM2_CAS_1,           0xAAAAAAAA
>> >> >         .word   SA11X0_DRAM2_CAS_2,           0xAAAAAAAA
>> >> > //        .word   SA11X0_STATIC_CONTROL_2,      0x42194449
>> >> >         .word   SA11X0_SMROM_CONFIGURATION,   0xAFCCAFCC
>> >> >         .word   SA11X0_DRAM_CONFIGURATION,    0x72547254        // Disabled
>> >> >         .word   0, 0
>> >> > --------[snap]--------------------
>> > 
>> > Thank you.
>> > I have written a little program which prints the correct values used in bootldr
>> > (They use quite some macros to specify the value), I'll try to patch RedBoot
>> > and get this to work. Of course I'll post the patch if it works.
>> > 
>> > Stefan


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