Skip to contentSkip to conversation

Staging: comedi: Removed expression that has no effect

PATCH In review Adrian Remonda 2 participants 3 messages May 12, 2015 – May 14, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Staging: comedi: Removed expression that has no effect

This patch remove a register from an '|' expression. It is wrong since after in the code, the variable ai_trig gets written back to that register.

modified: drivers/staging/comedi/drivers/ni_mio_common.c

---
 drivers/staging/comedi/drivers/ni_mio_common.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/staging/comedi/drivers/ni_mio_common.c +1 -2
index c741dde9c0bb..9dfd4e6e6ced 100644
@@ -2268,8 +2268,7 @@ static int ni_ai_cmd(struct comedi_device *dev, struct comedi_subdevice *s)
 	case TRIG_INT:
 	case TRIG_NOW:
 		ai_trig |= NISTC_AI_TRIG_START1_EDGE |
-			   NISTC_AI_TRIG_START1_SEL(0),
-			   NISTC_AI_TRIG_SEL_REG;
+			   NISTC_AI_TRIG_START1_SEL(0);
 		break;
 	case TRIG_EXT:
 		ai_trig |= NISTC_AI_TRIG_START1_SEL(CR_CHAN(cmd->start_arg) +
Signature · 1 line
2.1.4
#1 lore raw
Quoted 6 lines · Adrian Remonda

This patch remove a register from an '|' expression. It is wrong since after in the code, the variable ai_trig gets written back to that register.

modified: drivers/staging/comedi/drivers/ni_mio_common.c

What does this line mean here?

And Hartley sent a fix for this yesterday, I haven't had a chance to apply it yet...

thanks,

greg k-h

#2 lore raw
Quoted 8 lines · Greg Kroah-Hartman
Quoted 6 lines · Adrian Remonda

This patch remove a register from an '|' expression. It is wrong since after in the code, the variable ai_trig gets written back to that register.

modified: drivers/staging/comedi/drivers/ni_mio_common.c

Quoted 8 lines

What does this line mean here?

And Hartley sent a fix for this yesterday, I haven't had a chance to apply it yet...

thanks,

greg k-h

Sorry I did't see that there was a previous fix.