Skip to content

Commit

Permalink
media: rc-loopback: return number of emitters rather than error
Browse files Browse the repository at this point in the history
The LIRC_SET_TRANSMITTER_MASK ioctl should return the number of emitters
if an invalid list was set.

Cc: [email protected]
Signed-off-by: Sean Young <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
  • Loading branch information
seanyoung authored and mchehab committed Jul 22, 2021
1 parent 379e205 commit 6b7f554
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/rc/rc-loopback.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ static int loop_set_tx_mask(struct rc_dev *dev, u32 mask)

if ((mask & (RXMASK_REGULAR | RXMASK_LEARNING)) != mask) {
dprintk("invalid tx mask: %u\n", mask);
return -EINVAL;
return 2;
}

dprintk("setting tx mask: %u\n", mask);
Expand Down

0 comments on commit 6b7f554

Please sign in to comment.