Print this page
5218 posix definition of NULL
correct unistd.h and iso/stddef_iso.h
update gate source affected

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/fm/modules/common/fabric-xlate/fx_fabric.c
          +++ new/usr/src/cmd/fm/modules/common/fabric-xlate/fx_fabric.c
↓ open down ↓ 42 lines elided ↑ open up ↑
  43   43  /* MACRO for table entries with no TGT ereports */
  44   44  #define NT(class, bit, prep) class, bit, prep, NULL
  45   45  /* Translate Fabric ereports to ereport.io.pci.* */
  46   46  fab_erpt_tbl_t fab_pci_erpt_tbl[] = {
  47   47          PCI_DET_PERR,           PCI_STAT_PERROR,        NULL,
  48   48          PCI_MDPE,               PCI_STAT_S_PERROR,      NULL,
  49   49          PCI_SIG_SERR,           PCI_STAT_S_SYSERR,      NULL,
  50   50          PCI_MA,                 PCI_STAT_R_MAST_AB,     NULL,
  51   51          PCI_REC_TA,             PCI_STAT_R_TARG_AB,     NULL,
  52   52          PCI_SIG_TA,             PCI_STAT_S_TARG_AB,     NULL,
  53      -        NULL, NULL, NULL
       53 +        NULL, 0 , NULL
  54   54  };
  55   55  
  56   56  /* Translate Fabric ereports to ereport.io.pci.sec-* */
  57   57  static fab_erpt_tbl_t fab_pci_bdg_erpt_tbl[] = {
  58   58          PCI_DET_PERR,           PCI_STAT_PERROR,        NULL,
  59   59          PCI_MDPE,               PCI_STAT_S_PERROR,      NULL,
  60   60          PCI_REC_SERR,           PCI_STAT_S_SYSERR,      NULL,
  61   61  #ifdef sparc
  62   62          PCI_MA,                 PCI_STAT_R_MAST_AB,     NULL,
  63   63  #endif
  64   64          PCI_REC_TA,             PCI_STAT_R_TARG_AB,     NULL,
  65   65          PCI_SIG_TA,             PCI_STAT_S_TARG_AB,     NULL,
  66      -        NULL, NULL, NULL, NULL,
       66 +        NULL, 0 , NULL
  67   67  };
  68   68  
  69   69  
  70   70  /* Translate Fabric ereports to ereport.io.pci.dto */
  71   71  static fab_erpt_tbl_t fab_pci_bdg_ctl_erpt_tbl[] = {
  72   72          PCI_DTO,        PCI_BCNF_BCNTRL_DTO_STAT,       NULL,
  73      -        NULL, NULL, NULL
       73 +        NULL, 0, NULL
  74   74  };
  75   75  
  76   76  /* Translate Fabric ereports to ereport.io.pciex.* */
  77   77  static fab_erpt_tbl_t fab_pcie_ce_erpt_tbl[] = {
  78   78          PCIEX_RE,       PCIE_AER_CE_RECEIVER_ERR,       NULL,
  79   79          PCIEX_RNR,      PCIE_AER_CE_REPLAY_ROLLOVER,    NULL,
  80   80          PCIEX_RTO,      PCIE_AER_CE_REPLAY_TO,          NULL,
  81   81          PCIEX_BDP,      PCIE_AER_CE_BAD_DLLP,           NULL,
  82   82          PCIEX_BTP,      PCIE_AER_CE_BAD_TLP,            NULL,
  83   83          PCIEX_ANFE,     PCIE_AER_CE_AD_NFE,             NULL,
  84      -        NULL, NULL, NULL
       84 +        NULL, 0, NULL
  85   85  };
  86   86  
  87   87  /*
  88   88   * Translate Fabric ereports to ereport.io.pciex.*
  89   89   * The Target Ereports for this section is only used on leaf devices, with the
  90   90   * exception of TO
  91   91   */
  92   92  static fab_erpt_tbl_t fab_pcie_ue_erpt_tbl[] = {
  93   93          PCIEX_TE,       PCIE_AER_UCE_TRAINING,          NULL,
  94   94          PCIEX_DLP,      PCIE_AER_UCE_DLP,               NULL,
↓ open down ↓ 2 lines elided ↑ open up ↑
  97   97          PCIEX_FCP,      PCIE_AER_UCE_FCP,               NULL,
  98   98          PCIEX_MFP,      PCIE_AER_UCE_MTLP,              NULL,
  99   99          PCIEX_CTO,      PCIE_AER_UCE_TO,                PCI_TARG_MA,
 100  100          PCIEX_UC,       PCIE_AER_UCE_UC,                NULL,
 101  101          PCIEX_ECRC,     PCIE_AER_UCE_ECRC,              NULL,
 102  102          PCIEX_CA,       PCIE_AER_UCE_CA,                PCI_TARG_REC_TA,
 103  103  #ifdef sparc
 104  104          PCIEX_UR,       PCIE_AER_UCE_UR,                PCI_TARG_MA,
 105  105  #endif
 106  106          PCIEX_POIS,     PCIE_AER_UCE_PTLP,              PCI_TARG_MDPE,
 107      -        NULL, NULL, NULL
      107 +        NULL, 0, NULL
 108  108  };
 109  109  
 110  110  /* Translate Fabric ereports to ereport.io.pciex.* */
 111  111  static fab_erpt_tbl_t fab_pcie_sue_erpt_tbl[] = {
 112  112          PCIEX_S_TA_SC,  PCIE_AER_SUCE_TA_ON_SC,         PCI_TARG_REC_TA,
 113  113          PCIEX_S_MA_SC,  PCIE_AER_SUCE_MA_ON_SC,         PCI_TARG_MA,
 114  114          PCIEX_S_RTA,    PCIE_AER_SUCE_RCVD_TA,          PCI_TARG_REC_TA,
 115  115  #ifdef sparc
 116  116          PCIEX_S_RMA,    PCIE_AER_SUCE_RCVD_MA,          PCI_TARG_MA,
 117  117  #endif
 118  118          PCIEX_S_USC,    PCIE_AER_SUCE_USC_ERR,          NULL,
 119  119          PCIEX_S_USCMD,  PCIE_AER_SUCE_USC_MSG_DATA_ERR, PCI_TARG_REC_TA,
 120  120          PCIEX_S_UDE,    PCIE_AER_SUCE_UC_DATA_ERR,      PCI_TARG_MDPE,
 121  121          PCIEX_S_UAT,    PCIE_AER_SUCE_UC_ATTR_ERR,      PCI_TARG_MDPE,
 122  122          PCIEX_S_UADR,   PCIE_AER_SUCE_UC_ADDR_ERR,      PCI_TARG_MDPE,
 123  123          PCIEX_S_TEX,    PCIE_AER_SUCE_TIMER_EXPIRED,    NULL,
 124  124          PCIEX_S_PERR,   PCIE_AER_SUCE_PERR_ASSERT,      PCI_TARG_MDPE,
 125  125          PCIEX_S_SERR,   PCIE_AER_SUCE_SERR_ASSERT,      NULL,
 126  126          PCIEX_INTERR,   PCIE_AER_SUCE_INTERNAL_ERR,     NULL,
 127      -        NULL, NULL, NULL
      127 +        NULL, 0, NULL
 128  128  };
 129  129  
 130  130  /* Translate Fabric ereports to ereport.io.pcix.* */
 131  131  static fab_erpt_tbl_t fab_pcix_erpt_tbl[] = {
 132  132          PCIX_SPL_DIS,           PCI_PCIX_SPL_DSCD,      NULL,
 133  133          PCIX_UNEX_SPL,          PCI_PCIX_UNEX_SPL,      NULL,
 134  134          PCIX_RX_SPL_MSG,        PCI_PCIX_RX_SPL_MSG,    NULL,
 135      -        NULL, NULL, NULL
      135 +        NULL, 0, NULL
 136  136  };
 137  137  static fab_erpt_tbl_t *fab_pcix_bdg_erpt_tbl = fab_pcix_erpt_tbl;
 138  138  
 139  139  /* Translate Fabric ereports to ereport.io.pcix.sec-* */
 140  140  static fab_erpt_tbl_t fab_pcix_bdg_sec_erpt_tbl[] = {
 141  141          PCIX_SPL_DIS,           PCI_PCIX_BSS_SPL_DSCD,  NULL,
 142  142          PCIX_UNEX_SPL,          PCI_PCIX_BSS_UNEX_SPL,  NULL,
 143  143          PCIX_BSS_SPL_OR,        PCI_PCIX_BSS_SPL_OR,    NULL,
 144  144          PCIX_BSS_SPL_DLY,       PCI_PCIX_BSS_SPL_DLY,   NULL,
 145      -        NULL, NULL, NULL
      145 +        NULL, 0, NULL
 146  146  };
 147  147  
 148  148  /* Translate Fabric ereports to ereport.io.pciex.* */
 149  149  static fab_erpt_tbl_t fab_pcie_nadv_erpt_tbl[] = {
 150  150  #ifdef sparc
 151  151          PCIEX_UR,               PCIE_DEVSTS_UR_DETECTED,        NULL,
 152  152  #endif
 153  153          PCIEX_FAT,              PCIE_DEVSTS_FE_DETECTED,        NULL,
 154  154          PCIEX_NONFAT,           PCIE_DEVSTS_NFE_DETECTED,       NULL,
 155  155          PCIEX_CORR,             PCIE_DEVSTS_CE_DETECTED,        NULL,
 156      -        NULL, NULL, NULL
      156 +        NULL, 0, NULL
 157  157  };
 158  158  
 159  159  /* Translate Fabric ereports to ereport.io.pciex.* */
 160  160  static fab_erpt_tbl_t fab_pcie_rc_erpt_tbl[] = {
 161  161          PCIEX_RC_FE_MSG,        PCIE_AER_RE_STS_FE_MSGS_RCVD,   NULL,
 162  162          PCIEX_RC_NFE_MSG,       PCIE_AER_RE_STS_NFE_MSGS_RCVD,  NULL,
 163  163          PCIEX_RC_CE_MSG,        PCIE_AER_RE_STS_CE_RCVD,        NULL,
 164  164          PCIEX_RC_MCE_MSG,       PCIE_AER_RE_STS_MUL_CE_RCVD,    NULL,
 165  165          PCIEX_RC_MUE_MSG,       PCIE_AER_RE_STS_MUL_FE_NFE_RCVD, NULL,
 166      -        NULL, NULL, NULL
      166 +        NULL, 0, NULL
 167  167  };
 168  168  
 169  169  /*
 170  170   * Translate Fabric ereports to pseudo ereport.io.pciex.* RC Fabric Messages.
 171  171   * If the RP is not a PCIe compliant RP or does not support AER, rely on the
 172  172   * leaf fabric ereport to help create a xxx_MSG ereport coming from the RC.
 173  173   */
 174  174  static fab_erpt_tbl_t fab_pcie_fake_rc_erpt_tbl[] = {
 175  175          PCIEX_RC_FE_MSG,        PCIE_DEVSTS_FE_DETECTED,        NULL,
 176  176          PCIEX_RC_NFE_MSG,       PCIE_DEVSTS_NFE_DETECTED,       NULL,
 177  177          PCIEX_RC_CE_MSG,        PCIE_DEVSTS_CE_DETECTED,        NULL,
 178      -        NULL, NULL, NULL,
      178 +        NULL, 0, NULL
 179  179  };
 180  180  
 181  181  /* ARGSUSED */
 182  182  void
 183  183  fab_pci_fabric_to_data(fmd_hdl_t *hdl, nvlist_t *nvl, fab_data_t *data)
 184  184  {
 185  185          data->nvl = nvl;
 186  186  
 187  187          /* Generic PCI device information */
 188  188          FAB_LOOKUP(16,  "bdf",                  &data->bdf);
↓ open down ↓ 670 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX