[coreboot] [PATCH] 440BX registered SDRAM support

Stefan Reinauer stefan.reinauer at coreboot.org
Mon Mar 28 03:22:11 CEST 2011


On 3/27/11 5:36 AM, Keith Hui wrote:
> Adds support for initializing registered SDRAM modules on Intel 440BX 
> northbridge.
>
> Signed-off-by: Keith Hui <buurin at gmail.com>
>
> Index: src/northbridge/intel/i440bx/raminit.c
> ===================================================================
> --- src/northbridge/intel/i440bx/raminit.c    (revision 6460)
> +++ src/northbridge/intel/i440bx/raminit.c    (working copy)
>
> +    /* Set DRAMC[4:3] to proper memory type (EDO/SDRAM/Registered 
> SDRAM). */
> +
> +    if ((edosd & 0x84) == 0x84) {
> +        edosd = 0x10; // Registered SDRAM
> +    } else {
> +        // Clear [4:3] in case it's EDO.
> +        edosd &= 0x07;
> +//    } else if (edosd & 0x02) {
Besides being commented out, this piece of code would never be executed, 
as there already is an else case.
Also, modifying edosd in place is semi nice.

Please clean this up before committing. Maybe consider using switch/case?

Looks good otherwise.
> +//        edosd |= 0x00;
> +        if (edosd & 0x04) {
> +            edosd |= 0x08; // SDRAM
> +        }
>      }
> +    // Keep only [4:3].
>      edosd &= 0x18;
>
>      /* edosd is now in the form needed for DRAMC[4:3]. */





More information about the coreboot mailing list