PageRenderTime 63ms CodeModel.GetById 37ms RepoModel.GetById 1ms app.codeStats 0ms

/drivers/net/wireless/tiwlan1251/CUDK/UtilityAdapter/TI_Adapter.cpp

http://github.com/CyanogenMod/cm-kernel
C++ | 54 lines | 20 code | 9 blank | 25 comment | 1 complexity | aaa45ac335c13480b85b1f941e8542bc MD5 | raw file
Possible License(s): AGPL-1.0, GPL-2.0, LGPL-2.0
  1. /*******************************************************************************
  2. **+--------------------------------------------------------------------------+**
  3. **| |**
  4. **| Copyright 1998-2008 Texas Instruments, Inc. - http://www.ti.com/ |**
  5. **| |**
  6. **| Licensed under the Apache License, Version 2.0 (the "License"); |**
  7. **| you may not use this file except in compliance with the License. |**
  8. **| You may obtain a copy of the License at |**
  9. **| |**
  10. **| http://www.apache.org/licenses/LICENSE-2.0 |**
  11. **| |**
  12. **| Unless required by applicable law or agreed to in writing, software |**
  13. **| distributed under the License is distributed on an "AS IS" BASIS, |**
  14. **| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |**
  15. **| See the License for the specific language governing permissions and |**
  16. **| limitations under the License. |**
  17. **| |**
  18. **+--------------------------------------------------------------------------+**
  19. *******************************************************************************/
  20. //--------------------------------------------------------------------------
  21. // Module: TI_Adapter.cpp
  22. //
  23. // Purpose:
  24. //
  25. //--------------------------------------------------------------------------
  26. #include "CommonAdapter.h"
  27. #ifdef _WINDOWS
  28. #endif
  29. tiBOOL TI_CheckAdapterObject(void *pObj)
  30. {
  31. tiBOOL bRes = FALSE;
  32. TI_OAL* pOSLib = TI_OAL::GetInstance();
  33. if (pOSLib)
  34. bRes = !(pOSLib->TIIsBadWritePtr(pObj, sizeof(CTI_WLAN_AdapterAPI)));
  35. TI_OAL::FreeInstance();
  36. return bRes;
  37. }
  38. TI_WLAN_AdapterAPI* TI_AdapterCppInit(tiCHAR* pszDeviceName, tiBOOL bForce )
  39. {
  40. return CTI_WLAN_AdapterAPI::GetTIWLANAdapter(pszDeviceName, bForce);
  41. }
  42. tiINT32 TI_AdapterCppDeinit( TI_WLAN_AdapterAPI* pAdapter, tiBOOL bForce )
  43. {
  44. return CTI_WLAN_AdapterAPI::FreeTIWLANAdapter((CTI_WLAN_AdapterAPI*)pAdapter, bForce);
  45. }