On 08/12/2013 05:04 AM, Philipp Zabel wrote: > Am Donnerstag, den 08.08.2013, 12:43 -0600 schrieb Stephen Warren: ... >> Equally, if every binding is either-or, you may as well force drivers >> passing the binding to just call different APIs based on their binding >> definition. >> >> If (2), then you'd need to pass both the legacy property name and >> reset-names value separately, since I imagine those values would be >> different, consider: >> >> old: >> >> nvidia,phy-reset-gpio = <&gpio 1 0>; >> >> new: >> >> reset-gpios = <&gpio 1 0>; >> reset-names = "phy"; > > Correct. In this case: > > rstc = of_get_named_reset_control(np, "nvidia,phy-reset-gpio", 0); > if (IS_ERR(rstc)) { > ret = PTR_ERR(rstc); > if (ret == -EPROBE_DEFER) > return ret; > rstc = reset_control_get(dev, "phy"); > if (IS_ERR(rstc)) > return PTR_ERR(rstc); > } > > Maybe encapsulate this in a convenience wrapper: > > rstc = reset_control_get_legacy(dev, "phy", "nvidia,phy-reset-gpio"); Yes, that's exactly what I envisaged. Thanks. -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html