Lines Matching refs:parent
494 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); \
526 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); \
557 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in do_sas_phy_enable()
605 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in do_sas_phy_reset()
653 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in sas_phy_setup()
672 shost = dev_to_shost(dev->parent); in sas_phy_match()
687 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in sas_phy_release()
692 put_device(dev->parent); in sas_phy_release()
708 struct sas_phy *sas_phy_alloc(struct device *parent, int number) in sas_phy_alloc() argument
710 struct Scsi_Host *shost = dev_to_shost(parent); in sas_phy_alloc()
721 phy->dev.parent = get_device(parent); in sas_phy_alloc()
724 if (scsi_is_sas_expander_device(parent)) { in sas_phy_alloc()
725 struct sas_rphy *rphy = dev_to_rphy(parent); in sas_phy_alloc()
843 shost = dev_to_shost(dev->parent); in sas_port_match()
862 put_device(dev->parent); in sas_port_release()
902 struct sas_port *sas_port_alloc(struct device *parent, int port_id) in sas_port_alloc() argument
904 struct Scsi_Host *shost = dev_to_shost(parent); in sas_port_alloc()
915 port->dev.parent = get_device(parent); in sas_port_alloc()
921 if (scsi_is_sas_expander_device(parent)) { in sas_port_alloc()
922 struct sas_rphy *rphy = dev_to_rphy(parent); in sas_port_alloc()
947 struct sas_port *sas_port_alloc_num(struct device *parent) in sas_port_alloc_num() argument
950 struct Scsi_Host *shost = dev_to_shost(parent); in sas_port_alloc_num()
955 if (scsi_is_sas_expander_device(parent)) { in sas_port_alloc_num()
956 struct sas_rphy *rphy = dev_to_rphy(parent); in sas_port_alloc_num()
963 return sas_port_alloc(parent, index); in sas_port_alloc_num()
1035 struct device *parent = port->dev.parent; in sas_port_delete() local
1037 sysfs_remove_link(&port->dev.kobj, dev_name(parent)); in sas_port_delete()
1143 struct device *parent = port->dev.parent->parent->parent; in sas_port_mark_backlink() local
1148 res = sysfs_create_link(&port->dev.kobj, &parent->kobj, in sas_port_mark_backlink()
1149 dev_name(parent)); in sas_port_mark_backlink()
1216 struct sas_phy *phy = dev_to_phy(rphy->dev.parent); in show_sas_rphy_enclosure_identifier()
1217 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in show_sas_rphy_enclosure_identifier()
1236 struct sas_phy *phy = dev_to_phy(rphy->dev.parent); in show_sas_rphy_bay_identifier()
1237 struct Scsi_Host *shost = dev_to_shost(phy->dev.parent); in show_sas_rphy_bay_identifier()
1363 shost = dev_to_shost(dev->parent->parent); in sas_rphy_match()
1384 shost = dev_to_shost(dev->parent->parent); in sas_end_dev_match()
1407 shost = dev_to_shost(dev->parent->parent); in sas_expander_match()
1427 put_device(dev->parent); in sas_expander_release()
1436 put_device(dev->parent); in sas_end_device_release()
1461 struct sas_rphy *sas_end_device_alloc(struct sas_port *parent) in sas_end_device_alloc() argument
1463 struct Scsi_Host *shost = dev_to_shost(&parent->dev); in sas_end_device_alloc()
1472 rdev->rphy.dev.parent = get_device(&parent->dev); in sas_end_device_alloc()
1474 if (scsi_is_sas_expander_device(parent->dev.parent)) { in sas_end_device_alloc()
1475 struct sas_rphy *rphy = dev_to_rphy(parent->dev.parent); in sas_end_device_alloc()
1478 parent->port_identifier); in sas_end_device_alloc()
1481 shost->host_no, parent->port_identifier); in sas_end_device_alloc()
1500 struct sas_rphy *sas_expander_alloc(struct sas_port *parent, in sas_expander_alloc() argument
1503 struct Scsi_Host *shost = dev_to_shost(&parent->dev); in sas_expander_alloc()
1516 rdev->rphy.dev.parent = get_device(&parent->dev); in sas_expander_alloc()
1539 struct sas_port *parent = dev_to_sas_port(rphy->dev.parent); in sas_rphy_add() local
1540 struct Scsi_Host *shost = dev_to_shost(parent->dev.parent); in sas_rphy_add()
1545 if (parent->rphy) in sas_rphy_add()
1547 parent->rphy = rphy; in sas_rphy_add()
1599 struct Scsi_Host *shost = dev_to_shost(rphy->dev.parent->parent); in sas_rphy_free()
1634 struct sas_port *parent = dev_to_sas_port(rphy->dev.parent); in sas_rphy_unlink() local
1636 parent->rphy = NULL; in sas_rphy_unlink()