From: Jes Sorensen Date: Wed, 9 Apr 2014 21:21:13 +0000 (+0200) Subject: staging: rtl8723au: Remove ugly pktfile interface X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=4c9c5700d6719f2e7b45e1c71fdfbc88b5ce44d5;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git staging: rtl8723au: Remove ugly pktfile interface Signed-off-by: Jes Sorensen Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723au/include/xmit_osdep.h b/drivers/staging/rtl8723au/include/xmit_osdep.h index b94e5467c408..9740ef6d96f9 100644 --- a/drivers/staging/rtl8723au/include/xmit_osdep.h +++ b/drivers/staging/rtl8723au/include/xmit_osdep.h @@ -18,15 +18,6 @@ #include #include -struct pkt_file { - struct sk_buff *pkt; - __kernel_size_t pkt_len; /* the remainder length of the open_file */ - unsigned char *cur_buffer; - u8 *buf_start; - u8 *cur_addr; - __kernel_size_t buf_len; -}; - #define NR_XMITFRAME 256 @@ -44,9 +35,6 @@ int rtw_os_xmit_resource_alloc23a(struct rtw_adapter *padapter, struct xmit_buf *pxmitbuf, u32 alloc_sz); void rtw_os_xmit_resource_free23a(struct rtw_adapter *padapter, struct xmit_buf *pxmitbuf); -void _rtw_open_pktfile23a(struct sk_buff *pkt, struct pkt_file *pfile); -uint _rtw_pktfile_read23a(struct pkt_file *pfile, u8 *rmem, uint rlen); -int rtw_endofpktfile23a(struct pkt_file *pfile); void rtw_os_pkt_complete23a(struct rtw_adapter *padapter, struct sk_buff *pkt); void rtw_os_xmit_complete23a(struct rtw_adapter *padapter, diff --git a/drivers/staging/rtl8723au/os_dep/xmit_linux.c b/drivers/staging/rtl8723au/os_dep/xmit_linux.c index 3cf539a2dd0f..69f88848715a 100644 --- a/drivers/staging/rtl8723au/os_dep/xmit_linux.c +++ b/drivers/staging/rtl8723au/os_dep/xmit_linux.c @@ -24,42 +24,6 @@ #include #include -void _rtw_open_pktfile23a(struct sk_buff *pktptr, struct pkt_file *pfile) -{ - pfile->pkt = pktptr; - pfile->buf_start = pktptr->data; - pfile->cur_addr = pktptr->data; - pfile->buf_len = pktptr->len; - pfile->pkt_len = pktptr->len; - - pfile->cur_buffer = pfile->buf_start; -} - -uint _rtw_pktfile_read23a(struct pkt_file *pfile, u8 *rmem, uint rlen) -{ - uint len = 0; - - len = pfile->buf_len - ((unsigned long)(pfile->cur_addr) - - (unsigned long)(pfile->buf_start)); - len = (rlen > len) ? len : rlen; - - if (rmem) - skb_copy_bits(pfile->pkt, pfile->buf_len-pfile->pkt_len, - rmem, len); - - pfile->cur_addr += len; - pfile->pkt_len -= len; - - return len; -} - -int rtw_endofpktfile23a(struct pkt_file *pfile) -{ - if (pfile->pkt_len == 0) - return true; - return false; -} - int rtw_os_xmit_resource_alloc23a(struct rtw_adapter *padapter, struct xmit_buf *pxmitbuf, u32 alloc_sz) {