Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Staging: winbond: wbhal_f.h Coding style fixes.

I fixed all checkpatch problems and also converted the
function arguments from hungarian notation and CamelCase.

Signed-off-by: Lars Lindley <lindley@coyote.org>
Acked-by: Dan Carpenter <error27@gmail.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

authored by

Lars Lindley and committed by
Greg Kroah-Hartman
b66e65e2 6112fd6e

+76 -55
+76 -55
drivers/staging/winbond/wbhal_f.h
··· 1 - //===================================================================== 2 - // Device related include 3 - //===================================================================== 1 + /* 2 + * ===================================================================== 3 + * Device related include 4 + * ===================================================================== 5 + */ 4 6 #include "wb35reg_f.h" 5 7 #include "wb35tx_f.h" 6 8 #include "wb35rx_f.h" 7 9 8 10 #include "core.h" 9 11 10 - //==================================================================================== 11 - // Function declaration 12 - //==================================================================================== 13 - void hal_remove_mapping_key( struct hw_data * pHwData, u8 *pmac_addr ); 14 - void hal_remove_default_key( struct hw_data * pHwData, u32 index ); 15 - unsigned char hal_set_mapping_key( struct hw_data * adapter, u8 *pmac_addr, u8 null_key, u8 wep_on, u8 *ptx_tsc, u8 *prx_tsc, u8 key_type, u8 key_len, u8 *pkey_data ); 16 - unsigned char hal_set_default_key( struct hw_data * adapter, u8 index, u8 null_key, u8 wep_on, u8 *ptx_tsc, u8 *prx_tsc, u8 key_type, u8 key_len, u8 *pkey_data ); 17 - void hal_clear_all_default_key( struct hw_data * pHwData ); 18 - void hal_clear_all_group_key( struct hw_data * pHwData ); 19 - void hal_clear_all_mapping_key( struct hw_data * pHwData ); 20 - void hal_clear_all_key( struct hw_data * pHwData ); 21 - void hal_set_power_save_mode( struct hw_data * pHwData, unsigned char power_save, unsigned char wakeup, unsigned char dtim ); 22 - void hal_get_power_save_mode( struct hw_data * pHwData, u8 *pin_pwr_save ); 23 - void hal_set_slot_time( struct hw_data * pHwData, u8 type ); 24 - #define hal_set_atim_window( _A, _ATM ) 25 - void hal_start_bss( struct hw_data * pHwData, u8 mac_op_mode ); 26 - void hal_join_request( struct hw_data * pHwData, u8 bss_type ); // 0:BSS STA 1:IBSS STA// 27 - void hal_stop_sync_bss( struct hw_data * pHwData ); 28 - void hal_resume_sync_bss( struct hw_data * pHwData); 29 - void hal_set_aid( struct hw_data * pHwData, u16 aid ); 30 - void hal_set_bssid( struct hw_data * pHwData, u8 *pbssid ); 31 - void hal_get_bssid( struct hw_data * pHwData, u8 *pbssid ); 32 - void hal_set_listen_interval( struct hw_data * pHwData, u16 listen_interval ); 33 - void hal_set_cap_info( struct hw_data * pHwData, u16 capability_info ); 34 - void hal_set_ssid( struct hw_data * pHwData, u8 *pssid, u8 ssid_len ); 35 - void hal_start_tx0( struct hw_data * pHwData ); 36 - #define hal_get_cwmin( _A ) ( (_A)->cwmin ) 37 - void hal_set_cwmax( struct hw_data * pHwData, u16 cwin_max ); 38 - #define hal_get_cwmax( _A ) ( (_A)->cwmax ) 39 - void hal_set_rsn_wpa( struct hw_data * pHwData, u32 * RSN_IE_Bitmap , u32 * RSN_OUI_type , unsigned char bDesiredAuthMode); 40 - void hal_set_connect_info( struct hw_data * pHwData, unsigned char boConnect ); 41 - u8 hal_get_est_sq3( struct hw_data * pHwData, u8 Count ); 42 - void hal_descriptor_indicate( struct hw_data * pHwData, struct wb35_descriptor *pDes ); 43 - u8 hal_get_antenna_number( struct hw_data * pHwData ); 44 - u32 hal_get_bss_pk_cnt( struct hw_data * pHwData ); 45 - #define hal_get_region_from_EEPROM( _A ) ( (_A)->reg.EEPROMRegion ) 46 - #define hal_get_tx_buffer( _A, _B ) Wb35Tx_get_tx_buffer( _A, _B ) 47 - #define hal_software_set( _A ) (_A->SoftwareSet) 48 - #define hal_driver_init_OK( _A ) (_A->IsInitOK) 49 - #define hal_rssi_boundary_high( _A ) (_A->RSSI_high) 50 - #define hal_rssi_boundary_low( _A ) (_A->RSSI_low) 51 - #define hal_scan_interval( _A ) (_A->Scan_Interval) 12 + /* ===================================================================== 13 + * Function declaration 14 + * ===================================================================== 15 + */ 16 + void hal_remove_mapping_key(struct hw_data *hw_data, u8 *mac_addr); 17 + void hal_remove_default_key(struct hw_data *hw_data, u32 index); 18 + unsigned char hal_set_mapping_key(struct hw_data *adapter, u8 *mac_addr, 19 + u8 null_key, u8 wep_on, u8 *tx_tsc, 20 + u8 *rx_tsc, u8 key_type, u8 key_len, 21 + u8 *key_data); 22 + unsigned char hal_set_default_key(struct hw_data *adapter, u8 index, 23 + u8 null_key, u8 wep_on, u8 *tx_tsc, 24 + u8 *rx_tsc, u8 key_type, u8 key_len, 25 + u8 *key_data); 26 + void hal_clear_all_default_key(struct hw_data *hw_data); 27 + void hal_clear_all_group_key(struct hw_data *hw_data); 28 + void hal_clear_all_mapping_key(struct hw_data *hw_data); 29 + void hal_clear_all_key(struct hw_data *hw_data); 30 + void hal_set_power_save_mode(struct hw_data *hw_data, unsigned char power_save, 31 + unsigned char wakeup, unsigned char dtim); 32 + void hal_get_power_save_mode(struct hw_data *hw_data, u8 *in_pwr_save); 33 + void hal_set_slot_time(struct hw_data *hw_data, u8 type); 52 34 53 - #define PHY_DEBUG( msg, args... ) 35 + #define hal_set_atim_window(_A, _ATM) 54 36 55 - #define hal_get_time_count( _P ) (_P->time_count/10) // return 100ms count 56 - #define hal_detect_error( _P ) (_P->WbUsb.DetectCount) 37 + void hal_start_bss(struct hw_data *hw_data, u8 mac_op_mode); 57 38 58 - //------------------------------------------------------------------------- 59 - // The follow function is unused for IS89C35 60 - //------------------------------------------------------------------------- 39 + /* 0:BSS STA 1:IBSS STA */ 40 + void hal_join_request(struct hw_data *hw_data, u8 bss_type); 41 + 42 + void hal_stop_sync_bss(struct hw_data *hw_data); 43 + void hal_resume_sync_bss(struct hw_data *hw_data); 44 + void hal_set_aid(struct hw_data *hw_data, u16 aid); 45 + void hal_set_bssid(struct hw_data *hw_data, u8 *bssid); 46 + void hal_get_bssid(struct hw_data *hw_data, u8 *bssid); 47 + void hal_set_listen_interval(struct hw_data *hw_data, u16 listen_interval); 48 + void hal_set_cap_info(struct hw_data *hw_data, u16 capability_info); 49 + void hal_set_ssid(struct hw_data *hw_data, u8 *ssid, u8 ssid_len); 50 + void hal_start_tx0(struct hw_data *hw_data); 51 + 52 + #define hal_get_cwmin(_A) ((_A)->cwmin) 53 + 54 + void hal_set_cwmax(struct hw_data *hw_data, u16 cwin_max); 55 + 56 + #define hal_get_cwmax(_A) ((_A)->cwmax) 57 + 58 + void hal_set_rsn_wpa(struct hw_data *hw_data, u32 *rsn_ie_bitmap, 59 + u32 *rsn_oui_type , unsigned char desired_auth_mode); 60 + void hal_set_connect_info(struct hw_data *hw_data, unsigned char bo_connect); 61 + u8 hal_get_est_sq3(struct hw_data *hw_data, u8 count); 62 + void hal_descriptor_indicate(struct hw_data *hw_data, 63 + struct wb35_descriptor *des); 64 + u8 hal_get_antenna_number(struct hw_data *hw_data); 65 + u32 hal_get_bss_pk_cnt(struct hw_data *hw_data); 66 + 67 + #define hal_get_region_from_EEPROM(_A) ((_A)->reg.EEPROMRegion) 68 + #define hal_get_tx_buffer(_A, _B) Wb35Tx_get_tx_buffer(_A, _B) 69 + #define hal_software_set(_A) (_A->SoftwareSet) 70 + #define hal_driver_init_OK(_A) (_A->IsInitOK) 71 + #define hal_rssi_boundary_high(_A) (_A->RSSI_high) 72 + #define hal_rssi_boundary_low(_A) (_A->RSSI_low) 73 + #define hal_scan_interval(_A) (_A->Scan_Interval) 74 + 75 + #define PHY_DEBUG(msg, args...) 76 + 77 + /* return 100ms count */ 78 + #define hal_get_time_count(_P) (_P->time_count / 10) 79 + #define hal_detect_error(_P) (_P->WbUsb.DetectCount) 80 + 81 + /* The follow function is unused for IS89C35 */ 61 82 #define hal_disable_interrupt(_A) 62 83 #define hal_enable_interrupt(_A) 63 - #define hal_get_interrupt_type( _A) 84 + #define hal_get_interrupt_type(_A) 64 85 #define hal_get_clear_interrupt(_A) 65 - #define hal_ibss_disconnect(_A) hal_stop_sync_bss(_A) 86 + #define hal_ibss_disconnect(_A) (hal_stop_sync_bss(_A)) 66 87 #define hal_join_request_stop(_A) 67 - #define hw_get_cxx_reg( _A, _B, _C ) 68 - #define hw_set_cxx_reg( _A, _B, _C ) 88 + #define hw_get_cxx_reg(_A, _B, _C) 89 + #define hw_set_cxx_reg(_A, _B, _C) 69 90 70 91