lkml.org 
[lkml]   [2011]   [Apr]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectlinux-next: manual merge of the tty tree with the bluetooth tree
Hi Greg,

Today's linux-next merge of the tty tree got a conflict in
drivers/bluetooth/hci_ldisc.c between commit 78b4a56c28c0 ("Bluetooth:
hci_uart: check the return value of recv()") from the bluetooth tree and
commit b1c43f82c5aa ("tty: make receive_buf() return the amout of bytes
received") from the tty tree.

I fixed it up (see below) and can carry the fix as necessary.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au

diff --cc drivers/bluetooth/hci_ldisc.c
index 320f718,0d4da5e..0000000
--- a/drivers/bluetooth/hci_ldisc.c
+++ b/drivers/bluetooth/hci_ldisc.c
@@@ -357,21 -357,21 +357,22 @@@ static void hci_uart_tty_wakeup(struct
*
* Return Value: None
*/
- static void hci_uart_tty_receive(struct tty_struct *tty, const u8 *data, char *flags, int count)
+ static unsigned int hci_uart_tty_receive(struct tty_struct *tty,
+ const u8 *data, char *flags, int count)
{
- int ret;
struct hci_uart *hu = (void *)tty->disc_data;
+ int received;

if (!hu || tty != hu->tty)
- return;
+ return -ENODEV;

if (!test_bit(HCI_UART_PROTO_SET, &hu->flags))
- return;
+ return -EINVAL;

spin_lock(&hu->rx_lock);
- ret = hu->proto->recv(hu, (void *) data, count);
- if (ret > 0)
+ received = hu->proto->recv(hu, (void *) data, count);
- hu->hdev->stat.byte_rx += count;
++ if (received > 0)
+ hu->hdev->stat.byte_rx += count;
spin_unlock(&hu->rx_lock);

tty_unthrottle(tty);


\
 
 \ /
  Last update: 2011-04-26 09:57    [W:0.047 / U:0.664 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site