- /* check if we're attaching to the switch twice */
- pdev = pdev->bus->phy_map[0];
- if (!pdev) {
- ar8xxx_free(priv);
- return 0;
- }
-
- /* switch device has not been initialized, reuse priv */
- if (!pdev->priv) {
- priv->port4_phy = true;
- priv->dev.ports = (AR8216_NUM_PORTS - 1);
- pdev->priv = priv;
- return 0;
- }
-
- ar8xxx_free(priv);
-