[PATCH 2/9] i2c: add generic routine to parse DT for timing information

Wolfram Sang wsa at the-dreams.de
Fri Dec 4 00:41:40 PST 2015


> > +void of_i2c_parse_timings(struct device_node *node, struct i2c_timings *t, bool use_defaults)
> > +{
> > +	memset(t, 0, sizeof(*t));
> > +
> > +	if (of_property_read_u32(node, "clock-frequency", &t->bus_freq_hz) && use_defaults)
> > +		t->bus_freq_hz = 100000;
> 
> Why not create device_i2c_parse_timings() instead and use unified device
> properties API?

Sure, just missed it.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-rockchip/attachments/20151204/4a1b861c/attachment-0001.sig>


More information about the Linux-rockchip mailing list