diff options
Diffstat (limited to 'drivers/scsi/libsas/sas_expander.c')
-rw-r--r-- | drivers/scsi/libsas/sas_expander.c | 20 |
1 files changed, 14 insertions, 6 deletions
diff --git a/drivers/scsi/libsas/sas_expander.c b/drivers/scsi/libsas/sas_expander.c index f84084bba2f0..e8d0115a025a 100644 --- a/drivers/scsi/libsas/sas_expander.c +++ b/drivers/scsi/libsas/sas_expander.c | |||
@@ -329,6 +329,7 @@ static void ex_assign_report_general(struct domain_device *dev, | |||
329 | dev->ex_dev.ex_change_count = be16_to_cpu(rg->change_count); | 329 | dev->ex_dev.ex_change_count = be16_to_cpu(rg->change_count); |
330 | dev->ex_dev.max_route_indexes = be16_to_cpu(rg->route_indexes); | 330 | dev->ex_dev.max_route_indexes = be16_to_cpu(rg->route_indexes); |
331 | dev->ex_dev.num_phys = min(rg->num_phys, (u8)MAX_EXPANDER_PHYS); | 331 | dev->ex_dev.num_phys = min(rg->num_phys, (u8)MAX_EXPANDER_PHYS); |
332 | dev->ex_dev.t2t_supp = rg->t2t_supp; | ||
332 | dev->ex_dev.conf_route_table = rg->conf_route_table; | 333 | dev->ex_dev.conf_route_table = rg->conf_route_table; |
333 | dev->ex_dev.configuring = rg->configuring; | 334 | dev->ex_dev.configuring = rg->configuring; |
334 | memcpy(dev->ex_dev.enclosure_logical_id, rg->enclosure_logical_id, 8); | 335 | memcpy(dev->ex_dev.enclosure_logical_id, rg->enclosure_logical_id, 8); |
@@ -1133,15 +1134,17 @@ static void sas_print_parent_topology_bug(struct domain_device *child, | |||
1133 | }; | 1134 | }; |
1134 | struct domain_device *parent = child->parent; | 1135 | struct domain_device *parent = child->parent; |
1135 | 1136 | ||
1136 | sas_printk("%s ex %016llx phy 0x%x <--> %s ex %016llx phy 0x%x " | 1137 | sas_printk("%s ex %016llx (T2T supp:%d) phy 0x%x <--> %s ex %016llx " |
1137 | "has %c:%c routing link!\n", | 1138 | "(T2T supp:%d) phy 0x%x has %c:%c routing link!\n", |
1138 | 1139 | ||
1139 | ex_type[parent->dev_type], | 1140 | ex_type[parent->dev_type], |
1140 | SAS_ADDR(parent->sas_addr), | 1141 | SAS_ADDR(parent->sas_addr), |
1142 | parent->ex_dev.t2t_supp, | ||
1141 | parent_phy->phy_id, | 1143 | parent_phy->phy_id, |
1142 | 1144 | ||
1143 | ex_type[child->dev_type], | 1145 | ex_type[child->dev_type], |
1144 | SAS_ADDR(child->sas_addr), | 1146 | SAS_ADDR(child->sas_addr), |
1147 | child->ex_dev.t2t_supp, | ||
1145 | child_phy->phy_id, | 1148 | child_phy->phy_id, |
1146 | 1149 | ||
1147 | ra_char[parent_phy->routing_attr], | 1150 | ra_char[parent_phy->routing_attr], |
@@ -1238,10 +1241,15 @@ static int sas_check_parent_topology(struct domain_device *child) | |||
1238 | sas_print_parent_topology_bug(child, parent_phy, child_phy); | 1241 | sas_print_parent_topology_bug(child, parent_phy, child_phy); |
1239 | res = -ENODEV; | 1242 | res = -ENODEV; |
1240 | } | 1243 | } |
1241 | } else if (parent_phy->routing_attr == TABLE_ROUTING && | 1244 | } else if (parent_phy->routing_attr == TABLE_ROUTING) { |
1242 | child_phy->routing_attr != SUBTRACTIVE_ROUTING) { | 1245 | if (child_phy->routing_attr == SUBTRACTIVE_ROUTING || |
1243 | sas_print_parent_topology_bug(child, parent_phy, child_phy); | 1246 | (child_phy->routing_attr == TABLE_ROUTING && |
1244 | res = -ENODEV; | 1247 | child_ex->t2t_supp && parent_ex->t2t_supp)) { |
1248 | /* All good */; | ||
1249 | } else { | ||
1250 | sas_print_parent_topology_bug(child, parent_phy, child_phy); | ||
1251 | res = -ENODEV; | ||
1252 | } | ||
1245 | } | 1253 | } |
1246 | break; | 1254 | break; |
1247 | case FANOUT_DEV: | 1255 | case FANOUT_DEV: |