Show
Ignore:
Timestamp:
07/17/08 21:50:37 (4 months ago)
Author:
mjones
Message:

Clean up AMD FAM10 HT variable initialization. The structure init is cleaner, avoid compiler warnings, and matches the AMD example code more closely.

Signed-off-by: Marc Jones <marc.jones@…>

Acked-by: Peter Stuge <peter@…>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@…>

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/coreboot-v2/src/northbridge/amd/amdht/h3ncmn.c

    r3423 r3425  
    402402                                { 
    403403                                        /* Pass the node and link on which the generic synch flood event occurred. */ 
    404                                         sHtEventHWHtCrc evt = {sizeof(sHtEventHWHtCrc), node, link, (u8)crc}; 
     404                                        sHtEventHWHtCrc evt; 
     405                                        evt.eSize = sizeof(sHtEventHWHtCrc); 
     406                                        evt.node = node; 
     407                                        evt.link = link; 
     408                                        evt.laneMask = (uint8)crc; 
    405409 
    406410                                        pDat->HtBlock->AMD_CB_EventNotify(HT_EVENT_CLASS_HW_FAULT, 
     
    415419                                { 
    416420                                        /* Pass the node and link on which the generic synch flood event occurred. */ 
    417                                         sHtEventHWSynchFlood evt = {sizeof(sHtEventHWSynchFlood), node, link}; 
     421                                        sHtEventHWSynchFlood evt; 
     422                                        evt.eSize = sizeof(sHtEventHWSynchFlood); 
     423                                        evt.node = node; 
     424                                        evt.link = link; 
    418425 
    419426                                        pDat->HtBlock->AMD_CB_EventNotify(HT_EVENT_CLASS_HW_FAULT, 
     
    11131120        } 
    11141121        STOP_HERE; /*  This is an error internal condition */ 
    1115  
    1116         return 0xFF;    // make the compiler happy. 
    11171122} 
    11181123 
     
    11441149        } 
    11451150        STOP_HERE; /*  This is an internal error condition */ 
    1146  
    1147         return 0xFF;    // make the compiler happy. 
    11481151} 
    11491152 
     
    14691472                                                if (pDat->HtBlock->AMD_CB_EventNotify) 
    14701473                                                { 
    1471                                                         sHtEventOptRequiredCap evt ={sizeof(sHtEventOptRequiredCap), 
    1472                                                                                 pDat->PortList[i].NodeID, 
    1473                                                                                 pDat->PortList[i].HostLink, 
    1474                                                                                 pDat->PortList[i].HostDepth}; 
     1474                                                        sHtEventOptRequiredCap evt; 
     1475                                                        evt.eSize = sizeof(sHtEventOptRequiredCap); 
     1476                                                        evt.node = pDat->PortList[i].NodeID; 
     1477                                                        evt.link = pDat->PortList[i].HostLink; 
     1478                                                        evt.depth = pDat->PortList[i].HostDepth; 
    14751479 
    14761480                                                        pDat->HtBlock->AMD_CB_EventNotify(HT_EVENT_CLASS_WARNING, 
     
    15141518                                                if (pDat->HtBlock->AMD_CB_EventNotify) 
    15151519                                                { 
    1516                                                         sHtEventOptRequiredCap evt ={sizeof(sHtEventOptRequiredCap), 
    1517                                                                         pDat->PortList[i].NodeID, 
    1518                                                                         pDat->PortList[i].HostLink, 
    1519                                                                         pDat->PortList[i].HostDepth}; 
     1520                                                        sHtEventOptRequiredCap evt; 
     1521                                                        evt.eSize = sizeof(sHtEventOptRequiredCap); 
     1522                                                        evt.node = pDat->PortList[i].NodeID; 
     1523                                                        evt.link = pDat->PortList[i].HostLink; 
     1524                                                        evt.depth = pDat->PortList[i].HostDepth; 
    15201525 
    15211526                                                        pDat->HtBlock->AMD_CB_EventNotify(HT_EVENT_CLASS_WARNING,