forked from Minki/linux
mm: Add folio_nid()
This is the folio equivalent of page_to_nid(). Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Acked-by: Mike Rapoport <rppt@linux.ibm.com> Reviewed-by: David Howells <dhowells@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz>
This commit is contained in:
parent
dd10ab049b
commit
874fd90caf
@ -1429,6 +1429,11 @@ static inline int page_to_nid(const struct page *page)
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline int folio_nid(const struct folio *folio)
|
||||
{
|
||||
return page_to_nid(&folio->page);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_NUMA_BALANCING
|
||||
static inline int cpu_pid_to_cpupid(int cpu, int pid)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user