未验证 提交 75c4df83 编写于 作者: B Bernard Xiong 提交者: GitHub

Merge pull request #4555 from thread-liu/liukang

[update] stm32mp1 opemamp malloc -> rt_malloc.
......@@ -18,18 +18,21 @@
#include <stdlib.h>
extern void *rt_malloc(unsigned long nbytes);
extern void rt_free(void *ptr);
#ifdef __cplusplus
extern "C" {
#endif
static inline void *metal_allocate_memory(unsigned int size)
{
return (malloc(size));
return (rt_malloc(size));
}
static inline void metal_free_memory(void *ptr)
{
free(ptr);
rt_free(ptr);
}
#ifdef __cplusplus
......
......@@ -18,18 +18,21 @@
#include <stdlib.h>
extern void *rt_malloc(unsigned long nbytes);
extern void rt_free(void *ptr);
#ifdef __cplusplus
extern "C" {
#endif
static inline void *metal_allocate_memory(unsigned int size)
{
return (malloc(size));
return (rt_malloc(size));
}
static inline void metal_free_memory(void *ptr)
{
free(ptr);
rt_free(ptr);
}
#ifdef __cplusplus
......
......@@ -18,18 +18,21 @@
#include <stdlib.h>
extern void *rt_malloc(unsigned long nbytes);
extern void rt_free(void *ptr);
#ifdef __cplusplus
extern "C" {
#endif
static inline void *metal_allocate_memory(unsigned int size)
{
return (malloc(size));
return (rt_malloc(size));
}
static inline void metal_free_memory(void *ptr)
{
free(ptr);
rt_free(ptr);
}
#ifdef __cplusplus
......
......@@ -18,18 +18,21 @@
#include <stdlib.h>
extern void *rt_malloc(unsigned long nbytes);
extern void rt_free(void *ptr);
#ifdef __cplusplus
extern "C" {
#endif
static inline void *metal_allocate_memory(unsigned int size)
{
return (malloc(size));
return (rt_malloc(size));
}
static inline void metal_free_memory(void *ptr)
{
free(ptr);
rt_free(ptr);
}
#ifdef __cplusplus
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册