/** * mdio_mux_multiplexer_switch_fn - This function is called by the mdio-mux * layer when it thinks the mdio bus * multiplexer needs to switch. * @current_child: current value of the mux register. * @desired_child: value of the 'reg' property of the target child MDIO node. * @data: Private data used by this switch_fn passed to mdio_mux_init function * via mdio_mux_init(.., .., .., .., data, ..). * * The first time this function is called, current_child == -1. * If current_child == desired_child, then the mux is already set to the * correct bus.
*/ staticint mdio_mux_multiplexer_switch_fn(int current_child, int desired_child, void *data)
{ struct platform_device *pdev; struct mdio_mux_multiplexer_state *s; int ret = 0;
pdev = (struct platform_device *)data;
s = platform_get_drvdata(pdev);
if (!(current_child ^ desired_child)) return 0;
if (s->do_deselect)
ret = mux_control_deselect(s->muxc); if (ret) {
dev_err(&pdev->dev, "mux_control_deselect failed in %s: %d\n",
__func__, ret); return ret;
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.