Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/arch/arm/mach-msm/smd_tty.c b/arch/arm/mach-msm/smd_tty.c
- index 8bea09e..e12e536 100644
- --- a/arch/arm/mach-msm/smd_tty.c
- +++ b/arch/arm/mach-msm/smd_tty.c
- @@ -57,8 +57,18 @@ static void smd_readx_cb(void *data, int count, void *ctxt)
- {
- struct tty_struct *tty = ctxt;
- struct tty_ldisc *ld;
- + int idx;
- if (!tty)
- return;
- +
- + if(tty->index==0)
- + {
- + printk("SMD Read: ");
- + for(idx=0; idx < count; idx++)
- + printk("%c", ((unsigned char*)data)[idx]);
- + printk("\n");
- + }
- +
- ld = tty_ldisc_ref(tty);
- if (ld) {
- if (ld->ops->receive_buf)
- @@ -190,6 +200,7 @@ static int smd_tty_write(struct tty_struct *tty, const unsigned char *buf, int l
- {
- struct smd_tty_info *info = tty->driver_data;
- int avail;
- + int idx;
- /* if we're writing to a packet channel we will
- ** never be able to write more data than there
- @@ -199,6 +210,14 @@ static int smd_tty_write(struct tty_struct *tty, const unsigned char *buf, int l
- if (len > avail)
- len = avail;
- + if(tty->index==0)
- + {
- + printk("SMD Write: ");
- + for(idx=0; idx < len; idx++)
- + printk("%c", buf[idx]);
- + printk("\n");
- + }
- +
- return smd_write(info->ch, buf, len);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement