mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 14:42:37 +02:00
ANDROID: staging: android: ion: Fix build when CONFIG_ION_SYSTEM_HEAP=n
Fixes: 5e3a3fe770e6 ("ANDROID: staging: android: ion: Expose total heap and pool sizes via sysfs")
When CONFIG_ION_SYSTEM_HEAP not set ion_page_pool_nr_pages symbol will not
be compiled. Fix this by providing an implementation for this configuration.
Bug: 138148041
Test: build with CONFIG_ION_SYSTEM_HEAP=n
Change-Id: I77b87e8cd6789a06336c724c206acc832b302d08
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
This commit is contained in:
parent
19d5fdf92c
commit
74af3535e0
|
|
@ -315,7 +315,12 @@ struct ion_page_pool *ion_page_pool_create(gfp_t gfp_mask, unsigned int order);
|
|||
void ion_page_pool_destroy(struct ion_page_pool *pool);
|
||||
struct page *ion_page_pool_alloc(struct ion_page_pool *pool);
|
||||
void ion_page_pool_free(struct ion_page_pool *pool, struct page *page);
|
||||
|
||||
#ifdef CONFIG_ION_SYSTEM_HEAP
|
||||
long ion_page_pool_nr_pages(void);
|
||||
#else
|
||||
static inline long ion_page_pool_nr_pages(void) { return 0; }
|
||||
#endif
|
||||
|
||||
/** ion_page_pool_shrink - shrinks the size of the memory cached in the pool
|
||||
* @pool: the pool
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user