Lines Matching refs:dr
14 struct mdiobus_devres *dr = this; in devm_mdiobus_free() local
16 mdiobus_free(dr->mii); in devm_mdiobus_free()
32 struct mdiobus_devres *dr; in devm_mdiobus_alloc_size() local
34 dr = devres_alloc(devm_mdiobus_free, sizeof(*dr), GFP_KERNEL); in devm_mdiobus_alloc_size()
35 if (!dr) in devm_mdiobus_alloc_size()
38 dr->mii = mdiobus_alloc_size(sizeof_priv); in devm_mdiobus_alloc_size()
39 if (!dr->mii) { in devm_mdiobus_alloc_size()
40 devres_free(dr); in devm_mdiobus_alloc_size()
44 devres_add(dev, dr); in devm_mdiobus_alloc_size()
45 return dr->mii; in devm_mdiobus_alloc_size()
51 struct mdiobus_devres *dr = this; in devm_mdiobus_unregister() local
53 mdiobus_unregister(dr->mii); in devm_mdiobus_unregister()
76 struct mdiobus_devres *dr; in __devm_mdiobus_register() local
83 dr = devres_alloc(devm_mdiobus_unregister, sizeof(*dr), GFP_KERNEL); in __devm_mdiobus_register()
84 if (!dr) in __devm_mdiobus_register()
89 devres_free(dr); in __devm_mdiobus_register()
93 dr->mii = bus; in __devm_mdiobus_register()
94 devres_add(dev, dr); in __devm_mdiobus_register()
109 struct mdiobus_devres *dr; in devm_of_mdiobus_register() local
116 dr = devres_alloc(devm_mdiobus_unregister, sizeof(*dr), GFP_KERNEL); in devm_of_mdiobus_register()
117 if (!dr) in devm_of_mdiobus_register()
122 devres_free(dr); in devm_of_mdiobus_register()
126 dr->mii = mdio; in devm_of_mdiobus_register()
127 devres_add(dev, dr); in devm_of_mdiobus_register()