]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/media/rc/iguanair.c
[media] lirc: make transmit interface consistent
[karo-tx-linux.git] / drivers / media / rc / iguanair.c
index a4ab2e6b3f82fcdba0364745e064be3970b3ba8b..19632b1c21908cb52e0c483f7a7339f647756e1e 100644 (file)
@@ -364,8 +364,8 @@ static int iguanair_tx(struct rc_dev *dev, unsigned *txbuf, unsigned count)
                periods = DIV_ROUND_CLOSEST(txbuf[i] * ir->carrier, 1000000);
                bytes = DIV_ROUND_UP(periods, 127);
                if (size + bytes > ir->bufsize) {
-                       count = i;
-                       break;
+                       rc = -EINVAL;
+                       goto out;
                }
                while (periods > 127) {
                        ir->packet->payload[size++] = 127 | space;