资源简介
linux下RTL8821蓝牙驱动,ubuntu
代码片段和文件信息
/*
*
* Realtek Bluetooth USB driver
*
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not write to the Free Software
* Foundation Inc. 59 Temple Place Suite 330 Boston MA 02111-1307 USA
*
*/
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include “rtk_bt.h“
#define VERSION “3.1“
#ifdef BTCOEX
#include “rtk_coex.h“
#endif
static uint8_t gEVersion = 0xFF;
#if HCI_VERSION_CODE >= KERNEL_VERSION(3 7 1)
static bool reset = 0;
#endif
static struct usb_driver btusb_driver;
static struct usb_device_id btusb_table[] = {
{
.match_flags = USB_DEVICE_ID_MATCH_VENDOR |
USB_DEVICE_ID_MATCH_INT_INFO
.idVendor = 0x0bda
.bInterfaceClass = 0xe0
.bInterfaceSubClass = 0x01
.bInterfaceProtocol = 0x01
} {
.match_flags = USB_DEVICE_ID_MATCH_VENDOR |
USB_DEVICE_ID_MATCH_INT_INFO
.idVendor = 0x13d3
.bInterfaceClass = 0xe0
.bInterfaceSubClass = 0x01
.bInterfaceProtocol = 0x01
} {
.match_flags = USB_DEVICE_ID_MATCH_VENDOR |
USB_DEVICE_ID_MATCH_INT_INFO
.idVendor = 0x0489
.bInterfaceClass = 0xe0
.bInterfaceSubClass = 0x01
.bInterfaceProtocol = 0x01
} { }
};
static void rtk_free(struct btusb_data *data)
{
#if LINUX_VERSION_CODE < KERNEL_VERSION(3 7 1)
kfree(data);
#endif
return;
}
static struct btusb_data *rtk_alloc(struct usb_interface *intf)
{
struct btusb_data *data;
#if LINUX_VERSION_CODE < KERNEL_VERSION(3 7 1)
data = kzalloc(sizeof(*data) GFP_KERNEL);
#else
data = devm_kzalloc(&intf->dev sizeof(*data) GFP_KERNEL);
#endif
return data;
}
MODULE_DEVICE_TABLE(usb btusb_table);
static int inc_tx(struct btusb_data *data)
{
unsigned long flags;
int rv;
spin_lock_irqsave(&data->txlock flags);
rv = test_bit(BTUSB_SUSPENDING &data->flags);
if (!rv)
data->tx_in_flight++;
spin_unlock_irqrestore(&data->txlock flags);
return rv;
}
#if HCI_VERSION_CODE >= KERNEL_VERSION(3 18 0)
static inline void btusb_free_frags(struct btusb_data *data)
{
unsigned long flags;
spin_lock_irqsave(&data->rxlock flags);
kfree_skb(data->evt_skb);
data->evt_skb = NULL;
kfree_skb(data->acl_skb);
data->acl_skb = NULL;
kfree_skb(data->sco_skb);
data->sco_skb = NULL;
spin_un
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-04-10 10:45 LINUX_BT\
目录 0 2017-04-10 10:46 LINUX_BT\8821AU\
文件 321 2017-04-10 10:46 LINUX_BT\8821AU\Makefile
文件 40024 2017-04-10 10:36 LINUX_BT\8821AU\rtl8821a_fw
目录 0 2017-06-30 19:50 LINUX_BT\bluetooth_usb_driver\
文件 300 2017-03-14 14:37 LINUX_BT\bluetooth_usb_driver\Makefile
文件 68598 2017-04-10 10:56 LINUX_BT\bluetooth_usb_driver\rtk_bt.c
文件 5577 2017-03-14 14:37 LINUX_BT\bluetooth_usb_driver\rtk_bt.h
文件 67923 2017-03-14 14:37 LINUX_BT\bluetooth_usb_driver\rtk_coex.c
文件 9894 2017-03-14 14:37 LINUX_BT\bluetooth_usb_driver\rtk_coex.h
目录 0 2017-06-30 20:50 LINUX_BT\bluetooth_usb_driver\SI\
文件 53248 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.IAB
文件 848 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.IAD
文件 12288 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.IMB
文件 448 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.IMD
文件 16 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.PFI
文件 776 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.PO
文件 1760 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.PR
文件 8608 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.PRI
文件 103884 2017-06-30 19:51 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.PS
文件 39 2017-06-30 20:50 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.SearchResults
文件 13669 2017-06-30 20:50 LINUX_BT\bluetooth_usb_driver\SI\bluetooth_usb_driver.WK3
文件 761 2017-04-10 10:45 LINUX_BT\Makefile
文件 5209 2017-03-14 14:37 LINUX_BT\Readme.txt
- 上一篇:游程编码实现图像压缩
- 下一篇:springCloud demo
相关资源
- 嵌入式Linux视频教程完整视频
- Red_Hat_Enterprise_Linux-7-Performance_Tuning_
- Linux C大文件的创建和读写速率
- linux基础及应用课后习题答案 .pdf
- linux fb-test-帧缓冲 两个完整源代码
- GTK+glade3设计的计算器适用于linux、w
- minigui clock时钟
- Linux命令速查手册.CHM
- 自己实现linux下ls命令 的两个选项
- linux题
- Linux环境下的网络抓包工具pcap,界面
- BT08B蓝牙模块手册
- 最新版本linux libc库实现源码
- gtk写的贪吃蛇游戏
- wince上查找周围的蓝牙并连接
- grub引导文件
- linux为服务器,Windows为客户端的简单
- 智能小车硬件课设循迹,避障,蓝牙
- VmwareHorizonView6ForLinuxVDI全套解决方案所
- 学生信息管理系统项 Linux
- 操作系统接口:兼容Unix/Linux命令接口
- OpenVPN在Linux教程.pdf
- Linux 常用C函数中文版
- linux c下acc打包成RTP并在VLC上播放
- 用net-snmp的api实现trap接收,windows+li
- 基于Linux嵌入式网络视频监控系统
- linux网络编程源码
- 把Linux中的文本文件格式转为Windows的
- Live555基于h264嵌入式linux下rtsp项目的裁
- OK6410 linux混杂设备驱动LED
评论
共有 条评论