1
0
Fork 0

staging: rtl8188eu: Merge usb_ops.h into usb_ops_linux.h

Signed-off-by: navin patidar <navin.patidar@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
hifive-unleashed-5.1
navin patidar 2014-06-21 18:19:37 +05:30 committed by Greg Kroah-Hartman
parent 622c10a404
commit 17452ee9d3
13 changed files with 29 additions and 67 deletions

View File

@ -26,7 +26,6 @@
#include <hal_intf.h>
#include <usb_osintf.h>
#include <usb_ops.h>
extern void indicate_wx_scan_complete_event(struct adapter *padapter);

View File

@ -23,7 +23,6 @@
#include <drv_types.h>
#include <recv_osdep.h>
#include <mlme_osdep.h>
#include <usb_ops.h>
#include <wifi.h>
#include <linux/vmalloc.h>

View File

@ -23,7 +23,6 @@
#include <drv_types.h>
#include <wifi.h>
#include <osdep_intf.h>
#include <usb_ops.h>
#include <usb_osintf.h>
#include <linux/vmalloc.h>

View File

@ -28,8 +28,6 @@
#include <rtw_iol.h>
#include <usb_ops.h>
void iol_mode_enable(struct adapter *padapter, u8 enable)
{
u8 reg_0xf0 = 0;

View File

@ -23,7 +23,7 @@
#include <recv_osdep.h>
#include <mlme_osdep.h>
#include <usb_ops.h>
#include <usb_ops_linux.h>
#include <wifi.h>
#include <rtl8188e_hal.h>

View File

@ -22,7 +22,7 @@
#include <drv_types.h>
#include <wifi.h>
#include <osdep_intf.h>
#include <usb_ops.h>
#include <usb_ops_linux.h>
#include <rtl8188e_hal.h>
s32 rtl8188eu_init_xmit_priv(struct adapter *adapt)

View File

@ -26,7 +26,6 @@
#include <rtl8188e_hal.h>
#include <rtl8188e_led.h>
#include <rtw_iol.h>
#include <usb_ops.h>
#include <usb_hal.h>
#include <usb_osintf.h>

View File

@ -1,55 +0,0 @@
/******************************************************************************
*
* Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of version 2 of the GNU General Public License as
* published by the Free Software Foundation.
*
* 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.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
*
*
******************************************************************************/
#ifndef __USB_OPS_H_
#define __USB_OPS_H_
#include <linux/version.h>
#include <osdep_service.h>
#include <drv_types.h>
#include <osdep_intf.h>
#define REALTEK_USB_VENQT_READ 0xC0
#define REALTEK_USB_VENQT_WRITE 0x40
#define ALIGNMENT_UNIT 16
#define MAX_VENDOR_REQ_CMD_SIZE 254 /* 8188cu SIE Support */
#define MAX_USB_IO_CTL_SIZE (MAX_VENDOR_REQ_CMD_SIZE + ALIGNMENT_UNIT)
#include <usb_ops_linux.h>
#define USB_HIGH_SPEED_BULK_SIZE 512
#define USB_FULL_SPEED_BULK_SIZE 64
static inline u8 rtw_usb_bulk_size_boundary(struct adapter *padapter,
int buf_len)
{
u8 rst = true;
struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(padapter);
if (pdvobjpriv->ishighspeed)
rst = (0 == (buf_len) % USB_HIGH_SPEED_BULK_SIZE) ?
true : false;
else
rst = (0 == (buf_len) % USB_FULL_SPEED_BULK_SIZE) ?
true : false;
return rst;
}
#endif /* __USB_OPS_H_ */

View File

@ -29,6 +29,16 @@
#define RTW_USB_BULKOUT_TIME 5000/* ms */
#define REALTEK_USB_VENQT_READ 0xC0
#define REALTEK_USB_VENQT_WRITE 0x40
#define ALIGNMENT_UNIT 16
#define MAX_VENDOR_REQ_CMD_SIZE 254 /* 8188cu SIE Support */
#define MAX_USB_IO_CTL_SIZE (MAX_VENDOR_REQ_CMD_SIZE + ALIGNMENT_UNIT)
#define USB_HIGH_SPEED_BULK_SIZE 512
#define USB_FULL_SPEED_BULK_SIZE 64
#define _usbctrl_vendorreq_async_callback(urb, regs) \
_usbctrl_vendorreq_async_callback(urb)
#define usb_bulkout_zero_complete(purb, regs) \
@ -42,6 +52,21 @@
#define usb_read_interrupt_complete(purb, regs) \
usb_read_interrupt_complete(purb)
static inline u8 rtw_usb_bulk_size_boundary(struct adapter *padapter,
int buf_len)
{
u8 rst = true;
struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(padapter);
if (pdvobjpriv->ishighspeed)
rst = (0 == (buf_len) % USB_HIGH_SPEED_BULK_SIZE) ?
true : false;
else
rst = (0 == (buf_len) % USB_FULL_SPEED_BULK_SIZE) ?
true : false;
return rst;
}
unsigned int ffaddr2pipehdl(struct dvobj_priv *pdvobj, u32 addr);
u8 usb_read8(struct adapter *adapter, u32 addr);

View File

@ -29,7 +29,6 @@
#include <rtw_ioctl.h>
#include <rtw_ioctl_set.h>
#include <rtw_mp_ioctl.h>
#include <usb_ops.h>
#include <rtl8188e_hal.h>
#include <rtw_mp.h>

View File

@ -26,7 +26,7 @@
#include <recv_osdep.h>
#include <osdep_intf.h>
#include <usb_ops.h>
#include <usb_ops_linux.h>
/* alloc os related resource in struct recv_frame */
int rtw_os_recv_resource_alloc(struct adapter *padapter,

View File

@ -28,7 +28,7 @@
#include <linux/vmalloc.h>
#include <osdep_intf.h>
#include <usb_ops.h>
#include <usb_ops_linux.h>
#include <usb_osintf.h>
#include <usb_hal.h>
#include <rtw_ioctl.h>

View File

@ -19,7 +19,6 @@
#define _USB_OPS_LINUX_C_
#include <drv_types.h>
#include <usb_ops.h>
#include <recv_osdep.h>
#include <rtw_sreset.h>