mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
of: Move reserved memory private function declarations
fdt_init_reserved_mem() and fdt_reserved_mem_save_node() are private to the DT code, so move there declarations to of_private.h. There's no need for the dummy functions as CONFIG_OF_RESERVED_MEM is always enabled for CONFIG_OF_EARLY_FLATTREE. Cc: Frank Rowand <frowand.list@gmail.com> Signed-off-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20210527193841.1284169-1-robh@kernel.org
This commit is contained in:
parent
1ee292a66e
commit
12d55d3b53
3 changed files with 6 additions and 6 deletions
|
@ -171,4 +171,8 @@ static inline int of_dma_get_range(struct device_node *np,
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
void fdt_init_reserved_mem(void);
|
||||||
|
void fdt_reserved_mem_save_node(unsigned long node, const char *uname,
|
||||||
|
phys_addr_t base, phys_addr_t size);
|
||||||
|
|
||||||
#endif /* _LINUX_OF_PRIVATE_H */
|
#endif /* _LINUX_OF_PRIVATE_H */
|
||||||
|
|
|
@ -22,6 +22,8 @@
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
#include <linux/memblock.h>
|
#include <linux/memblock.h>
|
||||||
|
|
||||||
|
#include "of_private.h"
|
||||||
|
|
||||||
#define MAX_RESERVED_REGIONS 64
|
#define MAX_RESERVED_REGIONS 64
|
||||||
static struct reserved_mem reserved_mem[MAX_RESERVED_REGIONS];
|
static struct reserved_mem reserved_mem[MAX_RESERVED_REGIONS];
|
||||||
static int reserved_mem_count;
|
static int reserved_mem_count;
|
||||||
|
|
|
@ -39,9 +39,6 @@ int of_reserved_mem_device_init_by_name(struct device *dev,
|
||||||
const char *name);
|
const char *name);
|
||||||
void of_reserved_mem_device_release(struct device *dev);
|
void of_reserved_mem_device_release(struct device *dev);
|
||||||
|
|
||||||
void fdt_init_reserved_mem(void);
|
|
||||||
void fdt_reserved_mem_save_node(unsigned long node, const char *uname,
|
|
||||||
phys_addr_t base, phys_addr_t size);
|
|
||||||
struct reserved_mem *of_reserved_mem_lookup(struct device_node *np);
|
struct reserved_mem *of_reserved_mem_lookup(struct device_node *np);
|
||||||
#else
|
#else
|
||||||
static inline int of_reserved_mem_device_init_by_idx(struct device *dev,
|
static inline int of_reserved_mem_device_init_by_idx(struct device *dev,
|
||||||
|
@ -59,9 +56,6 @@ static inline int of_reserved_mem_device_init_by_name(struct device *dev,
|
||||||
|
|
||||||
static inline void of_reserved_mem_device_release(struct device *pdev) { }
|
static inline void of_reserved_mem_device_release(struct device *pdev) { }
|
||||||
|
|
||||||
static inline void fdt_init_reserved_mem(void) { }
|
|
||||||
static inline void fdt_reserved_mem_save_node(unsigned long node,
|
|
||||||
const char *uname, phys_addr_t base, phys_addr_t size) { }
|
|
||||||
static inline struct reserved_mem *of_reserved_mem_lookup(struct device_node *np)
|
static inline struct reserved_mem *of_reserved_mem_lookup(struct device_node *np)
|
||||||
{
|
{
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
Loading…
Add table
Reference in a new issue