mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 20:51:03 +02:00
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: Wanpeng Li <liwp@linux.vnet.ibm.com> Cc: Wu Fengguang <fengguang.wu@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
committed by
Linus Torvalds
parent
deaf386ee5
commit
3965c9ae47
@@ -886,3 +886,23 @@ out:
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL(wait_iff_congested);
|
||||
|
||||
int pdflush_proc_obsolete(struct ctl_table *table, int write,
|
||||
void __user *buffer, size_t *lenp, loff_t *ppos)
|
||||
{
|
||||
char kbuf[] = "0\n";
|
||||
|
||||
if (*ppos) {
|
||||
*lenp = 0;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (copy_to_user(buffer, kbuf, sizeof(kbuf)))
|
||||
return -EFAULT;
|
||||
printk_once(KERN_WARNING "%s exported in /proc is scheduled for removal\n",
|
||||
table->procname);
|
||||
|
||||
*lenp = 2;
|
||||
*ppos += *lenp;
|
||||
return 2;
|
||||
}
|
||||
|
Reference in New Issue
Block a user