summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlberto Garcia <agarcia@igalia.com>2012-12-10 11:49:58 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-01-15 18:24:37 -0800
commit69a6b9b1b6aec645d2efa23db2c15ed287e672dd (patch)
tree180e2afbbb21b2d98c1c9dc640bedd84bbe6737a
parentcc83f833c77c1d233e3843af18c1abf8d561d1fa (diff)
downloadtalos-op-linux-69a6b9b1b6aec645d2efa23db2c15ed287e672dd.tar.gz
talos-op-linux-69a6b9b1b6aec645d2efa23db2c15ed287e672dd.zip
ipack/devices/ipoctal: don't check if nb_bytes is < 0
It is an unsigned int so that check is pointless. Signed-off-by: Alberto Garcia <agarcia@igalia.com> Signed-off-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/ipack/devices/ipoctal.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/ipack/devices/ipoctal.c b/drivers/ipack/devices/ipoctal.c
index e66135da63ce..a33a849765c6 100644
--- a/drivers/ipack/devices/ipoctal.c
+++ b/drivers/ipack/devices/ipoctal.c
@@ -183,10 +183,8 @@ static void ipoctal_irq_tx(struct ipoctal_channel *channel)
unsigned char value;
unsigned int *pointer_write = &channel->pointer_write;
- if (channel->nb_bytes <= 0) {
- channel->nb_bytes = 0;
+ if (channel->nb_bytes == 0)
return;
- }
value = channel->tty_port.xmit_buf[*pointer_write];
iowrite8(value, &channel->regs->w.thr);
OpenPOWER on IntegriCloud