projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd0f371
)
mm_types.h: change set_page_private to inline function
author
Guoqing Jiang
<guoqing.jiang@cloud.ionos.com>
Tue, 2 Jun 2020 04:48:09 +0000
(21:48 -0700)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Tue, 2 Jun 2020 17:59:08 +0000
(10:59 -0700)
Change it to inline function to make callers use the proper argument. And
no need for it to be macro per Andrew's comment [1].
[1] https://lore.kernel.org/lkml/
20200518221235
.
1fa32c38e5766113f78e3f0d
@linux-foundation.org/
Signed-off-by: Guoqing Jiang <guoqing.jiang@cloud.ionos.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Link:
http://lkml.kernel.org/r/20200525203149.18802-1-guoqing.jiang@cloud.ionos.com
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/mm_types.h
patch
|
blob
|
history
diff --git
a/include/linux/mm_types.h
b/include/linux/mm_types.h
index
4aba6c0
..
ef6d3af
100644
(file)
--- a/
include/linux/mm_types.h
+++ b/
include/linux/mm_types.h
@@
-240,7
+240,11
@@
static inline atomic_t *compound_pincount_ptr(struct page *page)
#define PAGE_FRAG_CACHE_MAX_ORDER get_order(PAGE_FRAG_CACHE_MAX_SIZE)
#define page_private(page) ((page)->private)
-#define set_page_private(page, v) ((page)->private = (v))
+
+static inline void set_page_private(struct page *page, unsigned long private)
+{
+ page->private = private;
+}
struct page_frag_cache {
void * va;