lkml.org 
[lkml]   [2006]   [Mar]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[patch] add private data to notifier_block
From
Date
While most current uses of notifier_block use a global struct, I would
like to be able to use it on a per device basis for drivers which have
multiple device instances. I would also like to be able to have a
private data struct associated with the notifier block so that per
device data can be easily accessed. This patch will modify the
notifier_block struct to add a void *, and will require no modifications
to any other users of the notifier_block.

Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>

---
include/linux/notifier.h | 1 +
1 files changed, 1 insertion(+)

--- 2.6-git-kca.orig/include/linux/notifier.h
+++ 2.6-git-kca/include/linux/notifier.h
@@ -15,6 +15,7 @@ struct notifier_block
{
int (*notifier_call)(struct notifier_block *self, unsigned long, void *);
struct notifier_block *next;
+ void *data;
int priority;
};

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2006-03-21 20:53    [W:0.065 / U:0.224 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site