Skip to contentSkip to conversation

broken cast in parport_pc

PATCH Dave Jones 1 participant 1 message Dec 10, 2005 Parallel port

lore
Share & tools
lore

Dave Jones

author
#0 lore raw

Spotted by a Fedora user. Compiling with DEBUG_PARPORT set fails due to the broken cast.

Just remove it.

include/linux/parport_pc.h renamed from include/linux/parport_pc.h~ +1 -1
@@ -86,7 +86,7 @@ extern __inline__ void dump_parport_stat
 	unsigned char dcr = inb (CONTROL (p));
 	unsigned char dsr = inb (STATUS (p));
 	static char *ecr_modes[] = {"SPP", "PS2", "PPFIFO", "ECP", "xXx", "yYy", "TST", "CFG"};
-	const struct parport_pc_private *priv = (parport_pc_private *)p->physport->private_data;
+	const struct parport_pc_private *priv = p->physport->private_data;
 	int i;
 
 	printk (KERN_DEBUG "*** parport state (%s): ecr=[%s", str, ecr_modes[(ecr & 0xe0) >> 5]);