Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 30cedcf3 authored by David Härdeman's avatar David Härdeman Committed by Mauro Carvalho Chehab
Browse files

[media] winbond-cir: correctness fix



This is a minor correctness fix for the duration calculation in
winbond-cir (the read value should be incremented by one).

Signed-off-by: default avatarDavid Härdeman <david@hardeman.nu>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 8ac45649
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -358,7 +358,7 @@ wbcir_irq_rx(struct wbcir_data *data, struct pnp_dev *device)
		if (data->rxstate == WBCIR_RXSTATE_ERROR)
		if (data->rxstate == WBCIR_RXSTATE_ERROR)
			continue;
			continue;
		rawir.pulse = irdata & 0x80 ? false : true;
		rawir.pulse = irdata & 0x80 ? false : true;
		rawir.duration = US_TO_NS((irdata & 0x7F) * 10);
		rawir.duration = US_TO_NS(((irdata & 0x7F) + 1) * 10);
		ir_raw_event_store_with_filter(data->dev, &rawir);
		ir_raw_event_store_with_filter(data->dev, &rawir);
	}
	}