lkml.org 
[lkml]   [2008]   [Jan]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [RESEND][PATCH-2.6.24-rc8] Fix fakephp deadlock
On Tue, Jan 22, 2008 at 02:28:08PM +0000, Ian Abbott wrote:
> #include <linux/init.h>
> #include <linux/string.h>
> #include <linux/slab.h>
> +#include <linux/workqueue.h>
> #include "../pci.h"
> #if !defined(MODULE)
> @@ -63,10 +64,13 @@ struct dummy_slot {
> struct list_head node;
> struct hotplug_slot *slot;
> struct pci_dev *dev;
> + struct work_struct remove_work;
> + unsigned long removed;

You are treating "removed" as an atomic value, so why not just make it
an atomic_t?

And what is protecting the fact that the flag could be set right after
it gets checked? I don't see a lock here :)

thanks,

greg k-h


\
 
 \ /
  Last update: 2008-01-23 18:55    [W:0.036 / U:0.336 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site