aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/hardware/mISDN/hfcsusb.c
diff options
context:
space:
mode:
authorKarsten Keil <keil@b1-systems.de>2009-07-09 04:02:29 -0400
committerKarsten Keil <keil@b1-systems.de>2009-07-25 14:18:16 -0400
commitfb286f0471a04ef646c8e5c79750ae6718183745 (patch)
tree6e88ae4869ca1aedb5e674733a903324530d6ee1 /drivers/isdn/hardware/mISDN/hfcsusb.c
parentf3fad223ed69f406f33c9619c256858d5a5fc5c7 (diff)
mISDN: Make clearing B-channel a common function
Clearing B-channel is needed in every driver, so it makes sense to have it as common function. Signed-off-by: Karsten Keil <keil@b1-systems.de>
Diffstat (limited to 'drivers/isdn/hardware/mISDN/hfcsusb.c')
-rw-r--r--drivers/isdn/hardware/mISDN/hfcsusb.c16
1 files changed, 1 insertions, 15 deletions
diff --git a/drivers/isdn/hardware/mISDN/hfcsusb.c b/drivers/isdn/hardware/mISDN/hfcsusb.c
index 6b7704c41b94..fc46a26cb14f 100644
--- a/drivers/isdn/hardware/mISDN/hfcsusb.c
+++ b/drivers/isdn/hardware/mISDN/hfcsusb.c
@@ -1809,21 +1809,7 @@ deactivate_bchannel(struct bchannel *bch)
1809 hw->name, __func__, bch->nr); 1809 hw->name, __func__, bch->nr);
1810 1810
1811 spin_lock_irqsave(&hw->lock, flags); 1811 spin_lock_irqsave(&hw->lock, flags);
1812 if (test_and_clear_bit(FLG_TX_NEXT, &bch->Flags)) { 1812 mISDN_clear_bchannel(bch);
1813 dev_kfree_skb(bch->next_skb);
1814 bch->next_skb = NULL;
1815 }
1816 if (bch->tx_skb) {
1817 dev_kfree_skb(bch->tx_skb);
1818 bch->tx_skb = NULL;
1819 }
1820 bch->tx_idx = 0;
1821 if (bch->rx_skb) {
1822 dev_kfree_skb(bch->rx_skb);
1823 bch->rx_skb = NULL;
1824 }
1825 clear_bit(FLG_ACTIVE, &bch->Flags);
1826 clear_bit(FLG_TX_BUSY, &bch->Flags);
1827 spin_unlock_irqrestore(&hw->lock, flags); 1813 spin_unlock_irqrestore(&hw->lock, flags);
1828 hfcsusb_setup_bch(bch, ISDN_P_NONE); 1814 hfcsusb_setup_bch(bch, ISDN_P_NONE);
1829 hfcsusb_stop_endpoint(hw, bch->nr); 1815 hfcsusb_stop_endpoint(hw, bch->nr);