Thread (20 messages) 20 messages, 5 authors, 2014-01-09
STALE4534d

[PATCH v4 3/3] i2c: mv64xxx: Fix bus hang on A0 version of the Armada XP SoCs

From: Thomas Petazzoni <hidden>
Date: 2014-01-07 22:17:21
Also in: linux-i2c

Dear Gregory CLEMENT,

On Tue,  7 Jan 2014 17:35:04 +0100, Gregory CLEMENT wrote:
 	if (of_device_is_compatible(np, "marvell,mv78230-i2c")) {
-		drv_data->offload_enabled = true;
 		drv_data->errata_delay = true;
+
+		if (!of_find_property(np, "offload-broken", NULL))
+			drv_data->offload_enabled = true;
 	}
I think of_property_read_bool() is more appropriate than
of_find_property() in this situation, because offload-broken is indeed
a boolean property.

Something like:

		drv_data->offload_enable = !of_property_read_bool(np, "offload-broken");

Thanks!

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help