osal_bufmgr.h 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. /**************************************************************************************************
  2. Phyplus Microelectronics Limited confidential and proprietary.
  3. All rights reserved.
  4. IMPORTANT: All rights of this software belong to Phyplus Microelectronics
  5. Limited ("Phyplus"). Your use of this Software is limited to those
  6. specific rights granted under the terms of the business contract, the
  7. confidential agreement, the non-disclosure agreement and any other forms
  8. of agreements as a customer or a partner of Phyplus. You may not use this
  9. Software unless you agree to abide by the terms of these agreements.
  10. You acknowledge that the Software may not be modified, copied,
  11. distributed or disclosed unless embedded on a Phyplus Bluetooth Low Energy
  12. (BLE) integrated circuit, either as a product or is integrated into your
  13. products. Other than for the aforementioned purposes, you may not use,
  14. reproduce, copy, prepare derivative works of, modify, distribute, perform,
  15. display or sell this Software and/or its documentation for any purposes.
  16. YOU FURTHER ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE
  17. PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED,
  18. INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE,
  19. NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
  20. PHYPLUS OR ITS SUBSIDIARIES BE LIABLE OR OBLIGATED UNDER CONTRACT,
  21. NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER
  22. LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
  23. INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE
  24. OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT
  25. OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
  26. (INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
  27. **************************************************************************************************/
  28. /**************************************************************************************************
  29. Filename: osal_bufmgr.h
  30. Revised:
  31. Revision:
  32. Description: This file contains the buffer management definitions.
  33. **************************************************************************************************/
  34. #ifndef OSAL_BUFMGR_H
  35. #define OSAL_BUFMGR_H
  36. #include "comdef.h"
  37. #ifdef __cplusplus
  38. extern "C"
  39. {
  40. #endif
  41. /*********************************************************************
  42. * INCLUDES
  43. */
  44. /*********************************************************************
  45. * CONSTANTS
  46. */
  47. /*********************************************************************
  48. * VARIABLES
  49. */
  50. /*********************************************************************
  51. * MACROS
  52. */
  53. /*********************************************************************
  54. * TYPEDEFS
  55. */
  56. /*********************************************************************
  57. * VARIABLES
  58. */
  59. /*********************************************************************
  60. * FUNCTIONS
  61. */
  62. /*
  63. * Allocate a block of memory.
  64. */
  65. extern void *osal_bm_alloc( uint16 size );
  66. /*
  67. * Add or remove header space for the payload pointer.
  68. */
  69. extern void *osal_bm_adjust_header( void *payload_ptr, int16 size );
  70. /*
  71. * Add or remove tail space for the payload pointer.
  72. */
  73. extern void *osal_bm_adjust_tail( void *payload_ptr, int16 size );
  74. /*
  75. * Free a block of memory.
  76. */
  77. extern void osal_bm_free( void *payload_ptr );
  78. /*********************************************************************
  79. *********************************************************************/
  80. #ifdef __cplusplus
  81. }
  82. #endif
  83. #endif /* OSAL_BUFMGR_H */