From a59069371911c2dac45acbef54181d9fec3d8ff5 Mon Sep 17 00:00:00 2001 From: pvvx Date: Mon, 10 Apr 2017 15:32:02 +0300 Subject: [PATCH] update --- .cproject | 301 +++----- .settings/language.settings.xml | 2 +- .settings/org.eclipse.cdt.codan.core.prefs | 70 +- .../common/api/wifi/rtw_wowlan/dev_wowlan.c | 2 +- .../common/api/wifi/rtw_wowlan/wifi_wowlan.h | 8 +- .../component/common/api/wifi/wifi_conf.c | 73 +- .../component/common/api/wifi/wifi_conf.h | 4 +- .../api/wifi/wifi_simple_config_parser.h | 4 +- RTL00_SDKV35a/component/common/api/wifi_api.c | 15 +- RTL00_SDKV35a/component/common/api/wifi_api.h | 6 +- .../drivers/sdio/realtek/sdio_host/src/sd.c | 4 +- .../drivers/wlan/realtek/include/drv_types.h | 78 +- .../drivers/wlan/realtek/include/hal_intf.h | 2 +- .../drivers/wlan/realtek/include/rtw_cmd.h | 6 +- .../wlan/realtek/include/rtw_ioctl_set.h | 2 +- .../wlan/realtek/include/rtw_mlme_ext.h | 8 +- .../drivers/wlan/realtek/include/wifi_lib.h | 415 ++++++----- .../drivers/wlan/realtek/include/wlan_lib.h | 697 ++++++++++-------- .../wlan/realtek/src/hal/OUTSRC/phydm.h | 4 +- .../wlan/realtek/src/hal/OUTSRC/phydm_types.h | 6 +- .../hal/OUTSRC/rtl8195a/ROM_RTL8195A_PHYDM.h | 10 +- .../wlan/realtek/src/osdep/freertos/wrapper.h | 4 +- .../common/network/netbios/netbios.c | 13 +- .../component/os/freertos/cmsis_os.c | 12 +- .../Source/portable/MemMang/heap_5.c | 3 +- RTL00_SDKV35a/component/os/os_dep/osdep_api.c | 1 + .../8195a/fwlib/rtl8195a/src/rtl8195a_uart.c | 4 +- .../soc/realtek/8195a/fwlib/src/hal_ssi.c | 4 +- .../misc/rtl_std_lib/include/rtl_bios_data.h | 6 +- .../misc/rtl_std_lib/lib_rtlstd/c_stdio.c | 19 +- .../rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c | 38 +- .../lib_rtlstd/rtl_eabi_cast_ram.c | 15 +- .../rtl_std_lib/lib_rtlstd/rtl_math_ram.c | 5 +- RTL00_SDKV35a/include.txt | 1 + project/inc/lwipopts.h | 1 + project/src/user/atcmd_user.c | 2 + project/src/user/wifi_console.c | 4 +- 37 files changed, 1008 insertions(+), 841 deletions(-) create mode 100644 RTL00_SDKV35a/include.txt diff --git a/.cproject b/.cproject index 5905371..fc9752d 100644 --- a/.cproject +++ b/.cproject @@ -257,7 +257,7 @@ - + @@ -613,8 +613,8 @@ - - + + @@ -640,139 +640,88 @@ - - + diff --git a/.settings/language.settings.xml b/.settings/language.settings.xml index baf2884..02a1622 100644 --- a/.settings/language.settings.xml +++ b/.settings/language.settings.xml @@ -27,7 +27,7 @@ - + diff --git a/.settings/org.eclipse.cdt.codan.core.prefs b/.settings/org.eclipse.cdt.codan.core.prefs index 77386c2..b5248c6 100644 --- a/.settings/org.eclipse.cdt.codan.core.prefs +++ b/.settings/org.eclipse.cdt.codan.core.prefs @@ -1,67 +1,71 @@ eclipse.preferences.version=1 org.eclipse.cdt.codan.checkers.errnoreturn=Warning -org.eclipse.cdt.codan.checkers.errnoreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},implicit\=>false} +org.eclipse.cdt.codan.checkers.errnoreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No return\\")",implicit\=>false} org.eclipse.cdt.codan.checkers.errreturnvalue=Error -org.eclipse.cdt.codan.checkers.errreturnvalue.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.checkers.errreturnvalue.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused return value\\")"} +org.eclipse.cdt.codan.checkers.nocommentinside=-Error +org.eclipse.cdt.codan.checkers.nocommentinside.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Nesting comments\\")"} +org.eclipse.cdt.codan.checkers.nolinecomment=-Error +org.eclipse.cdt.codan.checkers.nolinecomment.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Line comments\\")"} org.eclipse.cdt.codan.checkers.noreturn=Error -org.eclipse.cdt.codan.checkers.noreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},implicit\=>false} +org.eclipse.cdt.codan.checkers.noreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No return value\\")",implicit\=>false} org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation=Error -org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Abstract class cannot be instantiated\\")"} org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem=Error -org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Ambiguous problem\\")"} org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem=Warning -org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Assignment in condition\\")"} org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem=Error -org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Assignment to itself\\")"} org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem=Warning -org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},no_break_comment\=>"no break",last_case_param\=>false,empty_case_param\=>false} +org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No break at end of case\\")",no_break_comment\=>"no break",last_case_param\=>false,empty_case_param\=>false} org.eclipse.cdt.codan.internal.checkers.CatchByReference=Warning -org.eclipse.cdt.codan.internal.checkers.CatchByReference.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},unknown\=>false,exceptions\=>()} +org.eclipse.cdt.codan.internal.checkers.CatchByReference.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Catching by reference is recommended\\")",unknown\=>false,exceptions\=>()} org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem=Error -org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Circular inheritance\\")"} org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization=Warning -org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},skip\=>true} +org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Class members should be properly initialized\\")",skip\=>true} org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Field cannot be resolved\\")"} org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Function cannot be resolved\\")"} org.eclipse.cdt.codan.internal.checkers.InvalidArguments=Error -org.eclipse.cdt.codan.internal.checkers.InvalidArguments.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.InvalidArguments.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid arguments\\")"} org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem=Error -org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid template argument\\")"} org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem=Error -org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Label statement not found\\")"} org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem=Error -org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Member declaration not found\\")"} org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Method cannot be resolved\\")"} org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker=-Info -org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},pattern\=>"^[a-z]",macro\=>true,exceptions\=>()} +org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Name convention for function\\")",pattern\=>"^[a-z]",macro\=>true,exceptions\=>()} org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem=Warning -org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Class has a virtual method and non-virtual destructor\\")"} org.eclipse.cdt.codan.internal.checkers.OverloadProblem=Error -org.eclipse.cdt.codan.internal.checkers.OverloadProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.OverloadProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid overload\\")"} org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem=Error -org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid redeclaration\\")"} org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem=Error -org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid redefinition\\")"} org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem=-Warning -org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Return with parenthesis\\")"} org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem=-Warning -org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Format String Vulnerability\\")"} org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem=Warning -org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true,exceptions\=>()} +org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Statement has no effect\\")",macro\=>true,exceptions\=>()} org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem=Warning -org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},paramNot\=>false} +org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Suggested parenthesis around expression\\")",paramNot\=>false} org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem=Warning -org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},else\=>false,afterelse\=>false} +org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Suspicious semicolon\\")",else\=>false,afterelse\=>false} org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Type cannot be resolved\\")"} org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true} +org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused function declaration\\")",macro\=>true} org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true} +org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused static function\\")",macro\=>true} org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem=Warning -org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},macro\=>true,exceptions\=>("@(\#)","$Id")} +org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused variable declaration in file scope\\")",macro\=>true,exceptions\=>("@(\#)","$Id")} org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem=Error -org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true}} +org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Symbol is not resolved\\")"} diff --git a/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/dev_wowlan.c b/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/dev_wowlan.c index b458346..929c014 100644 --- a/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/dev_wowlan.c +++ b/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/dev_wowlan.c @@ -1,7 +1,7 @@ #include #include #include -#include +#include #include #include diff --git a/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/wifi_wowlan.h b/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/wifi_wowlan.h index 82355fe..cdf2621 100644 --- a/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/wifi_wowlan.h +++ b/RTL00_SDKV35a/component/common/api/wifi/rtw_wowlan/wifi_wowlan.h @@ -212,16 +212,16 @@ struct rtw_wowlan_rx_filter { #if defined(__IAR_SYSTEMS_ICC__) #pragma pack(1) #else -#error "this structure needs to be packed!" +//#error "this structure needs to be packed!" #endif -struct rtw_wowlan_status { +struct rtw_wowlan { u32 wakeup_reasons; //record wake up reason u32 filter_id; //record which pattern is matched -}; +} _status __attribute__ ((__packed__)); #if defined(__IAR_SYSTEMS_ICC__) #pragma pack() #else -#error "this structure needs to be packed!" +//#error "this structure needs to be packed!" #endif /** diff --git a/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.c b/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.c index fd7112e..b4f1f74 100644 --- a/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.c +++ b/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.c @@ -22,6 +22,8 @@ extern int inic_start(void); extern int inic_stop(void); #endif +#include "wifi_api.h" + #include "wlan_lib.h" #if CONFIG_DEBUG_LOG > 0 @@ -872,23 +874,17 @@ int wifi_get_drv_ability(uint32_t *ability) { //----------------------------------------------------------------------------// int wifi_set_country(rtw_country_code_t country_code) { - int ret; - - ret = wext_set_country(WLAN0_NAME, country_code); - - return ret; + return wext_set_country(WLAN0_NAME, country_code); } //----------------------------------------------------------------------------// int wifi_set_channel_plan(uint8_t channel_plan) { const char * ifname = WLAN0_NAME; - int ret = 0; char buf[24]; rtw_memset(buf, 0, sizeof(buf)); snprintf(buf, 24, "set_ch_plan %x", channel_plan); - ret = wext_private_command(ifname, buf, SHOW_PRIVATE_OUT); - return ret; + return wext_private_command(ifname, buf, SHOW_PRIVATE_OUT); } //----------------------------------------------------------------------------// @@ -922,16 +918,12 @@ void wifi_set_mib(void) { //----------------------------------------------------------------------------// int wifi_rf_on(void) { - int ret; - ret = rltk_wlan_rf_on(); - return ret; + return rltk_wlan_rf_on(); } //----------------------------------------------------------------------------// int wifi_rf_off(void) { - int ret; - ret = rltk_wlan_rf_off(); - return ret; + return rltk_wlan_rf_off(); } //----------------------------------------------------------------------------// @@ -1078,6 +1070,59 @@ int wifi_get_last_error(void) { int wpas_wps_init(const char* ifname); #endif +int wifi_start_ap_s(PSOFTAP_CONFIG p) { + const char *ifname = WLAN0_NAME; + int ret = 0; + + if (wifi_mode == RTW_MODE_STA_AP) { + ifname = WLAN1_NAME; + } + + if (is_promisc_enabled()) + promisc_set(0, NULL, 0); + + wifi_reg_event_handler(WIFI_EVENT_STA_ASSOC, wifi_ap_sta_assoc_hdl, NULL); + wifi_reg_event_handler(WIFI_EVENT_STA_DISASSOC, wifi_ap_sta_disassoc_hdl, + NULL); + + ret = wext_set_mode(ifname, IW_MODE_MASTER); + if (ret < 0) + goto exit; + ret = wext_set_channel(ifname, p->channel); //Set channel before starting ap + if (ret < 0) + goto exit; + + switch (p->security_type) { + case RTW_SECURITY_OPEN: + break; + case RTW_SECURITY_WPA2_AES_PSK: + ret = wext_set_auth_param(ifname, IW_AUTH_80211_AUTH_ALG, + IW_AUTH_ALG_OPEN_SYSTEM); + if (ret == 0) + ret = wext_set_key_ext(ifname, IW_ENCODE_ALG_CCMP, NULL, 0, 0, 0, 0, + NULL, 0); + if (ret == 0) + ret = wext_set_passphrase(ifname, (u8*) p->password, strlen(p->password)); + break; + default: + ret = -1; + printf("WIFICONF: security type is not supported\n"); + break; + } + if (ret < 0) + goto exit; + if(p->ssid_hidden) { + ret = set_hidden_ssid(ifname, 1); + if (ret < 0) + goto exit; + } + ret = wext_set_ap_ssid(ifname, (u8*) p->ssid, strlen(p->ssid)); +#if defined(CONFIG_ENABLE_WPS_AP) && CONFIG_ENABLE_WPS_AP + wpas_wps_init(ifname); +#endif +exit: return ret; +} + int wifi_start_ap(char *ssid, rtw_security_t security_type, char *password, int ssid_len, int password_len, int channel) { const char *ifname = WLAN0_NAME; diff --git a/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.h b/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.h index 7d95edd..ac8bbc0 100644 --- a/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.h +++ b/RTL00_SDKV35a/component/common/api/wifi/wifi_conf.h @@ -3,10 +3,10 @@ #define __WIFI_CONF_API_H #include "FreeRTOS.h" -#include "wifi_constants.h" +#include "wifi_constants.h" #include "wifi_structures.h" #include "wifi_util.h" -#include "wifi_ind.h" +#include "wifi_ind.h" #include #ifdef __cplusplus diff --git a/RTL00_SDKV35a/component/common/api/wifi/wifi_simple_config_parser.h b/RTL00_SDKV35a/component/common/api/wifi/wifi_simple_config_parser.h index 330ecdb..85d5d7d 100644 --- a/RTL00_SDKV35a/component/common/api/wifi/wifi_simple_config_parser.h +++ b/RTL00_SDKV35a/component/common/api/wifi/wifi_simple_config_parser.h @@ -68,13 +68,15 @@ struct simple_config_lib_config { }; -#pragma pack(1) + +#pragma pack(push, 1) struct rtk_test_sc { /* API exposed to user */ unsigned char ssid[32]; unsigned char password[65]; unsigned int ip_addr; }; +#pragma pack(pop) /* expose data */ extern s32 is_promisc_callback_unlock; diff --git a/RTL00_SDKV35a/component/common/api/wifi_api.c b/RTL00_SDKV35a/component/common/api/wifi_api.c index 133cf16..d28f280 100644 --- a/RTL00_SDKV35a/component/common/api/wifi_api.c +++ b/RTL00_SDKV35a/component/common/api/wifi_api.c @@ -173,6 +173,8 @@ uint8 chk_ap_netif_num(void) return wlan_ap_netifn; } +extern int wifi_start_ap_s(PSOFTAP_CONFIG p); + rtw_result_t wifi_run_ap(void) { chk_ap_netif_num(); @@ -184,12 +186,7 @@ rtw_result_t wifi_run_ap(void) { if(wext_set_sta_num(wifi_ap_cfg.max_sta) != 0) { // Max number of STAs, should be 1..3, default is 3 error_printf("AP not set max connections %d!\n", wifi_ap_cfg.max_sta); }; - ret = wifi_start_ap(wifi_ap_cfg.ssid, //char *ssid, - wifi_ap_cfg.security_type, //rtw_security_t ecurity_type, - wifi_ap_cfg.password, //char *password, - strlen(wifi_ap_cfg.ssid), //int ssid_len, - strlen(wifi_ap_cfg.password), //int password_len, - wifi_ap_cfg.channel); //int channel + ret = wifi_start_ap_s(&wifi_ap_cfg); wifi_run_mode |= RTW_MODE_AP; if (ret != RTW_SUCCESS) { error_printf("Error(%d): Start AP failed!\n\n", ret);; @@ -438,12 +435,16 @@ int wifi_run(rtw_mode_t mode) { if(wifi_set_country(wifi_cfg.country_code) != RTW_SUCCESS) { error_printf("Error set tx country_code (%d)!", wifi_cfg.country_code); }; -// extern uint8_t rtw_power_percentage_idx; +// extern uint8_t rtw_power_percentage_idx; // rtw_tx_pwr_percentage_t +#if 1 // rltk_set_tx_power_percentage() return all = 0 ! + rltk_set_tx_power_percentage(wifi_cfg.tx_pwr); +#else if(rtw_power_percentage_idx != wifi_cfg.tx_pwr) { if(rltk_set_tx_power_percentage(wifi_cfg.tx_pwr) != RTW_SUCCESS) { error_printf("Error set tx power (%d)!", wifi_cfg.tx_pwr); }; } +#endif debug_printf("mode == wifi_mode? (%d == %d?)\n", mode, wifi_mode); // if(mode == wifi_mode) { diff --git a/RTL00_SDKV35a/component/common/api/wifi_api.h b/RTL00_SDKV35a/component/common/api/wifi_api.h index a3c7e9e..5a89c8c 100644 --- a/RTL00_SDKV35a/component/common/api/wifi_api.h +++ b/RTL00_SDKV35a/component/common/api/wifi_api.h @@ -64,12 +64,12 @@ typedef struct _wifi_config { typedef struct _softap_config { unsigned char ssid[NDIS_802_11_LENGTH_SSID]; unsigned char password[IW_PASSPHRASE_MAX_SIZE]; - rtw_security_t security_type; - uint16 beacon_interval; // Note: support 100 ~ 60000 ms, default 100 + rtw_security_t security_type; // Only: RTW_SECURITY_OPEN, RTW_SECURITY_WPA2_AES_PSK + unsigned short beacon_interval; // default 100 unsigned char channel; // 1..14 unsigned char ssid_hidden; // Note: default 0 unsigned char max_sta; // 1..3 -} SOFTAP_CONFIG, *PSOFTAP_CONFIG; +} SOFTAP_CONFIG, * PSOFTAP_CONFIG; //---- Interface 1 - wlan1 - ST - struct - typedef struct _station_config { unsigned char ssid[NDIS_802_11_LENGTH_SSID]; diff --git a/RTL00_SDKV35a/component/common/drivers/sdio/realtek/sdio_host/src/sd.c b/RTL00_SDKV35a/component/common/drivers/sdio/realtek/sdio_host/src/sd.c index dd81f93..722cef1 100644 --- a/RTL00_SDKV35a/component/common/drivers/sdio/realtek/sdio_host/src/sd.c +++ b/RTL00_SDKV35a/component/common/drivers/sdio/realtek/sdio_host/src/sd.c @@ -108,7 +108,7 @@ SD_RESULT SD_GetCapacity(uint32_t *sector_count) { //----- SD_ReadBlocks SD_RESULT SD_ReadBlocks(u32 sector, u8 *data, u32 count) { - int rd_count; + int rd_count = 0; unsigned char * buf; if ((u32) data & 3) { @@ -144,7 +144,7 @@ SD_RESULT SD_ReadBlocks(u32 sector, u8 *data, u32 count) { //----- SD_WriteBlocks SD_RESULT SD_WriteBlocks(u32 sector, const u8 *data, u32 count) { - int wr_count; + int wr_count = 0; unsigned char * buf; if ((u32) data & 3) { diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/drv_types.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/drv_types.h index 49bedcc..f2dc7c1 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/drv_types.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/drv_types.h @@ -612,20 +612,20 @@ struct _ADAPTER{ u16 interface_type;//USB,SDIO,SPI,PCI u32 work_mode; //STA, AP, STA+AP, PROMISC, P2P - struct dvobj_priv *dvobj; - struct mlme_priv mlmepriv; - struct mlme_ext_priv mlmeextpriv; - struct cmd_priv cmdpriv; + struct dvobj_priv *dvobj; //+8 + struct mlme_priv mlmepriv; //+12 [1244] + struct mlme_ext_priv mlmeextpriv; //+1256 [912] + struct cmd_priv cmdpriv; //+2168 struct evt_priv evtpriv; //struct io_queue *pio_queue; struct io_priv iopriv; - struct xmit_priv xmitpriv; - struct recv_priv recvpriv; - struct sta_priv stapriv; + struct xmit_priv xmitpriv; //+2248 + struct recv_priv recvpriv; //+2752 + struct sta_priv stapriv; //+3024 [164] struct security_priv securitypriv; - struct registry_priv registrypriv; - struct pwrctrl_priv pwrctrlpriv; - struct eeprom_priv eeprompriv; + struct registry_priv registrypriv; // registrypriv.power_percentage_idx +4929 + struct pwrctrl_priv pwrctrlpriv; // pwrctrlpriv.bInternalAutoSuspend //+5061 + struct eeprom_priv eeprompriv; //+5128? //TODO // struct led_priv ledpriv; @@ -666,20 +666,20 @@ struct _ADAPTER{ struct wifi_display_info wfd_info; #endif //CONFIG_WFD - PVOID HalData; - u32 hal_data_sz; - struct hal_ops HalFunc; + PVOID HalData; //+5656 + u32 hal_data_sz; //+5660 + struct hal_ops HalFunc; //+5664 - s32 bDriverStopped; - s32 bSurpriseRemoved; - s32 bCardDisableWOHSM; - u8 RxStop; //Used to stop rx thread as early as possible + s32 bDriverStopped; //+5880 + s32 bSurpriseRemoved; //+5884 + s32 bCardDisableWOHSM; //+5888 + u8 RxStop; //Used to stop rx thread as early as possible //+5892 u32 IsrContent; u32 ImrContent; u8 EepromAddressSize; - u8 hw_init_completed; + u8 hw_init_completed; //+5905 u8 bDriverIsGoingToUnload; u8 init_adpt_in_progress; u8 bMpDriver; @@ -692,9 +692,9 @@ struct _ADAPTER{ _thread_hdl_ evtThread; #endif #if defined(CONFIG_ISR_THREAD_MODE_POLLING) || defined(CONFIG_ISR_THREAD_MODE_INTERRUPT) - struct task_struct isrThread; + struct task_struct isrThread; //+5888? #endif - struct task_struct cmdThread; + struct task_struct cmdThread; //+5920 #ifdef CONFIG_XMIT_THREAD_MODE struct task_struct xmitThread; #endif @@ -702,13 +702,13 @@ struct _ADAPTER{ struct task_struct recvThread; #endif #ifdef CONFIG_RECV_TASKLET_THREAD - struct task_struct recvtasklet_thread; + struct task_struct recvtasklet_thread; //+5952 #endif #ifdef CONFIG_XMIT_TASKLET_THREAD #ifdef PLATFORM_LINUX struct tasklet_struct xmit_tasklet; #else - struct task_struct xmittasklet_thread; + struct task_struct xmittasklet_thread; //+5984 #endif #endif #ifdef CONFIG_SDIO_XMIT_THREAD @@ -721,8 +721,8 @@ struct _ADAPTER{ void (*dvobj_deinit)(struct dvobj_priv *dvobj); #endif - void (*intf_start)(_adapter * adapter); - void (*intf_stop)(_adapter * adapter); + void (*intf_start)(_adapter * adapter); //+6008 + void (*intf_stop)(_adapter * adapter); //+6012 #ifdef PLATFORM_WINDOWS _nic_hdl hndis_adapter;//hNdisAdapter(NDISMiniportAdapterHandle); @@ -741,9 +741,9 @@ struct _ADAPTER{ #endif //#ifdef PLATFORM_ECOS #if defined(PLATFORM_FREERTOS) || defined (PLATFORM_CMSIS_RTOS) - _nic_hdl pnetdev; - int bup; - struct net_device_stats stats; + _nic_hdl pnetdev; //+6016 + int bup; //+6020 + struct net_device_stats stats; //+6024 #endif //#ifdef PLATFORM_FREERTOS #ifdef PLATFORM_LINUX @@ -773,7 +773,7 @@ struct _ADAPTER{ int bup; _lock glock; #endif //PLATFORM_FREEBSD - u8 net_closed; + u8 net_closed; //+6052 u8 bFWReady; //u8 bBTFWReady; @@ -785,20 +785,20 @@ struct _ADAPTER{ u8 bDisableAutosuspend; #endif - _adapter *pbuddy_adapter; + _adapter *pbuddy_adapter; //+6056 - _mutex *hw_init_mutex; + _mutex *hw_init_mutex; //+6060 #if defined(CONFIG_CONCURRENT_MODE) - u8 isprimary; //is primary adapter or not - u8 adapter_type; - u8 iface_type; //interface port type + u8 isprimary; //is primary adapter or not //+6064 + u8 adapter_type; //+6065 + u8 iface_type; //interface port type //+6056 //for global synchronization - _mutex *ph2c_fwcmd_mutex; - _mutex *psetch_mutex; - _mutex *psetbw_mutex; + _mutex *ph2c_fwcmd_mutex; //+6068 + _mutex *psetch_mutex; //+6072 + _mutex *psetbw_mutex; //+6076 - struct co_data_priv *pcodatapriv;//data buffer shared among interfaces + struct co_data_priv *pcodatapriv;//data buffer shared among interfaces //+6080 #endif #ifdef CONFIG_BR_EXT @@ -827,7 +827,7 @@ struct _ADAPTER{ PLOOPBACKDATA ploopback; #endif - u8 fix_rate; + u8 fix_rate; //+6084 #ifdef CONFIG_CAC_TEST unsigned char in_cta_test; #endif @@ -837,7 +837,7 @@ struct _ADAPTER{ u8 debug_level; #endif -}; +}; // [6088] (!) #define adapter_to_dvobj(adapter) (adapter->dvobj) #define adapter_to_pwrctl(adapter) (&adapter->pwrctrlpriv) diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/hal_intf.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/hal_intf.h index 8457298..f9ae749 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/hal_intf.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/hal_intf.h @@ -234,7 +234,7 @@ struct hal_ops { void (*disable_interrupt)(_adapter *padapter); s32 (*interrupt_handler)(_adapter *padapter); - void (*clear_interrupt)(_adapter *padapter); +// void (*clear_interrupt)(_adapter *padapter); // None SDK3.5a #ifdef CONFIG_WOWLAN void (*disable_interrupt_but_cpwm2)(_adapter *padapter); diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_cmd.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_cmd.h index 79b6ce1..45baff9 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_cmd.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_cmd.h @@ -925,11 +925,11 @@ Result: #define H2C_RSP_OFFSET 512 -#define H2C_SUCCESS 0x00 +#define H2C_SUCCESS 0x00 #define H2C_SUCCESS_RSP 0x01 #define H2C_DUPLICATED 0x02 -#define H2C_DROPPED 0x03 -#define H2C_PARAMETERS_ERROR 0x04 +#define H2C_DROPPED 0x03 +#define H2C_PARAMETERS_ERROR 0x04 #define H2C_REJECTED 0x05 #define H2C_CMD_OVERFLOW 0x06 #define H2C_RESERVED 0x07 diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_ioctl_set.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_ioctl_set.h index 8e247e3..1d21ff7 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_ioctl_set.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_ioctl_set.h @@ -68,7 +68,7 @@ u8 rtw_validate_ssid(NDIS_802_11_SSID *ssid); u16 rtw_get_cur_max_rate(_adapter *adapter); //int rtw_set_scan_mode(_adapter *adapter, RT_SCAN_TYPE scan_mode); int rtw_set_channel_plan(_adapter *adapter, u8 channel_plan); -int rtw_set_country(_adapter *adapter, const char *country_code); +//int rtw_set_country(_adapter *adapter, const char *country_code); //int rtw_set_band(_adapter *adapter, enum _BAND band); #endif diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_mlme_ext.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_mlme_ext.h index b504f25..41733c6 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_mlme_ext.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/rtw_mlme_ext.h @@ -481,13 +481,13 @@ typedef struct _RT_CHANNEL_INFO extern int rtw_is_channel_set_contains_channel(RT_CHANNEL_INFO *channel_set, const u32 channel_num, int *pchannel_idx); #ifdef CONFIG_CUSTOM_IE -#ifndef _CUS_IE_ -#define _CUS_IE_ -typedef struct _cus_ie +#ifndef __CUS_IE_ +#define __CUS_IE_ +typedef struct __cus_ie { u8 *ie; u8 type; -}rtw_custom_ie_t, *p_rtw_custom_ie_t; +} rtw_custom_ie_t, *p_rtw_custom_ie_t; #endif /* _CUS_IE_ */ #endif diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wifi_lib.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wifi_lib.h index 1fcf508..c2d2856 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wifi_lib.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wifi_lib.h @@ -7,7 +7,13 @@ #include "osdep_service.h" #include "freertos/wrapper.h" +//#include "wlan_bssdef.h" +//#include "wifi_simple_config_parser.h" +//#include "rtw_rf.h" #include "rtl_bios_data.h" +#include "drv_types.h" +#include "wlan/realtek/src/hal/hal_data.h" +//#include "phydm.h" #define _atr_aligned2_ __attribute__((aligned(2))) #define _atr_aligned4_ __attribute__((aligned(4))) @@ -54,16 +60,16 @@ typedef uint8_t BOOLEAN; typedef uint8_t u1Byte; typedef uint16_t u2Byte; -typedef uint32_t u4Byte; +//typedef uint32_t u4Byte; typedef uint64_t u8Byte; typedef uint64_t __attribute__((aligned(4))) _u8Byte; -typedef sint8_t s1Byte; +//typedef sint8_t s1Byte; typedef sint16_t s2Byte; -typedef sint32_t s4Byte; -typedef sint8_t *ps1Byte; +//typedef sint32_t s4Byte; +//typedef sint8_t *ps1Byte; typedef uint8_t *pu1Byte; typedef uint16_t *pu2Byte; -typedef uint32_t *pu4Byte; +//typedef uint32_t *pu4Byte; typedef uint32_t sizetype; typedef struct _ADAPTER _adapter; @@ -75,6 +81,7 @@ typedef void *_mutex; typedef int (*init_done_ptr)(void); +/* rtw_efuse.h enum _EFUSE_DEF_TYPE // : sint32_t { TYPE_EFUSE_MAX_SECTION = 0x0, @@ -90,7 +97,9 @@ enum _IFACE_TYPE //: sint32_t { IFACE_PORT0 = 0x0, IFACE_PORT1 = 0x1, MAX_IFACE_PORT = 0x2, }; +*/ +/* rtl8195a_pmu_task.h enum _FW_ERR0_STATUS_ //: sint32_t { FES0_H2C_CMDID = 0x1, @@ -354,7 +363,7 @@ struct atomic_t { _lock lock; }; */ - +/* osdep_intf.h struct iw_request_info { uint16_t cmd; uint16_t flags; @@ -362,7 +371,9 @@ struct iw_request_info { typedef int (*iw_handler)(struct net_device *, struct iw_request_info *, union iwreq_data *, char *); +*/ +/* wlan_bssdef.h struct _NDIS_802_11_SSID { uint32_t SsidLength; uint8_t Ssid[36]; @@ -455,6 +466,7 @@ struct wlan_network { WLAN_BSSID_EX network; WLAN_BCN_INFO BcnInfo; }; +*/ /* osdep_service.h typedef void *_timerHandle; @@ -467,12 +479,13 @@ struct wlan_network { }; typedef struct timer_list _timer; - */ - +*/ +/* rtw_qos.h struct qos_priv { uint32_t qos_option; }; - + */ +/* wifi.h struct __attribute__((packed)) _atr_aligned2_ rtw_ieee80211_ht_cap { uint16_t cap_info; uint8_t ampdu_params_info; @@ -481,7 +494,9 @@ struct __attribute__((packed)) _atr_aligned2_ rtw_ieee80211_ht_cap { uint32_t tx_BF_cap_info; uint8_t antenna_selection_info; }; +*/ +/* rtw_ht.h struct ht_priv { uint32_t ht_option; uint32_t ampdu_enable; @@ -493,7 +508,8 @@ struct ht_priv { uint8_t stbc_cap; struct rtw_ieee80211_ht_cap ht_cap; }; - +*/ +/* rtw_mlme.h struct _atr_aligned4_ _RT_LINK_DETECT_T { uint32_t NumTxOkInPeriod; uint32_t NumRxOkInPeriod; @@ -506,7 +522,6 @@ struct _atr_aligned4_ _RT_LINK_DETECT_T { BOOLEAN bHigherBusyTxTraffic; }; typedef struct _RT_LINK_DETECT_T RT_LINK_DETECT_T; - enum _RT_SCAN_TYPE //: sint32_t { SCAN_PASSIVE = 0x0, SCAN_ACTIVE = 0x1, SCAN_MIX = 0x2 @@ -569,7 +584,8 @@ struct mlme_priv { uint8_t scanning_via_buddy_intf; struct recv_frame *p_copy_recv_frame; }; - +*/ +/* rtw_mlme_ext.h struct _atr_aligned4_ _RT_CHANNEL_INFO { uint8_t ChannelNum; RT_SCAN_TYPE ScanType; // uint8_t ScanType; // byte/dword? @@ -584,7 +600,8 @@ struct ss_res { int scan_mode; NDIS_802_11_SSID ssid[1]; }; - +*/ +/* wifi.h struct __attribute__((packed)) __attribute__((aligned(1))) ADDBA_request { uint8_t dialog_token; uint16_t BA_para_set; @@ -623,7 +640,8 @@ struct HT_info_element { uint8_t infos[5]; uint8_t MCS_rate[16]; }; - +*/ +/* rtw_mlme_ext.h struct FW_Sta_Info { struct sta_info *psta; uint32_t status; @@ -672,16 +690,17 @@ struct mlme_ext_info { struct HT_info_element HT_info; struct FW_Sta_Info FW_sta_info[5]; }; - +*/ +/* #ifndef _CUS_IE_ #define _CUS_IE_ typedef struct _cus_ie{ __u8 *ie; __u8 type; } cus_ie, *p_cus_ie; -#endif /* _CUS_IE_ */ +#endif */ // typedef struct _cus_ie *p_cus_ie; - +/* rtw_mlme_ext.h struct mlme_ext_priv { //__attribute__((packed))? _adapter *padapter; //+0 padapter+1256 [912] uint8_t mlmeext_init; @@ -725,7 +744,9 @@ struct mlme_ext_priv { //__attribute__((packed))? uint8_t bChDeauthDisabled; uint8_t bConcurrentFlushingSTA; }; +*/ +/* rtw_cmd.h struct cmd_priv { _queue cmd_queue; uint8_t cmdthd_running; @@ -738,6 +759,27 @@ struct evt_priv { uint8_t *evt_allocated_buf; uint32_t evt_done_cnt; }; +*/ +/* drv_types.h +struct dvobj_priv +{ + void *if1; + void *if2; + void *padapters[2]; + uint8_t iface_nums; + uint8_t RtOutPipe[3]; + uint8_t Queue2Pipe[8]; + uint8_t irq_alloc; + uint8_t irq_enabled; + _lock irq_th_lock; +}; +*/ +/* trw_io.h + +struct fifo_more_data { + uint32_t more_data; + uint32_t len; +}; struct _io_ops { int (*init_io_priv)(struct dvobj_priv *); @@ -756,7 +798,8 @@ struct _io_ops { struct io_priv { struct _io_ops io_ops; }; - +*/ +/* rtw_xmit.h struct rtw_tx_ring { struct tx_buf_desc *desc; dma_addr_t dma; @@ -802,7 +845,8 @@ struct _atr_aligned8_ xmit_priv { uint32_t free_xmit_extbuf_cnt; uint16_t nqos_ssn; }; - +*/ +/* trw_recv.h struct rtw_rx_ring { struct recv_buf_stat *desc; dma_addr_t dma; @@ -865,7 +909,8 @@ struct _atr_aligned8_ recv_priv { uint16_t promisc_bk_rxfltmap2; uint8_t promisc_mgntframe_enabled; }; - +*/ +/* sta_info.h struct _atr_aligned4_ sta_priv { uint8_t *pallocated_stainfo_buf; uint32_t allocated_stainfo_size; @@ -889,14 +934,13 @@ struct _atr_aligned4_ sta_priv { uint16_t tim_bitmap; uint16_t max_num_sta; }; - +*/ +/* trw_security.h union Keytype { uint8_t skey[16]; uint32_t lkey[4]; }; - - union pn48 { u8Byte val; struct { @@ -910,7 +954,9 @@ union pn48 { uint8_t TSC7; }_byte_; }; +*/ +/* wlan_bssdef.h struct _NDIS_802_11_WEP { uint32_t Length; uint32_t KeyIndex; @@ -918,7 +964,9 @@ struct _NDIS_802_11_WEP { uint8_t KeyMaterial[16]; }; typedef struct _NDIS_802_11_WEP NDIS_802_11_WEP; +*/ +/* rtw_psk.h struct $D75518714447A990003EBC933C23F70E { uint32_t HighPart; uint32_t LowPart; @@ -979,7 +1027,9 @@ struct _wpa_global_info { typedef struct _wpa_global_info WPA_GLOBAL_INFO; typedef struct _wpa_sta_info WPA_STA_INFO; +*/ +/* rtw_security.h struct _atr_aligned4_ security_priv { uint32_t dot11AuthAlgrthm; uint32_t dot11PrivacyAlgrthm; @@ -1023,7 +1073,8 @@ struct _atr_aligned4_ security_priv { uint8_t wpa_passphrase[65]; uint8_t wps_phase; }; - +*/ +/* derv_types.h struct _atr_aligned4_ registry_priv { uint8_t chip_version; uint8_t hci; @@ -1067,7 +1118,8 @@ struct _atr_aligned4_ registry_priv { uint8_t adaptivity_dc_backoff; int8_t adaptivity_th_l2h_ini; }; - +*/ +/* trw_powerctrl.h typedef void *_sema; typedef _sema _pwrlock; @@ -1138,7 +1190,8 @@ struct _atr_aligned4_ pwrctrl_priv { uint8_t tdma_rfon_period_len_3; uint8_t lps_dtim; }; - +*/ +/* rtw_eeprom.h struct _atr_aligned2_ eeprom_priv { // __attribute__((packed))!? uint8_t bautoload_fail_flag; uint8_t mac_addr[6]; @@ -1148,7 +1201,8 @@ struct _atr_aligned2_ eeprom_priv { // __attribute__((packed))!? uint8_t EEPROMRFGainOffset; uint8_t EEPROMRFGainVal; }; - +*/ +/* rtw_rf.h enum _CHANNEL_WIDTH // : sint32_t { CHANNEL_WIDTH_20 = 0x0, @@ -1159,7 +1213,9 @@ enum _CHANNEL_WIDTH // : sint32_t CHANNEL_WIDTH_MAX = 0x5, }; typedef enum _CHANNEL_WIDTH CHANNEL_WIDTH; +*/ +/* hal_intf.h enum _HAL_DEF_VARIABLE // : sint32_t { HAL_DEF_UNDERCORATEDSMOOTHEDPWDB = 0x0, @@ -1196,11 +1252,11 @@ enum _HAL_ODM_VARIABLE // : sint32_t HAL_ODM_REGULATION = 0x4, }; typedef enum _HAL_ODM_VARIABLE HAL_ODM_VARIABLE; - +*/ +/* freertos_service.h typedef void *_thread_hdl_; - -/* - // osdep_service.h +*/ +/* osdep_service.h struct task_struct { const char *task_name; @@ -1226,19 +1282,7 @@ typedef struct net_device *_nic_hdl; uint32_t rx_overflow; }; */ - -struct dvobj_priv { - void *if1; - void *if2; - void *padapters[2]; - uint8_t iface_nums; - uint8_t RtOutPipe[3]; - uint8_t Queue2Pipe[8]; - uint8_t irq_alloc; - uint8_t irq_enabled; - _lock irq_th_lock; -}; - +/* rtw_recv.h struct phy_info { uint8_t RxPWDBAll; uint8_t SignalQuality; @@ -1314,7 +1358,7 @@ union { uint32_t mem[32]; }; }; -/* + union $AB04817EA6EB89125E28056B7464A4D7 { _list list; struct recv_frame_hdr hdr; @@ -1325,8 +1369,7 @@ union recv_frame { union $AB04817EA6EB89125E28056B7464A4D7 u; }; */ -/* - // skbuff.h +/* skbuff.h struct sk_buff { struct sk_buff *next; @@ -1347,7 +1390,7 @@ union recv_frame { uint32_t qlen; }; */ - +/* rtw_xmit.h struct tx_servq { _list tx_pending; _queue sta_pending; @@ -1366,6 +1409,12 @@ struct sta_xmit_priv { _list apsd; uint16_t txseq_tid[16]; }; +*/ +/* rtw_recv.h +struct recv_buf_stat { + uint32_t rxdw0; + uint32_t rxdw1; +}; struct stainfo_rxcache { uint16_t tid_rxseq[16]; @@ -1377,8 +1426,9 @@ struct sta_recv_priv { _queue defrag_q; struct stainfo_rxcache rxcache; }; - -struct stainfo_stats { +*/ +/* sta_info.h + struct stainfo_stats { u8Byte rx_mgnt_pkts; u8Byte rx_ctrl_pkts; u8Byte rx_data_pkts; @@ -1475,20 +1525,15 @@ struct sta_info { uint8_t RXEVM[4]; uint8_t RXSNR[4]; }; -/* - // wifi_conf.h +*/ +/* wifi_conf.h struct _atr_aligned4_ _cus_ie { uint8_t *ie; uint8_t type; }; */ - -struct fifo_more_data { - uint32_t more_data; - uint32_t len; -}; - +/* rtw_xmit.h struct hw_xmit { _queue *sta_queue; int accnt; @@ -1504,12 +1549,8 @@ struct tx_buf_desc { uint32_t txdw6; uint32_t txdw7; }; - -struct recv_buf_stat { - uint32_t rxdw0; - uint32_t rxdw1; -}; - +*/ +/* rtw_psk.h struct _wpa_sta_info { int state; int gstate; @@ -1536,7 +1577,8 @@ struct _wpa_sta_info { int clientGkeyUpdate; LARGE_INTEGER clientMICReportReplayCounter; }; - +*/ +/* rtw_xmit.h struct pkt_attrib { uint8_t type; uint8_t subtype; @@ -1627,6 +1669,7 @@ struct submit_ctx { uint32_t timeout_ms; int status; }; +*/ /* // wrapper.h struct net_device @@ -1712,12 +1755,15 @@ struct submit_ctx { union iwreq_data u; }; */ +/* drv_types.h struct co_data_priv { uint8_t co_ch; uint8_t co_bw; uint8_t co_ch_offset; uint8_t rsvd; }; +*/ +/* hal_intf.h enum _HARDWARE_TYPE // : sint32_t { @@ -1759,7 +1805,8 @@ enum _HARDWARE_TYPE // : sint32_t HARDWARE_TYPE_RTL8188FS = 0x23, HARDWARE_TYPE_MAX = 0x24, }; - +*/ +/* hal_phy.h struct RF_Shadow_Compare_Map { uint32_t Value; uint8_t Compare; @@ -1768,7 +1815,8 @@ struct RF_Shadow_Compare_Map { uint8_t Driver_Write; }; typedef struct RF_Shadow_Compare_Map RF_SHADOW_T; - +*/ +/* rtw_powerctrl.h enum _PS_BBRegBackup_ // : sint32_t { PSBBREG_RF0 = 0x0, @@ -1777,9 +1825,8 @@ enum _PS_BBRegBackup_ // : sint32_t PSBBREG_AFE0 = 0x3, PSBBREG_TOTALCNT = 0x4, }; - -/* - // hal_irqn.h +*/ +/* hal_irqn.h enum _IRQn_Type_ // : sint32_t { NonMaskableInt_IRQn = 0xFFFFFFF2, @@ -1852,9 +1899,8 @@ enum _PS_BBRegBackup_ // : sint32_t uint32_t Priority; }; typedef struct _IRQ_HANDLE_ IRQ_HANDLE; - */ -/* - // hal_soc_ps_monitor.h +*/ +/* hal_soc_ps_monitor.h struct _power_state_ { uint8_t FuncIdx; @@ -1876,9 +1922,9 @@ enum _PS_BBRegBackup_ // : sint32_t BOOL SleepFlag; }; typedef struct _power_mgn_ Power_Mgn; +*/ - /* - // hal_gpio.h + /* hal_gpio.h enum $E1AD70AB12E7AA6E98B8D89D9B965EB5 //: sint32_t { _PORT_A = 0x0, @@ -1913,7 +1959,7 @@ enum _PS_BBRegBackup_ // : sint32_t }; typedef struct _HAL_GPIO_ADAPTER_ *PHAL_GPIO_ADAPTER; */ - +/* hal_intf.h struct hal_ops { uint32_t (*hal_power_on)(_adapter *); uint32_t (*hal_init)(_adapter *); @@ -1976,66 +2022,8 @@ struct hal_ops { uint8_t); uint8_t (*hal_get_tx_buff_rsvd_page_num)(_adapter *, bool); }; - -struct _atr_aligned4_ _ADAPTER { - uint16_t HardwareType; - uint16_t interface_type; //+2 - uint32_t work_mode; - struct dvobj_priv *dvobj; //+8 - struct mlme_priv mlmepriv; //+12 [1244] - struct mlme_ext_priv mlmeextpriv; //+1256 [912] - struct cmd_priv cmdpriv; //+2168 - struct evt_priv evtpriv; //+ - struct io_priv iopriv; - struct xmit_priv xmitpriv; //+2248 - struct recv_priv recvpriv; //+2752 - struct sta_priv stapriv; //+3024 [164] - struct security_priv securitypriv; - struct registry_priv registrypriv; - struct pwrctrl_priv pwrctrlpriv; // pwrctrlpriv.bInternalAutoSuspend //+5061 - struct eeprom_priv eeprompriv; - PVOID HalData; - uint32_t hal_data_sz; - struct hal_ops HalFunc; - int32_t bDriverStopped; //+5880 - int32_t bSurpriseRemoved; //+5884 - int32_t bCardDisableWOHSM; //+5888 - uint8_t RxStop; //+5892 - uint32_t IsrContent; - uint32_t ImrContent; - uint8_t EepromAddressSize; - uint8_t hw_init_completed; //+5905 - uint8_t bDriverIsGoingToUnload; - uint8_t init_adpt_in_progress; - uint8_t bMpDriver; - uint8_t bForwardingDisabled; - struct task_struct isrThread; //+5888 - struct task_struct cmdThread; //+5920 - struct task_struct recvtasklet_thread; //+5952 - struct task_struct xmittasklet_thread; //+5984 - void (*intf_start)(_adapter *); //+6008 - void (*intf_stop)(_adapter *); //+6012 - _nic_hdl pnetdev; //+6016 - int bup; //+6020 - struct net_device_stats stats; - uint8_t net_closed; //+6052 - uint8_t bFWReady; - uint8_t bLinkInfoDump; - uint8_t bRxRSSIDisplay; - _adapter *pbuddy_adapter; //+6056 - _mutex *hw_init_mutex; //+6060 - uint8_t isprimary; //+6064 - uint8_t adapter_type; //+6065 - uint8_t iface_type; //+6056 - _mutex *ph2c_fwcmd_mutex; //+6068 - _mutex *psetch_mutex; //+6072 - _mutex *psetbw_mutex; //+6076 - struct co_data_priv *pcodatapriv; //+6080 - uint8_t fix_rate; //+6084 -}; // [6088] (!) -typedef struct _ADAPTER *PADAPTER; -// if sizeof(struct _ADAPTER) != 6088 #error "Check aligned struct!" ! - +*/ +/* HalVerDef.h enum tag_HAL_IC_Type_Definition // : sint32_t { CHIP_8192S = 0x0, @@ -2104,7 +2092,8 @@ struct _atr_aligned4_ tag_HAL_VERSION { uint8_t ROMVer; }; typedef struct tag_HAL_VERSION HAL_VERSION; - +*/ +/* hal_intf.h enum _HW_VARIABLES //: sint32_t { HW_VAR_MEDIA_STATUS = 0x0, @@ -2189,13 +2178,15 @@ enum _HW_VARIABLES //: sint32_t HW_VAR_ASIX_IOT = 0x4F, HW_VAR_PROMISC = 0x50, }; - +*/ +/* hal_phy.h enum _BAND_TYPE // : sint32_t { BAND_ON_2_4G = 0x0, BAND_ON_5G = 0x1, BAND_ON_BOTH = 0x2, BANDMAX = 0x3, }; typedef enum _BAND_TYPE BAND_TYPE; - +*/ +/* hal_com_phycfg.h struct _BB_REGISTER_DEFINITION { uint32_t rfintfs; uint32_t rfintfo; @@ -2206,7 +2197,8 @@ struct _BB_REGISTER_DEFINITION { uint32_t rfLSSIReadBackPi; }; typedef struct _BB_REGISTER_DEFINITION BB_REGISTER_DEFINITION_T; - +*/ +/* rtw_mlme.h enum dot11AuthAlgrthmNum //: sint32_t { dot11AuthAlgrthm_Open = 0x0, @@ -2216,7 +2208,8 @@ enum dot11AuthAlgrthmNum //: sint32_t dot11AuthAlgrthm_WAPI = 0x4, dot11AuthAlgrthm_MaxNum = 0x5, }; - +*/ +/* rtw_mlme_ext.h enum _RT_CHANNEL_DOMAIN //: sint32_t { RT_CHANNEL_DOMAIN_FCC = 0x0, @@ -2283,7 +2276,8 @@ enum _RT_CHANNEL_DOMAIN //: sint32_t RT_CHANNEL_DOMAIN_MAX = 0x59, RT_CHANNEL_DOMAIN_REALTEK_DEFINE = 0x7F, }; - +*/ +/* freertos_intfs.h struct _driver_priv { int drv_registered; _mutex hw_init_mutex; @@ -2292,7 +2286,9 @@ struct _driver_priv { _mutex setbw_mutex; }; typedef struct _driver_priv drv_priv; +*/ +/* PhyDM_Adaptivity.h struct _ADAPTIVITY_STATISTICS { s1Byte TH_L2H_ini_mode2; s1Byte TH_EDCCA_HL_diff_mode2; @@ -2309,12 +2305,14 @@ struct _ADAPTIVITY_STATISTICS { u1Byte AdajustIGILevel; }; typedef struct _ADAPTIVITY_STATISTICS ADAPTIVITY_STATISTICS; - +*/ +/* phydm_NoiseMonitor.h struct _ODM_NOISE_MONITOR_ { s1Byte noise[1]; s2Byte noise_all; }; typedef struct _ODM_NOISE_MONITOR_ ODM_NOISE_MONITOR; +*/ /* in rtl_bios_data.h struct _FALSE_ALARM_STATISTICS { u4Byte Cnt_Parity_Fail; @@ -2335,13 +2333,13 @@ struct _FALSE_ALARM_STATISTICS { }; typedef struct _FALSE_ALARM_STATISTICS FALSE_ALARM_STATISTICS; */ - +/* phydm.h enum _BASEBAND_CONFIG_PHY_REG_PG_VALUE_TYPE //: sint32_t { PHY_REG_PG_RELATIVE_VALUE = 0x0, PHY_REG_PG_EXACT_VALUE = 0x1, }; typedef enum _BASEBAND_CONFIG_PHY_REG_PG_VALUE_TYPE PHY_REG_PG_TYPE; - +*/ /* in rtl_bios_data.h struct _atr_aligned4_ _CFO_TRACKING_ { BOOLEAN bATCStatus; @@ -2370,11 +2368,13 @@ struct _atr_aligned8_ _ROM_INFO { }; typedef struct _ROM_INFO ROM_INFO; */ - +/* ROM_RTL8195A_PHYDM.h typedef struct _ROM_INFO *PROM_INFO; - +*/ +/* phydm_types.h typedef struct sta_info *PSTA_INFO_T; - +*/ +/* phydm.h struct _ODM_Phy_Dbg_Info_ { s1Byte RxSNRdB[4]; u4Byte NumQryPhyStatus; @@ -2717,7 +2717,73 @@ struct _atr_aligned8_ ODM_RF_Calibration_Structure { u4Byte DpkThermal[4]; }; typedef struct ODM_RF_Calibration_Structure ODM_RF_CAL_T; +*/ +/* drv_types.h +#include "ieee80211.h" +#include "rtw_cmd.h" +struct _atr_aligned4_ _ADAPTER { + uint16_t HardwareType; + uint16_t interface_type; //+2 + uint32_t work_mode; + struct dvobj_priv *dvobj; //+8 + struct mlme_priv mlmepriv; //+12 [1244] + struct mlme_ext_priv mlmeextpriv; //+1256 [912] + struct cmd_priv cmdpriv; //+2168 + struct evt_priv evtpriv; //+ + struct io_priv iopriv; + struct xmit_priv xmitpriv; //+2248 + struct recv_priv recvpriv; //+2752 + struct sta_priv stapriv; //+3024 [164] + struct security_priv securitypriv; + struct registry_priv registrypriv; + struct pwrctrl_priv pwrctrlpriv; // pwrctrlpriv.bInternalAutoSuspend //+5061 + struct eeprom_priv eeprompriv; + PVOID HalData; + uint32_t hal_data_sz; + struct hal_ops HalFunc; + int32_t bDriverStopped; //+5880 + int32_t bSurpriseRemoved; //+5884 + int32_t bCardDisableWOHSM; //+5888 + uint8_t RxStop; //+5892 + uint32_t IsrContent; + uint32_t ImrContent; + uint8_t EepromAddressSize; + uint8_t hw_init_completed; //+5905 + uint8_t bDriverIsGoingToUnload; + uint8_t init_adpt_in_progress; + uint8_t bMpDriver; + uint8_t bForwardingDisabled; + struct task_struct isrThread; //+5888 + struct task_struct cmdThread; //+5920 + struct task_struct recvtasklet_thread; //+5952 + struct task_struct xmittasklet_thread; //+5984 + void (*intf_start)(_adapter *); //+6008 + void (*intf_stop)(_adapter *); //+6012 + _nic_hdl pnetdev; //+6016 + int bup; //+6020 + struct net_device_stats stats; + uint8_t net_closed; //+6052 + uint8_t bFWReady; + uint8_t bLinkInfoDump; + uint8_t bRxRSSIDisplay; + _adapter *pbuddy_adapter; //+6056 + _mutex *hw_init_mutex; //+6060 + uint8_t isprimary; //+6064 + uint8_t adapter_type; //+6065 + uint8_t iface_type; //+6056 + _mutex *ph2c_fwcmd_mutex; //+6068 + _mutex *psetch_mutex; //+6072 + _mutex *psetbw_mutex; //+6076 + struct co_data_priv *pcodatapriv; //+6080 + uint8_t fix_rate; //+6084 +}; // [6088] (!) +typedef struct _ADAPTER *PADAPTER; +// if sizeof(struct _ADAPTER) != 6088 #error "Check aligned struct!" ! + +*/ + +/* phydm.h struct _atr_aligned8_ DM_Out_Source_Dynamic_Mechanism_Structure { PADAPTER Adapter; BOOLEAN odm_ready; @@ -2887,7 +2953,8 @@ struct _atr_aligned8_ DM_Out_Source_Dynamic_Mechanism_Structure { }; typedef struct DM_Out_Source_Dynamic_Mechanism_Structure DM_ODM_T; typedef struct DM_Out_Source_Dynamic_Mechanism_Structure *PDM_ODM_T; - +*/ +/* halphy enum _PWRTRACK_CONTROL_METHOD //: sint32_t { BBSWING = 0x0, TXAGC = 0x1, MIX_MODE = 0x2, @@ -2939,7 +3006,9 @@ struct _H2CParam_RsvdPage_ { }; typedef struct _H2CParam_RsvdPage_ H2CParam_RsvdPage; typedef struct _H2CParam_RsvdPage_ *PH2CParam_RsvdPage; +*/ +/* wlan_bssdef.h struct _NDIS_802_11_VARIABLE_IEs { uint8_t ElementID; uint8_t Length; @@ -2977,6 +3046,7 @@ enum _NDIS_802_11_WEP_STATUS //: sint32_t Ndis802_11_EncrypteionWAPI = 0x8, }; typedef enum _NDIS_802_11_WEP_STATUS NDIS_802_11_WEP_STATUS; +*/ struct __attribute__((packed)) __attribute__((aligned(1))) rtk_sc { u8 pattern_type; @@ -3023,7 +3093,7 @@ struct pattern_ops { sc_decode_profile_call_back decode_profile; sc_get_tlv_info_call_back get_tlv_info; }; - +/* halpower struct _atr_aligned2_ _WL_PWR_CFG_ { // __attribute__((packed))!? uint16_t offset; uint8_t cut_msk; @@ -3035,17 +3105,21 @@ struct _atr_aligned2_ _WL_PWR_CFG_ { // __attribute__((packed))!? uint8_t value; }; typedef struct _WL_PWR_CFG_ WLAN_PWR_CFG; +*/ +/* rtw_mlme.h struct cmd_hdl { uint32_t parmsize; uint8_t (*h2cfuns)(struct _ADAPTER *, uint8_t *); }; - +*/ +/* rtw_cmd.h struct _cmd_callback { uint32_t cmd_code; void (*callback)(_adapter *, struct cmd_obj *); }; - +*/ +/* phydm.h enum _ODM_Common_Info_Definition //: sint32_t { ODM_CMNINFO_PLATFORM = 0x0, @@ -3151,13 +3225,15 @@ enum _ODM_Support_Ability_Definition // : sint32_t ODM_RF_RX_GAIN_TRACK = 0x2000000, ODM_RF_CALIBRATION = 0x4000000, }; - +*/ +/* hal_phy.h enum _RF_PATH //: sint32_t { RF_PATH_A = 0x0, RF_PATH_B = 0x1, RF_PATH_C = 0x2, RF_PATH_D = 0x3, }; typedef enum _RF_PATH RF_PATH; - +*/ +/* rtw_cmd.h enum _EXTCHNL_OFFSET //: sint32_t { EXTCHNL_OFFSET_NO_EXT = 0x0, @@ -3256,7 +3332,8 @@ enum MGN_RATE //: sint32_t MGN_VHT4SS_MCS9 = 0xC7, MGN_UNKNOWN = 0xC8, }; - +*/ +/* rtw_mlme.h rtw_mlme_ext.h struct _RT_CHANNEL_PLAN_2G { uint8_t Channel[14]; uint8_t Len; @@ -3276,12 +3353,14 @@ struct mlme_handler { uint32_t num; uint32_t (*func)(_adapter *, struct recv_frame *); }; - +*/ +/* rtw_event.h struct fwevent { uint32_t parmsize; void (*event_callback)(_adapter *, uint8_t *); }; - +*/ +/* rtw_recv.h struct recv_buf { _list list; PADAPTER adapter; @@ -3302,7 +3381,8 @@ struct recv_reorder_ctrl { _queue pending_recvframe_queue; _timer reordering_ctrl_timer; }; - +*/ +/* phydm.h enum _ODM_RF_RADIO_PATH // : sint32_t { ODM_RF_PATH_A = 0x0, @@ -3403,7 +3483,8 @@ enum _ODM_FW_Config_Type //: sint32_t CONFIG_FW_BT = 0x7, }; typedef enum _ODM_FW_Config_Type ODM_FW_Config_Type; - +*/ +/* hal_com_phycfg.h enum _RATE_SECTION //: sint32_t { CCK = 0x0, @@ -3418,12 +3499,8 @@ enum _RATE_SECTION //: sint32_t VHT_4SSMCS0_4SSMCS9 = 0x9, }; typedef enum _RATE_SECTION RATE_SECTION; - -struct map_mask_s { - uint16_t mask_start; - uint16_t mask_end; -}; - +*/ +/* hal_pg.h struct _TxPowerInfo24G { uint8_t IndexCCK_Base[1][6]; uint8_t IndexBW40_Base[1][6]; @@ -3432,9 +3509,8 @@ struct _TxPowerInfo24G { }; typedef struct _TxPowerInfo24G TxPowerInfo24G; typedef struct _TxPowerInfo24G *PTxPowerInfo24G; - -/* - +*/ +/* wifi_constants.h enum rtw_bss_type_t // __int32 { RTW_BSS_TYPE_INFRASTRUCTURE = 0x0, @@ -3466,7 +3542,8 @@ enum rtw_802_11_band_t // __int32 RTW_802_11_BAND_2_4GHZ = 0x1, }; - +*/ +/* wifi_structures.h struct rtw_ssid { unsigned int8_t len; diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wlan_lib.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wlan_lib.h index 0c5936b..caef2ee 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wlan_lib.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/include/wlan_lib.h @@ -14,6 +14,7 @@ extern "C" { #include "wireless.h" #include "wifi_lib.h" +#include "freertos/freertos_xmit.h" // rom_rtw_message.o //-------------------------------- @@ -44,7 +45,7 @@ extern void rtw_indicate_sta_assoc(uint64_t padapter, uint64_t buf); extern void rtw_indicate_sta_disassoc(_adapter *padapter, uint8_t *addr); extern void rtw_indicate_wx_assoc_event(uint64_t padapter, uint64_t a2); extern void rtw_indicate_wx_disassoc_event(uint64_t padapter, uint64_t a2); -extern int rtw_set_wpa_ie(_adapter *padapter, char *pie, int ielen); +// extern int rtw_set_wpa_ie(_adapter *padapter, char *pie, int ielen); extern void strtopsk(uint8_t *des, uint8_t *src, int len); extern int rtw_wx_get_passphrase(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra); extern int rtw_wx_set_ap_essid(struct net_device *dev, struct iw_request_info *a, union iwreq_data *wrqu, char *extra); @@ -57,7 +58,7 @@ extern int rtw_set_sta_num(int ap_sta_num); extern int rtw_del_sta(struct net_device *dev, u8 *sta_addr); extern int rtw_ex_get_drv_ability(struct net_device *dev, struct iw_request_info *info, struct iw_point *wrqu, char *extra); extern int rtw_ex_get(struct net_device *dev, struct iw_request_info *info, union iwreq_data *wdata, char *extra); -extern void *rtw_ioctl(struct net_device *dev, struct iwreq *rq, int cmd); +//extern void *rtw_ioctl(struct net_device *dev, struct iwreq *rq, int cmd); // Data declarations extern u8 g_user_ap_sta_num; // = 5u; extern const struct iw_priv_args rtw_private_args[26]; /* = @@ -121,21 +122,21 @@ extern void rtw_reset_securitypriv(_adapter *adapter); extern void rtw_os_indicate_disconnect(_adapter *adapter); extern int rtw_init_netdev_name(struct net_device *pnetdev, const char *ifname); extern struct net_device *rtw_init_netdev(_adapter *old_padapter); -extern int rtw_init_io_priv(_adapter *padapter, void (*set_intf_ops)(struct _io_ops *)); -extern _adapter *rtw_drv_if2_init(_adapter *primary_padapter, char *name, void (*set_intf_ops)(struct _io_ops *)); +//extern int rtw_init_io_priv(_adapter *padapter, void (*set_intf_ops)(struct _io_ops *)); +//extern _adapter *rtw_drv_if2_init(_adapter *primary_padapter, char *name, void (*set_intf_ops)(struct _io_ops *)); extern void rtw_drv_if2_stop(_adapter *if2); extern void rtw_drv_if2_free(_adapter *primary_padapter); extern init_done_ptr netdev_open(struct net_device *pnetdev); extern int netdev_if2_open(struct net_device *pnetdev); extern int netdev_if2_open(struct net_device *pnetdev); extern init_done_ptr netdev_open(struct net_device *pnetdev); -extern struct net_device *rtw_drv_probe(struct net_device *parent_dev, uint32_t mode); +//extern struct net_device *rtw_drv_probe(struct net_device *parent_dev, uint32_t mode); extern int rtw_dev_remove(struct net_device *pnetdev); extern void rtw_drv_entry(); extern void rtw_drv_halt(); // Data declarations extern init_done_ptr p_wlan_init_done_callback; -extern uint8_t rtw_power_percentage_idx; +extern uint8_t rtw_power_percentage_idx; // rtw_tx_pwr_percentage_t extern init_done_ptr p_wlan_uart_adapter_callback; extern uint8_t rtw_adaptivity_en; extern uint8_t rtw_adaptivity_mode; @@ -143,16 +144,16 @@ extern int8_t rtw_adaptivity_th_l2h_ini; extern drv_priv drvpriv; //-------------------------------- // hal_com.o -extern void dump_chip_info(int a1, int a2, int a3, int a4, HAL_VERSION ChipVersion); -extern int hal_com_get_channel_plan(_adapter *padapter, uint8_t hw_channel_plan, int sw_channel_plan, int def_channel_plan, BOOLEAN AutoLoadFail); -extern int HAL_IsLegalChannel(_adapter *Adapter, uint32_t Channel); -extern int MRateToHwRate(uint8_t rate); +//extern void dump_chip_info(int a1, int a2, int a3, int a4, HAL_VERSION ChipVersion); +//extern int hal_com_get_channel_plan(_adapter *padapter, uint8_t hw_channel_plan, int sw_channel_plan, int def_channel_plan, BOOLEAN AutoLoadFail); +//extern int HAL_IsLegalChannel(_adapter *Adapter, uint32_t Channel); +//extern int MRateToHwRate(uint8_t rate); extern signed int HwRateToMRate(uint8_t rate); extern void HalSetBrateCfg(_adapter *Adapter, uint8_t *mBratesOS, uint16_t *pBrateCfg); -extern signed int Hal_MappingOutPipe(_adapter *pAdapter, uint8_t NumOutPipe); +//extern signed int Hal_MappingOutPipe(_adapter *pAdapter, uint8_t NumOutPipe); extern void hal_init_macaddr(_adapter *adapter); extern void hw_var_port_switch(_adapter *adapter); -extern void SetHwReg(PADAPTER padapter, int variable, uint8_t *val); +//extern void SetHwReg(PADAPTER padapter, int variable, uint8_t *val); extern signed int eqNByte(uint8_t *str1, uint8_t *str2, uint32_t num); extern signed int GetU1ByteIntegerFromStringInDecimal(char *Str, uint8_t *pInt); extern void switch_power_saving_mode(_adapter *padapter, int benable); @@ -163,18 +164,22 @@ extern u8 CSWTCH_17[19]; //-------------------------------- // HalHWImg8195A_MAC.o // Function declarations -extern void ODM_ReadAndConfig_MP_8195A_MAC_REG(PDM_ODM_T pDM_Odm); -extern signed int ODM_GetVersion_MP_8195A_MAC_REG(); // return 26; +extern void ODM_ReadAndConfig_MP_8195A_MAC_REG(PDM_ODM_T pDM_Odm); +/* +extern signed int ODM_GetVersion_MP_8195A_MAC_REG(void); // return 26; +*/ // Data declarations extern u32 Array_MP_8195A_MAC_REG[194]; //-------------------------------- // HalHWImg8195A_RF.o // Function declarations extern signed int CheckPositive(PDM_ODM_T pDM_Odm, const u4Byte Condition1, const u4Byte Condition2, const u4Byte Condition3, const u4Byte Condition4); -extern void ODM_ReadAndConfig_MP_8195A_RadioA(PDM_ODM_T pDM_Odm); +extern void ODM_ReadAndConfig_MP_8195A_RadioA(PDM_ODM_T pDM_Odm); +/* extern signed int ODM_GetVersion_MP_8195A_RadioA(); extern void ODM_ReadAndConfig_MP_8195A_RADIO_DIFF(PDM_ODM_T pDM_Odm, u4Byte *Array, u4Byte ArrayLen, u4Byte a4); extern signed int ODM_GetVersion_MP_8195A_RADIO_DIFF(); +*/ extern void ODM_ReadAndConfig_MP_8195A_TxPowerTrack_QFN48(PDM_ODM_T pDM_Odm); extern void ODM_ReadAndConfig_MP_8195A_TxPowerTrack_QFN56(PDM_ODM_T pDM_Odm); extern void ODM_ReadAndConfig_MP_8195A_TxPowerTrack_TFBGA96(PDM_ODM_T pDM_Odm); @@ -200,8 +205,11 @@ extern void GetDeltaSwingTable_8195A(PDM_ODM_T pDM_Odm, ps1Byte *TemperatureUP_A extern void GetDeltaSwingXtalTable_8195A(PDM_ODM_T pDM_Odm, ps1Byte *TemperatureUP_Xtal, ps1Byte *TemperatureDOWN_Xtal); extern void ODM_TxXtalTrackSetXtal_8195A(PDM_ODM_T pDM_Odm); extern void setIqkMatrix_8195A(PDM_ODM_T pDM_Odm, int OFDM_index, int RFPath, s4Byte IqkResult_X, s4Byte IqkResult_Y); -extern void Hal_MPT_CCKTxPowerAdjust(PADAPTER Adapter); +extern void Hal_MPT_CCKTxPowerAdjust(PADAPTER Adapter); +/* extern void ODM_TxPwrTrackSetPwr_8195A(PDM_ODM_T pDM_Odm, PWRTRACK_METHOD Method, int RFPath, u8 ChannelMappedIndex); +extern void PHY_IQCalibrate_8195A(PADAPTER pAdapter, int bReCovery, int bRestore); +*/ extern void ConfigureTxpowerTrack_8195A(PTXPWRTRACK_CFG pConfig); extern int phy_PathA_IQK_8195A(PADAPTER pAdapter, BOOLEAN configPathB); extern signed int phy_PathA_RxIQK8195A(PADAPTER pAdapter, BOOLEAN configPathB); @@ -222,7 +230,6 @@ extern signed int phy_SimularityCompare_8195A(PADAPTER pAdapter, s4Byte (*result extern void phy_IQCalibrate_8195A(PADAPTER pAdapter, s4Byte (*result)[8], int t, int is2T); extern void phy_LCCalibrate_8195A(PDM_ODM_T pDM_Odm, BOOLEAN is2T); extern void PHY_LCCalibrate_8195A(PDM_ODM_T pDM_Odm); -extern void PHY_IQCalibrate_8195A(PADAPTER pAdapter, int bReCovery, int bRestore); extern void DoIQK_8195A(PDM_ODM_T pDM_Odm, u8 DeltaThermalIndex, u8 ThermalValue, u8 Threshold); extern void phy_SetRFPathSwitch_8195A(PADAPTER pAdapter, int bMain, BOOLEAN is2T); extern void PHY_SetRFPathSwitch_8195A(PADAPTER pAdapter, int bMain); @@ -277,14 +284,16 @@ extern int max_timer_used_num; //-------------------------------- // rtl8195a_cmd.o // Function declarations +/* extern int32_t FillH2CCmd8195A(PADAPTER padapter, int ElementID, uint64_t CmdLen); -extern void rtl8195a_set_FwRsvdPage_cmd(PADAPTER padapter, PH2CParam_RsvdPage pRsvdPage); extern void rtl8195a_set_FwMediaStatusRpt_cmd(PADAPTER padapter, int mstatus, int macid); extern void rtl8195a_set_FwMacIdConfig_cmd(_adapter *padapter, int mac_id, int raid, int bw, uint8_t sgi, uint32_t mask); extern void rtl8195a_set_FwPwrMode_cmd(PADAPTER padapter, int psmode); extern void rtl8195a_download_rsvd_page(PADAPTER padapter, int mstatus); extern void rtl8195a_set_FwJoinBssRpt_cmd(PADAPTER padapter, int mstatus); extern void rtl8195a_Add_RateATid(PADAPTER pAdapter, uint32_t bitmap, uint8_t *arg_ary, int rssi_level); +*/ +extern void rtl8195a_set_FwRsvdPage_cmd(PADAPTER padapter, PH2CParam_RsvdPage pRsvdPage); extern PADAPTER rtl8195a_set_BcnIgnoreEDCCA_cmd(PADAPTER result, int enable, int a3); //-------------------------------- // rtl8195a_rf6052.o @@ -295,59 +304,72 @@ extern int PHY_RF6052_Config8195A(PADAPTER Adapter); //-------------------------------- // rtw_efuse.o // Function declarations +/* rtw_efuse.h extern void Efuse_PowerSwitch(PADAPTER pAdapter, uint8_t bWrite, uint8_t PwrState); extern int Efuse_GetCurrentSize(PADAPTER pAdapter, uint8_t efuseType, BOOLEAN bPseudoTest); extern int Efuse_CalculateWordCnts(uint8_t word_en); extern void EFUSE_GetEfuseDefinition(PADAPTER pAdapter, int efuseType, uint8_t type, void *pOut, BOOLEAN bPseudoTest); extern int efuse_OneByteRead(PADAPTER pAdapter, int addr, uint8_t *data, int bPseudoTest); -extern int efuse_read8(PADAPTER padapter, int address, uint8_t *value); extern int efuse_OneByteWrite(PADAPTER pAdapter, int addr, int data, int bPseudoTest); -extern int efuse_write8(PADAPTER padapter, int address, uint8_t *value); extern int Efuse_PgPacketWrite(PADAPTER pAdapter, int offset, int word_en, uint8_t *data, BOOLEAN bPseudoTest); -extern void efuse_WordEnableDataRead(uint8_t word_en, uint8_t *sourdata, uint8_t *targetdata); extern int Efuse_WordEnableDataWrite(PADAPTER pAdapter, int efuse_addr, uint8_t word_en, uint8_t *data, BOOLEAN bPseudoTest); extern int rtw_efuse_access(PADAPTER padapter, int bWrite, int start_addr, int cnts, uint8_t *data); extern signed int efuse_GetCurrentSize(PADAPTER padapter, uint16_t *size); extern signed int rtw_efuse_map_read(PADAPTER padapter, int addr, int cnts, uint8_t *data); extern signed int rtw_efuse_map_write(PADAPTER padapter, int addr, int cnts, uint8_t *data); -extern void Efuse_ReadAllMap(PADAPTER pAdapter, int efuseType, uint8_t *Efuse, BOOLEAN bPseudoTest); extern void EFUSE_ShadowRead(PADAPTER pAdapter, int Type, int Offset, uint32_t *Value); extern void EFUSE_ShadowMapUpdate(PADAPTER pAdapter, int efuseType, BOOLEAN bPseudoTest, int a4); +*/ +extern void efuse_WordEnableDataRead(uint8_t word_en, uint8_t *sourdata, uint8_t *targetdata); +extern void Efuse_ReadAllMap(PADAPTER pAdapter, int efuseType, uint8_t *Efuse, BOOLEAN bPseudoTest); +extern int efuse_write8(PADAPTER padapter, int address, uint8_t *value); +extern int efuse_read8(PADAPTER padapter, int address, uint8_t *value); //-------------------------------- // rtw_ieee80211.o // Function declarations +/* ieee80211.h extern void rtw_macaddr_cfg(uint8_t *mac_addr, int a2); -extern int rtw_get_cipher_info(struct wlan_network *pnetwork); extern void rtw_get_bcn_info(struct wlan_network *pnetwork); +*/ +extern int rtw_get_cipher_info(struct wlan_network *pnetwork); //-------------------------------- // rtw_wlan_util.o // Function declarations -extern int cckrates_included(u8 *rate, int ratelen); -extern int cckratesonly_included(u8 *rate, int ratelen); -extern signed int networktype_to_raid_ex(PADAPTER padapter, int network_type); +/* rtw_mlme_ext.h +extern int get_beacon_interval(WLAN_BSSID_EX *bss, int a2, int a3); +extern int is_client_associated_to_ap(int result); +extern BOOL is_client_associated_to_ibss(_adapter *padapter); +extern void write_cam(_adapter *padapter, uint8_t entry, int ctrl, uint8_t *mac, uint8_t *key); +extern void VCS_update(_adapter *padapter, struct sta_info *psta); +extern int rtw_check_bcn_info(_adapter *Adapter, uint8_t *pframe, uint32_t packet_len); +extern void update_beacon_info(_adapter *padapter, uint8_t *pframe, unsigned int pkt_len, struct sta_info *psta); +extern signed int is_ap_in_tkip(_adapter *padapter); +extern int update_basic_rate(u8 *ptn, unsigned int ptn_sz); +extern int update_supported_rate(u8 *ptn, unsigned int ptn_sz); +extern int update_MCS_rate(struct HT_caps_element *pHT_caps); +extern int get_highest_rate_idx(uint32_t mask); +extern void Update_RA_Entry(_adapter *padapter, struct sta_info *psta); +extern void set_sta_rate(_adapter *padapter, struct sta_info *psta); +extern void update_tx_basic_rate(_adapter *padapter, int wirelessmode); +extern signed int check_assoc_AP(uint8_t *pframe, unsigned int len); + +extern void update_capinfo(PADAPTER Adapter, uint16_t updateCap); +extern void update_wireless_mode(_adapter *padapter, uint32_t a2, int a3); +extern void update_bmc_sta_support_rate(_adapter *padapter, uint32_t mac_id); +extern void Switch_DM_Func(_adapter *padapter, uint32_t mode, int enable); extern signed int judge_network_type(_adapter *padapter, u8 *rate, int ratelen); -extern int ratetbl_val_2wifirate(u8 rate); -extern int is_basicrate(_adapter *padapter, int rate); -extern int ratetbl2rateset(_adapter *padapter, u8 *rateset); extern void get_rate_set(_adapter *padapter, u8 *pbssrate, int *bssrate_len, int a4); extern void UpdateBrateTbl(PADAPTER Adapter, uint8_t *mBratesOS); extern void UpdateBrateTblForSoftAP(uint8_t *bssrateset, uint32_t bssratelen); extern void Save_DM_Func_Flag(_adapter *padapter, int a2, int a3); -extern void Restore_DM_Func_Flag(_adapter *padapter); -extern void Switch_DM_Func(_adapter *padapter, uint32_t mode, int enable); extern void Set_MSR(_adapter *padapter, uint8_t type); extern int set_opmode(_adapter *padapter, NDIS_802_11_NETWORK_INFRASTRUCTURE networktype); extern void SelectChannel(_adapter *padapter, int channel); extern void SetBWMode(_adapter *padapter, int bwmode, int channel_offset); extern void set_channel_bwmode(_adapter *padapter, int channel, int channel_offset, int bwmode); -extern uint8_t *get_my_bssid(WLAN_BSSID_EX *pnetwork); -extern int get_beacon_interval(WLAN_BSSID_EX *bss, int a2, int a3); -extern int is_client_associated_to_ap(int result); -extern BOOL is_client_associated_to_ibss(_adapter *padapter); -extern int is_IBSS_empty(_adapter *padapter); -extern unsigned int decide_wait_for_beacon_timeout(unsigned int bcn_interval); -extern void invalidate_cam_all(_adapter *padapter); -extern void write_cam(_adapter *padapter, uint8_t entry, int ctrl, uint8_t *mac, uint8_t *key); +*/ +extern int wifirate2_ratetbl_inx(u8 rate); +extern int support_short_GI(_adapter *padapter, struct HT_caps_element *pHT_caps); extern void clear_cam_entry(_adapter *padapter, uint8_t entry); extern void flush_all_cam_entry(_adapter *padapter); extern int WMM_param_handler(_adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE); @@ -356,25 +378,19 @@ extern void HT_caps_handler(_adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE); extern void HT_info_handler(_adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE); extern void HTOnAssocRsp(_adapter *padapter); extern void ERP_IE_handler(_adapter *padapter, PNDIS_802_11_VARIABLE_IEs pIE); -extern void VCS_update(_adapter *padapter, struct sta_info *psta); -extern int rtw_check_bcn_info(_adapter *Adapter, uint8_t *pframe, uint32_t packet_len); -extern void update_beacon_info(_adapter *padapter, uint8_t *pframe, unsigned int pkt_len, struct sta_info *psta); -extern signed int is_ap_in_tkip(_adapter *padapter); -extern int wifirate2_ratetbl_inx(u8 rate); -extern int update_basic_rate(u8 *ptn, unsigned int ptn_sz); -extern int update_supported_rate(u8 *ptn, unsigned int ptn_sz); -extern int update_MCS_rate(struct HT_caps_element *pHT_caps); -extern int support_short_GI(_adapter *padapter, struct HT_caps_element *pHT_caps); -extern int get_highest_rate_idx(uint32_t mask); -extern void Update_RA_Entry(_adapter *padapter, struct sta_info *psta); +extern int is_IBSS_empty(_adapter *padapter); +extern unsigned int decide_wait_for_beacon_timeout(unsigned int bcn_interval); +extern void invalidate_cam_all(_adapter *padapter); extern void enable_rate_adaptive(_adapter *padapter, struct sta_info *psta); -extern void set_sta_rate(_adapter *padapter, struct sta_info *psta); -extern void update_tx_basic_rate(_adapter *padapter, int wirelessmode); -extern signed int check_assoc_AP(uint8_t *pframe, unsigned int len); extern void update_IOT_info(_adapter *padapter); -extern void update_capinfo(PADAPTER Adapter, uint16_t updateCap); -extern void update_wireless_mode(_adapter *padapter, uint32_t a2, int a3); -extern void update_bmc_sta_support_rate(_adapter *padapter, uint32_t mac_id); +extern int cckrates_included(u8 *rate, int ratelen); +extern int cckratesonly_included(u8 *rate, int ratelen); +extern signed int networktype_to_raid_ex(PADAPTER padapter, int network_type); +extern int ratetbl_val_2wifirate(u8 rate); +extern int is_basicrate(_adapter *padapter, int rate); +extern int ratetbl2rateset(_adapter *padapter, u8 *rateset); +extern void Restore_DM_Func_Flag(_adapter *padapter); +extern uint8_t *get_my_bssid(WLAN_BSSID_EX *pnetwork); extern void update_TSF(struct mlme_ext_priv *pmlmeext, uint8_t *pframe, unsigned int len); extern void correct_TSF(_adapter *padapter, struct mlme_ext_priv *pmlmeext); // Data declarations @@ -527,14 +543,15 @@ extern _sema *pExportWlanIrqSemaphore; // freertos_recv.o // Function declarations extern int rtw_os_recv_resource_init(struct recv_priv *precvpriv, _adapter *padapter); -extern int rtw_os_recv_resource_alloc(_adapter *padapter, struct recv_frame *precvframe); extern int rtw_os_recvbuf_resource_alloc(_adapter *padapter, struct recv_buf *precvbuf); extern int rtw_os_recvbuf_resource_free(_adapter *padapter, struct recv_buf *precvbuf); extern int rtw_tkip_countermeasure(_adapter *padapter); -extern void rtw_handle_tkip_mic_err(_adapter *padapter, int bgroup); -extern int rtw_recv_indicatepkt(_adapter *padapter, struct recv_frame *precv_frame); extern void rtw_init_recv_timer(struct recv_reorder_ctrl *preorder_ctrl); - +/* +extern int rtw_os_recv_resource_alloc(_adapter *padapter, union recv_frame *precvframe); +extern void rtw_handle_tkip_mic_err(_adapter *padapter, int bgroup); +extern int rtw_recv_indicatepkt(_adapter *padapter, union recv_frame *precv_frame); +*/ //-------------------------------- // freertos_skbuff.o // Function declarations @@ -581,7 +598,8 @@ extern int skb_fail_count; extern int max_skb_buf_num; // = 8; //-------------------------------- // freertos_xmit.o -// Function declarations +// Function declarations -> freertos_xmit.h +/* extern signed int rtw_remainder_len(struct pkt_file *pfile); extern void rtw_open_pktfile(_pkt *pktptr, struct pkt_file *pfile); extern unsigned int rtw_pktfile_read(struct pkt_file *pfile, uint8_t *rmem, unsigned int rlen); @@ -592,57 +610,60 @@ extern void rtw_os_xmit_complete(_adapter *padapter, struct xmit_frame *pxframe) extern void rtw_os_xmit_schedule(_adapter *padapter, _irqL a2, int a3); extern int rtw_xmit_entry(_pkt *pkt, _nic_hdl pnetdev, int a3); extern int rtw_os_can_xmit(struct net_device *dev); +*/ //-------------------------------- // hal_intf.o // Function declarations +/* hal_intf.h extern int32_t rtw_hal_fill_h2c_cmd(int32_t result, uint8_t ElementID, uint32_t CmdLen, uint8_t *pCmdBuffer); extern void rtw_hal_fill_fake_txdesc(_adapter *padapter, uint8_t *pDesc, uint32_t BufferLen, uint8_t IsPsPoll, uint8_t IsBTQosNull, uint8_t bDataFrame); extern _adapter *rtw_hal_get_txbuff_rsvd_page_num(_adapter *result, bool wowlan); -extern void rtw_hal_chip_configure(_adapter *padapter); -extern void rtw_hal_read_chip_info(_adapter *padapter); -extern void rtw_hal_read_chip_version(_adapter *padapter); -extern void rtw_hal_def_value_init(_adapter *padapter); -extern void rtw_hal_free_data(_adapter *padapter); -extern void rtw_hal_dm_init(_adapter *padapter); -extern void rtw_hal_dm_deinit(_adapter *padapter); extern int rtw_hal_init(_adapter *padapter); extern int rtw_hal_deinit(_adapter *padapter); -extern void rtw_hal_set_hwreg(_adapter *padapter, uint8_t variable, uint8_t *val); -extern void rtw_hal_get_hwreg(_adapter *padapter, uint8_t variable, uint8_t *val); extern int rtw_hal_set_def_var(_adapter *padapter, HAL_DEF_VARIABLE eVariable, PVOID pValue); extern int rtw_hal_get_def_var(_adapter *padapter, HAL_DEF_VARIABLE eVariable, PVOID pValue); -extern void rtw_hal_set_odm_var(_adapter *padapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, BOOLEAN bSet); -extern void rtw_hal_get_odm_var(_adapter *padapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, BOOLEAN bSet); -extern void rtw_hal_enable_interrupt(_adapter *padapter); -extern void rtw_hal_disable_interrupt(_adapter *padapter); extern int rtw_hal_inirp_init(_adapter *padapter); extern int rtw_hal_inirp_deinit(_adapter *padapter); -extern void rtw_hal_irp_reset(_adapter *padapter); extern int32_t rtw_hal_xmit(_adapter *padapter, struct xmit_frame *pxmitframe); extern int32_t rtw_hal_mgnt_xmit(_adapter *padapter, struct xmit_frame *pmgntframe); extern int32_t rtw_hal_init_xmit_priv(_adapter *padapter); -extern void rtw_hal_free_xmit_priv(_adapter *padapter); extern int32_t rtw_hal_init_recv_priv(_adapter *padapter); -extern void rtw_hal_free_recv_priv(_adapter *padapter); extern void rtw_hal_update_ra_mask(struct sta_info *psta, uint8_t rssi_level); extern void rtw_hal_add_ra_tid(_adapter *padapter, uint32_t bitmap, uint8_t *arg, uint8_t rssi_level); extern void rtw_hal_update_txdesc(_adapter *padapter, struct xmit_frame *pxmitframe, uint8_t *pbuf); -extern void rtw_hal_clone_data(_adapter *dst_padapter, _adapter *src_padapter); -extern void rtw_hal_start_thread(_adapter *padapter); -extern void rtw_hal_stop_thread(_adapter *padapter); extern int rtw_hal_read_bbreg(_adapter *padapter, uint32_t RegAddr, uint32_t BitMask); extern void rtw_hal_write_bbreg(_adapter *padapter, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); extern int rtw_hal_read_rfreg(_adapter *padapter, uint32_t eRFPath, uint32_t RegAddr, uint32_t BitMask); extern void rtw_hal_write_rfreg(_adapter *padapter, uint32_t eRFPath, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); extern int32_t rtw_hal_interrupt_handler(_adapter *padapter); -extern void rtw_hal_set_bwmode(_adapter *padapter, CHANNEL_WIDTH Bandwidth, uint8_t Offset); -extern void rtw_hal_set_chan(_adapter *padapter, uint8_t channel); extern void rtw_hal_set_chnl_bw(_adapter *padapter, int channel, CHANNEL_WIDTH Bandwidth, uint8_t Offset40, uint8_t Offset80); -extern void rtw_hal_dm_watchdog(_adapter *padapter); extern int32_t rtw_hal_recv_tasklet(_adapter *padapter); +*/ extern int32_t rtw_hal_macid_sleep(PADAPTER padapter, int macid, int a3); extern int32_t rtw_hal_macid_wakeup(PADAPTER padapter, int macid, int a3); -extern void decide_chip_type_by_device_id(_adapter *padapter); +extern void decide_chip_type_by_device_id(_adapter *padapter); +extern void rtw_hal_dm_watchdog(_adapter *padapter); +extern void rtw_hal_set_bwmode(_adapter *padapter, CHANNEL_WIDTH Bandwidth, uint8_t Offset); +extern void rtw_hal_set_chan(_adapter *padapter, uint8_t channel); +extern void rtw_hal_clone_data(_adapter *dst_padapter, _adapter *src_padapter); +extern void rtw_hal_start_thread(_adapter *padapter); +extern void rtw_hal_stop_thread(_adapter *padapter); +extern void rtw_hal_free_recv_priv(_adapter *padapter); +extern void rtw_hal_free_xmit_priv(_adapter *padapter); +extern void rtw_hal_irp_reset(_adapter *padapter); +extern void rtw_hal_set_odm_var(_adapter *padapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, BOOLEAN bSet); +extern void rtw_hal_get_odm_var(_adapter *padapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, BOOLEAN bSet); +extern void rtw_hal_enable_interrupt(_adapter *padapter); +extern void rtw_hal_disable_interrupt(_adapter *padapter); +extern void rtw_hal_set_hwreg(_adapter *padapter, uint8_t variable, uint8_t *val); +extern void rtw_hal_get_hwreg(_adapter *padapter, uint8_t variable, uint8_t *val); +extern void rtw_hal_chip_configure(_adapter *padapter); +extern void rtw_hal_read_chip_info(_adapter *padapter); +extern void rtw_hal_read_chip_version(_adapter *padapter); +extern void rtw_hal_def_value_init(_adapter *padapter); +extern void rtw_hal_free_data(_adapter *padapter); +extern void rtw_hal_dm_init(_adapter *padapter); +extern void rtw_hal_dm_deinit(_adapter *padapter); //-------------------------------- // hal_phy.o // Function declarations @@ -675,8 +696,10 @@ extern void TryDone(PDM_ODM_T pDM_Odm, PODM_RA_INFO_T pRaInfo); extern void RateDownStepRAM8195A(PDM_ODM_T pDM_Odm, PODM_RA_INFO_T pRaInfo, int step); extern void RateDecisionRAM8195A(PDM_ODM_T pDM_Odm, PODM_RA_INFO_T pRaInfo); extern void ArfrRefresh(PDM_ODM_T pDM_Odm, PODM_RA_INFO_T pRaInfo); -extern void H2CHDL_Set_MACID_Config(PDM_ODM_T pDM_Odm, u8 *pbuf); +extern void H2CHDL_Set_MACID_Config(PDM_ODM_T pDM_Odm, u8 *pbuf); +/* extern void PHY_DM_RA_SetRSSI_8195A(PDM_ODM_T pDM_Odm, int MacID, u8 Rssi); +*/ // Data declarations extern u8 Noisy_State; extern u8 ARFB_table[9][7]; /* = @@ -717,13 +740,17 @@ extern u8 PER_RATE_DOWN[20]; /* = extern void ConfigureTxpowerTrack(PDM_ODM_T pDM_Odm, PTXPWRTRACK_CFG pConfig); extern void ODM_ClearTxPowerTrackingState(PDM_ODM_T pDM_Odm); extern void ODM_TXPowerTrackingCallback_ThermalMeter(PADAPTER Adapter); -extern void ODM_ResetIQKResult(PDM_ODM_T pDM_Odm); +//extern void ODM_ResetIQKResult(PDM_ODM_T pDM_Odm); +/* extern int ODM_GetRightChnlPlaceforIQK(int chnl); +*/ // Data declarations //-------------------------------- // HalPwrSeqCmd.o // Function declarations +/* extern signed int HalPwrSeqCmdParsing(_adapter *padapter, uint8_t CutVersion, uint8_t FabVersion, int InterfaceType, WLAN_PWR_CFG *PwrSeqCmd); +*/ // Data declarations //-------------------------------- // hci_intfs.o @@ -736,17 +763,20 @@ extern void hci_dvobj_free_irq(struct dvobj_priv *dvobj); //-------------------------------- // rtw_ioctl_set.o // Function declarations -extern int rtw_do_join(_adapter *padapter, _irqL a2); +/* extern int rtw_set_802_11_bssid(_adapter *padapter, uint8_t *bssid); extern int rtw_set_802_11_ssid(_adapter *padapter, NDIS_802_11_SSID *ssid, int a3); extern signed int rtw_set_802_11_infrastructure_mode(_adapter *padapter, NDIS_802_11_NETWORK_INFRASTRUCTURE networktype); extern signed int rtw_set_802_11_bssid_list_scan(_adapter *padapter, NDIS_802_11_SSID *pssid, int ssid_max_num); extern int rtw_set_802_11_authentication_mode(_adapter *padapter, struct NDIS_802_11_AUTHENTICATION_MODE authmode); extern int rtw_set_802_11_add_wep(_adapter *padapter, NDIS_802_11_WEP *wep); +*/ +extern int rtw_do_join(_adapter *padapter, _irqL a2); // Data declarations //-------------------------------- // rtw_io.o // Function declarations +/* extern int rtw_read8(_adapter *adapter, uint32_t addr); extern int rtw_read16(_adapter *adapter, uint32_t addr); extern int rtw_read32(_adapter *adapter, uint32_t addr); @@ -755,28 +785,35 @@ extern int32_t rtw_write16(_adapter *adapter, uint32_t addr, int val); extern int32_t rtw_write32(_adapter *adapter, uint32_t addr, uint32_t val); extern signed int rtw_read_port(_adapter *adapter, uint32_t addr, uint32_t cnt, uint8_t *mem, struct fifo_more_data *more_data); extern signed int rtw_write_port(_adapter *adapter, uint32_t addr, uint32_t cnt, uint8_t *mem); -extern void rtw_set_chip_endian(_adapter *adapter); extern int rtw_get_chip_endian(_adapter padapter); +*/ +extern void rtw_set_chip_endian(_adapter *adapter); // Data declarations //-------------------------------- // rtw_cmd.o -// Function declarations +// Function declarations -> rtw_cmd.h +/* extern sint rtw_init_cmd_priv(struct cmd_priv *pcmdpriv); extern sint rtw_init_evt_priv(struct evt_priv *pevtpriv); extern void rtw_free_cmd_priv(struct cmd_priv *pcmdpriv); extern sint rtw_enqueue_cmd(_queue *queue, struct cmd_obj *obj); extern struct cmd_obj *rtw_dequeue_cmd(_queue *queue, _irqL a2, int a3); -extern struct list_head *rtw_observequeue_cmd(_queue *queue); extern signed int rtw_init_cmd_priv(struct cmd_priv *pcmdpriv); +*/ +extern struct list_head *rtw_observequeue_cmd(_queue *queue); extern int rtw_cmd_filter(struct cmd_priv *pcmdpriv, struct cmd_obj *cmd_obj); extern void rtw_free_cmd_obj(struct cmd_obj *pcmd); //extern int rtw_enqueue_cmd(struct cmd_priv *pcmdpriv, struct cmd_obj *cmd_obj); extern void rtw_set_channel_plan_cmd_callback(_adapter *padapter, struct cmd_obj *pcmd); extern void rtw_survey_cmd_callback(_adapter *padapter, struct cmd_obj *pcmd); -extern void rtw_disassoc_cmd_callback(_adapter *padapter, struct cmd_obj *pcmd, int a3); +extern void rpt_timer_setting_wk_hdl(_adapter *padapter, uint16_t minRptTime, int a3); extern void rtw_joinbss_cmd_callback(_adapter *padapter, struct cmd_obj *pcmd); extern void rtw_setstaKey_cmdrsp_callback(_adapter *padapter, struct cmd_obj *pcmd); extern void rtw_cmd_thread(thread_context context); +extern void dynamic_chk_wk_hdl(_adapter *padapter, uint8_t *pbuf, int sz); +extern void lps_ctrl_wk_hdl(_adapter *padapter, int lps_ctrl_type, int a3); +/* trw_cmd.h +extern void rtw_disassoc_cmd_callback(_adapter *padapter, struct cmd_obj *pcmd, int a3); extern int rtw_createbss_cmd(_adapter *padapter); extern int rtw_joinbss_cmd(_adapter *padapter, struct wlan_network *pnetwork); extern int rtw_disassoc_cmd(_adapter *padapter); @@ -786,16 +823,14 @@ extern int rtw_clearstakey_cmd(_adapter *padapter, uint8_t *psta, uint8_t entry, extern int rtw_addbareq_cmd(_adapter *padapter, int tid, uint8_t *addr); extern int rtw_dynamic_chk_wk_cmd(_adapter *padapter); extern struct cmd_obj *rtw_set_chplan_cmd(_adapter *padapter, int chplan, int enqueue); -extern void dynamic_chk_wk_hdl(_adapter *padapter, uint8_t *pbuf, int sz); -extern void lps_ctrl_wk_hdl(_adapter *padapter, int lps_ctrl_type, int a3); extern int rtw_lps_ctrl_wk_cmd(_adapter *padapter, int lps_ctrl_type, int enqueue); extern struct cmd_obj *rtw_sitesurvey_cmd(_adapter *padapter, NDIS_802_11_SSID *pssid, int ssid_max_num); -extern void rpt_timer_setting_wk_hdl(_adapter *padapter, uint16_t minRptTime, int a3); extern int rtw_rpt_timer_cfg_cmd(_adapter *padapter, int minRptTime); extern int rtw_ps_cmd(_adapter *padapter); extern int rtw_chk_hi_queue_cmd(_adapter *padapter); extern signed int rtw_drvextra_cmd_hdl(_adapter *padapter, u8 *pbuf, int a3); extern int rtw_c2h_wk_cmd(PADAPTER padapter); +*/ // Data declarations extern const struct cmd_hdl wlancmds[63]; extern const struct _cmd_callback rtw_cmd_callback[63]; @@ -809,34 +844,43 @@ extern void rtw_free_netdev(struct net_device *netdev); //-------------------------------- // phydm.o // Function declarations -extern void ODM_CmnInfoInit(PDM_ODM_T pDM_Odm, ODM_CMNINFO_E CmnInfo, u4Byte Value); +/* extern void ODM_CmnInfoHook(PDM_ODM_T pDM_Odm, ODM_CMNINFO_E CmnInfo, PVOID pValue); -extern void ODM_CmnInfoPtrArrayHook(PDM_ODM_T pDM_Odm, ODM_CMNINFO_E CmnInfo, int Index, PVOID pValue); +extern void ODM_DMInit(PDM_ODM_T pDM_Odm); +extern void ODM_DMWatchdog(PDM_ODM_T pDM_Odm); +*/ +extern void ODM_CmnInfoInit(PDM_ODM_T pDM_Odm, ODM_CMNINFO_E CmnInfo, u4Byte Value); extern void ODM_CmnInfoUpdate(PDM_ODM_T pDM_Odm, u4Byte CmnInfo, u8Byte Value); extern void odm_CommonInfoSelfInit(PDM_ODM_T pDM_Odm); -extern void ODM_DMInit(PDM_ODM_T pDM_Odm); extern void odm_CommonInfoSelfUpdate(PDM_ODM_T pDM_Odm); -extern void ODM_DMWatchdog(PDM_ODM_T pDM_Odm); extern void odm_CommonInfoSelfReset(PDM_ODM_T pDM_Odm); -extern ADAPTIVITY_STATISTICS *PhyDM_Get_Structure(PDM_ODM_T pDM_Odm, int Structure_Type); extern void odm_SwAntDetectInit(PDM_ODM_T pDM_Odm); +/* +extern void ODM_CmnInfoPtrArrayHook(PDM_ODM_T pDM_Odm, ODM_CMNINFO_E CmnInfo, int Index, PVOID pValue); +extern ADAPTIVITY_STATISTICS *PhyDM_Get_Structure(PDM_ODM_T pDM_Odm, int Structure_Type); +*/ // Data declarations //-------------------------------- // rtl8195a_phycfg.o // Function declarations +/* extern int PHY_QueryBBReg_8195A_Safe(PADAPTER Adapter, uint32_t RegAddr, uint32_t BitMask); extern void PHY_SetBBReg_8195A_Safe(PADAPTER Adapter, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); -extern int phy_RFSerialRead_8195A(PADAPTER Adapter, RF_PATH eRFPath, uint32_t Offset); extern uint32_t PHY_QueryRFReg_8195A(PADAPTER Adapter, uint32_t eRFPath, uint32_t RegAddr, uint32_t BitMask); extern void PHY_SetRFReg_8195A(PADAPTER Adapter, uint32_t eRFPath, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); extern BOOL PHY_MACConfig8195A(PADAPTER Adapter); +extern int PHY_GetTxPowerIndex_8195A(PADAPTER pAdapter, int RFPath, int Rate, CHANNEL_WIDTH BandWidth, uint8_t Channel); +extern void PHY_SetTxPowerLevel8195A(PADAPTER Adapter, int Channel); +extern void PHY_SetBWMode8195A(PADAPTER Adapter, CHANNEL_WIDTH Bandwidth, int Offset); +extern void PHY_SetSwChnlBWMode8195A(PADAPTER Adapter, uint8_t channel, CHANNEL_WIDTH Bandwidth, int Offset40, uint8_t Offset80); +*/ +extern void PHY_SwChnl8195A(PADAPTER Adapter, uint8_t channel); +extern int phy_RFSerialRead_8195A(PADAPTER Adapter, RF_PATH eRFPath, uint32_t Offset); extern int PHY_BBConfig8195A(PADAPTER Adapter); extern int PHY_ConfigRFWithParaFile_8195A(PADAPTER Adapter, uint8_t *pFileName, RF_PATH eRFPath); extern void phy_PowerIndexCheck8195A(PADAPTER Adapter, uint8_t channel, uint8_t *cckPowerLevel, uint8_t *ofdmPowerLevel, uint8_t *BW20PowerLevel, uint8_t *BW40PowerLevel); extern void PHY_SetTxPowerIndex_8195A(PADAPTER Adapter, uint32_t PowerIndex, int RFPath, int Rate); extern void phy_TxPwrAdjInPercentage(PADAPTER Adapter, uint8_t *pTxPwrIdx); -extern int PHY_GetTxPowerIndex_8195A(PADAPTER pAdapter, int RFPath, int Rate, CHANNEL_WIDTH BandWidth, uint8_t Channel); -extern void PHY_SetTxPowerLevel8195A(PADAPTER Adapter, int Channel); extern void phy_SpurCalibration_8195A(PADAPTER pAdapter); extern void phy_SetRegBW_8195A(PADAPTER Adapter, CHANNEL_WIDTH CurrentBW); extern int phy_GetSecondaryChnl_8195A(PADAPTER Adapter); @@ -844,9 +888,6 @@ extern void phy_PostSetBwMode8195A(PADAPTER Adapter); extern void phy_SwChnl8195A(PADAPTER pAdapter); extern void phy_SwChnlAndSetBwMode8195A(PADAPTER Adapter); extern void PHY_HandleSwChnlAndSetBW8195A(PADAPTER Adapter, int bSwitchChannel, int bSetBandWidth, uint8_t ChannelNum, CHANNEL_WIDTH ChnlWidth, EXTCHNL_OFFSET ExtChnlOffsetOf40MHz, EXTCHNL_OFFSET ExtChnlOffsetOf80MHz, uint8_t CenterFrequencyIndex1); -extern void PHY_SetBWMode8195A(PADAPTER Adapter, CHANNEL_WIDTH Bandwidth, int Offset); -extern void PHY_SwChnl8195A(PADAPTER Adapter, uint8_t channel); -extern void PHY_SetSwChnlBWMode8195A(PADAPTER Adapter, uint8_t channel, CHANNEL_WIDTH Bandwidth, int Offset40, uint8_t Offset80); // Data declarations //-------------------------------- // rtl8195a_pmu_cmd.o @@ -856,8 +897,10 @@ extern void MediaDisconnection(PADAPTER padapter, int macid); extern void RATaskEnable(PADAPTER padapter); extern void SetMediaStatus(PADAPTER padapter, int macid, int status); extern void H2CHDL_JoinInfo(PADAPTER padapter, uint8_t *pCmdBuffer); -extern void H2CHDL_SetRsvdPage(PADAPTER padapter, uint8_t *pCmdBuffer); +extern void H2CHDL_SetRsvdPage(PADAPTER padapter, uint8_t *pCmdBuffer); +/* extern uint32_t H2CCmdCommon(PADAPTER padapter, int ElementID, uint8_t *pCmdBuffer); +*/ // Data declarations //-------------------------------- // rtl8195a_pmu_task.o @@ -868,27 +911,13 @@ extern void ChangeStateByTDMA(PADAPTER padapter); extern void GetMinRateInRRSR(PADAPTER padapter); extern void CheckInReqState(PADAPTER padapter); extern void InitCheckStateTimer(); -extern void InitGTimer1ms(PADAPTER padapter, uint8_t IRQDis, int TimerID, uint32_t Period); -extern void DeInitGTimer1ms(PADAPTER padapter, int TimerID); -extern void ChangeTransmiteRate(int offset, uint8_t rate); -extern void PowerBitSetting(int bPowerBit, int offset); -extern void ChkandChangePS(PPS_PARM pPSParm, int bPowerBit); -extern int IssueRsvdPagePacketSetting(int PageNum, int bHwSEQEn, uint8_t RtyLmt); extern void InitRsvdPgPkt(); extern void IssuePSPoll(); -extern signed int WaitTxStateMachineOk(); -extern signed int IssueNullData(PPS_PARM pPSParm, int bPowerBit, uint8_t RtyLmt); extern void WriteTxPause(uint8_t value, uint8_t rcode); extern void PsCloseRF(); extern void PsOpenRF(); -extern void SetPwrStateReg(PPS_PARM pPSParm, int PwrStateType, uint8_t value); extern BOOL ChkTxQueueIsEmpty(); extern void InitPS(PADAPTER padapter); -extern void ConfigListenBeaconPeriod(PPS_PARM pPSParm, int RLBM, int AwakeInterval); -extern signed int PS_S2_Condition_Match(PPS_PARM pPSParm); -extern signed int PS_S4_Condition_Match(PADAPTER padapter); -extern unsigned int PS_32K_Condition_Match(); -extern void PS_S2ToS3ToS0State(PADAPTER padapter, int nulldata0Allow); extern void PS_S2ToS0State(PPS_PARM pPSParm); extern void PS_S3ToS2orS0State(PPS_PARM pPSParm); extern void PS_S0ToS1ToS2State(PADAPTER padapter); @@ -898,19 +927,14 @@ extern void PS_S2ToS5State(PPS_PARM pPSParm); extern void PS_S5ToS2State(PPS_PARM pPSParm); extern void PS_S0ToS6State(PADAPTER padapter); extern void PS_S6ToS0State(PPS_PARM pPSParm); -extern void CheckTSFIsStable(int ReqState); extern void WaitHWStateReady(); extern void SysClkDown(PPS_PARM pPSParm); extern void SysClkUp(PPS_PARM pPSParm); extern void ResetPSParm(PADAPTER padapter); -extern void PS_S4ToS2State(PPS_PARM pPSParm, int ReleaseTxPause); extern void SleepTo32K(PPS_PARM pPSParm); -extern void Change_PS_State(PADAPTER padapter, int request_ps_state, int nulldata0Allow); extern void Legacy_PS_Setting(PADAPTER padapter); -extern void PSModeSetting(PADAPTER padapter, int on); extern void ChangePSStateByRPWM(PADAPTER padapter); extern void ChangeTDMAState(PADAPTER padapter); -extern void TDMAChangeStateTask(PADAPTER padapter, _irqL a2); extern void EnterPS(PADAPTER padapter); extern void SetSmartPSTimer(PADAPTER padapter); extern void GTimer7Handle(void *Data); @@ -922,7 +946,6 @@ extern void PSRxBcnProcess(PADAPTER padapter); extern void TxPktInPSOn(PADAPTER padapter); extern void PsBcnToProcess(PADAPTER padapter); extern void GTimer6Handle(void *Data); -extern signed int RPWMProcess(PADAPTER padapter, int benter32k); extern void PSSetMode(PADAPTER padapter, PLEGACY_PS_PARM pparm); extern void SpeRPT(PADAPTER padapter); extern void ISR_BcnEarly(PADAPTER padapter); @@ -934,27 +957,53 @@ extern void ISR_RxUCMD1(PADAPTER padapter); extern void ISR_RxUCMD0(PADAPTER padapter); extern void ISR_TxPktIn(PADAPTER padapter); extern void H2CHDL_SetPwrMode(PADAPTER padapter, uint8_t *pCmdBuffer); -extern void CheckInReqStateTask(PADAPTER padapter, int a2, int a3); -extern uint32_t HalGetNullTxRpt(PADAPTER padapter); extern void ISR_TBTT(PADAPTER padapter); extern void H2CHDL_BcnIgnoreEDCCA(PADAPTER padapter, uint8_t *pCmdBuffer); extern void PMUInitial(PADAPTER padapter); extern void PMUTask(PADAPTER padapter); +/* +extern void InitGTimer1ms(PADAPTER padapter, uint8_t IRQDis, int TimerID, uint32_t Period); +extern void DeInitGTimer1ms(PADAPTER padapter, int TimerID); +extern void ChangeTransmiteRate(int offset, uint8_t rate); +extern void PowerBitSetting(int bPowerBit, int offset); +extern void ChkandChangePS(PPS_PARM pPSParm, int bPowerBit); +extern int IssueRsvdPagePacketSetting(int PageNum, int bHwSEQEn, uint8_t RtyLmt); +extern signed int WaitTxStateMachineOk(); +extern signed int IssueNullData(PPS_PARM pPSParm, int bPowerBit, uint8_t RtyLmt); +extern void SetPwrStateReg(PPS_PARM pPSParm, int PwrStateType, uint8_t value); +extern void ConfigListenBeaconPeriod(PPS_PARM pPSParm, int RLBM, int AwakeInterval); +extern signed int PS_S2_Condition_Match(PPS_PARM pPSParm); +extern signed int PS_S4_Condition_Match(PADAPTER padapter); +extern unsigned int PS_32K_Condition_Match(); +extern void PS_S2ToS3ToS0State(PADAPTER padapter, int nulldata0Allow); +extern void CheckTSFIsStable(int ReqState); +extern void PS_S4ToS2State(PPS_PARM pPSParm, int ReleaseTxPause); +extern void Change_PS_State(PADAPTER padapter, int request_ps_state, int nulldata0Allow); +extern void PSModeSetting(PADAPTER padapter, int on); +extern void TDMAChangeStateTask(PADAPTER padapter, _irqL a2); +extern signed int RPWMProcess(PADAPTER padapter, int benter32k); +extern void CheckInReqStateTask(PADAPTER padapter, int a2, int a3); +extern uint32_t HalGetNullTxRpt(PADAPTER padapter); +*/ // Data declarations extern BOOL bCheckStateTIMER; extern uint32_t WifiMcuCmdBitMap_20974; //-------------------------------- // rtl8195a_recv.o // Function declarations -extern int32_t rtl8195a_init_recv_priv(_adapter *padapter); +/* +extern int32_t rtl8195a_init_recv_priv(_adapter *padapter); +*/ // Data declarations //-------------------------------- // rtl8195a_rxdesc.o // Function declarations -extern void process_rssi(_adapter *padapter, struct recv_frame *prframe); extern int32_t translate2dbm(int signal_strength_idx); -extern void rtl8195a_query_rx_desc_status(struct recv_frame *precvframe, uint8_t *pdesc); -extern void rtl8195a_query_rx_phy_status(struct recv_frame *precvframe, uint8_t *pphy_status, int a3); +/* +extern void process_rssi(_adapter *padapter, union recv_frame *prframe); +extern void rtl8195a_query_rx_desc_status(union recv_frame *precvframe, uint8_t *pdesc); +extern void rtl8195a_query_rx_phy_status(union recv_frame *precvframe, uint8_t *pphy_status, int a3); +*/ // Data declarations //-------------------------------- // rtl8195a_xmit.o @@ -962,20 +1011,24 @@ extern void rtl8195a_query_rx_phy_status(struct recv_frame *precvframe, uint8_t extern uint8_t *GetTxBufDesc(_adapter *padapter, int queue_index); extern void UpdateFirstTxbdtoXmitBuf(_adapter *padapter, struct xmit_frame *pxmitframe); extern BOOL check_nic_enough_desc(_adapter *padapter, struct pkt_attrib *pattrib); -extern int32_t rtl8195ab_init_xmit_priv(PADAPTER padapter); extern void rtl8195ab_free_xmit_priv(PADAPTER padapter); -extern uint32_t GetDmaTxbdIdx(uint32_t ff_hwaddr); extern struct xmit_buf *rtl8195a_enqueue_xmitbuf(struct rtw_tx_ring *ring, struct xmit_buf *pxmitbuf); -extern struct list_head *rtl8195a_dequeue_xmitbuf(struct rtw_tx_ring *ring); extern signed int SetTxbdForLxDMARtl8195ab(_adapter *padapter, struct xmit_frame *pxmitframe, struct tx_buf_desc *pTxbd); extern void UpdateTxbdHostIndex(_adapter *padapter, uint32_t ff_hwaddr); extern struct xmit_buf *SetXimtBuf(struct xmit_frame *pxmitframe); -extern int FreeXimtBuf(struct xmit_buf *pxmitbuf); extern int rtw_dump_xframe(_adapter *padapter, struct xmit_frame *pxmitframe); extern BOOL check_tx_desc_resource(_adapter *padapter, int prio); +extern void rtl8195ab_xmitframe_resume(_adapter *padapter); +/* +extern int32_t rtl8195ab_init_xmit_priv(PADAPTER padapter); +extern uint32_t GetDmaTxbdIdx(uint32_t ff_hwaddr); +extern struct list_head *rtl8195a_dequeue_xmitbuf(struct rtw_tx_ring *ring); +extern int FreeXimtBuf(struct xmit_buf *pxmitbuf); +*/ +/* extern struct list_head *rtw_dequeue_xframe(struct xmit_priv *pxmitpriv, struct hw_xmit *phwxmit_i, sint entry); extern int32_t rtw_xmitframe_coalesce(_adapter *padapter, _pkt *pkt, struct xmit_frame *pxmitframe); -extern void rtl8195ab_xmitframe_resume(_adapter *padapter); +*/ extern int32_t rtl8195ab_mgnt_xmit(_adapter *padapter, struct xmit_frame *pmgntframe); extern int32_t rtl8195ab_hal_xmit(_adapter *padapter, struct xmit_frame *pxmitframe); extern int32_t rtl8195ab_hal_xmitframe_enqueue(_adapter *padapter, struct xmit_frame *pxmitframe); @@ -983,13 +1036,15 @@ extern int32_t rtl8195ab_hal_xmitframe_enqueue(_adapter *padapter, struct xmit_f //-------------------------------- // rtw_intfs.o // Function declarations +/* extern signed int rtw_init_default_value(_adapter *padapter); -extern void rtw_cancel_all_timer(_adapter *padapter); extern signed int rtw_free_drv_sw(_adapter *padapter); extern signed int rtw_reset_drv_sw(_adapter *padapter); extern signed int rtw_init_drv_sw(_adapter *padapter); extern int rtw_start_drv_threads(_adapter *padapter); +*/ extern void rtw_stop_drv_threads(_adapter *padapter); +extern void rtw_cancel_all_timer(_adapter *padapter); // Data declarations //-------------------------------- // rtw_mlme.o @@ -998,7 +1053,6 @@ extern void rtw_free_mlme_ie_data(uint8_t **ppie, uint32_t *plen); extern void rtw_init_mlme_timer(_adapter *padapter); extern void rtw_del_mlme_timer(struct mlme_priv *pmlmepriv); extern void reconnect_timer_hdl(void *FunctionContext); -extern uint8_t *rtw_init_mlme_priv(_adapter *padapter, int a2, int a3); extern void rtw_mfree_mlme_priv_lock(struct mlme_priv *pmlmepriv); extern void rtw_free_mlme_priv_ie_data(struct mlme_priv *pmlmepriv); extern void rtw_free_mlme_priv(struct mlme_priv *pmlmepriv); @@ -1006,21 +1060,12 @@ extern sint rtw_enqueue_network(_queue *queue, struct wlan_network *pnetwork); extern struct list_head *rtw_alloc_network(struct mlme_priv *pmlmepriv, _irqL a2, int a3); extern void rtw_free_network(struct mlme_priv *pmlmepriv, struct wlan_network *pnetwork, int isfreeall); extern void rtw_free_network_nolock(struct mlme_priv *pmlmepriv, struct wlan_network *pnetwork); -extern _queue *rtw_find_network(_queue *scanned_queue, uint8_t *addr); -extern void rtw_free_network_queue(_adapter *padapter, int isfreeall, int a3); extern sint rtw_if_up(_adapter *padapter); extern void rtw_generate_random_ibss(uint8_t *pibss); extern uint8_t *rtw_get_capability_from_ie(uint8_t *ie); -extern int rtw_get_capability(WLAN_BSSID_EX *bss, int a2, int a3); extern uint8_t *rtw_get_beacon_interval_from_ie(uint8_t *ie); -extern uint8_t *rtw_init_mlme_priv(_adapter *padapter, int a2, int a3); -extern uint32_t rtw_is_same_ibss(_adapter *adapter, struct wlan_network *pnetwork); -extern int is_same_network(WLAN_BSSID_EX *src, WLAN_BSSID_EX *dst, int a3); -extern struct list_head *rtw_get_oldest_wlan_network(_queue *scanned_queue); -extern void update_network(WLAN_BSSID_EX *dst, WLAN_BSSID_EX *src, _adapter *padapter, int update_ie); extern void rtw_update_scanned_network(_adapter *adapter, WLAN_BSSID_EX *target); extern void rtw_add_network(_adapter *adapter, WLAN_BSSID_EX *pnetwork, int a3); -extern void rtw_survey_event_callback(_adapter *adapter, uint8_t *pbuf, int a3); extern void rtw_free_assoc_resources(_adapter *adapter, int lock_scanned_queue); extern void rtw_indicate_connect(_adapter *padapter); extern void rtw_indicate_disconnect(_adapter *padapter); @@ -1030,93 +1075,77 @@ extern void rtw_stassoc_hw_rpt(_adapter *adapter, struct sta_info *psta); extern void rtw_stassoc_event_callback(_adapter *adapter, uint8_t *pbuf); extern void rtw_stadel_event_callback(_adapter *adapter, uint8_t *pbuf); extern void rtw_join_timeout_handler(_adapter *adapter, _irqL a2, int a3, int a4); -//void rtw_join_timeout_handler(void *FunctionContext, _irqL a2, int a3, int a4); -extern void rtw_scan_timeout_handler(_adapter *adapter, _irqL a2, int a3); -//void rtw_scan_timeout_handler(void *FunctionContext); extern void rtw_dynamic_check_timer_handlder(_adapter *adapter); extern void dynamic_check_timer_handlder(void *FunctionContext); -extern int rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv, _irqL a2, int a3); extern void rtw_surveydone_event_callback(_adapter *adapter, uint8_t *pbuf); extern sint rtw_set_auth(_adapter *adapter, struct security_priv *psecuritypriv); extern sint rtw_set_key(_adapter *adapter, struct security_priv *psecuritypriv, sint keyid, uint8_t set_tx); -extern unsigned int rtw_restruct_wmm_ie(_adapter *adapter, uint8_t *in_ie, uint8_t *out_ie, unsigned int in_len, unsigned int initial_out_len); extern sint rtw_restruct_sec_ie(_adapter *adapter, uint8_t *in_ie, uint8_t *out_ie, unsigned int in_len); extern void rtw_joinbss_reset(_adapter *padapter); extern unsigned int rtw_restructure_ht_ie(_adapter *padapter, uint8_t *in_ie, uint8_t *out_ie, unsigned int in_len, unsigned int *pout_len); extern void rtw_update_ht_cap(_adapter *padapter, uint8_t *pie, unsigned int ie_len); +extern sint rtw_linked_check(_adapter *padapter); +/* +extern uint8_t *rtw_init_mlme_priv(_adapter *padapter, int a2, int a3); +extern int rtw_get_capability(WLAN_BSSID_EX *bss, int a2, int a3); +extern _queue *rtw_find_network(_queue *scanned_queue, uint8_t *addr); +extern void rtw_free_network_queue(_adapter *padapter, int isfreeall, int a3); +extern uint8_t *rtw_init_mlme_priv(_adapter *padapter, int a2, int a3); +extern uint32_t rtw_is_same_ibss(_adapter *adapter, struct wlan_network *pnetwork); +extern int is_same_network(WLAN_BSSID_EX *src, WLAN_BSSID_EX *dst, int a3); +extern struct list_head *rtw_get_oldest_wlan_network(_queue *scanned_queue); +extern void update_network(WLAN_BSSID_EX *dst, WLAN_BSSID_EX *src, _adapter *padapter, int update_ie); +extern void rtw_survey_event_callback(_adapter *adapter, uint8_t *pbuf, int a3); +//void rtw_join_timeout_handler(void *FunctionContext, _irqL a2, int a3, int a4); +//void rtw_scan_timeout_handler(void *FunctionContext); +extern void rtw_scan_timeout_handler(_adapter *adapter, _irqL a2, int a3); +extern int rtw_select_and_join_from_scanned_queue(struct mlme_priv *pmlmepriv, _irqL a2, int a3); +extern unsigned int rtw_restruct_wmm_ie(_adapter *adapter, uint8_t *in_ie, uint8_t *out_ie, unsigned int in_len, unsigned int initial_out_len); extern void rtw_joinbss_event_prehandle(_adapter *adapter, uint8_t *pbuf, int a3); extern void rtw_issue_addbareq_cmd(_adapter *padapter, struct xmit_frame *pxmitframe); -extern sint rtw_linked_check(_adapter *padapter); extern sint rtw_buddy_adapter_up(sint result); extern sint check_buddy_fwstate(sint result, sint state); +*/ // Data declarations extern uint8_t auto_reconnect_running; extern void (*p_wlan_autoreconnect_hdl)(rtw_security_t, char *, int, char *, int, int); //-------------------------------- // rtw_mlme_ext.o // Function declarations -extern u8 *get_da(u8 *pframe); -extern u8 *get_sa(u8 *pframe); -extern signed int OnAction(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int DoReserved(_adapter *padapter, struct recv_frame *precv_frame); -extern void mgt_dispatcher(_adapter *padapter, struct mlme_handler *ptable, struct recv_frame *precv_frame); +/* +extern signed int OnAction(_adapter *padapter, union recv_frame *precv_frame); +extern signed int DoReserved(_adapter *padapter, union recv_frame *precv_frame); +extern void mgt_dispatcher(_adapter *padapter, struct mlme_handler *ptable, union recv_frame *precv_frame); extern int rtw_is_channel_set_contains_channel(RT_CHANNEL_INFO *channel_set, const uint32_t channel_num, int *pchannel_idx); -extern int init_hw_mlme_ext(_adapter *padapter); -extern unsigned int init_channel_set(_adapter *padapter, int ChannelPlan, RT_CHANNEL_INFO *channel_set); -extern void free_mlme_ext_priv(struct mlme_ext_priv *pmlmeext); -//void mgt_dispatcher(_adapter *padapter, struct recv_frame *precv_frame, int a3); -extern unsigned int OnAction_public(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int OnAction_p2p(_adapter *padapter, struct recv_frame *precv_frame); +//void mgt_dispatcher(_adapter *padapter, union recv_frame *precv_frame, int a3); +extern unsigned int OnAction_public(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnAction_p2p(_adapter *padapter, union recv_frame *precv_frame); extern struct xmit_frame *alloc_mgtxmitframe(struct xmit_priv *pxmitpriv); extern struct xmit_frame *alloc_FwRsvdframe(struct xmit_priv *pxmitpriv, uint32_t size); -extern void update_mgnt_tx_rate(_adapter *padapter, uint8_t rate); extern void update_mgntframe_attrib(_adapter *padapter, struct pkt_attrib *pattrib); -extern struct xmit_frame *rtw_build_mgnt_frame(_adapter *padapter, uint8_t *data, int len); extern void dump_mgntframe(_adapter *padapter, struct xmit_frame *pmgntframe); -extern int rtw_send_mgnt(_adapter *padapter, uint8_t *data, int len, uint16_t flags); -extern void issue_action_BSSCoexistPacket(_adapter *padapter); -extern uint32_t update_hidden_ssid(uint8_t *ies, uint32_t ies_len, int hidden_ssid_mode); -extern void issue_beacon(_adapter *padapter); -extern void issue_probersp(_adapter *padapter, u8 *da, uint8_t is_valid_p2p_probereq); -extern signed int OnProbeReq(_adapter *padapter, struct recv_frame *precv_frame); +extern signed int OnProbeReq(_adapter *padapter, union recv_frame *precv_frame); extern void issue_probereq(_adapter *padapter, NDIS_802_11_SSID *pssid, int blnbc); extern void issue_auth(_adapter *padapter, struct sta_info *psta, int status); -extern signed int OnAuth(_adapter *padapter, struct recv_frame *precv_frame); +extern signed int OnAuth(_adapter *padapter, union recv_frame *precv_frame); extern void issue_asocrsp(_adapter *padapter, uint16_t status, struct sta_info *pstat, int pkt_type); -extern void issue_assocreq(_adapter *padapter); -extern void issue_nulldata(_adapter *padapter, unsigned int power_mode); -extern void issue_qos_nulldata(_adapter *padapter, u8 *da, uint16_t tid); extern void issue_deauth(_adapter *padapter, u8 *da, uint32_t reason); -extern void issue_action_BA(_adapter *padapter, u8 *raddr, u8 action, uint16_t status); -extern signed int OnAction_back(_adapter *padapter, struct recv_frame *precv_frame); +extern signed int OnAction_back(_adapter *padapter, union recv_frame *precv_frame); extern signed int send_beacon(_adapter *padapter); -extern signed int collect_bss_info(_adapter *padapter, struct recv_frame *precv_frame, WLAN_BSSID_EX *bssid); -extern void start_clnt_auth(_adapter *padapter); -extern void start_clnt_assoc(_adapter *padapter); -extern signed int OnAuthClient(_adapter *padapter, struct recv_frame *precv_frame); -extern int report_scan_result_one(_adapter *padapter, WLAN_BSSID_EX *bssid); -extern int add_site_survey(_adapter *padapter, WLAN_BSSID_EX *bssid); -extern void report_survey_event(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int OnProbeRsp(_adapter *padapter, struct recv_frame *precv_frame); -extern void report_surveydone_event(_adapter *padapter); -extern void report_join_res(_adapter *padapter, int res); -extern signed int OnAssocRsp(_adapter *padapter, struct recv_frame *precv_frame); -extern void report_del_sta_event(_adapter *padapter, u8 *MacAddr, uint16_t reason); +extern signed int collect_bss_info(_adapter *padapter, union recv_frame *precv_frame, WLAN_BSSID_EX *bssid); +extern signed int OnAuthClient(_adapter *padapter, union recv_frame *precv_frame); +extern void report_survey_event(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnProbeRsp(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnAssocRsp(_adapter *padapter, union recv_frame *precv_frame); extern signed int receive_disconnect(_adapter *padapter, u8 *MacAddr, uint16_t reason); -extern signed int OnBeacon(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int OnDeAuth(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int OnDisassoc(_adapter *padapter, struct recv_frame *precv_frame); -extern void report_add_sta_event(_adapter *padapter, u8 *MacAddr, int cam_idx); -extern signed int OnAssocReq(_adapter *padapter, struct recv_frame *precv_frame); -extern signed int rtw_port_switch_chk(_adapter *adapter); +extern signed int OnBeacon(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnDeAuth(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnDisassoc(_adapter *padapter, union recv_frame *precv_frame); +extern signed int OnAssocReq(_adapter *padapter, union recv_frame *precv_frame); extern void update_sta_info(_adapter *padapter, struct sta_info *psta); -extern void mlmeext_sta_del_event_callback(_adapter *padapter); -extern void linked_info_dump(_adapter *padapter, _irqL a2, int a3); -extern void linked_rx_signal_strehgth_display(_adapter *padapter, int a2); extern void linked_status_chk(_adapter *padapter, int a2); extern void survey_timer_hdl(_adapter *padapter, int a2); //void survey_timer_hdl(void *FunctionContext); -extern void link_timer_hdl(_adapter *padapter); //void link_timer_hdl(void *FunctionContext); extern void addba_timer_hdl(struct sta_info *psta); extern int NULL_hdl(_adapter *padapter, uint8_t *pbuf); @@ -1131,12 +1160,42 @@ extern int tx_beacon_hdl(_adapter *padapter, u8 *pbuf, int a3); extern sint check_buddy_mlmeinfo_state(sint result, uint32_t state); extern void site_survey(_adapter *padapter, int a2, int a3); extern int sitesurvey_cmd_hdl(_adapter *padapter, uint8_t *pbuf, int a3); -extern int concurrent_chk_start_clnt_join(_adapter *padapter); extern void start_clnt_join(_adapter *padapter, int a2, int a3); extern signed int join_cmd_hdl(_adapter *padapter, uint8_t *pbuf, int a3); -extern void concurrent_chk_joinbss_done(_adapter *padapter, int join_res); extern void mlmeext_joinbss_event_callback(_adapter *padapter, int join_res, int a3); extern signed int set_chplan_hdl(_adapter *padapter, u8 *pbuf); +*/ +extern struct xmit_frame *rtw_build_mgnt_frame(_adapter *padapter, uint8_t *data, int len); +extern void update_mgnt_tx_rate(_adapter *padapter, uint8_t rate); +extern int rtw_send_mgnt(_adapter *padapter, uint8_t *data, int len, uint16_t flags); +extern void issue_action_BSSCoexistPacket(_adapter *padapter); +extern uint32_t update_hidden_ssid(uint8_t *ies, uint32_t ies_len, int hidden_ssid_mode); +extern void issue_beacon(_adapter *padapter); +extern void issue_probersp(_adapter *padapter, u8 *da, uint8_t is_valid_p2p_probereq); +extern void issue_assocreq(_adapter *padapter); +extern void issue_nulldata(_adapter *padapter, unsigned int power_mode); +extern void issue_qos_nulldata(_adapter *padapter, u8 *da, uint16_t tid); +extern void issue_action_BA(_adapter *padapter, u8 *raddr, u8 action, uint16_t status); +extern void start_clnt_auth(_adapter *padapter); +extern void start_clnt_assoc(_adapter *padapter); +extern int report_scan_result_one(_adapter *padapter, WLAN_BSSID_EX *bssid); +extern int add_site_survey(_adapter *padapter, WLAN_BSSID_EX *bssid); +extern void report_surveydone_event(_adapter *padapter); +extern void report_join_res(_adapter *padapter, int res); +extern void report_del_sta_event(_adapter *padapter, u8 *MacAddr, uint16_t reason); +extern void report_add_sta_event(_adapter *padapter, u8 *MacAddr, int cam_idx); +extern void mlmeext_sta_del_event_callback(_adapter *padapter); +extern void linked_info_dump(_adapter *padapter, _irqL a2, int a3); +extern void linked_rx_signal_strehgth_display(_adapter *padapter, int a2); +extern signed int rtw_port_switch_chk(_adapter *adapter); +extern void link_timer_hdl(_adapter *padapter); +extern u8 *get_da(u8 *pframe); +extern u8 *get_sa(u8 *pframe); +extern int concurrent_chk_start_clnt_join(_adapter *padapter); +extern void concurrent_chk_joinbss_done(_adapter *padapter, int join_res); +extern int init_hw_mlme_ext(_adapter *padapter); +extern unsigned int init_channel_set(_adapter *padapter, int ChannelPlan, RT_CHANNEL_INFO *channel_set); +extern void free_mlme_ext_priv(struct mlme_ext_priv *pmlmeext); extern void init_mlme_ext_timer(_adapter *padapter); extern int init_mlme_ext_priv(_adapter *padapter); // Data declarations @@ -1151,7 +1210,8 @@ extern const RT_CHANNEL_PLAN_2G RTW_ChannelPlan2G[8]; /* = { { 1u, 2u, 3u, 4u, 5u, 6u, 7u, 8u, 9u, 10u, 11u, 12u, 13u, 0u }, 13u }, { { 1u, 2u, 3u, 4u, 5u, 6u, 7u, 8u, 9u, 10u, 11u, 12u, 13u, 0u }, 13u } }; */ -extern const uint8_t WPS_OUI[4]; // = { 0u, 80u, 242u, 4u }; +extern const uint8_t WPS_OUI[4]; // = { 0u, 80u, 242u, 4u }; +typedef int (*mac_monitor_ptr)(uint8_t *, char); extern mac_monitor_ptr mac_monitor_callback; extern struct mlme_handler mlme_sta_tbl[14]; /* = { @@ -1222,16 +1282,18 @@ extern const struct fwevent wlanevents[24]; /* = extern u8 *get_hdr_bssid(u8 *pframe); extern int filter_packet(u8 *buf, int length); extern signed int promisc_get_encrypt(_adapter *padapter, uint8_t *bssid); -extern void promisc_info_get(_adapter *padapter, struct recv_frame *prframe, ieee80211_frame_info_t *ppromisc_info, int a4); extern void promisc_set_enable(_adapter *padapter, int enabled, int len_used); extern void promisc_deinit(_adapter *padapter); -extern int promisc_recv_func(_adapter *padapter, struct recv_frame *rframe); extern int promisc_set(rtw_rcr_level_t enabled, void (*callback)(u8 *, unsigned int, void *), int len_used); extern int promisc_set_mgntframe(int result); extern int is_promisc_enabled(); extern void promisc_issue_probereq(); extern void promisc_issue_probersp(u8 *da); -extern int promisc_get_fixed_channel(void *fixed_bssid, uint8_t *ssid, int *ssid_length); +extern int promisc_get_fixed_channel(void *fixed_bssid, uint8_t *ssid, int *ssid_length); +/* +extern void promisc_info_get(_adapter *padapter, union recv_frame *prframe, ieee80211_frame_info_t *ppromisc_info, int a4); +extern int promisc_recv_func(_adapter *padapter, union recv_frame *rframe); +*/ // Data declarations extern void (*promisc_callback_all)(u8 *, unsigned int, void *); extern _sema promisc_sema; @@ -1254,18 +1316,20 @@ extern void CalcMIC(OCTET_STRING EAPOLMsgSend, int algo, u8 *key, int keylen); extern int DecWPA2KeyData(WPA_STA_INFO *pStaInfo, u8 *key, int keylen, u8 *kek, int keklen, u8 *kout); extern int DecGTK(OCTET_STRING EAPOLMsgRecvd, u8 *kek, int keklen, int keylen, u8 *kout); extern void ToDrv_SetGTK(_adapter *padapter); +extern void ResendTimeout(void *task_psta, _irqL a2); +extern void set_wpa_global_PSK(u8 *key); +extern void psk_derive(_adapter *padapter, u8 *passphrase, u8 *ssid); +extern int tkip_send_mic_failure_report(_adapter *padapter); +/* extern void init_wpa_sta_info(_adapter *padapter, struct sta_info *psta); extern void SendEAPOL(_adapter *padapter, struct sta_info *psta, int resend); extern void ClientSendEAPOL(_adapter *padapter, struct sta_info *psta, int resend); -extern void ResendTimeout(void *task_psta, _irqL a2); extern void EAPOLKeyRecvd(_adapter *padapter, struct sta_info *psta); extern void ClientEAPOLKeyRecvd(_adapter *padapter, struct sta_info *psta); -extern void set_wpa_global_PSK(u8 *key); -extern void psk_derive(_adapter *padapter, u8 *passphrase, u8 *ssid); extern void psk_init(_adapter *padapter, u8 *pie, int ielen); extern int psk_strip_rsn_pairwise(uint8_t *ie, int ie_len); extern int psk_strip_wpa_pairwise(uint8_t *ie, int ie_len); -extern int tkip_send_mic_failure_report(_adapter *padapter); +*/ // Data declarations extern uint8_t psk_essid[2][36]; extern uint8_t psk_passphrase[2][65]; @@ -1279,8 +1343,11 @@ extern void ips_enter(_adapter *padapter); extern int ips_leave(_adapter *padapter); extern signed int rtw_pwr_unassociated_idle(_adapter *adapter); extern void rtw_ps_processor(_adapter *padapter); -extern void rtw_set_rpwm(PADAPTER padapter, uint8_t pslv); extern int PS_RDY_CHECK(_adapter *padapter); +extern int rtw_pm_set_tdma_param(_adapter *padapter, uint8_t tdma_slot_period, uint8_t tdma_rfon_period_len_1, uint8_t tdma_rfon_period_len_2, uint8_t tdma_rfon_period_len_3); +extern int rtw_pm_set_lps_dtim(_adapter *padapter, uint8_t lps_dtim); +/* +extern void rtw_set_rpwm(PADAPTER padapter, uint8_t pslv); extern void rtw_set_ps_mode(PADAPTER padapter, int ps_mode, int smart_ps, int bcn_ant_mode); extern int32_t LPS_RF_ON_check(PADAPTER padapter, uint32_t delay_ms); extern void LPS_Enter(PADAPTER padapter); @@ -1291,60 +1358,61 @@ extern void rtw_free_pwrctrl_priv(PADAPTER adapter); extern int rtw_pwr_wakeup(_adapter *padapter, uint32_t ips_deffer_ms, const char *caller); extern int rtw_pm_set_lps(_adapter *padapter, int mode); extern int rtw_pm_set_ips(_adapter *padapter, int mode); -extern int rtw_pm_set_tdma_param(_adapter *padapter, uint8_t tdma_slot_period, uint8_t tdma_rfon_period_len_1, uint8_t tdma_rfon_period_len_2, uint8_t tdma_rfon_period_len_3); -extern int rtw_pm_set_lps_dtim(_adapter *padapter, uint8_t lps_dtim); extern int rtw_pm_get_lps_dtim(_adapter *padapter); +*/ // Data declarations //-------------------------------- // rtw_recv.o // Function declarations -extern uint8_t *recvframe_pull(uint8_t *result, sint sz); -extern uint8_t *recvframe_pull_tail(uint8_t *result, sint sz); extern void rtw_signal_stat_timer_hdl(void *FunctionContext); extern void rtw_init_sta_recv_priv(struct sta_recv_priv *psta_recvpriv); extern sint rtw_init_recv_priv(struct recv_priv *precvpriv, _adapter *padapter); extern void rtw_mfree_recv_priv_lock(struct recv_priv *precvpriv); +extern void rtw_free_recvframe_queue(_queue *pframequeue, _queue *pfree_recv_queue); +extern union recv_frame *portctrl(_adapter *adapter, union recv_frame *precv_frame); +extern sint recv_decache(union recv_frame *precv_frame, uint8_t bretry, struct stainfo_rxcache *prxcache); +extern void process_pwrbit_data(_adapter *padapter, union recv_frame *precv_frame, int a3, int a4); +extern void process_wmmps_data(_adapter *padapter, union recv_frame *precv_frame); +extern void count_rx_stats(_adapter *padapter, union recv_frame *prframe, struct sta_info *sta); +extern sint sta2sta_data_frame(_adapter *adapter, union recv_frame *precv_frame, struct sta_info **psta, int a4); +extern sint ap2sta_data_frame(_adapter *adapter, union recv_frame *precv_frame, struct sta_info **psta); +extern sint sta2ap_data_frame(_adapter *adapter, union recv_frame *precv_frame, struct sta_info **psta); +extern sint validate_recv_ctrl_frame(_adapter *padapter, union recv_frame *precv_frame); +extern sint validate_recv_data_frame(_adapter *adapter, union recv_frame *precv_frame); +extern sint wlanhdr_to_ethhdr(union recv_frame *precvframe, int a2, int a3); +extern union recv_frame *recvframe_defrag(_adapter *adapter, _queue *defrag_q); +extern _queue *recvframe_chk_defrag(PADAPTER padapter, union recv_frame *precv_frame); +extern sint validate_recv_mgnt_frame(PADAPTER padapter, union recv_frame **pprecv_frame); +extern sint validate_recv_frame(_adapter *adapter, union recv_frame **pprecv_frame); +extern int amsdu_to_msdu(_adapter *padapter, union recv_frame *prframe); +extern int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, int seq_num); +extern int enqueue_reorder_recvframe(struct recv_reorder_ctrl *preorder_ctrl, union recv_frame *prframe); +extern int recv_indicatepkts_in_order(_adapter *padapter, struct recv_reorder_ctrl *preorder_ctrl, int bforced); +extern int recv_indicatepkt_reorder(_adapter *padapter, union recv_frame *prframe, int a3); +extern void rtw_free_recv_priv(struct recv_priv *precvpriv); +extern int recv_func_prehandle(_adapter *padapter, union recv_frame *rframe, int a3); +extern int recv_func_posthandle(_adapter *padapter, union recv_frame *prframe); +extern int recv_func(_adapter *padapter, union recv_frame *rframe, int a3); +extern void rtw_recv_tasklet(thread_context context); +/* +extern sint recvframe_chkmic(_adapter *adapter, union recv_frame *precvframe, int a3, int a4); +extern union recv_frame *decryptor(_adapter *padapter, union recv_frame *precv_frame); +extern uint8_t *recvframe_pull(uint8_t *result, sint sz); +extern uint8_t *recvframe_pull_tail(uint8_t *result, sint sz); extern struct list_head *rtw_alloc_recvframe(_queue *pfree_recv_queue); //struct list_head *rtw_alloc_recvframe(_queue *pfree_recv_queue, _irqL a2, int a3); -extern int rtw_free_recvframe(struct recv_frame *precvframe, _queue *pfree_recv_queue); -extern sint rtw_enqueue_recvframe(struct recv_frame *precvframe, _queue *queue); -extern sint rtw_enqueue_recvframe(struct recv_frame *precvframe, _queue *queue); -extern void rtw_free_recvframe_queue(_queue *pframequeue, _queue *pfree_recv_queue); +extern int rtw_free_recvframe(union recv_frame *precvframe, _queue *pfree_recv_queue); +extern sint rtw_enqueue_recvframe(union recv_frame *precvframe, _queue *queue); +extern sint rtw_enqueue_recvframe(union recv_frame *precvframe, _queue *queue); extern int rtw_free_uc_swdec_pending_queue(_adapter *adapter, _irqL a2, int a3); -extern void rtw_free_recv_priv(struct recv_priv *precvpriv); extern sint rtw_enqueue_recvbuf_to_head(struct recv_buf *precvbuf, _queue *queue); -extern uint32_t rtw_free_buf_pending_queue(_adapter *adapter); +extern uint32_t rtw_free_buf_pending_queue(_adapter *adapter); extern sint rtw_enqueue_recvbuf(struct recv_buf *precvbuf, _queue *queue); extern struct list_head *rtw_dequeue_recvbuf(_queue *queue, _irqL a2, int a3); -extern sint recvframe_chkmic(_adapter *adapter, struct recv_frame *precvframe, int a3, int a4); -extern struct recv_frame *decryptor(_adapter *padapter, struct recv_frame *precv_frame); -extern struct recv_frame *portctrl(_adapter *adapter, struct recv_frame *precv_frame); -extern sint recv_decache(struct recv_frame *precv_frame, uint8_t bretry, struct stainfo_rxcache *prxcache); -extern void process_pwrbit_data(_adapter *padapter, struct recv_frame *precv_frame, int a3, int a4); -extern void process_wmmps_data(_adapter *padapter, struct recv_frame *precv_frame); -extern void count_rx_stats(_adapter *padapter, struct recv_frame *prframe, struct sta_info *sta); -extern sint sta2sta_data_frame(_adapter *adapter, struct recv_frame *precv_frame, struct sta_info **psta, int a4); -extern sint ap2sta_data_frame(_adapter *adapter, struct recv_frame *precv_frame, struct sta_info **psta); -extern sint sta2ap_data_frame(_adapter *adapter, struct recv_frame *precv_frame, struct sta_info **psta); -extern sint validate_recv_ctrl_frame(_adapter *padapter, struct recv_frame *precv_frame); -extern sint validate_recv_data_frame(_adapter *adapter, struct recv_frame *precv_frame); -extern sint wlanhdr_to_ethhdr(struct recv_frame *precvframe, int a2, int a3); -extern struct recv_frame *recvframe_defrag(_adapter *adapter, _queue *defrag_q); -extern _queue *recvframe_chk_defrag(PADAPTER padapter, struct recv_frame *precv_frame); -extern sint validate_recv_mgnt_frame(PADAPTER padapter, struct recv_frame **pprecv_frame); -extern sint validate_recv_frame(_adapter *adapter, struct recv_frame **pprecv_frame); -extern int amsdu_to_msdu(_adapter *padapter, struct recv_frame *prframe); -extern int check_indicate_seq(struct recv_reorder_ctrl *preorder_ctrl, int seq_num); -extern int enqueue_reorder_recvframe(struct recv_reorder_ctrl *preorder_ctrl, struct recv_frame *prframe); -extern int recv_indicatepkts_in_order(_adapter *padapter, struct recv_reorder_ctrl *preorder_ctrl, int bforced); -extern int recv_indicatepkt_reorder(_adapter *padapter, struct recv_frame *prframe, int a3); extern void rtw_reordering_ctrl_timeout_handler(void *pcontext, _irqL a2); -extern int process_recv_indicatepkts(_adapter *padapter, struct recv_frame *prframe, int a3); -extern int recv_func_prehandle(_adapter *padapter, struct recv_frame *rframe, int a3); -extern int recv_func_posthandle(_adapter *padapter, struct recv_frame *prframe); -extern int recv_func(_adapter *padapter, struct recv_frame *rframe, int a3); -extern int32_t rtw_recv_entry(struct recv_frame *precvframe, int a2, int a3); -extern void rtw_recv_tasklet(thread_context context); +extern int process_recv_indicatepkts(_adapter *padapter, union recv_frame *prframe, int a3); +extern int32_t rtw_recv_entry(union recv_frame *precvframe, int a2, int a3); +*/ // Data declarations extern const uint8_t SNAP_ETH_TYPE_APPLETALK_AARP[2]; // = { 128u, 243u }; extern const uint8_t SNAP_ETH_TYPE_IPX[2]; // = { 129u, 55u }; @@ -1359,24 +1427,27 @@ extern const uint8_t oui_rfc1042[3]; // = { 0u, 0u, 0u }; // Function declarations extern void rtw_wep_encrypt(_adapter *padapter, uint8_t *pxmitframe); extern void rtw_wep_decrypt(_adapter *padapter, uint8_t *precvframe); +extern void rtw_use_tkipkey_handler(void *FunctionContext); +extern void rtw_free_sec_priv(struct security_priv *psecpriv); +/* extern signed int rtw_tkip_encrypt(_adapter *padapter, uint8_t *pxmitframe); extern int rtw_tkip_decrypt(_adapter *padapter, uint8_t *precvframe); extern signed int rtw_aes_encrypt(_adapter *padapter, uint8_t *pxmitframe, int a3, int a4); extern int rtw_aes_decrypt(_adapter *padapter, uint8_t *precvframe, int a3, int a4); -extern void rtw_use_tkipkey_handler(void *FunctionContext); extern int rtw_init_sec_priv(_adapter *padapter); -extern void rtw_free_sec_priv(struct security_priv *psecpriv); +*/ // Data declarations //-------------------------------- // rtw_sta_mgt.o // Function declarations -extern int wifi_mac_hash(uint8_t *mac); extern void rtw_init_stainfo(struct sta_info *psta); extern int rtw_init_sta_priv(_adapter *padapter); extern void rtw_free_sta_xmit_priv_lock(struct sta_xmit_priv *psta_xmitpriv); extern void rtw_mfree_stainfo(struct sta_info *psta); extern void rtw_mfree_sta_priv_lock(struct sta_priv *pstapriv); extern signed int rtw_free_sta_priv(struct sta_priv *pstapriv); +/* +extern int wifi_mac_hash(uint8_t *mac); extern void init_addba_retry_timer(_adapter *padapter, struct sta_info *psta); extern struct sta_info *rtw_alloc_stainfo(struct sta_priv *pstapriv, uint8_t *hwaddr, _irqL a3, _irqL a4); extern signed int rtw_free_stainfo(_adapter *padapter, struct sta_info *psta, int a3); @@ -1384,6 +1455,7 @@ extern struct sta_info *rtw_get_stainfo(struct sta_priv *pstapriv, uint8_t *hwad extern signed int rtw_init_bcmc_stainfo(_adapter *padapter, int a2, int a3); extern struct sta_info *rtw_get_bcmc_stainfo(_adapter *padapter, int a2, int a3); extern void rtw_free_all_stainfo(_adapter *padapter, _irqL a2, int a3); +*/ // Data declarations //-------------------------------- // rtw_xmit.o @@ -1392,6 +1464,16 @@ extern void init_txservq(struct tx_servq *ptxservq); extern void set_qos(struct pkt_file *ppktfile, struct pkt_attrib *pattrib); extern void rtw_init_sta_xmit_priv(struct sta_xmit_priv *psta_xmitpriv); extern void rtw_mfree_xmit_priv_lock(struct xmit_priv *pxmitpriv); +extern void rtw_update_protection(_adapter *padapter, uint8_t *ie, unsigned int ie_len); +extern void rtw_free_xmitframe_queue(struct xmit_priv *pxmitpriv, _queue *pframequeue); +extern void rtw_alloc_hwxmits(_adapter *padapter); +extern void rtw_free_hwxmits(_adapter *padapter); +extern void rtw_free_xmit_priv(struct xmit_priv *pxmitpriv); +extern int32_t rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, _adapter *padapter); +extern void dequeue_xmitframes_to_sleeping_queue(_adapter *padapter, struct sta_info *psta, _queue *pframequeue); +extern void rtw_xmit_tasklet(thread_context context); +extern BOOL rtw_sctx_chk_waring_status(int status); +/* extern int qos_acm(uint8_t acm_mask, int priority); extern int32_t xmitframe_addmic(_adapter *padapter, struct xmit_frame *pxmitframe); extern int32_t xmitframe_swencrypt(_adapter *padapter, struct xmit_frame *pxmitframe); @@ -1401,34 +1483,26 @@ extern int32_t rtw_txframes_sta_ac_pending(_adapter *padapter, struct pkt_attrib extern void rtw_txframes_update_attrib_vcs_info(_adapter *padapter, struct xmit_frame *pxmitframe); extern int rtw_calculate_wlan_pkt_size_by_attribue(struct pkt_attrib *pattrib); extern int32_t rtw_put_snap(uint8_t *data, int h_proto); -extern void rtw_update_protection(_adapter *padapter, uint8_t *ie, unsigned int ie_len); extern void rtw_count_tx_stats(PADAPTER padapter, struct xmit_frame *pxmitframe, uint64_t sz); extern int32_t rtw_free_xmitbuf_ext(struct xmit_priv *pxmitpriv, struct xmit_buf *pxmitbuf, int a3); extern struct list_head *rtw_alloc_xmitframe(struct xmit_priv *pxmitpriv, _irqL a2); extern int32_t rtw_free_xmitframe(struct xmit_priv *pxmitpriv, struct xmit_frame *pxmitframe); -extern void rtw_free_xmitframe_queue(struct xmit_priv *pxmitpriv, _queue *pframequeue); extern struct tx_servq *rtw_get_sta_pending(_adapter *padapter, struct sta_info *psta, sint up, uint8_t *ac); extern struct sta_info *rtw_xmit_classifier(_adapter *padapter, struct xmit_frame *pxmitframe); extern BOOL rtw_xmitframe_enqueue(_adapter *padapter, struct xmit_frame *pxmitframe); -extern void rtw_alloc_hwxmits(_adapter *padapter); -extern void rtw_free_hwxmits(_adapter *padapter); -extern void rtw_free_xmit_priv(struct xmit_priv *pxmitpriv); extern void rtw_init_hwxmits(struct hw_xmit *phwxmit, sint entry); -extern int32_t rtw_init_xmit_priv(struct xmit_priv *pxmitpriv, _adapter *padapter); extern signed int rtw_get_ff_hwaddr(struct xmit_frame *pxmitframe); extern sint xmitframe_enqueue_for_sleeping_sta(_adapter *padapter, struct xmit_frame *pxmitframe); -extern void dequeue_xmitframes_to_sleeping_queue(_adapter *padapter, struct sta_info *psta, _queue *pframequeue); extern void stop_sta_xmit(_adapter *padapter, struct sta_info *psta); extern void wakeup_sta_to_xmit(_adapter *padapter, struct sta_info *psta); extern void xmit_delivery_enabled_frames(_adapter *padapter, struct sta_info *psta, int a3); -extern void rtw_xmit_tasklet(thread_context context); extern int32_t rtw_xmit(_adapter *padapter, _pkt **ppkt); -extern BOOL rtw_sctx_chk_waring_status(int status); extern void rtw_sctx_done_err(struct submit_ctx **sctx, int status); extern struct list_head *rtw_alloc_xmitbuf(struct xmit_priv *pxmitpriv, _irqL a2); extern int32_t rtw_free_xmitbuf(struct xmit_priv *pxmitpriv, struct xmit_buf *pxmitbuf, int a3); extern struct xmit_buf *rtw_alloc_xmitbuf_ext(struct xmit_priv *pxmitpriv, uint32_t size, int a3); extern void rtw_sctx_done(struct submit_ctx **sctx); +*/ // Data declarations //-------------------------------- // phydm_RegConfig8195A.o @@ -1438,7 +1512,9 @@ extern void odm_ConfigRF_RadioA_8195A(PDM_ODM_T pDM_Odm, u4Byte Addr, u4Byte Dat extern void odm_ConfigBB_AGC_8195A(PDM_ODM_T pDM_Odm, u4Byte Addr, u4Byte Bitmask, u4Byte Data); extern void odm_ConfigBB_PHY_REG_PG_8195A(PDM_ODM_T pDM_Odm, u4Byte Band, u4Byte RfPath, u4Byte TxNum, u4Byte Addr, u4Byte Bitmask, u4Byte Data); extern void odm_ConfigBB_PHY_8195A(PDM_ODM_T pDM_Odm, u4Byte Addr, u4Byte Bitmask, u4Byte Data); +/* extern void odm_ConfigBB_TXPWR_LMT_8195A(PDM_ODM_T pDM_Odm, int Regulation, int Band, int Bandwidth, u1Byte RateSection, u1Byte RfPath, u1Byte Channel, u1Byte PowerLimit); +*/ // Data declarations //-------------------------------- // lxbus_hci_intf.o @@ -1447,12 +1523,16 @@ extern struct dvobj_priv *hci_lxbus_dvobj_init(); extern void hci_lxbus_dvobj_deinit(struct dvobj_priv *dvobj); extern void hci_lxbus_dvobj_request_irq(struct dvobj_priv *dvobj); extern void hci_lxbus_free_irq(struct dvobj_priv *dvobj); +/* extern void hci_lxbus_intf_stop(PADAPTER padapter); +*/ // Data declarations //-------------------------------- // lxbus_intf.o // Function declarations +/* extern signed int lextra_bus_dma_Interrupt(void *data); +*/ // Data declarations //-------------------------------- // lxbus_ops.o @@ -1465,14 +1545,20 @@ extern uint32_t bus_read32(struct dvobj_priv *pintfhdl, uint32_t addr, int32_t * extern int bus_read16(struct dvobj_priv *pintfhdl, uint32_t addr, int32_t *err); extern int bus_read8(struct dvobj_priv *pintfhdl, uint32_t addr, int32_t *err); extern void rtl8195a_free_tx_ring(_adapter *padapter, unsigned int prio); -extern signed int rtl8195a_init_desc_ring(_adapter *padapter); -extern signed int rtl8195a_free_desc_ring(_adapter *padapter); -extern void rtl8195a_reset_desc_ring(_adapter *padapter, _irqL a2, int a3); extern void InitLxDmaRtl8195a(_adapter *Adapter); extern void rtl8195a_prepare_bcn_tasklet(void *priv); extern signed int get_txdesc_buf_addr(int ff_hwaddr); extern signed int rtl8195a_check_txdesc_closed(_adapter *padapter, uint32_t queue_idx, uint32_t index); extern void rtl8195a_tx_isr(PADAPTER Adapter, int prio); +extern signed int CheckRxTgRtl8195a(_adapter *padapter, uint8_t *rx_desc, uint16_t rx_queue_idx); +extern int rtl8192ee_check_rxdesc_remain(_adapter *padapter, int rx_queue_idx); +extern void rtl8195a_recv_tasklet(void *priv); +extern void rtl8195a_xmit_tasklet(void *priv); +extern void lxbus_set_intf_ops(struct _io_ops *pops); +/* +extern signed int rtl8195a_init_desc_ring(_adapter *padapter); +extern signed int rtl8195a_free_desc_ring(_adapter *padapter); +extern void rtl8195a_reset_desc_ring(_adapter *padapter, _irqL a2, int a3); extern signed int InterruptRecognized8195a(PADAPTER Adapter); extern void InitInterrupt8195a(PADAPTER padapter); extern void EnableDMA8195a(PADAPTER padapter); @@ -1480,13 +1566,9 @@ extern void EnableInterrupt8195a(PADAPTER padapter); extern void DisableDMA8195a(PADAPTER padapter); extern void DisableInterrupt8195a(PADAPTER padapter); extern void UpdateInterruptMask8195a(PADAPTER Adapter, uint32_t *pAddMSRB, uint32_t *pRemoveMSR); -extern signed int CheckRxTgRtl8195a(_adapter *padapter, uint8_t *rx_desc, uint16_t rx_queue_idx); -extern int rtl8192ee_check_rxdesc_remain(_adapter *padapter, int rx_queue_idx); -extern void rtl8195a_recv_tasklet(void *priv); extern void rtl8195a_tx_int_handler(_adapter *padapter, int a2, int a3); extern int32_t InterruptHandle8195a(_adapter *padapter, int a2, int a3); -extern void rtl8195a_xmit_tasklet(void *priv); -extern void lxbus_set_intf_ops(struct _io_ops *pops); +*/ // Data declarations extern uint8_t rx_ring_pool[4][2104]; extern u16 CSWTCH_48[8]; // = { 928, 932, 936, 940, 936, 944, 952, 936 }; @@ -1518,7 +1600,9 @@ extern BOOL Phydm_CalNHMcnt(PVOID pDM_VOID); extern void Phydm_CheckEnvironment(PVOID pDM_VOID); extern void Phydm_SearchPwdBLowerBound(PVOID pDM_VOID); extern void Phydm_AdaptivityInit(PVOID pDM_VOID); +/* extern void Phydm_Adaptivity(PVOID pDM_VOID, int IGI); +*/ // Data declarations //-------------------------------- // PhyDM_AntDiv.o @@ -1530,7 +1614,9 @@ extern void ODM_SwAntDivRestAfterLink(PDM_ODM_T pDM_Odm); // Function declarations extern void ODM_CfoTrackingInit(PVOID pDM_VOID); extern void ODM_CfoTracking(PVOID pDM_VOID); +/* extern void ODM_ParsingCFO(PVOID pDM_VOID, PVOID pPktinfo_VOID, s1Byte *pcfotail); +*/ // Data declarations //-------------------------------- // phydm_debug.o @@ -1603,7 +1689,8 @@ extern void odm_TXPowerTrackingThermalMeterInit(PVOID pDM_VOID); extern void odm_TXPowerTrackingCheckIOT(PVOID pDM_VOID); extern void ODM_TXPowerTrackingCheck(PVOID pDM_VOID); // Data declarations -extern const u4Byte OFDMSwingTable_New[43]; /* = +/* +extern const u4Byte OFDMSwingTable_New[43] = { 188743725u, 201326640u, 213909555u, 226492470u, 239075385u, 251658300u, 268435520u, 285212740u, 301989960u, 318767180u, 339738705u, 360710230u, 381681755u, 402653280u, @@ -1628,31 +1715,33 @@ extern u4Byte ODM_Get_Rate_Bitmap(PVOID pDM_VOID, u4Byte macid, u4Byte ra_mask, //------------------------------------------------------------------------- // hal_com_phycfg.o // Function declarations +/* extern int PHY_GetTxPowerByRateBase(PADAPTER Adapter, int Band, int RfPath, int TxNum, RATE_SECTION RateSection); -extern void phy_SetTxPowerByRateBase(PADAPTER Adapter, int Band, int RfPath, RATE_SECTION RateSection, uint8_t TxNum, uint8_t Value); extern void PHY_GetRateValuesOfTxPowerByRate(PADAPTER pAdapter, uint32_t RegAddr, uint32_t BitMask, uint32_t Value, uint8_t *RateIndex, int8_t *PwrByRateVal, uint8_t *RateNum); -extern void PHY_StoreTxPowerByRateNew(PADAPTER pAdapter, uint32_t Band, uint32_t RfPath, uint32_t TxNum, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); -extern void PHY_InitTxPowerByRate(PADAPTER pAdapter); extern void PHY_StoreTxPowerByRate(PADAPTER pAdapter, uint32_t Band, uint32_t RfPath, uint32_t TxNum, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); -extern signed int phy_GetChnlIndex(int Channel, uint8_t *ChannelIdx); extern signed int PHY_GetTxPowerIndexBase(PADAPTER pAdapter, int RFPath, int Rate, CHANNEL_WIDTH BandWidth, uint8_t Channel, PBOOLEAN bIn24G); extern PADAPTER PHY_GetTxPowerTrackingOffset(PADAPTER result, int RFPath, int Rate); extern int PHY_GetRateIndexOfTxPowerByRate(uint8_t Rate); extern unsigned int PHY_GetTxPowerByRate(PADAPTER pAdapter, int Band, int RFPath, int TxNum, uint8_t Rate); -extern void phy_StoreTxPowerByRateBase(PADAPTER pAdapter); extern void PHY_SetTxPowerByRate(PADAPTER pAdapter, int Band, int RFPath, int TxNum, uint8_t Rate, int8_t Value); -extern void phy_ConvertTxPowerByRateInDbmToRelativeValues(PADAPTER pAdapter); -extern void PHY_TxPowerByRateConfiguration(PADAPTER pAdapter); extern void PHY_SetTxPowerIndexByRateArray(PADAPTER pAdapter, int RFPath, CHANNEL_WIDTH BandWidth, uint8_t Channel, uint8_t *Rates, uint8_t RateArraySize); extern void PHY_SetTxPowerIndexByRateSection(PADAPTER pAdapter, int RFPath, uint8_t Channel, int RateSection); extern void PHY_SetTxPowerLevelByPath(PADAPTER Adapter, uint8_t channel, int path); -extern signed int phy_GetWorldWideLimit(int8_t *LimitTable, int regulation, int16_t channel); -extern int phy_GetChannelIndexOfTxPowerLimit(int Band, uint8_t Channel); extern int PHY_GetTxPowerLimit(PADAPTER Adapter, uint32_t RegPwrTblSel, BAND_TYPE Band, CHANNEL_WIDTH Bandwidth, uint8_t RfPath, uint8_t DataRate, uint8_t Channel); -extern void PHY_ConvertTxPowerLimitToPowerIndex(PADAPTER Adapter); -extern void PHY_InitTxPowerLimit(PADAPTER Adapter); extern void PHY_SetTxPowerLimit(PADAPTER Adapter, int Regulation, int Band, int Bandwidth, uint8_t RateSection, uint8_t RfPath, uint8_t Channel, uint8_t PowerLimit); extern int PHY_GetTxPowerIndex(PADAPTER pAdapter, int RFPath, int Rate, CHANNEL_WIDTH BandWidth, uint8_t Channel); +*/ +extern void PHY_ConvertTxPowerLimitToPowerIndex(PADAPTER Adapter); +extern void PHY_InitTxPowerLimit(PADAPTER Adapter); +extern void phy_StoreTxPowerByRateBase(PADAPTER pAdapter); +extern void phy_ConvertTxPowerByRateInDbmToRelativeValues(PADAPTER pAdapter); +extern void PHY_TxPowerByRateConfiguration(PADAPTER pAdapter); +extern signed int phy_GetWorldWideLimit(int8_t *LimitTable, int regulation, int16_t channel); +extern int phy_GetChannelIndexOfTxPowerLimit(int Band, uint8_t Channel); +extern void PHY_StoreTxPowerByRateNew(PADAPTER pAdapter, uint32_t Band, uint32_t RfPath, uint32_t TxNum, uint32_t RegAddr, uint32_t BitMask, uint32_t Data); +extern void phy_SetTxPowerByRateBase(PADAPTER Adapter, int Band, int RfPath, RATE_SECTION RateSection, uint8_t TxNum, uint8_t Value); +extern void PHY_InitTxPowerByRate(PADAPTER pAdapter); +extern signed int phy_GetChnlIndex(int Channel, uint8_t *ChannelIdx); // Data declarations //------------------------------------------------------------------------- // Data declarations @@ -1683,7 +1772,6 @@ extern signed int Hal_EfuseWordEnableDataWrite(PADAPTER padapter, int efuse_addr extern void Hal_EfusePowerSwitch(PADAPTER padapter, int bWrite, int PwrState); extern void rtl8195a_free_hal_data(PADAPTER padapter); extern void StopTxBeacon(PADAPTER padapter); -extern void SetHalODMVar8195A(PADAPTER Adapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, int bSet); extern void rtl8195a_start_thread(_adapter *padapter); extern void rtl8195a_stop_thread(_adapter *padapter); extern void Hal_ReadEFuse(PADAPTER padapter, int efuseType, int _offset, int _size_byte, uint8_t *pbuf, uint8_t bPseudoTest); @@ -1693,36 +1781,43 @@ extern void rtw_flash_map_erase(PADAPTER padapter, int a2, int a3, uint32_t a4); extern int32_t Hal_EfusePgPacketWrite(PADAPTER padapter, uint8_t offset, int word_en, uint8_t *pData, uint8_t bPseudoTest); extern int Hal_EfuseGetCurrentSize(PADAPTER pAdapter, uint8_t efuseType, int bPseudoTest); extern signed int rtw_flash_map_write(PADAPTER padapter, uint16_t addr, uint16_t cnts, uint8_t *data); -extern int32_t rtl8195a_FirmwareDownload(PADAPTER padapter, BOOLEAN bUsedWoWLANFw); extern void rtl8195a_InitBeaconParameters(PADAPTER padapter); extern void InitBurstPktLen_8195AB(PADAPTER Adapter); extern void rtl8195a_set_hal_ops(struct hal_ops *pHalFunc); -extern int32_t rtl8195a_InitLLTTable(PADAPTER padapter); extern signed int Hal_GetChnlGroup8195A(int Channel, uint8_t *pGroup); +extern void Hal_EfuseParseIDCode(PADAPTER padapter, uint8_t *hwinfo); +extern void Hal_ReadPowerValueFromPROM_8195A(PADAPTER Adapter, PTxPowerInfo24G pwrInfo24G, uint8_t *PROMContent, int AutoLoadFail); +extern void Hal_EfuseParsePackageType_8195A(PADAPTER pAdapter, uint8_t *hwinfo, int a3); +extern void Hal_EfuseParseChnlPlan_8195A(PADAPTER padapter, uint8_t *hwinfo, BOOLEAN AutoLoadFail); +extern int BWMapping_8195A(PADAPTER Adapter, struct pkt_attrib *pattrib); +extern signed int SCMapping_8195A(PADAPTER Adapter, struct pkt_attrib *pattrib); +extern void rtl8195a_update_txdesc(struct xmit_frame *pxmitframe, uint8_t *pbuf); +/* +extern void SetHalODMVar8195A(PADAPTER Adapter, HAL_ODM_VARIABLE eVariable, PVOID pValue1, int bSet); +extern int32_t rtl8195a_FirmwareDownload(PADAPTER padapter, BOOLEAN bUsedWoWLANFw); +extern int32_t rtl8195a_InitLLTTable(PADAPTER padapter); extern signed int rtw_flash_read(PADAPTER padapter, int addr, int cnts, uint8_t *data); extern signed int rtw_flash_write(PADAPTER padapter, int addr, int cnts, uint8_t *data); extern int rtw_config_map_read(PADAPTER padapter, int addr, int cnts, uint8_t *data, uint8_t efuse); extern int rtw_config_map_write(PADAPTER padapter, int addr, int cnts, uint8_t *data, uint8_t efuse); extern void Hal_InitPGData(PADAPTER padapter, uint8_t *PROMContent, int a3, int a4); -extern void Hal_EfuseParseIDCode(PADAPTER padapter, uint8_t *hwinfo); -extern void Hal_ReadPowerValueFromPROM_8195A(PADAPTER Adapter, PTxPowerInfo24G pwrInfo24G, uint8_t *PROMContent, int AutoLoadFail); extern void Hal_EfuseParseTxPowerInfo_8195A(PADAPTER padapter, uint8_t *PROMContent, int AutoLoadFail); extern void Hal_EfuseParseEEPROMVer_8195A(PADAPTER padapter, uint8_t *hwinfo, int AutoLoadFail); -extern void Hal_EfuseParsePackageType_8195A(PADAPTER pAdapter, uint8_t *hwinfo, int a3); -extern void Hal_EfuseParseChnlPlan_8195A(PADAPTER padapter, uint8_t *hwinfo, BOOLEAN AutoLoadFail); extern void Hal_EfuseParseCustomerID_8195A(PADAPTER padapter, uint8_t *hwinfo, int AutoLoadFail); extern void Hal_EfuseParseXtal_8195A(PADAPTER pAdapter, uint8_t *hwinfo, int AutoLoadFail); extern void Hal_EfuseParseThermalMeter_8195A(PADAPTER padapter, uint8_t *PROMContent, int AutoLoadFail); extern void Hal_ReadRFGainOffset(PADAPTER Adapter, uint8_t *PROMContent, int AutoloadFail); -extern int BWMapping_8195A(PADAPTER Adapter, struct pkt_attrib *pattrib); -extern signed int SCMapping_8195A(PADAPTER Adapter, struct pkt_attrib *pattrib); -extern void rtl8195a_update_txdesc(struct xmit_frame *pxmitframe, uint8_t *pbuf); extern void rtl8195a_fill_fake_txdesc(PADAPTER padapter, uint8_t *pDesc, uint32_t BufferLen, int IsPsPoll, uint8_t IsBTQosNull, uint8_t bDataFrame); extern void SetHwReg8195A(PADAPTER padapter, int variable, uint8_t *val); extern void GetHwReg8195A(PADAPTER padapter, int variable, uint8_t *val); extern signed int SetHalDefVar8195A(PADAPTER padapter, HAL_DEF_VARIABLE variable, void *pval); extern signed int GetHalDefVar8195A(PADAPTER padapter, HAL_DEF_VARIABLE variable, void *pval); +*/ // Data declarations +struct map_mask_s { + uint16_t mask_start; + uint16_t mask_end; +}; extern const struct map_mask_s efuse_map_mask[4]; // = { { 32u, 207u }, { 220u, 221u }, { 282u, 311u }, { 313u, 319u } }; extern const struct map_mask_s flash_map_mask[2]; // = { { 32u, 311u }, { 313u, 319u } }; //-------------------------------- @@ -1731,24 +1826,26 @@ extern const struct map_mask_s flash_map_mask[2]; // = { { 32u, 311u }, { 313u, extern int rtw_ht_operation_update(_adapter *padapter); extern void associated_clients_update_0(_adapter *padapter, int updated, int a3); extern signed int chk_sta_is_alive(struct sta_info *psta); -extern void add_RATid(_adapter *padapter, struct sta_info *psta, int rssi_level); -extern void update_sta_info_apmode(_adapter *padapter, struct sta_info *psta, int a3); -extern void update_beacon(_adapter *padapter, int ie_id, uint8_t *oui, uint8_t tx); extern int rtw_check_beacon_data(_adapter *padapter, uint8_t *pbuf, int len); -extern void associated_clients_update(_adapter *padapter, int updated, int a3); extern void bss_cap_update_on_sta_join(_adapter *padapter, struct sta_info *psta); -extern signed int bss_cap_update_on_sta_leave(_adapter *padapter, struct sta_info *psta); -extern signed int ap_free_sta(_adapter *padapter, struct sta_info *psta, int reason); extern void expire_timeout_chk(_adapter *padapter); extern int rtw_sta_flush(_adapter *padapter); -extern void free_mlme_ap_info(_adapter *padapter, _irqL a2); extern void sta_info_update(_adapter *padapter, struct sta_info *psta); extern void ap_sta_info_defer_update(_adapter *padapter, struct sta_info *psta); extern void start_ap_mode(_adapter *padapter); extern void init_mlme_ap_info(_adapter *padapter); +extern int set_hidden_ssid(const char *ifname, uint8_t value); +/* +extern void add_RATid(_adapter *padapter, struct sta_info *psta, int rssi_level); +extern void update_sta_info_apmode(_adapter *padapter, struct sta_info *psta, int a3); +extern void update_beacon(_adapter *padapter, int ie_id, uint8_t *oui, uint8_t tx); +extern void associated_clients_update(_adapter *padapter, int updated, int a3); +extern signed int bss_cap_update_on_sta_leave(_adapter *padapter, struct sta_info *psta); +extern signed int ap_free_sta(_adapter *padapter, struct sta_info *psta, int reason); +extern void free_mlme_ap_info(_adapter *padapter, _irqL a2); extern void stop_ap_mode(_adapter *padapter, _irqL a2); extern uint32_t rtw_generate_bcn_ie(_adapter *adapter, uint8_t *ssid, int ssid_len, uint8_t *ie); -extern int set_hidden_ssid(const char *ifname, uint8_t value); +*/ // Data declarations //-------------------------------- diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm.h index e7f015e..ac34dbb 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm.h @@ -1277,7 +1277,7 @@ typedef struct DM_Out_Source_Dynamic_Mechanism_Structure //-----------HOOK BEFORE REG INIT-----------// // ODM Platform info AP/ADSL/CE/MP = 1/2/3/4 u1Byte SupportPlatform; - // ODM Support Ability DIG/RATR/TX_PWR_TRACK/ KK = 1/2/3/K + // ODM Support Ability DIG/RATR/TX_PWR_TRACK/ �K�K = 1/2/3/�K u4Byte SupportAbility; // ODM PCIE/USB/SDIO = 1/2/3 u1Byte SupportInterface; @@ -1491,7 +1491,7 @@ typedef struct DM_Out_Source_Dynamic_Mechanism_Structure PROM_INFO pROMInfo; FALSE_ALARM_STATISTICS FalseAlmCnt; - CFO_TRACKING DM_CfoTrack; + CFO_TRACKING DM_CfoTrack; FALSE_ALARM_STATISTICS FlaseAlmCntBuddyAdapter; //#ifdef CONFIG_ANTENNA_DIVERSITY diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm_types.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm_types.h index 71cbafc..07332d5 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm_types.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/phydm_types.h @@ -375,10 +375,10 @@ typedef enum _RT_SPINLOCK_TYPE{ typedef unsigned short u2Byte,*pu2Byte; typedef unsigned int u4Byte,*pu4Byte; typedef unsigned long long u8Byte,*pu8Byte; - typedef signed char s1Byte,*ps1Byte; /* GCC ROM char = unsigned char */ + typedef signed char s1Byte,*ps1Byte; /* GCC ROM char = unsigned char */ typedef signed short s2Byte,*ps2Byte; - typedef signed long s4Byte,*ps4Byte; - typedef long long s8Byte,*ps8Byte; + typedef signed long s4Byte,*ps4Byte; + typedef long long s8Byte,*ps8Byte; typedef struct sta_info STA_INFO_T,*PSTA_INFO_T; diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/rtl8195a/ROM_RTL8195A_PHYDM.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/rtl8195a/ROM_RTL8195A_PHYDM.h index 7123055..09ce243 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/rtl8195a/ROM_RTL8195A_PHYDM.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC/rtl8195a/ROM_RTL8195A_PHYDM.h @@ -20,6 +20,7 @@ #ifndef __ROM_RTL8195A_PHYDM_H__ #define __ROM_RTL8195A_PHYDM_H__ +#ifndef _RTL_BIOS_DATA_H_ typedef struct _FALSE_ALARM_STATISTICS{ u4Byte Cnt_Parity_Fail; u4Byte Cnt_Rate_Illegal; @@ -56,16 +57,19 @@ typedef struct _CFO_TRACKING_ u1Byte CFO_TH_ATC; }CFO_TRACKING, *PCFO_TRACKING; + +extern FALSE_ALARM_STATISTICS FalseAlmCnt; +extern CFO_TRACKING DM_CfoTrack; + typedef struct _ROM_INFO{ u1Byte EEPROMVersion; u1Byte CrystalCap; u8Byte DebugComponents; u4Byte DebugLevel; -}ROM_INFO, *PROM_INFO; +} ROM_INFO, *PROM_INFO; -extern FALSE_ALARM_STATISTICS FalseAlmCnt; -extern CFO_TRACKING DM_CfoTrack; extern ROM_INFO ROMInfo; +#endif u1Byte ROM_odm_QueryRxPwrPercentage( diff --git a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/osdep/freertos/wrapper.h b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/osdep/freertos/wrapper.h index c58d89f..c2ddd40 100644 --- a/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/osdep/freertos/wrapper.h +++ b/RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/osdep/freertos/wrapper.h @@ -414,7 +414,7 @@ struct net_device_stats { struct net_device { char name[16]; void *priv; /* pointer to private data */ - unsigned char dev_addr[6]; /* set during bootup */ + unsigned char dev_addr[6]; /* set during bootup */ int (*init)(void); int (*open)(struct net_device *dev); int (*stop)(struct net_device *dev); @@ -449,6 +449,8 @@ void del_timer_sync(struct timer_list * timer); void init_timer_wrapper(void); void deinit_timer_wrapper(void); +typedef void (*TIMER_FUN)(void *context); + void rtw_init_timer(_timer *ptimer, void *adapter, TIMER_FUN pfunc,void* cntx, const char *name); void rtw_set_timer(_timer *ptimer,u32 delay_time); u8 rtw_cancel_timer(_timer *ptimer); diff --git a/RTL00_SDKV35a/component/common/network/netbios/netbios.c b/RTL00_SDKV35a/component/common/network/netbios/netbios.c index cb0db96..1b4a066 100644 --- a/RTL00_SDKV35a/component/common/network/netbios/netbios.c +++ b/RTL00_SDKV35a/component/common/network/netbios/netbios.c @@ -163,12 +163,13 @@ PACK_STRUCT_END # include "arch/epstruct.h" #endif -//#define toupper(CH) \ -// (((CH) >= 'a' && (CH) <= 'z') ? ((CH) - 'a' + 'A') : (CH)) +LOCAL char toupper(char ch) { + return ((ch >= 'a' && ch <= 'z') ? ch - 'a' + 'A' : ch); +} /** NetBIOS decoding name */ -static int8_t NETBIOS_CODE_ATTR NBNS_decode(char *dst, char *src) +LOCAL int8_t NETBIOS_CODE_ATTR NBNS_decode(char *dst, char *src) { uint8_t i, j; char c; @@ -217,7 +218,7 @@ static void NBNS_encode(char *dst, char *src, uint8_t type) #endif /** NetBIOS Name service recv callback */ -static void NETBIOS_CODE_ATTR +LOCAL void NETBIOS_CODE_ATTR netbios_recv(void *arg, struct udp_pcb *upcb, struct pbuf *p, ip_addr_t *addr, u16_t port) { LWIP_UNUSED_ARG(arg); @@ -226,7 +227,7 @@ netbios_recv(void *arg, struct udp_pcb *upcb, struct pbuf *p, ip_addr_t *addr, if (current_netif != NULL && current_netif->num < NET_IF_NUM) { uint32 ip = current_netif->ip_addr.addr; char *curbiosname = netbios_name[current_netif->num]; - if (curbiosname[0] != '\0' && ip != NULL + if (curbiosname[0] != '\0' && ip != 0 /* we only answer if we got a default interface */ && (((ip ^ addr->addr) & current_netif->netmask.addr) == 0)) { // запрет ответа другой подсети #if DEBUGSOO > 3 @@ -308,7 +309,7 @@ netbios_recv(void *arg, struct udp_pcb *upcb, struct pbuf *p, ip_addr_t *addr, } } -struct udp_pcb * NETBIOS_CODE_ATTR netbios_pcb(void) { +LOCAL struct udp_pcb * NETBIOS_CODE_ATTR netbios_pcb(void) { struct udp_pcb *pcb; for (pcb = udp_pcbs; pcb != NULL; pcb = pcb->next) { if (pcb->local_port == NETBIOS_PORT) diff --git a/RTL00_SDKV35a/component/os/freertos/cmsis_os.c b/RTL00_SDKV35a/component/os/freertos/cmsis_os.c index f89830a..ba3430d 100644 --- a/RTL00_SDKV35a/component/os/freertos/cmsis_os.c +++ b/RTL00_SDKV35a/component/os/freertos/cmsis_os.c @@ -74,12 +74,12 @@ static int inHandlerMode (void) #if configSignalManagementSupport // the older FreeRTOS version didn't support Signal Management functions static void add_thread_signal_map (osThreadId thread_id, EventGroupHandle_t signals) { - int dummy; + uint32_t dummy; // uint32_t i; ThreadSignalRec *prec_entity; if (inHandlerMode()) { - dummy = portSET_INTERRUPT_MASK_FROM_ISR(); + dummy = portSET_INTERRUPT_MASK_FROM_ISR(); } else { vPortEnterCritical(); @@ -135,7 +135,7 @@ static EventGroupHandle_t find_signal_by_thread (osThreadId thread_id) { EventGroupHandle_t signals_hdl=NULL; // uint32_t i; - int dummy; + uint32_t dummy; ThreadSignalRec *prec_entity; if (inHandlerMode()) { @@ -185,7 +185,7 @@ static EventGroupHandle_t remove_thread_signal_map (osThreadId thread_id) { EventGroupHandle_t signals_hdl=NULL; // uint32_t i; - int dummy; + uint32_t dummy; ThreadSignalRec *prec_entity; ThreadSignalRec *pprev_entity; @@ -989,7 +989,7 @@ osPoolId osPoolCreate (const osPoolDef_t *pool_def) /// \note MUST REMAIN UNCHANGED: \b osPoolAlloc shall be consistent in every CMSIS-RTOS. void *osPoolAlloc (osPoolId pool_id) { - int dummy; + uint32_t dummy; void *p = NULL; uint32_t i; uint32_t index; @@ -1047,7 +1047,7 @@ void *osPoolCAlloc (osPoolId pool_id) /// \note MUST REMAIN UNCHANGED: \b osPoolFree shall be consistent in every CMSIS-RTOS. osStatus osPoolFree (osPoolId pool_id, void *block) { - int dummy; + uint32_t dummy; uint32_t index; if (pool_id == NULL) { diff --git a/RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/portable/MemMang/heap_5.c b/RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/portable/MemMang/heap_5.c index 1c10808..9150e15 100644 --- a/RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/portable/MemMang/heap_5.c +++ b/RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/portable/MemMang/heap_5.c @@ -169,7 +169,6 @@ space. */ #define xBlockAllocatedBit (( ( size_t ) 1 ) << ( ( sizeof( size_t ) * heapBITS_PER_BYTE ) - 1 )) /* Realtek test code start */ -//TODO: remove section when combine BD and BF #if (defined(CONFIG_PLATFORM_8195A) || defined(CONFIG_PLATFORM_8711B)) #include "section_config.h" SRAM_HEAP_SECTION @@ -541,7 +540,7 @@ const HeapRegion_t *pxHeapRegion; uint8 chip_id = HalGetChipId(); while( pxHeapRegion->xSizeInBytes > 0 ) { - if(pxHeapRegion->pucStartAddress > 0x20000000 + if(pxHeapRegion->pucStartAddress > (uint8_t *)0x20000000 && chip_id >= CHIP_ID_8711AN && chip_id <= CHIP_ID_8711AF) { // pxHeapRegion->pucStartAddress = 0; // pxHeapRegion->xSizeInBytes = 0; diff --git a/RTL00_SDKV35a/component/os/os_dep/osdep_api.c b/RTL00_SDKV35a/component/os/os_dep/osdep_api.c index 15c63ec..f938be2 100644 --- a/RTL00_SDKV35a/component/os/os_dep/osdep_api.c +++ b/RTL00_SDKV35a/component/os/os_dep/osdep_api.c @@ -22,6 +22,7 @@ #define _OSDEP_API_C_ #include +#include extern _LONG_CALL_ char *_strcpy(char *dest, const char *src); extern _LONG_CALL_ VOID *_memset(void *dst0, int Val,SIZE_T length); diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_uart.c b/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_uart.c index bb014c6..da20edb 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_uart.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/rtl8195a/src/rtl8195a_uart.c @@ -142,6 +142,8 @@ HalRuartResetTRxFifoRtl8195a( return HAL_OK; } +extern u64 div_u64(u64 dividend, u32 divisor); + HAL_Status HalRuartGenBaudRateRtl8195a( IN RUART_SPEED_SETTING *pBaudSetting @@ -152,7 +154,7 @@ HalRuartGenBaudRateRtl8195a( u32 min_err=0xffffffff; u32 uart_ovsr; u32 uart_ovsr_mod; - u32 min_uart_ovsr; // ovsr with mini err + u32 min_uart_ovsr =0; // ovsr with mini err u32 min_uart_ovsr_mod; u64 uart_clock; u32 divisor_temp; diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/src/hal_ssi.c b/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/src/hal_ssi.c index 96c92f9..7003be7 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/src/hal_ssi.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/src/hal_ssi.c @@ -547,13 +547,13 @@ HalSsiInit(VOID *Data) DBG_SSI_ERR("Invalid SPI Index.\n"); break; } - +/* ret = FunctionChk(Function, (u32)PinmuxSelect); if(ret == _FALSE){ DBG_SSI_ERR("Invalid Pinmux Setting.\n"); return HAL_ERR_PARA; } - +*/ #ifdef CONFIG_SOC_PS_MODULE REG_POWER_STATE SsiPwrState; #endif diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/include/rtl_bios_data.h b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/include/rtl_bios_data.h index cc58bb5..2a4cd72 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/include/rtl_bios_data.h +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/include/rtl_bios_data.h @@ -92,7 +92,7 @@ typedef struct _FALSE_ALARM_STATISTICS { u32 Cnt_CCA_all; u32 Cnt_BW_USC; u32 Cnt_BW_LSC; -} FALSE_ALARM_STATISTICS; +} FALSE_ALARM_STATISTICS, *PFALSE_ALARM_STATISTICS; extern FALSE_ALARM_STATISTICS FalseAlmCnt; // 100006E0 typedef struct _rom_info { @@ -100,7 +100,7 @@ typedef struct _rom_info { u8 CrystalCap; u64 DebugComponents; u32 DebugLevel; -} ROM_INFO; +} ROM_INFO, *PROM_INFO; extern ROM_INFO ROMInfo; // 10000720 typedef struct _CFO_TRACKING_ { @@ -118,7 +118,7 @@ typedef struct _CFO_TRACKING_ { u8 CFO_TH_XTAL_HIGH; u8 CFO_TH_XTAL_LOW; u8 CFO_TH_ATC; -}CFO_TRACKING; +} CFO_TRACKING, *PCFO_TRACKING;; extern CFO_TRACKING DM_CfoTrack; // 10000738 /* in rom_libgloss_retarget.h diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/c_stdio.c b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/c_stdio.c index 4ff3a67..b8bddaf 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/c_stdio.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/c_stdio.c @@ -4,6 +4,7 @@ #include #include #include "libc/rom/string/rom_libc_string.h" +#include "strproc.h" #define memchr __rtl_memchr_v1_00 #define memcmp __rtl_memcmp_v1_00 @@ -22,10 +23,6 @@ #define strsep __rtl_strsep_v1_00 #define strtok __rtl_strtok_v1_00 -static char toupper(char ch) { - return ((ch >= 'a' && ch <= 'z') ? ch - 'a' + 'A' : ch); -}; - #define NEWFP 1 #define ENDIAN_LITTLE 1234 #define ENDIAN_BIG 4321 @@ -191,6 +188,13 @@ str_fmt(char *p, int size, int fmt) /* * strtoupper() */ +#define strtoupper StrUpr +/* + +LOCAL char toupper(char ch) { + return ((ch >= 'a' && ch <= 'z') ? ch - 'a' + 'A' : ch); +}; + void strtoupper(char *p) { @@ -199,7 +203,7 @@ strtoupper(char *p) for (; *p; p++) *p = toupper (*p); } - +*/ /* $Id: atob.c,v 1.1.1.1 2006/08/23 17:03:06 pefo Exp $ */ /* @@ -633,7 +637,7 @@ c_vsprintf (char *d, const char *s, va_list ap) } else if (*s == 'o') base = 8; - else if (*s == 'b') + else //if (*s == 'b') base = 2; if (longlong) llbtoa(d, va_arg (ap, quad_t), @@ -1074,9 +1078,12 @@ int c_printf(const char *fmt, ...) int puts (const char *s) { + int i = 0; while(*s) { HalSerialPutcRtl8195a(*s++); + i++; } + return i; } void vTaskDelete(void *); diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c index 026201a..b65497e 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/ram_pvvx_libc.c @@ -6,6 +6,8 @@ #include "rtl_bios_data.h" #include "va_list.h" +#include "strproc.h" +#include "rt_lib_rom.h" #define CHECK_LIBC_INIT 0 //------------------------------------------------------------------------- @@ -67,8 +69,9 @@ unsigned long long __aeabi_llsr(unsigned long long val, unsigned int shift); extern struct _reent * _rtl_impure_ptr; +#if CHECK_LIBC_INIT extern int libc_has_init; -// extern impure_ptr +#endif // extern impure_ptr //------------------------------------------------------------------------- @@ -166,7 +169,6 @@ int vprintf(const char * fmt, __VALIST param) { int vsnprintf(char *str, size_t size, const char *fmt, __VALIST param) { int result; int w; - int v11; FILE f; #if CHECK_LIBC_INIT if (!libc_has_init) { @@ -297,9 +299,9 @@ int sscanf(const char *buf, const char *fmt, ...) { return i; } -char toupper(char ch) { +LOCAL char toupper(char ch) { return ((ch >= 'a' && ch <= 'z') ? ch - 'a' + 'A' : ch); -}; +} int _stricmp (const char *s1, const char *s2) { @@ -376,12 +378,15 @@ int __aeabi_dtoi(double d) return __rtl_dtoi_v1_00(d); } +extern _LONG_CALL_ int __rtl_dtoui_v1_00(double d); + //----- __aeabi_dtoui() int __aeabi_dtoui(double d) { return __rtl_dtoui_v1_00(d); } +extern _LONG_CALL_ float __rtl_itof_v1_00(int val); //----- __aeabi_i2f() float __aeabi_i2f(int val) { @@ -406,6 +411,7 @@ int __aeabi_ui2d(unsigned int val) return __rtl_uitod_v1_00(val); } +extern _LONG_CALL_ char * __rtl_ltoa_v1_00(int value, char *string, int radix); //----- __aeabi_itoa() char * __aeabi_itoa(int value, char *string, int radix) { @@ -418,6 +424,7 @@ char * __aeabi_ltoa(int value, char *string, int radix) return (char *)__rtl_ltoa_v1_00(value, string, radix); } +extern _LONG_CALL_ char * __rtl_ultoa_v1_00(unsigned int value, char *string, int radix); //----- __aeabi_utoa() char * __aeabi_utoa(unsigned int value, char *string, int radix) { @@ -430,42 +437,49 @@ char * __aeabi_ultoa(unsigned int value, char *string, int radix) return (char *)__rtl_ultoa_v1_00(value, string, radix); } +extern _LONG_CALL_ long long __rtl_ftol_v1_00(float f); //----- __aeabi_ftol() -int __aeabi_ftol(float f) +long long __aeabi_ftol(float f) { return __rtl_ftol_v1_00(f); } +extern _LONG_CALL_ double __rtl_ftod_v1_00(float f); //----- __aeabi_ftod() -int __aeabi_ftod(float f) +double __aeabi_ftod(float f) { return __rtl_ftod_v1_00(f); } +extern _LONG_CALL_ float __rtl_dtof_v1_00(double d); //----- __aeabi_dtof() float __aeabi_dtof(double d) { return __rtl_dtof_v1_00(d); } +extern _LONG_CALL_ float __rtl_fadd_v1_00(float a, float b); //----- __aeabi_fadd() float __aeabi_fadd(float a, float b) { return __rtl_fadd_v1_00(a, b); } +extern _LONG_CALL_ float __rtl_fsub_v1_00(float a, float b); //----- __aeabi_fsub() float __aeabi_fsub(float a, float b) { return __rtl_fsub_v1_00(a, b); } +extern _LONG_CALL_ float __rtl_fmul_v1_00(float a, float b); //----- __aeabi_fmul() float __aeabi_fmul(float a, float b) { return __rtl_fmul_v1_00(a, b); } +extern _LONG_CALL_ float __rtl_fdiv_v1_00(float a, float b); //----- __aeabi_fdiv() float __aeabi_fdiv(float a, float b) { @@ -473,25 +487,25 @@ float __aeabi_fdiv(float a, float b) } //----- __aeabi_dadd() -int __aeabi_dadd(double a, double b) +double __aeabi_dadd(double a, double b) { return __rtl_dadd_v1_00(a, b); } //----- __aeabi_dsub() -int __aeabi_dsub(double a, double b) +double __aeabi_dsub(double a, double b) { return __rtl_dsub_v1_00(a, b); } //----- __aeabi_dmul() -int __aeabi_dmul(double a, double b) +double __aeabi_dmul(double a, double b) { return __rtl_dmul_v1_00(a, b); } //----- __aeabi_ddiv() -int __aeabi_ddiv(double a, double b) +double __aeabi_ddiv(double a, double b) { return __rtl_ddiv_v1_00(a, b); } @@ -508,6 +522,7 @@ int __aeabi_dcmplt(double a, double b) return __rtl_dcmplt_v1_00(a, b); } +extern _LONG_CALL_ int __rtl_dcmple_v1_00(double a, double b); //----- __aeabi_dcmple() int __aeabi_dcmple(double a, double b) { @@ -520,12 +535,13 @@ int __aeabi_dcmpgt(double a, double b) return __rtl_dcmpgt_v1_00(a, b); } +extern _LONG_CALL_ int __rtl_fcmplt_v1_00(float a, float b); //----- __aeabi_fcmplt() int __aeabi_fcmplt(float a, float b) { return __rtl_fcmplt_v1_00(a, b); } - +extern _LONG_CALL_ int __rtl_fcmpgt_v1_00(float a, float b); //----- __aeabi_fcmpgt() int __aeabi_fcmpgt(float a, float b) { diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_eabi_cast_ram.c b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_eabi_cast_ram.c index 8f7589a..7f4b2ad 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_eabi_cast_ram.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_eabi_cast_ram.c @@ -4,6 +4,7 @@ */ #include "basic_types.h" +#include "rt_lib_rom.h" //------------------------------------------------------------------------- // Function declarations @@ -71,12 +72,15 @@ int rtl_dtoi(double d) return __rtl_dtoi_v1_00(d); } +extern _LONG_CALL_ int __rtl_dtoui_v1_00(double d); + //----- rtl_dtoui() int rtl_dtoui(double d) { return __rtl_dtoui_v1_00(d); } +extern _LONG_CALL_ float __rtl_itof_v1_00(int val); //----- rtl_i2f() float rtl_i2f(int val) { @@ -101,6 +105,7 @@ int rtl_ui2d(unsigned int val) return __rtl_uitod_v1_00(val); } +extern _LONG_CALL_ char * __rtl_ltoa_v1_00(int value, char *string, int radix); //----- rtl_itoa() char *rtl_itoa(int value, char *string, int radix) { @@ -113,6 +118,7 @@ char *rtl_ltoa(int value, char *string, int radix) return (char *)__rtl_ltoa_v1_00(value, string, radix); } +extern _LONG_CALL_ char * __rtl_ultoa_v1_00(unsigned int value, char *string, int radix); //----- rtl_utoa() char *rtl_utoa(unsigned int value, char *string, int radix) { @@ -125,6 +131,7 @@ char *rtl_ultoa(unsigned int value, char *string, int radix) return (char *)__rtl_ultoa_v1_00(value, string, radix); } +extern _LONG_CALL_ double __rtl_ftod_v1_00(float f); //----- rtl_ftol() int rtl_ftol(float f) { @@ -137,6 +144,7 @@ int rtl_ftod(float f) return __rtl_ftod_v1_00(f); } +extern _LONG_CALL_ float __rtl_fsub_v1_00(float a, float b); //----- rtl_dtof() float rtl_dtof(double d) { @@ -155,12 +163,14 @@ float rtl_fsub(float a, float b) return __rtl_fsub_v1_00(a, b); } +extern _LONG_CALL_ float __rtl_fmul_v1_00(float a, float b); //----- rtl_fmul() float rtl_fmul(float a, float b) { return __rtl_fmul_v1_00(a, b); } +extern _LONG_CALL_ float __rtl_fdiv_v1_00(float a, float b); //----- rtl_fdiv() float rtl_fdiv(float a, float b) { @@ -203,6 +213,7 @@ int rtl_dcmplt(double a, double b) return __rtl_dcmplt_v1_00(a, b); } +extern _LONG_CALL_ int __rtl_dcmple_v1_00(double a, double b); //----- rtl_dcmple() int rtl_dcmple(double a, double b) { @@ -214,13 +225,13 @@ int rtl_dcmpgt(double a, double b) { return __rtl_dcmpgt_v1_00(a, b); } - +extern _LONG_CALL_ int __rtl_fcmplt_v1_00(float a, float b); //----- rtl_fcmplt() int rtl_fcmplt(float a, float b) { return __rtl_fcmplt_v1_00(a, b); } - +extern _LONG_CALL_ int __rtl_fcmpgt_v1_00(float a, float b); //----- rtl_fcmpgt() int rtl_fcmpgt(float a, float b) { diff --git a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_math_ram.c b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_math_ram.c index 7fa3703..4809b33 100644 --- a/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_math_ram.c +++ b/RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/lib_rtlstd/rtl_math_ram.c @@ -20,25 +20,28 @@ float rtl_sin_f32(float a); // int __rtl_cos_f32_v1_00(); // int __rtl_sin_f32_v1_00(); - +extern _LONG_CALL_ float __rtl_fabsf_v1_00(float a); //----- rtl_fabsf() float rtl_fabsf(float a) { return __rtl_fabsf_v1_00(a); } +extern _LONG_CALL_ double __rtl_fabs_v1_00(double number); //----- rtl_fabs() int rtl_fabs(double a) { return __rtl_fabs_v1_00(a); } +extern _LONG_CALL_ float __rtl_cos_f32_v1_00(float a); //----- rtl_cos_f32() float rtl_cos_f32(float a) { return __rtl_cos_f32_v1_00(a); } +extern _LONG_CALL_ float __rtl_sin_f32_v1_00(float a); //----- rtl_sin_f32() float rtl_sin_f32(float a) { diff --git a/RTL00_SDKV35a/include.txt b/RTL00_SDKV35a/include.txt new file mode 100644 index 0000000..cd8a72d --- /dev/null +++ b/RTL00_SDKV35a/include.txt @@ -0,0 +1 @@ +-I../RTL00_SDKV35a/component/soc/realtek/common/bsp -I../RTL00_SDKV35a/component/os/freertos -I../RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/include -I../RTL00_SDKV35a/component/os/freertos/freertos_v8.1.2/Source/portable/GCC/ARM_CM3 -I../RTL00_SDKV35a/component/os/os_dep/include -I../RTL00_SDKV35a/component/soc/realtek/8195a/misc/driver -I../RTL00_SDKV35a/component/common/api/network/include -I../RTL00_SDKV35a/component/common/api -I../RTL00_SDKV35a/component/common/api/platform -I../RTL00_SDKV35a/component/common/api/wifi -I../RTL00_SDKV35a/component/common/api/wifi/rtw_wpa_supplicant/src -I../RTL00_SDKV35a/component/common/application -I../RTL00_SDKV35a/component/common/application/iotdemokit -I../RTL00_SDKV35a/component/common/application/google -I../RTL00_SDKV35a/component/common/media/framework -I../RTL00_SDKV35a/component/common/example -I../RTL00_SDKV35a/component/common/example/wlan_fast_connect -I../RTL00_SDKV35a/component/common/mbed/api -I../RTL00_SDKV35a/component/common/mbed/hal -I../RTL00_SDKV35a/component/common/mbed/hal_ext -I../RTL00_SDKV35a/component/common/mbed/targets/hal/rtl8195a -I../RTL00_SDKV35a/component/common/network -I../RTL00_SDKV35a/component/common/network/lwip/lwip_v1.4.1/port/realtek/freertos -I../RTL00_SDKV35a/component/common/network/lwip/lwip_v1.4.1/src/include -I../RTL00_SDKV35a/component/common/network/lwip/lwip_v1.4.1/src/include/lwip -I../RTL00_SDKV35a/component/common/network/lwip/lwip_v1.4.1/src/include/ipv4 -I../RTL00_SDKV35a/component/common/network/lwip/lwip_v1.4.1/port/realtek -I../RTL00_SDKV35a/component/common/test -I../RTL00_SDKV35a/component/soc/realtek/8195a/cmsis -I../RTL00_SDKV35a/component/soc/realtek/8195a/cmsis/device -I../RTL00_SDKV35a/component/soc/realtek/8195a/fwlib -I../RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/rtl8195a -I../RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/ -I../RTL00_SDKV35a/component/soc/realtek/8195a/misc/rtl_std_lib/include -I../RTL00_SDKV35a/component/common/drivers -I../RTL00_SDKV35a/component/common/drivers/wlan/realtek/include -I../RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/osdep -I../RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hci -I../RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal -I../RTL00_SDKV35a/component/common/drivers/wlan/realtek/src/hal/OUTSRC -I../RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/ram_lib/wlan/realtek/wlan_ram_map/rom -I../RTL00_SDKV35a/component/common/network/ssl/polarssl-1.3.8/include -I../RTL00_SDKV35a/component/common/network/ssl/ssl_ram_map/rom -I../RTL00_SDKV35a/component/common/utilities -I../RTL00_SDKV35a/component/common/application/apple/WACServer/External/Curve25519 -I../RTL00_SDKV35a/component/common/application/apple/WACServer/External/GladmanAES -I../RTL00_SDKV35a/component/soc/realtek/8195a/fwlib/ram_lib/usb_otg/include -I../RTL00_SDKV35a/component/common/media/codec -I../RTL00_SDKV35a/component/common/drivers/usb_class/host/uvc/inc -I../RTL00_SDKV35a/component/common/drivers/usb_class/device -I../RTL00_SDKV35a/component/common/drivers/usb_class/device/class -I../RTL00_SDKV35a/component/common/file_system/fatfs -I../RTL00_SDKV35a/component/common/file_system/fatfs/r0.10c/include -I../RTL00_SDKV35a/component/common/drivers/sdio/realtek/sdio_host/inc -I../RTL00_SDKV35a/component/common/audio -I../RTL00_SDKV35a/component/common/drivers/i2s -I../RTL00_SDKV35a/component/common/application/xmodem \ No newline at end of file diff --git a/project/inc/lwipopts.h b/project/inc/lwipopts.h index 54c7783..6e47e59 100644 --- a/project/inc/lwipopts.h +++ b/project/inc/lwipopts.h @@ -181,6 +181,7 @@ a lot of data that needs to be copied, this should be set high. */ /* Support Multicast */ #define LWIP_IGMP 1 +extern __attribute__ ((long_call)) unsigned int Rand(void); #define LWIP_RAND() Rand() /* Support TCP Keepalive */ diff --git a/project/src/user/atcmd_user.c b/project/src/user/atcmd_user.c index ad11bc8..02a7a02 100644 --- a/project/src/user/atcmd_user.c +++ b/project/src/user/atcmd_user.c @@ -165,6 +165,7 @@ LOCAL void fATSB(int argc, char *argv[]) //------------------------------------------------------------------------------ // Dump dword register //------------------------------------------------------------------------------ +extern u32 CmdDumpWord(IN u16 argc, IN u8 *argv[]); LOCAL void fATSD(int argc, char *argv[]) { /* @@ -179,6 +180,7 @@ LOCAL void fATSD(int argc, char *argv[]) //------------------------------------------------------------------------------ // Write dword register //------------------------------------------------------------------------------ +extern u32 CmdWriteWord(IN u16 argc, IN u8 *argv[]); LOCAL void fATSW(int argc, char *argv[]) { CmdWriteWord(argc-1, (unsigned char**)(argv+1)); diff --git a/project/src/user/wifi_console.c b/project/src/user/wifi_console.c index e667980..0d79117 100644 --- a/project/src/user/wifi_console.c +++ b/project/src/user/wifi_console.c @@ -21,7 +21,7 @@ extern struct netif xnetif[NET_IF_NUM]; //========================================================== //--- CONSOLE -------------------------- - +extern rtw_security_t translate_rtw_security(u8 security_type); // ATPN=[,password[,encryption[,auto reconnect[,reconnect pause]]]: WIFI Connect to AP LOCAL void fATPN(int argc, char *argv[]){ if(argc > 1) { @@ -216,7 +216,7 @@ unsigned char *tab_txt_rtw_secyrity[] = { "WPA/WPA2 AES", "Unknown" }; -unsigned int *tab_code_rtw_secyrity[] = { +int *tab_code_rtw_secyrity[] = { RTW_SECURITY_OPEN, RTW_SECURITY_WEP_PSK, RTW_SECURITY_WPA_TKIP_PSK,