diff options
Diffstat (limited to 'drivers/bluetooth/bluecard_cs.c')
-rw-r--r-- | drivers/bluetooth/bluecard_cs.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/drivers/bluetooth/bluecard_cs.c b/drivers/bluetooth/bluecard_cs.c index bd2ec7e284cc..26fe9c0e1d20 100644 --- a/drivers/bluetooth/bluecard_cs.c +++ b/drivers/bluetooth/bluecard_cs.c | |||
@@ -270,7 +270,7 @@ static void bluecard_write_wakeup(bluecard_info_t *info) | |||
270 | if (!(skb = skb_dequeue(&(info->txq)))) | 270 | if (!(skb = skb_dequeue(&(info->txq)))) |
271 | break; | 271 | break; |
272 | 272 | ||
273 | if (skb->pkt_type & 0x80) { | 273 | if (bt_cb(skb)->pkt_type & 0x80) { |
274 | /* Disable RTS */ | 274 | /* Disable RTS */ |
275 | info->ctrl_reg |= REG_CONTROL_RTS; | 275 | info->ctrl_reg |= REG_CONTROL_RTS; |
276 | outb(info->ctrl_reg, iobase + REG_CONTROL); | 276 | outb(info->ctrl_reg, iobase + REG_CONTROL); |
@@ -288,13 +288,13 @@ static void bluecard_write_wakeup(bluecard_info_t *info) | |||
288 | /* Mark the buffer as dirty */ | 288 | /* Mark the buffer as dirty */ |
289 | clear_bit(ready_bit, &(info->tx_state)); | 289 | clear_bit(ready_bit, &(info->tx_state)); |
290 | 290 | ||
291 | if (skb->pkt_type & 0x80) { | 291 | if (bt_cb(skb)->pkt_type & 0x80) { |
292 | DECLARE_WAIT_QUEUE_HEAD(wq); | 292 | DECLARE_WAIT_QUEUE_HEAD(wq); |
293 | DEFINE_WAIT(wait); | 293 | DEFINE_WAIT(wait); |
294 | 294 | ||
295 | unsigned char baud_reg; | 295 | unsigned char baud_reg; |
296 | 296 | ||
297 | switch (skb->pkt_type) { | 297 | switch (bt_cb(skb)->pkt_type) { |
298 | case PKT_BAUD_RATE_460800: | 298 | case PKT_BAUD_RATE_460800: |
299 | baud_reg = REG_CONTROL_BAUD_RATE_460800; | 299 | baud_reg = REG_CONTROL_BAUD_RATE_460800; |
300 | break; | 300 | break; |
@@ -410,9 +410,9 @@ static void bluecard_receive(bluecard_info_t *info, unsigned int offset) | |||
410 | if (info->rx_state == RECV_WAIT_PACKET_TYPE) { | 410 | if (info->rx_state == RECV_WAIT_PACKET_TYPE) { |
411 | 411 | ||
412 | info->rx_skb->dev = (void *) info->hdev; | 412 | info->rx_skb->dev = (void *) info->hdev; |
413 | info->rx_skb->pkt_type = buf[i]; | 413 | bt_cb(info->rx_skb)->pkt_type = buf[i]; |
414 | 414 | ||
415 | switch (info->rx_skb->pkt_type) { | 415 | switch (bt_cb(info->rx_skb)->pkt_type) { |
416 | 416 | ||
417 | case 0x00: | 417 | case 0x00: |
418 | /* init packet */ | 418 | /* init packet */ |
@@ -444,7 +444,7 @@ static void bluecard_receive(bluecard_info_t *info, unsigned int offset) | |||
444 | 444 | ||
445 | default: | 445 | default: |
446 | /* unknown packet */ | 446 | /* unknown packet */ |
447 | BT_ERR("Unknown HCI packet with type 0x%02x received", info->rx_skb->pkt_type); | 447 | BT_ERR("Unknown HCI packet with type 0x%02x received", bt_cb(info->rx_skb)->pkt_type); |
448 | info->hdev->stat.err_rx++; | 448 | info->hdev->stat.err_rx++; |
449 | 449 | ||
450 | kfree_skb(info->rx_skb); | 450 | kfree_skb(info->rx_skb); |
@@ -586,21 +586,21 @@ static int bluecard_hci_set_baud_rate(struct hci_dev *hdev, int baud) | |||
586 | switch (baud) { | 586 | switch (baud) { |
587 | case 460800: | 587 | case 460800: |
588 | cmd[4] = 0x00; | 588 | cmd[4] = 0x00; |
589 | skb->pkt_type = PKT_BAUD_RATE_460800; | 589 | bt_cb(skb)->pkt_type = PKT_BAUD_RATE_460800; |
590 | break; | 590 | break; |
591 | case 230400: | 591 | case 230400: |
592 | cmd[4] = 0x01; | 592 | cmd[4] = 0x01; |
593 | skb->pkt_type = PKT_BAUD_RATE_230400; | 593 | bt_cb(skb)->pkt_type = PKT_BAUD_RATE_230400; |
594 | break; | 594 | break; |
595 | case 115200: | 595 | case 115200: |
596 | cmd[4] = 0x02; | 596 | cmd[4] = 0x02; |
597 | skb->pkt_type = PKT_BAUD_RATE_115200; | 597 | bt_cb(skb)->pkt_type = PKT_BAUD_RATE_115200; |
598 | break; | 598 | break; |
599 | case 57600: | 599 | case 57600: |
600 | /* Fall through... */ | 600 | /* Fall through... */ |
601 | default: | 601 | default: |
602 | cmd[4] = 0x03; | 602 | cmd[4] = 0x03; |
603 | skb->pkt_type = PKT_BAUD_RATE_57600; | 603 | bt_cb(skb)->pkt_type = PKT_BAUD_RATE_57600; |
604 | break; | 604 | break; |
605 | } | 605 | } |
606 | 606 | ||
@@ -680,7 +680,7 @@ static int bluecard_hci_send_frame(struct sk_buff *skb) | |||
680 | 680 | ||
681 | info = (bluecard_info_t *)(hdev->driver_data); | 681 | info = (bluecard_info_t *)(hdev->driver_data); |
682 | 682 | ||
683 | switch (skb->pkt_type) { | 683 | switch (bt_cb(skb)->pkt_type) { |
684 | case HCI_COMMAND_PKT: | 684 | case HCI_COMMAND_PKT: |
685 | hdev->stat.cmd_tx++; | 685 | hdev->stat.cmd_tx++; |
686 | break; | 686 | break; |
@@ -693,7 +693,7 @@ static int bluecard_hci_send_frame(struct sk_buff *skb) | |||
693 | }; | 693 | }; |
694 | 694 | ||
695 | /* Prepend skb with frame type */ | 695 | /* Prepend skb with frame type */ |
696 | memcpy(skb_push(skb, 1), &(skb->pkt_type), 1); | 696 | memcpy(skb_push(skb, 1), &bt_cb(skb)->pkt_type, 1); |
697 | skb_queue_tail(&(info->txq), skb); | 697 | skb_queue_tail(&(info->txq), skb); |
698 | 698 | ||
699 | bluecard_write_wakeup(info); | 699 | bluecard_write_wakeup(info); |