summaryrefslogtreecommitdiff
path: root/usr/src/lib/libprtdiag_psr
diff options
context:
space:
mode:
authorzx143588 <none@none>2006-12-15 08:44:37 -0800
committerzx143588 <none@none>2006-12-15 08:44:37 -0800
commit87c478a5395a3af1176f469bdeaf2ce044e4ae1a (patch)
treeedeb88f7884805c2fc1106a1006786530b5f5adc /usr/src/lib/libprtdiag_psr
parenta644aa6f4739bce6d579237b166673ef07180ebf (diff)
downloadillumos-joyent-87c478a5395a3af1176f469bdeaf2ce044e4ae1a.tar.gz
6499670 prtdiag does not display the XAUI devices when configured in the system
Diffstat (limited to 'usr/src/lib/libprtdiag_psr')
-rw-r--r--usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.c14
-rw-r--r--usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.h6
-rw-r--r--usr/src/lib/libprtdiag_psr/sparc/ontario/common/ontario.c8
3 files changed, 14 insertions, 14 deletions
diff --git a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.c b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.c
index ef2940adfc..bf8652fb17 100644
--- a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.c
+++ b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.c
@@ -60,9 +60,8 @@
static void
huron_get_bus_type(char *path, struct io_card *card)
{
- if ((strcmp(path, HURON_N2_XAUI0) == 0) ||
- (strcmp(path, HURON_N2_XAUI1) == 0)) {
- (void) strcpy(card->bus_type, "SIU");
+ if (strcmp(path, HURON_NIU) == 0) {
+ (void) strcpy(card->bus_type, "NIU");
} else {
(void) strcpy(card->bus_type, "PCIE");
}
@@ -152,7 +151,6 @@ huron_pci_callback(picl_nodehdl_t pcih, void *args)
}
/* Walk through the children */
-
err = picl_get_propval_by_name(pcih, PICL_PROP_CHILD, &nodeh,
sizeof (picl_nodehdl_t));
@@ -168,7 +166,7 @@ huron_pci_callback(picl_nodehdl_t pcih, void *args)
continue;
}
- if (strcmp(piclclass, "siu") == 0) {
+ if (strcmp(piclclass, "sun4v") == 0) {
err = picl_get_propval_by_name(nodeh, PICL_PROP_CHILD,
&nodeh, sizeof (picl_nodehdl_t));
continue;
@@ -184,8 +182,6 @@ huron_pci_callback(picl_nodehdl_t pcih, void *args)
huron_get_bus_type(parent_path, &pci_card);
- huron_get_slot_number(parent_path, &pci_card);
-
err = picl_get_propval_by_name(nodeh, PICL_PROP_NAME, &name,
sizeof (name));
if (err == PICL_PROPNOTFOUND)
@@ -193,6 +189,10 @@ huron_pci_callback(picl_nodehdl_t pcih, void *args)
else if (err != PICL_SUCCESS)
return (err);
+ if (strcmp(parent_path, HURON_NIU) == 0)
+ huron_get_slot_number(path, &pci_card);
+ else
+ huron_get_slot_number(parent_path, &pci_card);
/* Figure NAC name */
if ((strcmp(name, NETWORK) == 0) &&
diff --git a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.h b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.h
index d73fa48259..3ba0bed875 100644
--- a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.h
+++ b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/huron.h
@@ -54,7 +54,7 @@ extern "C" {
#define OPHIR "GBE"
#define NETWORK "network"
#define PCIE "/PCIE"
-#define HURON_SIU "/siu@80"
+#define HURON_NIU "/niu@80"
#define HURON_SWITCH_A_PATH "/pci@0/pci@0"
#define HURON_SWITCH_B_PATH "/pci@0/pci@0/pci@1/pci@0"
#define HURON_SWITCH_C_PATH "/pci@0/pci@0/pci@8/pci@0"
@@ -74,8 +74,8 @@ extern "C" {
#define HURON_PCIE_SLOT5 "/pci@0/pci@0/pci@8/pci@0/pci@a"
#define HURON_PCIE_SLOT6 "/pci@0/pci@0/pci@8/pci@0/pci@9"
#define HURON_LSI_PATH "/pci@0/pci@0/pci@2/scsi@0"
-#define HURON_N2_XAUI0 "/siu@80/network@0"
-#define HURON_N2_XAUI1 "/siu@80/network@1"
+#define HURON_N2_XAUI0 "/niu@80/network@0"
+#define HURON_N2_XAUI1 "/niu@80/network@1"
#define SAS_SATA_HBA "SAS-SATA-HBA"
diff --git a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/ontario.c b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/ontario.c
index d64d2f3ef4..969cb53696 100644
--- a/usr/src/lib/libprtdiag_psr/sparc/ontario/common/ontario.c
+++ b/usr/src/lib/libprtdiag_psr/sparc/ontario/common/ontario.c
@@ -335,8 +335,8 @@ sun4v_display_pci(picl_nodehdl_t plafh)
} else if ((strncmp(platbuf, HURON_1U_PLATFORM,
strlen(HURON_1U_PLATFORM)) == 0) || (strncmp(platbuf,
HURON_2U_PLATFORM, strlen(HURON_2U_PLATFORM)) == 0)) {
- (void) picl_walk_tree_by_class(plafh, "siu",
- "siu", huron_pci_callback);
+ (void) picl_walk_tree_by_class(plafh, "sun4v",
+ "niu", huron_pci_callback);
(void) picl_walk_tree_by_class(plafh, "pciex",
"pciex", huron_pci_callback);
} else {
@@ -555,8 +555,8 @@ sun4v_display_hw_revisions(Prom_node *root, picl_nodehdl_t plafh)
HURON_2U_PLATFORM, strlen(HURON_2U_PLATFORM)) == 0)) {
(void) picl_walk_tree_by_class(plafh, "pciex",
"pciex", huron_hw_rev_callback);
- (void) picl_walk_tree_by_class(plafh, "siu",
- "siu", huron_hw_rev_callback);
+ (void) picl_walk_tree_by_class(plafh, "sun4v",
+ "niu", huron_hw_rev_callback);
(void) picl_walk_tree_by_class(plafh, "network",
"network", huron_hw_rev_callback);
(void) picl_walk_tree_by_class(plafh, "scsi-2", "scsi-2",