Commit 7300d0c2 authored by Sean Young's avatar Sean Young Committed by Mauro Carvalho Chehab

media: rc-loopback: send carrier reports

When carrier reports are enabled, send them over loopback.
Signed-off-by: default avatarSean Young <sean@mess.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent d9d01039
...@@ -111,10 +111,18 @@ static int loop_tx_ir(struct rc_dev *dev, unsigned *txbuf, unsigned count) ...@@ -111,10 +111,18 @@ static int loop_tx_ir(struct rc_dev *dev, unsigned *txbuf, unsigned count)
for (i = 0; i < count; i++) { for (i = 0; i < count; i++) {
rawir.pulse = i % 2 ? false : true; rawir.pulse = i % 2 ? false : true;
rawir.duration = txbuf[i]; rawir.duration = txbuf[i];
if (rawir.duration)
ir_raw_event_store_with_filter(dev, &rawir); ir_raw_event_store_with_filter(dev, &rawir);
} }
if (lodev->carrierreport) {
rawir.pulse = false;
rawir.carrier_report = true;
rawir.carrier = lodev->txcarrier;
ir_raw_event_store(dev, &rawir);
}
/* Fake a silence long enough to cause us to go idle */ /* Fake a silence long enough to cause us to go idle */
rawir.pulse = false; rawir.pulse = false;
rawir.duration = dev->timeout; rawir.duration = dev->timeout;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment