Lines Matching refs:pd

174 phy_register(struct phy_device *pd)  in phy_register()  argument
176 pd->pd_cells = OF_getpropint(pd->pd_node, "#phy-cells", 0); in phy_register()
177 pd->pd_phandle = OF_getpropint(pd->pd_node, "phandle", 0); in phy_register()
178 if (pd->pd_phandle == 0) in phy_register()
181 LIST_INSERT_HEAD(&phy_devices, pd, pd_list); in phy_register()
216 struct phy_device *pd; in phy_enable_cells() local
220 LIST_FOREACH(pd, &phy_devices, pd_list) { in phy_enable_cells()
221 if (pd->pd_phandle == phandle) in phy_enable_cells()
225 if (pd && pd->pd_enable) in phy_enable_cells()
226 return pd->pd_enable(pd->pd_cookie, &cells[1]); in phy_enable_cells()
489 pwm_register(struct pwm_device *pd) in pwm_register() argument
491 pd->pd_cells = OF_getpropint(pd->pd_node, "#pwm-cells", 0); in pwm_register()
492 pd->pd_phandle = OF_getpropint(pd->pd_node, "phandle", 0); in pwm_register()
493 if (pd->pd_phandle == 0) in pwm_register()
496 LIST_INSERT_HEAD(&pwm_devices, pd, pd_list); in pwm_register()
503 struct pwm_device *pd; in pwm_init_state() local
505 LIST_FOREACH(pd, &pwm_devices, pd_list) { in pwm_init_state()
506 if (pd->pd_phandle == cells[0]) { in pwm_init_state()
508 pd->pd_get_state(pd->pd_cookie, &cells[1], ps); in pwm_init_state()
510 if (pd->pd_cells >= 2) in pwm_init_state()
512 if (pd->pd_cells >= 3) in pwm_init_state()
524 struct pwm_device *pd; in pwm_get_state() local
526 LIST_FOREACH(pd, &pwm_devices, pd_list) { in pwm_get_state()
527 if (pd->pd_phandle == cells[0]) in pwm_get_state()
528 return pd->pd_get_state(pd->pd_cookie, &cells[1], ps); in pwm_get_state()
537 struct pwm_device *pd; in pwm_set_state() local
539 LIST_FOREACH(pd, &pwm_devices, pd_list) { in pwm_set_state()
540 if (pd->pd_phandle == cells[0]) in pwm_set_state()
541 return pd->pd_set_state(pd->pd_cookie, &cells[1], ps); in pwm_set_state()