Skip to content

Commit

Permalink
mm-page_alloc-rename-__gfp_wait-to-__gfp_reclaim-checkpatch-fixes
Browse files Browse the repository at this point in the history
WARNING: line over 80 characters
torvalds#110: FILE: drivers/block/drbd/drbd_bitmap.c:1010:
+		page = mempool_alloc(drbd_md_io_page_pool, __GFP_HIGHMEM|__GFP_RECLAIM);

WARNING: line over 80 characters
torvalds#139: FILE: drivers/block/nvme-core.c:1039:
+		ret = blk_rq_map_user(q, req, NULL, ubuffer, bufflen, __GFP_RECLAIM);

WARNING: line over 80 characters
torvalds#466: FILE: include/linux/gfp.h:110:
+#define __GFP_RECLAIM ((__force gfp_t)(___GFP_DIRECT_RECLAIM|___GFP_KSWAPD_RECLAIM))

ERROR: code indent should use tabs where possible
torvalds#547: FILE: kernel/power/swap.c:978:
+^I^I           __get_free_page(__GFP_RECLAIM | __GFP_HIGH);$

ERROR: code indent should use tabs where possible
torvalds#557: FILE: kernel/power/swap.c:1245:
+^I^I                                  __GFP_RECLAIM | __GFP_HIGH :$

ERROR: code indent should use tabs where possible
torvalds#558: FILE: kernel/power/swap.c:1246:
+^I^I                                  __GFP_RECLAIM | __GFP_NOWARN |$

WARNING: line over 80 characters
torvalds#570: FILE: lib/percpu_ida.c:138:
+ * used for internal memory allocations); thus if passed __GFP_RECLAIM we may sleep

ERROR: code indent should use tabs where possible
torvalds#596: FILE: mm/failslab.c:19:
+        if (failslab.ignore_gfp_reclaim && (gfpflags & __GFP_RECLAIM))$

WARNING: please, no spaces at the start of a line
torvalds#596: FILE: mm/failslab.c:19:
+        if (failslab.ignore_gfp_reclaim && (gfpflags & __GFP_RECLAIM))$

WARNING: line over 80 characters
torvalds#617: FILE: mm/filemap.c:2717:
+ * this page (__GFP_IO), and whether the call may block (__GFP_RECLAIM & __GFP_FS).

total: 4 errors, 6 warnings, 463 lines checked

NOTE: Whitespace errors detected.
      You may wish to use scripts/cleanpatch or scripts/cleanfile

./patches/mm-page_alloc-rename-__gfp_wait-to-__gfp_reclaim.patch has style problems, please review.

NOTE: If any of the errors are false positives, please report
      them to the maintainer, see CHECKPATCH in MAINTAINERS.

Please run checkpatch prior to sending patches

Cc: Mel Gorman <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
  • Loading branch information
akpm00 authored and sfrothwell committed Oct 21, 2015
1 parent 4508e17 commit 7d21bc0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions kernel/power/swap.c
Original file line number Diff line number Diff line change
Expand Up @@ -975,7 +975,7 @@ static int get_swap_reader(struct swap_map_handle *handle,
last = tmp;

tmp->map = (struct swap_map_page *)
__get_free_page(__GFP_RECLAIM | __GFP_HIGH);
__get_free_page(__GFP_RECLAIM | __GFP_HIGH);
if (!tmp->map) {
release_swap_reader(handle);
return -ENOMEM;
Expand Down Expand Up @@ -1242,9 +1242,9 @@ static int load_image_lzo(struct swap_map_handle *handle,

for (i = 0; i < read_pages; i++) {
page[i] = (void *)__get_free_page(i < LZO_CMP_PAGES ?
__GFP_RECLAIM | __GFP_HIGH :
__GFP_RECLAIM | __GFP_NOWARN |
__GFP_NORETRY);
__GFP_RECLAIM | __GFP_HIGH :
__GFP_RECLAIM | __GFP_NOWARN |
__GFP_NORETRY);

if (!page[i]) {
if (i < LZO_CMP_PAGES) {
Expand Down
2 changes: 1 addition & 1 deletion mm/failslab.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ bool should_failslab(size_t size, gfp_t gfpflags, unsigned long cache_flags)
if (gfpflags & __GFP_NOFAIL)
return false;

if (failslab.ignore_gfp_reclaim && (gfpflags & __GFP_RECLAIM))
if (failslab.ignore_gfp_reclaim && (gfpflags & __GFP_RECLAIM))
return false;

if (failslab.cache_filter && !(cache_flags & SLAB_FAILSLAB))
Expand Down

0 comments on commit 7d21bc0

Please sign in to comment.