PageRenderTime 20ms CodeModel.GetById 17ms app.highlight 1ms RepoModel.GetById 0ms app.codeStats 0ms

/include/linux/pfn.h

https://bitbucket.org/thekraven/iscream_thunderc-2.6.35
C++ Header | 13 lines | 10 code | 3 blank | 0 comment | 0 complexity | f8674b509287bb4543b5018e3c296b43 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.0, AGPL-1.0
 1#ifndef _LINUX_PFN_H_
 2#define _LINUX_PFN_H_
 3
 4#ifndef __ASSEMBLY__
 5#include <linux/types.h>
 6#endif
 7
 8#define PFN_ALIGN(x)	(((unsigned long)(x) + (PAGE_SIZE - 1)) & PAGE_MASK)
 9#define PFN_UP(x)	(((x) + PAGE_SIZE-1) >> PAGE_SHIFT)
10#define PFN_DOWN(x)	((x) >> PAGE_SHIFT)
11#define PFN_PHYS(x)	((phys_addr_t)(x) << PAGE_SHIFT)
12
13#endif