ex_phy->phy_state = PHY_DEVICE_DISCOVERED;
 }
 
+static void sas_ex_add_parent_port(struct domain_device *dev, int phy_id)
+{
+       struct expander_device *ex = &dev->ex_dev;
+       struct ex_phy *ex_phy = &ex->ex_phy[phy_id];
+
+       if (!ex->parent_port) {
+               ex->parent_port = sas_port_alloc(&dev->rphy->dev, phy_id);
+               /* FIXME: error handling */
+               BUG_ON(!ex->parent_port);
+               BUG_ON(sas_port_add(ex->parent_port));
+               sas_port_mark_backlink(ex->parent_port);
+       }
+       sas_port_add_phy(ex->parent_port, ex_phy->phy);
+}
+
 /* ---------- SMP task management ---------- */
 
 /* Give it some long enough timeout. In seconds. */
 
        /* Parent and domain coherency */
        if (!dev->parent && sas_phy_match_port_addr(dev->port, ex_phy)) {
-               sas_add_parent_port(dev, phy_id);
+               sas_ex_add_parent_port(dev, phy_id);
                return 0;
        }
        if (dev->parent && sas_phy_match_dev_addr(dev->parent, ex_phy)) {
-               sas_add_parent_port(dev, phy_id);
+               sas_ex_add_parent_port(dev, phy_id);
                if (ex_phy->routing_attr == TABLE_ROUTING)
                        sas_configure_phy(dev, phy_id, dev->port->sas_addr, 1);
                return 0;
 
        }
 }
 
-static inline void sas_add_parent_port(struct domain_device *dev, int phy_id)
-{
-       struct expander_device *ex = &dev->ex_dev;
-       struct ex_phy *ex_phy = &ex->ex_phy[phy_id];
-
-       if (!ex->parent_port) {
-               ex->parent_port = sas_port_alloc(&dev->rphy->dev, phy_id);
-               /* FIXME: error handling */
-               BUG_ON(!ex->parent_port);
-               BUG_ON(sas_port_add(ex->parent_port));
-               sas_port_mark_backlink(ex->parent_port);
-       }
-       sas_port_add_phy(ex->parent_port, ex_phy->phy);
-}
-
 static inline struct domain_device *sas_alloc_device(void)
 {
        struct domain_device *dev = kzalloc(sizeof(*dev), GFP_KERNEL);