linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sean Young <sean@mess.org>
To: linux-media@vger.kernel.org
Cc: stable@vger.kernel.org
Subject: [PATCH v2 1/5] media: rc-loopback: return number of emitters rather than error
Date: Mon,  5 Jul 2021 19:31:28 +0100	[thread overview]
Message-ID: <1c0df5716e9aa335d6d47558b3a1c7fbd7477bc7.1625509803.git.sean@mess.org> (raw)
In-Reply-To: <cover.1625509803.git.sean@mess.org>

The LIRC_SET_TRANSMITTER_MASK ioctl should return the number of emitters
if an invalid list was set.

Cc: stable@vger.kernel.org
Signed-off-by: Sean Young <sean@mess.org>
---
 drivers/media/rc/rc-loopback.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/rc/rc-loopback.c b/drivers/media/rc/rc-loopback.c
index 1ba3f96ffa7d..40ab66c850f2 100644
--- a/drivers/media/rc/rc-loopback.c
+++ b/drivers/media/rc/rc-loopback.c
@@ -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);
-- 
2.31.1


  reply	other threads:[~2021-07-05 18:31 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-05 18:31 [PATCH v2 0/5] Various rc-loopback fixes Sean Young
2021-07-05 18:31 ` Sean Young [this message]
2021-07-05 18:31 ` [PATCH v2 2/5] media: rc-loopback: use dev_dbg() rather than handrolled debug Sean Young
2021-07-05 18:31 ` [PATCH v2 3/5] media: rc-loopback: send carrier reports Sean Young
2021-07-05 18:31 ` [PATCH v2 4/5] media: rc-loopback: max_timeout of UINT_MAX does not work Sean Young
2021-07-05 18:31 ` [PATCH v2 5/5] media: rc: rename s_learning_mode() to s_wideband_receiver() Sean Young

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1c0df5716e9aa335d6d47558b3a1c7fbd7477bc7.1625509803.git.sean@mess.org \
    --to=sean@mess.org \
    --cc=linux-media@vger.kernel.org \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).