Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3965c9ae authored by Wanpeng Li's avatar Wanpeng Li Committed by Linus Torvalds
Browse files

mm: prepare for removal of obsolete /proc/sys/vm/nr_pdflush_threads



Since per-BDI flusher threads were introduced in 2.6, the pdflush
mechanism is not used any more.  But the old interface exported through
/proc/sys/vm/nr_pdflush_threads still exists and is obviously useless.

For back-compatibility, printk warning information and return 2 to notify
the users that the interface is removed.

Signed-off-by: default avatarWanpeng Li <liwp@linux.vnet.ibm.com>
Cc: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent deaf386e
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
What:		/proc/sys/vm/nr_pdflush_threads
Date:		June 2012
Contact:	Wanpeng Li <liwp@linux.vnet.ibm.com>
Description: Since pdflush is replaced by per-BDI flusher, the interface of old pdflush
             exported in /proc/sys/vm/ should be removed.
+8 −0
Original line number Diff line number Diff line
@@ -13,6 +13,14 @@ Who: Jim Cromie <jim.cromie@gmail.com>, Jason Baron <jbaron@redhat.com>

---------------------------

What: /proc/sys/vm/nr_pdflush_threads
When: 2012
Why: Since pdflush is deprecated, the interface exported in /proc/sys/vm/
     should be removed.
Who: Wanpeng Li <liwp@linux.vnet.ibm.com>

---------------------------

What:	CONFIG_APM_CPU_IDLE, and its ability to call APM BIOS in idle
When:	2012
Why:	This optional sub-feature of APM is of dubious reliability,
+0 −11
Original line number Diff line number Diff line
@@ -42,7 +42,6 @@ Currently, these files are in /proc/sys/vm:
- mmap_min_addr
- nr_hugepages
- nr_overcommit_hugepages
- nr_pdflush_threads
- nr_trim_pages         (only if CONFIG_MMU=n)
- numa_zonelist_order
- oom_dump_tasks
@@ -426,16 +425,6 @@ See Documentation/vm/hugetlbpage.txt

==============================================================

nr_pdflush_threads

The current number of pdflush threads.  This value is read-only.
The value changes according to the number of dirty pages in the system.

When necessary, additional pdflush threads are created, one per second, up to
nr_pdflush_threads_max.

==============================================================

nr_trim_pages

This is available only on NOMMU kernels.
+0 −5
Original line number Diff line number Diff line
@@ -52,11 +52,6 @@ struct wb_writeback_work {
	struct completion *done;	/* set if the caller waits */
};

/*
 * We don't actually have pdflush, but this one is exported though /proc...
 */
int nr_pdflush_threads;

/**
 * writeback_in_progress - determine whether there is writeback in progress
 * @bdi: the device's backing_dev_info structure.
+3 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
#include <linux/timer.h>
#include <linux/writeback.h>
#include <linux/atomic.h>
#include <linux/sysctl.h>

struct page;
struct device;
@@ -304,6 +305,8 @@ void clear_bdi_congested(struct backing_dev_info *bdi, int sync);
void set_bdi_congested(struct backing_dev_info *bdi, int sync);
long congestion_wait(int sync, long timeout);
long wait_iff_congested(struct zone *zone, int sync, long timeout);
int pdflush_proc_obsolete(struct ctl_table *table, int write,
		void __user *buffer, size_t *lenp, loff_t *ppos);

static inline bool bdi_cap_writeback_dirty(struct backing_dev_info *bdi)
{
Loading