From: Andrew Morton <akpm@linux-foundation.org>
Ulrich says that we never used these clone flags and that nothing should be
using them.
As we're down to only a single bit left in clone's flags argument, let's add a
warning to check that no userspace is actually using these. Hopefully we will
be able to recycle them.
Cc: Ulrich Drepper <drepper@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Roland McGrath <roland@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
kernel/fork.c | 16 ++++++++++++----
1 file changed, 12 insertions(+), 4 deletions(-)
diff -puN kernel/fork.c~clone-prepare-to-recycle-clone_detached-and-clone_stopped kernel/fork.c
--- a/kernel/fork.c~clone-prepare-to-recycle-clone_detached-and-clone_stopped
+++ a/kernel/fork.c
@@ -1420,10 +1420,18 @@ long do_fork(unsigned long clone_flags,
int trace = 0;
long nr;
- if (unlikely(current->ptrace)) {
- trace = fork_traceflag (clone_flags);
- if (trace)
- clone_flags |= CLONE_PTRACE;
+ /*
+ * We hope to recycle these flags after 2.6.26
+ */
+ if (unlikely(clone_flags & (CLONE_DETACHED|CLONE_STOPPED))) {
+ if (printk_ratelimit()) {
+ char comm[TASK_COMM_LEN];
+
+ printk(KERN_INFO "fork(): process `%s' used deprecated "
+ "clone flags 0x%lx\n",
+ get_task_comm(comm, current),
+ clone_flags & (CLONE_DETACHED|CLONE_STOPPED));
+ }
}
p = copy_process(clone_flags, stack_start, regs, stack_size,
_
-
| Stephen Rothwell | Announce: Linux-next (Or Andrew's dream :-)) |
| David Miller | [GIT]: Networking |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Karl Meyer | PROBLEM: 2.6.23-rc "NETDEV WATCHDOG: eth0: transmit timed out" |
git: | |
| Jakub Narebski | Re: VCS comparison table |
| Johannes Schindelin | [PATCH] Add a birdview-on-the-source-code section to the user manual |
| Guilhem Bonnefille | Re: [FAQ?] Rationale for git's way to manage the index |
| Dana How | [PATCH v2] Custom compression levels for objects and packs |
| Richard Stallman | Real men don't attack straw men |
| Dmitrij Czarkoff | malformatted MMC card fails to mount |
| Jan Stary | 4.1 on ALIX.1C - recommendations? |
| Cinder Cycling Shop | Re: Mountain and Road Bikes Liquidation Sale on 2007 models |
| Леонид Юрьев | [r8169] patch for RTL8102 (5 new MAC/PHY) |
| jamal | Re: [RFC][PATCH] Fixing SA/SP dumps on netlink/af_key |
| Timur Tabi | [PATCH 0/2] QE clock source improvements |
| Herbert Valerio Riedel | [PATCH,RFC] ep93xx_eth: conversion to phylib framework |
