staging: rtl8188eu:Remove function rtw_set_tx_chksum_offload()
PATCH 1/15 staging: rtl8188eu:Remove function rtw_set_tx_chksum_offload()
rtw_set_tx_chksum_offload() has empty defination.
--- drivers/staging/rtl8188eu/core/rtw_xmit.c | 2 -- drivers/staging/rtl8188eu/include/xmit_osdep.h | 2 -- drivers/staging/rtl8188eu/os_dep/xmit_linux.c | 4 ---- 3 files changed, 8 deletions(-)
drivers/staging/rtl8188eu/core/rtw_xmit.c +0 -2
@@ -621,8 +621,6 @@ static s32 update_attrib(struct adapter *padapter, struct sk_buff *pkt, struct pRT_TRACE (_module_rtl871x_xmit_c_, _drv_info_, ("update_attrib: bswenc = false\n" )); } -rtw_set_tx_chksum_offload (pkt, pattrib); -update_attrib_phy_info (pattrib, psta); exit:
drivers/staging/rtl8188eu/include/xmit_osdep.h +0 -2
@@ -49,8 +49,6 @@ int rtw_os_xmit_resource_alloc(struct adapter *padapter,void rtw_os_xmit_resource_free (struct adapter *padapter,struct xmit_buf *pxmitbuf,u32 free_sz); -void rtw_set_tx_chksum_offload (struct sk_buff *pkt,struct pkt_attrib *pattrib); -uint rtw_remainder_len (struct pkt_file *pfile);void _rtw_open_pktfile (struct sk_buff *pkt,struct pkt_file *pfile);uint _rtw_pktfile_read (struct pkt_file *pfile,u8 *rmem,uint rlen);
drivers/staging/rtl8188eu/os_dep/xmit_linux.c +0 -4
@@ -77,10 +77,6 @@ int rtw_endofpktfile(struct pkt_file *pfile)return false; } -void rtw_set_tx_chksum_offload (struct sk_buff *pkt,struct pkt_attrib *pattrib) -{ -} -int rtw_os_xmit_resource_alloc (struct adapter *padapter,struct xmit_buf *pxmitbuf,u32 alloc_sz) {int i;
Signature · 1 line
1.7.10.4
PATCH 2/15 staging:rtl8188eu:Remove code specific to kernel version < 2.6.35
--- drivers/staging/rtl8188eu/os_dep/xmit_linux.c | 5 ----- 1 file changed, 5 deletions(-)
drivers/staging/rtl8188eu/os_dep/xmit_linux.c +0 -5
@@ -113,7 +113,6 @@ void rtw_os_xmit_resource_free(struct adapter *padapter,void rtw_os_pkt_complete (struct adapter *padapter,struct sk_buff *pkt) { -#if (LINUX_VERSION_CODE >=KERNEL_VERSION (2 ,6 ,35 ))u16 queue;struct xmit_priv *pxmitpriv = &padapter->xmitpriv;
@@ -126,10 +125,6 @@ void rtw_os_pkt_complete(struct adapter *padapter, struct sk_buff *pkt)if (__netif_subqueue_stopped (padapter->pnetdev, queue))netif_wake_subqueue (padapter->pnetdev, queue); } -#else -if (netif_queue_stopped (padapter->pnetdev)) -netif_wake_queue (padapter->pnetdev); -#endif dev_kfree_skb_any (pkt); }
Signature · 1 line
1.7.10.4
PATCH 3/15 staging: rtl8188eu:Remove unused macro _init_queue()
In reply to navin patidar--- drivers/staging/rtl8712/osdep_service.h | 6 ------ 1 file changed, 6 deletions(-)
drivers/staging/rtl8712/osdep_service.h +0 -6
@@ -52,12 +52,6 @@ struct __queue {#define thread_exit () complete_and_exit(NULL, 0)#define _workitem struct work_struct -#define _init_queue (pqueue) \ - do { \ - _init_listhead(&((pqueue)->queue)); \ - spin_lock_init(&((pqueue)->lock)); \ - } while (0) -static inline struct list_head *get_next (struct list_head *list) {return list->next;
Signature · 1 line
1.7.10.4
Greg KH
maintainerRe: [PATCH 03/15] staging: rtl8188eu:Remove unused macro _init_queue()
Quoted 4 lines · navin patidar
Signed-off-by navin patidar <[email protected]>--- drivers/staging/rtl8712/osdep_service.h | 6 ------ 1 file changed, 6 deletions(-)
This is the rtl8712 driver, not the rtl8188eu driver.
And this patch causes a build error.
Please ALWAYS test your patches before sending them out :(
thanks,
greg k-h
Re: [PATCH 03/15] staging: rtl8188eu:Remove unused macro _init_queue()
Quoted 11 lines · Greg KH
Quoted 4 lines · navin patidar
Signed-off-by navin patidar <[email protected]>--- drivers/staging/rtl8712/osdep_service.h | 6 ------ 1 file changed, 6 deletions(-)This is the rtl8712 driver, not the rtl8188eu driver.
And this patch causes a build error.
Please ALWAYS test your patches before sending them out :(
Sorry
I made a silly mistake, i modified rtl8712 driver file unknowingly and compiled rtl8188eu alone to test.
Next time i'll do a complete kernel build before sending patches out.
regards,
navin patidar
PATCH 4/15 staging: rtl8188eu:Assign RTL8188E to padapter->chip_type directly
In reply to navin patidarAssign RTL8188E to padapter->chip_type directly instead of calling chip_by_usb_id() function to do same.
--- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/staging/rtl8188eu/os_dep/usb_intf.c +1 -4
@@ -546,11 +546,8 @@ static struct adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj, dvobj->if1 = padapter; padapter->bDriverStopped = true; - padapter->hw_init_mutex = &usb_drv->hw_init_mutex; - -/* step 1-1., decide the chip_type via vid/pid */ -chip_by_usb_id (padapter, pdid); + padapter->chip_type =RTL8188E ;if (rtw_handle_dualmac (padapter,1 ) != _SUCCESS) goto free_adapter;
Signature · 1 line
1.7.10.4
PATCH 5/15 staging: rtl8188eu:Remove unused function chip_by_usb_id()
In reply to navin patidar--- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/staging/rtl8188eu/os_dep/usb_intf.c +0 -7
@@ -219,13 +219,6 @@ static void usb_dvobj_deinit(struct usb_interface *usb_intf) } -static void chip_by_usb_id (struct adapter *padapter, -const struct usb_device_id *pdid) -{ - padapter->chip_type =NULL_CHIP_TYPE ; -hal_set_hw_type (padapter); -} -static void usb_intf_start (struct adapter *padapter) {RT_TRACE (_module_hci_intfs_c_, _drv_err_, ("+usb_intf_start\n" ));
Signature · 1 line
1.7.10.4
PATCH 6/15 staging: rtl8188eu:Remove unused function rtl8188eu_set_hw_type()
In reply to navin patidar--- drivers/staging/rtl8188eu/hal/usb_ops_linux.c | 6 ------ drivers/staging/rtl8188eu/include/usb_ops.h | 1 - 2 files changed, 7 deletions(-)
drivers/staging/rtl8188eu/hal/usb_ops_linux.c +0 -6
@@ -682,9 +682,3 @@ void rtl8188eu_set_intf_ops(struct _io_ops *pops) pops->_read_port_cancel = &usb_read_port_cancel; pops->_write_port_cancel = &usb_write_port_cancel; } - -void rtl8188eu_set_hw_type (struct adapter *adapt) -{ - adapt->chip_type =RTL8188E ; -DBG_88E ("CHIP TYPE: RTL8188E\n" ); -}
drivers/staging/rtl8188eu/include/usb_ops.h +0 -1
@@ -63,7 +63,6 @@ enum{#include <usb_ops_linux.h> void rtl8188eu_set_hw_type (struct adapter *padapter); -#define hal_set_hw_type rtl8188eu_set_hw_typevoid rtl8188eu_set_intf_ops (struct _io_ops *pops);#define usb_set_intf_ops rtl8188eu_set_intf_ops
Signature · 1 line
1.7.10.4
Re: [PATCH 06/15] staging: rtl8188eu:Remove unused function rtl8188eu_set_hw_type()
These would have been easier to review if this patch were folded in with the previous two patches. What I look for in these patches is, "Will the compile break if you get it wrong?"
For "[PATCH 04/15] staging: rtl8188eu:Assign RTL8188E to padapter->chip_type directly", you could get it wrong and the compile wouldn't break so I have to go into the code and look at it.
regards,
dan carpenter
PATCH 7/15 staging: rtl8188eu:Drop rtw_handle_dualmac() function calls in rtw_usb_if1_init()
In reply to navin patidarrtw_usb_if1_init() initializes pbuddy_padapter variable which is not being used.
--- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-)
drivers/staging/rtl8188eu/os_dep/usb_intf.c +1 -7
@@ -542,12 +542,9 @@ static struct adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj, padapter->hw_init_mutex = &usb_drv->hw_init_mutex; padapter->chip_type =RTL8188E ; -if (rtw_handle_dualmac (padapter,1 ) != _SUCCESS) - goto free_adapter; - pnetdev =rtw_init_netdev (padapter);if (pnetdev ==NULL ) - goto handle_dualmac; + goto free_adapter;SET_NETDEV_DEV (pnetdev,dvobj_to_dev (dvobj)); padapter =rtw_netdev_priv (pnetdev);
@@ -621,9 +618,6 @@ static struct adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj, free_hal_data:if (status != _SUCCESS)kfree (padapter->HalData); -handle_dualmac: -if (status != _SUCCESS) -rtw_handle_dualmac (padapter,0 ); free_adapter:if (status != _SUCCESS) {if (pnetdev)
Signature · 1 line
1.7.10.4
PATCH 8/15 staging: rtl8188eu:Drop rtw_handle_dualmac() function calls in rtw_usb_if1_deinit()
In reply to navin patidarrtw_usb_if1_init() assign NULL to pbuddy_padapter variable which is not being used.
--- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/rtl8188eu/os_dep/usb_intf.c +0 -1
@@ -654,7 +654,6 @@ static void rtw_usb_if1_deinit(struct adapter *if1)rtw_dev_unload (if1);DBG_88E ("+r871xu_dev_remove, hw_init_completed=%d\n" , if1->hw_init_completed); -rtw_handle_dualmac (if1,0 );rtw_free_drv_sw (if1);if (pnetdev)rtw_free_netdev (pnetdev);
Signature · 1 line
1.7.10.4
PATCH 9/15 staging: rtl8188eu:Remove unused function rtw_handle_dualmac()
In reply to navin patidar--- drivers/staging/rtl8188eu/core/rtw_wlan_util.c | 21 --------------------- 1 file changed, 21 deletions(-)
drivers/staging/rtl8188eu/core/rtw_wlan_util.c +0 -21
@@ -1663,24 +1663,3 @@ void beacon_timing_control(struct adapter *padapter) }static struct adapter *pbuddy_padapter; - -int rtw_handle_dualmac (struct adapter *adapter,bool init) -{ -int status = _SUCCESS; - -if (init) { -if (pbuddy_padapter ==NULL ) { - pbuddy_padapter = adapter; -DBG_88E ("%s(): pbuddy_padapter == NULL, Set pbuddy_padapter\n" , __func__); - }else { - adapter->pbuddy_adapter = pbuddy_padapter; - pbuddy_padapter->pbuddy_adapter = adapter; -/* clear global value */ - pbuddy_padapter =NULL ; -DBG_88E ("%s(): pbuddy_padapter exist, Exchange Information\n" , __func__); - } - }else { - pbuddy_padapter =NULL ; - } -return status; -}
Signature · 1 line
1.7.10.4
PATCH 10/15 staging: rtl8188eu:Remove unused variable struct adapter *pbuddy_padapter
In reply to navin patidar--- drivers/staging/rtl8188eu/core/rtw_wlan_util.c | 2 -- 1 file changed, 2 deletions(-)
drivers/staging/rtl8188eu/core/rtw_wlan_util.c +0 -2
@@ -1661,5 +1661,3 @@ void beacon_timing_control(struct adapter *padapter) {rtw_hal_bcn_related_reg_setting (padapter); } - -static struct adapter *pbuddy_padapter;
Signature · 1 line
1.7.10.4
Re: [PATCH 10/15] staging: rtl8188eu:Remove unused variable struct adapter *pbuddy_padapter
This one as well would have been easier to review if you folded patches 7-10 together.
regards,
dan carpenter
PATCH 11/15 staging: rtl8188eu:Remove inline function rtw_netif_wake_queue()
In reply to navin patidar--- drivers/staging/rtl8188eu/include/osdep_service.h | 5 ----- drivers/staging/rtl8188eu/os_dep/os_intfs.c | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-)
drivers/staging/rtl8188eu/include/osdep_service.h +0 -5
@@ -119,11 +119,6 @@ static inline int rtw_netif_queue_stopped(struct net_device *pnetdev)netif_tx_queue_stopped (netdev_get_tx_queue (pnetdev,3 )); } -static inline void rtw_netif_wake_queue (struct net_device *pnetdev) -{ -netif_tx_wake_all_queues (pnetdev); -} -static inline void rtw_netif_start_queue (struct net_device *pnetdev) {netif_tx_start_all_queues (pnetdev);
drivers/staging/rtl8188eu/os_dep/os_intfs.c +1 -1
@@ -1084,7 +1084,7 @@ int _netdev_open(struct net_device *pnetdev)if (!rtw_netif_queue_stopped (pnetdev))rtw_netif_start_queue (pnetdev);else -rtw_netif_wake_queue (pnetdev); +netif_tx_wake_all_queues (pnetdev);netdev_br_init (pnetdev);
Signature · 1 line
1.7.10.4
PATCH 12/15 staging: rtl8188eu:Remove inline function rtw_netif_start_queue()
In reply to navin patidar--- drivers/staging/rtl8188eu/include/osdep_service.h | 5 ----- drivers/staging/rtl8188eu/os_dep/os_intfs.c | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-)
drivers/staging/rtl8188eu/include/osdep_service.h +0 -5
@@ -119,11 +119,6 @@ static inline int rtw_netif_queue_stopped(struct net_device *pnetdev)netif_tx_queue_stopped (netdev_get_tx_queue (pnetdev,3 )); } -static inline void rtw_netif_start_queue (struct net_device *pnetdev) -{ -netif_tx_start_all_queues (pnetdev); -} -static inline void rtw_netif_stop_queue (struct net_device *pnetdev) {netif_tx_stop_all_queues (pnetdev);
drivers/staging/rtl8188eu/os_dep/os_intfs.c +1 -1
@@ -1082,7 +1082,7 @@ int _netdev_open(struct net_device *pnetdev)rtw_set_pwr_state_check_timer (&padapter->pwrctrlpriv);if (!rtw_netif_queue_stopped (pnetdev)) -rtw_netif_start_queue (pnetdev); +netif_tx_start_all_queues (pnetdev);else netif_tx_wake_all_queues (pnetdev);
Signature · 1 line
1.7.10.4
PATCH 13/15 staging: rtl8188eu:Remove inline function rtw_netif_stop_queue()
In reply to navin patidar--- drivers/staging/rtl8188eu/include/osdep_service.h | 5 ----- drivers/staging/rtl8188eu/os_dep/os_intfs.c | 4 ++-- drivers/staging/rtl8188eu/os_dep/usb_intf.c | 4 ++-- 3 files changed, 4 insertions(+), 9 deletions(-)
drivers/staging/rtl8188eu/include/osdep_service.h +0 -5
@@ -119,11 +119,6 @@ static inline int rtw_netif_queue_stopped(struct net_device *pnetdev)netif_tx_queue_stopped (netdev_get_tx_queue (pnetdev,3 )); } -static inline void rtw_netif_stop_queue (struct net_device *pnetdev) -{ -netif_tx_stop_all_queues (pnetdev); -} -#ifndef BIT #define BIT (x) (1 << (x))#endif
drivers/staging/rtl8188eu/os_dep/os_intfs.c +2 -2
@@ -1096,7 +1096,7 @@ netdev_open_normal_process: netdev_open_error: padapter->bup = false;netif_carrier_off (pnetdev); -rtw_netif_stop_queue (pnetdev); +netif_tx_stop_all_queues (pnetdev);RT_TRACE (_module_os_intfs_c_, _drv_err_, ("-88eu_drv - dev_open, fail!\n" ));DBG_88E ("-88eu_drv - drv_open fail, bup =%d\n" , padapter->bup);return -1 ;
@@ -1219,7 +1219,7 @@ int netdev_close(struct net_device *pnetdev)/* s1. */ if (pnetdev) {if (!rtw_netif_queue_stopped (pnetdev)) -rtw_netif_stop_queue (pnetdev); +netif_tx_stop_all_queues (pnetdev); }/* s2. */
drivers/staging/rtl8188eu/os_dep/usb_intf.c +2 -2
@@ -307,7 +307,7 @@ int rtw_hw_suspend(struct adapter *padapter)/* s1. */ if (pnetdev) {netif_carrier_off (pnetdev); -rtw_netif_stop_queue (pnetdev); +netif_tx_stop_all_queues (pnetdev); }/* s2. */
@@ -416,7 +416,7 @@ static int rtw_suspend(struct usb_interface *pusb_intf, pm_message_t message)/* s1. */ if (pnetdev) {netif_carrier_off (pnetdev); -rtw_netif_stop_queue (pnetdev); +netif_tx_stop_all_queues (pnetdev); }/* s2. */
Signature · 1 line
1.7.10.4
PATCH 14/15 staging: rtl8188eu:Remove unused inline function res_to_status()
In reply to navin patidar--- drivers/staging/rtl8188eu/include/osdep_service.h | 5 ----- 1 file changed, 5 deletions(-)
drivers/staging/rtl8188eu/include/osdep_service.h +0 -5
@@ -239,11 +239,6 @@ static inline void flush_signals_thread(void)flush_signals (current); } -static inline int res_to_status (int res) -{ -return res; -} -#define _RND (sz, r) ((((sz)+((r)-1))/(r))*(r))#define RND4 (x) (((x >> 2) + (((x & 3) == 0) ? 0 : 1)) << 2)
Signature · 1 line
1.7.10.4
PATCH 15/15 staging: rtl8188eu:Remove unused macros defined in osdep_service.h
In reply to navin patidar--- drivers/staging/rtl8188eu/include/osdep_service.h | 39 --------------------- 1 file changed, 39 deletions(-)
drivers/staging/rtl8188eu/include/osdep_service.h +0 -39
@@ -339,15 +339,7 @@ u64 rtw_division64(u64 x, u64 y);#define RTW_GET_BE24 (a) ((((u32) (a)[0]) << 16) | (((u32) (a)[1]) << 8) | \ ((u32) (a)[2])) -#define RTW_PUT_BE24 (a, val) \ - do { \ - (a)[0] = (u8) ((((u32) (val)) >> 16) & 0xff); \ - (a)[1] = (u8) ((((u32) (val)) >> 8) & 0xff); \ - (a)[2] = (u8) (((u32) (val)) & 0xff); \ - } while (0) -#define RTW_GET_BE32 (a) ((((u32) (a)[0]) << 24) | (((u32) (a)[1]) << 16) | \ - (((u32) (a)[2]) << 8) | ((u32) (a)[3]))#define RTW_PUT_BE32 (a, val) \ do { \ (a)[0] = (u8) ((((u32) (val)) >> 24) & 0xff); \
@@ -356,37 +348,6 @@ u64 rtw_division64(u64 x, u64 y); (a)[3 ] = (u8) (((u32) (val)) &0xff ); \ }while (0 ) -#define RTW_GET_LE32 (a) ((((u32) (a)[3]) << 24) | (((u32) (a)[2]) << 16) | \ - (((u32) (a)[1]) << 8) | ((u32) (a)[0])) -#define RTW_PUT_LE32 (a, val) \ - do { \ - (a)[3] = (u8) ((((u32) (val)) >> 24) & 0xff); \ - (a)[2] = (u8) ((((u32) (val)) >> 16) & 0xff); \ - (a)[1] = (u8) ((((u32) (val)) >> 8) & 0xff); \ - (a)[0] = (u8) (((u32) (val)) & 0xff); \ - } while (0) - -#define RTW_GET_BE64 (a) ((((u64) (a)[0]) << 56) | (((u64) (a)[1]) << 48) | \ - (((u64) (a)[2]) << 40) | (((u64) (a)[3]) << 32) | \ - (((u64) (a)[4]) << 24) | (((u64) (a)[5]) << 16) | \ - (((u64) (a)[6]) << 8) | ((u64) (a)[7])) -#define RTW_PUT_BE64 (a, val) \ - do { \ - (a)[0] = (u8) (((u64) (val)) >> 56); \ - (a)[1] = (u8) (((u64) (val)) >> 48); \ - (a)[2] = (u8) (((u64) (val)) >> 40); \ - (a)[3] = (u8) (((u64) (val)) >> 32); \ - (a)[4] = (u8) (((u64) (val)) >> 24); \ - (a)[5] = (u8) (((u64) (val)) >> 16); \ - (a)[6] = (u8) (((u64) (val)) >> 8); \ - (a)[7] = (u8) (((u64) (val)) & 0xff); \ - } while (0) - -#define RTW_GET_LE64 (a) ((((u64) (a)[7]) << 56) | (((u64) (a)[6]) << 48) | \ - (((u64) (a)[5]) << 40) | (((u64) (a)[4]) << 32) | \ - (((u64) (a)[3]) << 24) | (((u64) (a)[2]) << 16) | \ - (((u64) (a)[1]) << 8) | ((u64) (a)[0])) - void rtw_buf_free(u8 **buf, u32 *buf_len);void rtw_buf_update (u8 **buf,u32 *buf_len,u8 *src,u32 src_len);
Signature · 1 line
1.7.10.4