Description: Fix oflib examples
 Fix the soundbus example, enable it and rewrite the Makefile in
 more generic way.
Author: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
Origin: vendor, http://bugs.debian.org/609796
Bug-Debian: http://bugs.debian.org/609796

Index: oflib-0git20070620/example/Makefile
===================================================================
--- oflib-0git20070620.orig/example/Makefile
+++ oflib-0git20070620/example/Makefile
@@ -1,6 +1,9 @@
-default:
-	gcc -std=c99 -lofapi example.c -o example
-	gcc -std=c99 -lofapi ramtest.c -o ramtest
+BINARIES=example ramtest soundbus
+all: $(BINARIES)
+
+%: %.c
+	gcc -std=c99 -lofapi $< -o $@
 clean:
-	rm -f ramtest
-	rm -f example
+	rm -f $(BINARIES)
+
+.PHONY: clean all
Index: oflib-0git20070620/example/soundbus.c
===================================================================
--- oflib-0git20070620.orig/example/soundbus.c
+++ oflib-0git20070620/example/soundbus.c
@@ -73,7 +73,7 @@ void print_sound(struct device_node *nod
 	if(!property)
 		return;
 		
-	of_property_to_int(&layout_id, property, plen);
+	of_property_to_uint32(&layout_id, property, plen);
 	
 	printf("Layout ID: %d\n", layout_id);
 	
