summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorSamuel Iglesias Gonsalvez <siglesias@igalia.com>2012-06-25 17:15:44 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-06-25 10:50:00 -0700
commitdb1db294d9366e95a76f4ca7e6442240eba67a0a (patch)
tree856cda00dc309ea902a525b1e033dd984db38987 /drivers
parent7756d3e8b0acff580aab1f60c30e066e20a9900e (diff)
downloadlinux-db1db294d9366e95a76f4ca7e6442240eba67a0a.tar.bz2
Staging: ipack/devices/ipoctal: fix oops when accessing "buffer"
The buffer[][] field was replaced by tty_port->xmit_buf field but there was some places that "buffer" was still accessed, giving a kernel oops because it was uninitialized. Signed-off-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/ipack/devices/ipoctal.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/ipack/devices/ipoctal.c b/drivers/staging/ipack/devices/ipoctal.c
index 29214677ea0c..7fe1c932276b 100644
--- a/drivers/staging/ipack/devices/ipoctal.c
+++ b/drivers/staging/ipack/devices/ipoctal.c
@@ -46,7 +46,6 @@ struct ipoctal {
struct scc2698_channel *chan_regs;
struct scc2698_block *block_regs;
struct ipoctal_stats chan_stats[NR_CHANNELS];
- char *buffer[NR_CHANNELS];
unsigned int nb_bytes[NR_CHANNELS];
unsigned int count_wr[NR_CHANNELS];
wait_queue_head_t queue[NR_CHANNELS];
@@ -305,7 +304,7 @@ static int ipoctal_irq_handler(void *arg)
continue;
}
spin_lock(&ipoctal->lock[channel]);
- value = ipoctal->buffer[channel][*pointer_write];
+ value = ipoctal->tty_port[channel].xmit_buf[*pointer_write];
ipoctal_write_io_reg(ipoctal,
&ipoctal->chan_regs[channel].u.w.thr,
value);