Commit 1f13ae399c58af5a05b5cee61da864e1f4071de4
Committed by
Linus Torvalds
1 parent
f606b77f1a
Exists in
ti-lsk-linux-4.1.y
and in
10 other branches
mm: remove noisy remainder of the scan_unevictable interface
The deprecation warnings for the scan_unevictable interface triggers by scripts doing `sysctl -a | grep something else'. This is annoying and not helpful. The interface has been defunct since 264e56d8247e ("mm: disable user interface to manually rescue unevictable pages"), which was in 2011, and there haven't been any reports of usecases for it, only reports that the deprecation warnings are annying. It's unlikely that anybody is using this interface specifically at this point, so remove it. Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Showing 5 changed files with 0 additions and 97 deletions Side-by-side Diff
Documentation/ABI/stable/sysfs-devices-node
... | ... | @@ -85,14 +85,6 @@ |
85 | 85 | will be compacted. When it completes, memory will be freed |
86 | 86 | into blocks which have as many contiguous pages as possible |
87 | 87 | |
88 | -What: /sys/devices/system/node/nodeX/scan_unevictable_pages | |
89 | -Date: October 2008 | |
90 | -Contact: Lee Schermerhorn <lee.schermerhorn@hp.com> | |
91 | -Description: | |
92 | - When set, it triggers scanning the node's unevictable lists | |
93 | - and move any pages that have become evictable onto the respective | |
94 | - zone's inactive list. See mm/vmscan.c | |
95 | - | |
96 | 88 | What: /sys/devices/system/node/nodeX/hugepages/hugepages-<size>/ |
97 | 89 | Date: December 2009 |
98 | 90 | Contact: Lee Schermerhorn <lee.schermerhorn@hp.com> |
drivers/base/node.c
... | ... | @@ -289,8 +289,6 @@ |
289 | 289 | device_create_file(&node->dev, &dev_attr_distance); |
290 | 290 | device_create_file(&node->dev, &dev_attr_vmstat); |
291 | 291 | |
292 | - scan_unevictable_register_node(node); | |
293 | - | |
294 | 292 | hugetlb_register_node(node); |
295 | 293 | |
296 | 294 | compaction_register_node(node); |
... | ... | @@ -314,7 +312,6 @@ |
314 | 312 | device_remove_file(&node->dev, &dev_attr_distance); |
315 | 313 | device_remove_file(&node->dev, &dev_attr_vmstat); |
316 | 314 | |
317 | - scan_unevictable_unregister_node(node); | |
318 | 315 | hugetlb_unregister_node(node); /* no-op, if memoryless node */ |
319 | 316 | |
320 | 317 | device_unregister(&node->dev); |
include/linux/swap.h
... | ... | @@ -354,22 +354,6 @@ |
354 | 354 | extern int page_evictable(struct page *page); |
355 | 355 | extern void check_move_unevictable_pages(struct page **, int nr_pages); |
356 | 356 | |
357 | -extern unsigned long scan_unevictable_pages; | |
358 | -extern int scan_unevictable_handler(struct ctl_table *, int, | |
359 | - void __user *, size_t *, loff_t *); | |
360 | -#ifdef CONFIG_NUMA | |
361 | -extern int scan_unevictable_register_node(struct node *node); | |
362 | -extern void scan_unevictable_unregister_node(struct node *node); | |
363 | -#else | |
364 | -static inline int scan_unevictable_register_node(struct node *node) | |
365 | -{ | |
366 | - return 0; | |
367 | -} | |
368 | -static inline void scan_unevictable_unregister_node(struct node *node) | |
369 | -{ | |
370 | -} | |
371 | -#endif | |
372 | - | |
373 | 357 | extern int kswapd_run(int nid); |
374 | 358 | extern void kswapd_stop(int nid); |
375 | 359 | #ifdef CONFIG_MEMCG |
kernel/sysctl.c
... | ... | @@ -1460,13 +1460,6 @@ |
1460 | 1460 | .extra2 = &one, |
1461 | 1461 | }, |
1462 | 1462 | #endif |
1463 | - { | |
1464 | - .procname = "scan_unevictable_pages", | |
1465 | - .data = &scan_unevictable_pages, | |
1466 | - .maxlen = sizeof(scan_unevictable_pages), | |
1467 | - .mode = 0644, | |
1468 | - .proc_handler = scan_unevictable_handler, | |
1469 | - }, | |
1470 | 1463 | #ifdef CONFIG_MEMORY_FAILURE |
1471 | 1464 | { |
1472 | 1465 | .procname = "memory_failure_early_kill", |
mm/vmscan.c
... | ... | @@ -3797,67 +3797,4 @@ |
3797 | 3797 | } |
3798 | 3798 | } |
3799 | 3799 | #endif /* CONFIG_SHMEM */ |
3800 | - | |
3801 | -static void warn_scan_unevictable_pages(void) | |
3802 | -{ | |
3803 | - printk_once(KERN_WARNING | |
3804 | - "%s: The scan_unevictable_pages sysctl/node-interface has been " | |
3805 | - "disabled for lack of a legitimate use case. If you have " | |
3806 | - "one, please send an email to linux-mm@kvack.org.\n", | |
3807 | - current->comm); | |
3808 | -} | |
3809 | - | |
3810 | -/* | |
3811 | - * scan_unevictable_pages [vm] sysctl handler. On demand re-scan of | |
3812 | - * all nodes' unevictable lists for evictable pages | |
3813 | - */ | |
3814 | -unsigned long scan_unevictable_pages; | |
3815 | - | |
3816 | -int scan_unevictable_handler(struct ctl_table *table, int write, | |
3817 | - void __user *buffer, | |
3818 | - size_t *length, loff_t *ppos) | |
3819 | -{ | |
3820 | - warn_scan_unevictable_pages(); | |
3821 | - proc_doulongvec_minmax(table, write, buffer, length, ppos); | |
3822 | - scan_unevictable_pages = 0; | |
3823 | - return 0; | |
3824 | -} | |
3825 | - | |
3826 | -#ifdef CONFIG_NUMA | |
3827 | -/* | |
3828 | - * per node 'scan_unevictable_pages' attribute. On demand re-scan of | |
3829 | - * a specified node's per zone unevictable lists for evictable pages. | |
3830 | - */ | |
3831 | - | |
3832 | -static ssize_t read_scan_unevictable_node(struct device *dev, | |
3833 | - struct device_attribute *attr, | |
3834 | - char *buf) | |
3835 | -{ | |
3836 | - warn_scan_unevictable_pages(); | |
3837 | - return sprintf(buf, "0\n"); /* always zero; should fit... */ | |
3838 | -} | |
3839 | - | |
3840 | -static ssize_t write_scan_unevictable_node(struct device *dev, | |
3841 | - struct device_attribute *attr, | |
3842 | - const char *buf, size_t count) | |
3843 | -{ | |
3844 | - warn_scan_unevictable_pages(); | |
3845 | - return 1; | |
3846 | -} | |
3847 | - | |
3848 | - | |
3849 | -static DEVICE_ATTR(scan_unevictable_pages, S_IRUGO | S_IWUSR, | |
3850 | - read_scan_unevictable_node, | |
3851 | - write_scan_unevictable_node); | |
3852 | - | |
3853 | -int scan_unevictable_register_node(struct node *node) | |
3854 | -{ | |
3855 | - return device_create_file(&node->dev, &dev_attr_scan_unevictable_pages); | |
3856 | -} | |
3857 | - | |
3858 | -void scan_unevictable_unregister_node(struct node *node) | |
3859 | -{ | |
3860 | - device_remove_file(&node->dev, &dev_attr_scan_unevictable_pages); | |
3861 | -} | |
3862 | -#endif |