Skip to contentSkip to conversation

convert pcilynx.c to C99 initializers

PATCH Applied Adrian Bunk 2 participants 2 messages Jan 3, 2003

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 convert pcilynx.c to C99 initializers

Hi Andreas,

in 2.5.54 struct i2c_adapter changed resulting in a compile error in pcilynx.c. The patch below that converts pcilynx.c to C99 initializers fixes it.

cu
Adrian

drivers/ieee1394/pcilynx.c renamed from drivers/ieee1394/pcilynx.c.old +11 -14
@@ -127,23 +127,20 @@
 }
 
 static struct i2c_algo_bit_data bit_data = {
-	NULL,
-	bit_setsda,
-	bit_setscl,
-	bit_getsda,
-	bit_getscl,
-	5, 5, 100,		/*	waits, timeout */
+	.setsda			= bit_setsda,
+	.setscl			= bit_setscl,
+	.getsda			= bit_getsda,
+	.getscl			= bit_getscl,
+	.udelay			= 5,
+	.mdelay			= 5,
+	.timeout		= 100,
 }; 
 
 static struct i2c_adapter bit_ops = {
-	"PCILynx I2C adapter",
-	0xAA, //FIXME: probably we should get an id in i2c-id.h
-	NULL,
-	NULL,
-	NULL,
-	NULL,
-	bit_reg,
-	bit_unreg,
+	.name			= "PCILynx I2C adapter",
+	.id 			= 0xAA, //FIXME: probably we should get an id in i2c-id.h
+	.client_register	= bit_reg,
+	.client_unregister	= bit_unreg,
 };
 
 
Applied
#1 lore raw
Quoted 5 lines · Adrian Bunk

Hi Andreas,

in 2.5.54 struct i2c_adapter changed resulting in a compile error in pcilynx.c. The patch below that converts pcilynx.c to C99 initializers fixes it.

Applied to the SVN repo. Linus should get this over the weekend when I sync with him.

Signature · 4 lines
Debian     - http://www.debian.org/
Linux 1394 - http://www.linux1394.org/
Subversion - http://subversion.tigris.org/
Deqo       - http://www.deqo.com/