Skip to contentSkip to conversation

remove implicit sign bit on single bit

PATCH New Darren Jenkins\ 1 participant 1 message Feb 21, 2006

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 remove implicit sign bit on single bit

Quoted 13 lines · Alexey Dobriyan
Quoted 12 lines · Darren Jenkins
sound/oss/via82cxxx_audio.c renamed from sound/oss/via82cxxx_audio.c.orig +1 -2
@@ -306,9 +306,8 @@ struct via_info {
 	unsigned intmask: 1;	/* Needs int bits */
 	unsigned sixchannel: 1;	/* 8233/35 with 6 channel support */
 	unsigned volume: 1;
+	unsigned locked_rate : 1;
 
-	int locked_rate : 1;
-
 	int mixer_vol;		/* 8233/35 volume  - not yet implemented */
 
Quoted 8 lines

sound/oss/via82cxxx_audio.c struct via_info { · line 313

Quoted 1 line
sound/oss/via82cxxx_audio.c renamed from sound/oss/via82cxxx_audio.c.orig +0 -0
 	struct semaphore syscall_sem;

These patches are OK, except

	unsigned int a:1;

is preferred.

Yep, that was pointed out to me earlier. I hadn't gone through them to change them all yet.

I think the via82cxxx_audio.c patch should stay the same as the local context uses "unsigned foo:1;" but if you want I can do a patch that converts the whole file to "unsigned int foo:1;" style.

Here is a re-work of the other patches.

drivers/media/video/videocodec.h renamed from drivers/media/video/videocodec.h.orig +8 -8
@@ -222,14 +222,14 @@ M                       zr36055[1] 0001 
 /* ========================= */
 
 struct vfe_polarity {
-	int vsync_pol:1;
-	int hsync_pol:1;
-	int field_pol:1;
-	int blank_pol:1;
-	int subimg_pol:1;
-	int poe_pol:1;
-	int pvalid_pol:1;
-	int vclk_pol:1;
+	unsigned int vsync_pol:1;
+	unsigned int hsync_pol:1;
+	unsigned int field_pol:1;
+	unsigned int blank_pol:1;
+	unsigned int subimg_pol:1;
+	unsigned int poe_pol:1;
+	unsigned int pvalid_pol:1;
+	unsigned int vclk_pol:1;
 };
 
 struct vfe_settings {
drivers/media/dvb/frontends/l64781.c renamed from drivers/media/dvb/frontends/l64781.c.orig +1 -1
@@ -37,7 +37,7 @@ struct l64781_state {
 	struct dvb_frontend frontend;
 
 	/* private demodulator data */
-	int first:1;
+	unsigned int first:1;
 };
 
 #define dprintk(args...) \
drivers/isdn/hisax/isdnhdlc.h renamed from drivers/isdn/hisax/isdnhdlc.h.orig +4 -4
@@ -41,10 +41,10 @@ struct isdnhdlc_vars {
 	unsigned char shift_reg;
 	unsigned char ffvalue;
 
-	int data_received:1; 	// set if transferring data
-	int dchannel:1; 	// set if D channel (send idle instead of flags)
-	int do_adapt56:1; 	// set if 56K adaptation
-        int do_closing:1; 	// set if in closing phase (need to send CRC + flag
+	unsigned int data_received:1; 	// set if transferring data
+	unsigned int dchannel:1; 	// set if D channel (send idle instead of flags)
+	unsigned int do_adapt56:1; 	// set if 56K adaptation
+	unsigned int do_closing:1; 	// set if in closing phase (need to send CRC + flag
 };
 
 

_______________________________________________
Kernel-janitors mailing list
[email protected]
https://lists.osdl.org/mailman/listinfo/kernel-janitors