diff options
author | Timo Teräs <timo.teras@iki.fi> | 2010-12-15 13:48:10 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-12-16 15:35:15 -0500 |
commit | 244ba85606b567e6e990d2fac61e3bde5ff8f0ad (patch) | |
tree | 73b5ee539a44b5e6b0f816ff3e742ccd233f90b6 /drivers | |
parent | 4b2f9abea52af3782d349080fca5e189b0693792 (diff) |
staging: hv: remove unneeded osd_schedule_callback
No one calls it anymore, so remove it.
Reviewed-By: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Timo Teräs <timo.teras@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/hv/osd.c | 34 | ||||
-rw-r--r-- | drivers/staging/hv/osd.h | 4 |
2 files changed, 0 insertions, 38 deletions
diff --git a/drivers/staging/hv/osd.c b/drivers/staging/hv/osd.c index b699ee27f07f..b5a3940331b3 100644 --- a/drivers/staging/hv/osd.c +++ b/drivers/staging/hv/osd.c | |||
@@ -43,12 +43,6 @@ | |||
43 | #include <linux/slab.h> | 43 | #include <linux/slab.h> |
44 | #include "osd.h" | 44 | #include "osd.h" |
45 | 45 | ||
46 | struct osd_callback_struct { | ||
47 | struct work_struct work; | ||
48 | void (*callback)(void *); | ||
49 | void *data; | ||
50 | }; | ||
51 | |||
52 | void *osd_virtual_alloc_exec(unsigned int size) | 46 | void *osd_virtual_alloc_exec(unsigned int size) |
53 | { | 47 | { |
54 | #ifdef __x86_64__ | 48 | #ifdef __x86_64__ |
@@ -198,31 +192,3 @@ int osd_waitevent_waitex(struct osd_waitevent *wait_event, u32 timeout_in_ms) | |||
198 | return ret; | 192 | return ret; |
199 | } | 193 | } |
200 | EXPORT_SYMBOL_GPL(osd_waitevent_waitex); | 194 | EXPORT_SYMBOL_GPL(osd_waitevent_waitex); |
201 | |||
202 | static void osd_callback_work(struct work_struct *work) | ||
203 | { | ||
204 | struct osd_callback_struct *cb = container_of(work, | ||
205 | struct osd_callback_struct, | ||
206 | work); | ||
207 | (cb->callback)(cb->data); | ||
208 | kfree(cb); | ||
209 | } | ||
210 | |||
211 | int osd_schedule_callback(struct workqueue_struct *wq, | ||
212 | void (*func)(void *), | ||
213 | void *data) | ||
214 | { | ||
215 | struct osd_callback_struct *cb; | ||
216 | |||
217 | cb = kmalloc(sizeof(*cb), GFP_KERNEL); | ||
218 | if (!cb) { | ||
219 | printk(KERN_ERR "unable to allocate memory in osd_schedule_callback\n"); | ||
220 | return -1; | ||
221 | } | ||
222 | |||
223 | cb->callback = func; | ||
224 | cb->data = data; | ||
225 | INIT_WORK(&cb->work, osd_callback_work); | ||
226 | return queue_work(wq, &cb->work); | ||
227 | } | ||
228 | |||
diff --git a/drivers/staging/hv/osd.h b/drivers/staging/hv/osd.h index cae126ff6b9a..870ef0768833 100644 --- a/drivers/staging/hv/osd.h +++ b/drivers/staging/hv/osd.h | |||
@@ -63,8 +63,4 @@ extern int osd_waitevent_wait(struct osd_waitevent *wait_event); | |||
63 | extern int osd_waitevent_waitex(struct osd_waitevent *wait_event, | 63 | extern int osd_waitevent_waitex(struct osd_waitevent *wait_event, |
64 | u32 timeout_in_ms); | 64 | u32 timeout_in_ms); |
65 | 65 | ||
66 | int osd_schedule_callback(struct workqueue_struct *wq, | ||
67 | void (*func)(void *), | ||
68 | void *data); | ||
69 | |||
70 | #endif /* _OSD_H_ */ | 66 | #endif /* _OSD_H_ */ |