Re: [Bugme-new] [Bug 9906] New: Weird hang with NPTL and SIGPROF.



On Fri, 2008-03-07 at 15:26 -0800, Frank Mayhar wrote:
Based on Roland's comments and from reading the source, I have a
possible fix. I'm posting the attached patch _not_ for submission but
_only_ for comment. For one thing it's based on 2.6.18.5 and for
another it hasn't had much testing yet. I wanted to get it out here for
comment, though, in case anyone can see where I might have gone wrong.
Comments, criticism and (especially!) testing enthusiastically
requested.

The previous email was missing one small part of the patch, reproduced
below. Remain calm.
----------------------------------BEGIN------------------------------------
diff -urp /home/fmayhar/Static/linux-2.6.18.5/kernel/compat.c linux-2.6.18.5/kernel/compat.c
--- /home/fmayhar/Static/linux-2.6.18.5/kernel/compat.c 2006-12-01 16:13:05.000000000 -0800
+++ linux-2.6.18.5/kernel/compat.c 2008-03-06 17:26:21.000000000 -0800
@@ -161,18 +161,11 @@ asmlinkage long compat_sys_times(struct
if (tbuf) {
struct compat_tms tmp;
struct task_struct *tsk = current;
- struct task_struct *t;
cputime_t utime, stime, cutime, cstime;

read_lock(&tasklist_lock);
- utime = tsk->signal->utime;
- stime = tsk->signal->stime;
- t = tsk;
- do {
- utime = cputime_add(utime, t->utime);
- stime = cputime_add(stime, t->stime);
- t = next_thread(t);
- } while (t != tsk);
+ utime = tsk->signal->shared_utime;
+ stime = tsk->signal->shared_stime;

/*
* While we have tasklist_lock read-locked, no dying thread
-----------------------------------END-------------------------------------
--
Frank Mayhar <fmayhar@xxxxxxxxxx>
Google, Inc.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: HTTP/1.1 400 Bad Request (The data is invalid).
    ... This posting is provided "AS IS" with no warranties, ... installation of this patch my I have got this error. ... Microsoft Knowledge Base by reading the article no. ... problem but there is no fix available there. ...
    (microsoft.public.isa.clients)
  • Re: [SLE] {OT - anti - flame - post} Re: [SLE] SuSE9.2 64-Bit installation problems
    ... at the bottom, I scroll down to where it is. ... posting almost exclusively, those guys get hundreds of postings a day ... Will you send another patch to fix the prototype? ...
    (SuSE)
  • Re: OE bottom posting in news
    ... |> Is there a patch to fix this eternal problem in OE? ... |> Fed up with default being top posting! ...
    (microsoft.public.windows.inetexplorer.ie6_outlookexpress)
  • Re: Network doesnt work after installing Critical Update Patch.
    ... Posting on MS newsgroup will benefit all readers and you may get more help. ... > installing the patch it prompts him to reboot his computer. ... > I usually see this problem after installing some patches from Windows ... > are supposed to fix things, ...
    (microsoft.public.windowsxp.network_web)
  • Linux 2.6.19
    ... knowing that it's all your own d*mn fault, and you should just fix your ... [SCSI] ... [PATCH] ... USB: ipaq: Add HTC Modem Support ...
    (Linux-Kernel)