Skip to content

Commit

Permalink
WorkStruct: make allyesconfig
Browse files Browse the repository at this point in the history
Fix up for make allyesconfig.

Signed-Off-By: David Howells <[email protected]>
  • Loading branch information
dhowells committed Nov 22, 2006
1 parent 65f27f3 commit c402895
Show file tree
Hide file tree
Showing 282 changed files with 1,771 additions and 1,450 deletions.
6 changes: 3 additions & 3 deletions arch/i386/kernel/cpu/mcheck/non-fatal.c
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,10 @@ static void mce_checkregs (void *info)
}
}

static void mce_work_fn(void *data);
static DECLARE_WORK(mce_work, mce_work_fn, NULL);
static void mce_work_fn(struct work_struct *work);
static DECLARE_DELAYED_WORK(mce_work, mce_work_fn);

static void mce_work_fn(void *data)
static void mce_work_fn(struct work_struct *work)
{
on_each_cpu(mce_checkregs, NULL, 1, 1);
schedule_delayed_work(&mce_work, MCE_RATE);
Expand Down
11 changes: 6 additions & 5 deletions arch/i386/kernel/smpboot.c
Original file line number Diff line number Diff line change
Expand Up @@ -1049,13 +1049,15 @@ void cpu_exit_clear(void)

struct warm_boot_cpu_info {
struct completion *complete;
struct work_struct task;
int apicid;
int cpu;
};

static void __cpuinit do_warm_boot_cpu(void *p)
static void __cpuinit do_warm_boot_cpu(struct work_struct *work)
{
struct warm_boot_cpu_info *info = p;
struct warm_boot_cpu_info *info =
container_of(work, struct warm_boot_cpu_info, task);
do_boot_cpu(info->apicid, info->cpu);
complete(info->complete);
}
Expand All @@ -1064,7 +1066,6 @@ static int __cpuinit __smp_prepare_cpu(int cpu)
{
DECLARE_COMPLETION_ONSTACK(done);
struct warm_boot_cpu_info info;
struct work_struct task;
int apicid, ret;
struct Xgt_desc_struct *cpu_gdt_descr = &per_cpu(cpu_gdt_descr, cpu);

Expand All @@ -1089,15 +1090,15 @@ static int __cpuinit __smp_prepare_cpu(int cpu)
info.complete = &done;
info.apicid = apicid;
info.cpu = cpu;
INIT_WORK(&task, do_warm_boot_cpu, &info);
INIT_WORK(&info.task, do_warm_boot_cpu);

tsc_sync_disabled = 1;

/* init low mem mapping */
clone_pgd_range(swapper_pg_dir, swapper_pg_dir + USER_PGD_PTRS,
KERNEL_PGD_PTRS);
flush_tlb_all();
schedule_work(&task);
schedule_work(&info.task);
wait_for_completion(&done);

tsc_sync_disabled = 0;
Expand Down
4 changes: 2 additions & 2 deletions arch/i386/kernel/tsc.c
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ static unsigned int cpufreq_delayed_issched = 0;
static unsigned int cpufreq_init = 0;
static struct work_struct cpufreq_delayed_get_work;

static void handle_cpufreq_delayed_get(void *v)
static void handle_cpufreq_delayed_get(struct work_struct *work)
{
unsigned int cpu;

Expand Down Expand Up @@ -306,7 +306,7 @@ static int __init cpufreq_tsc(void)
{
int ret;

INIT_WORK(&cpufreq_delayed_get_work, handle_cpufreq_delayed_get, NULL);
INIT_WORK(&cpufreq_delayed_get_work, handle_cpufreq_delayed_get);
ret = cpufreq_register_notifier(&time_cpufreq_notifier_block,
CPUFREQ_TRANSITION_NOTIFIER);
if (!ret)
Expand Down
6 changes: 3 additions & 3 deletions arch/powerpc/platforms/pseries/eeh_event.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
/* EEH event workqueue setup. */
static DEFINE_SPINLOCK(eeh_eventlist_lock);
LIST_HEAD(eeh_eventlist);
static void eeh_thread_launcher(void *);
DECLARE_WORK(eeh_event_wq, eeh_thread_launcher, NULL);
static void eeh_thread_launcher(struct work_struct *);
DECLARE_WORK(eeh_event_wq, eeh_thread_launcher);

/* Serialize reset sequences for a given pci device */
DEFINE_MUTEX(eeh_event_mutex);
Expand Down Expand Up @@ -103,7 +103,7 @@ static int eeh_event_handler(void * dummy)
* eeh_thread_launcher
* @dummy - unused
*/
static void eeh_thread_launcher(void *dummy)
static void eeh_thread_launcher(struct work_struct *dummy)
{
if (kernel_thread(eeh_event_handler, NULL, CLONE_KERNEL) < 0)
printk(KERN_ERR "Failed to start EEH daemon\n");
Expand Down
9 changes: 5 additions & 4 deletions drivers/atm/idt77252.c
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ static int idt77252_change_qos(struct atm_vcc *vcc, struct atm_qos *qos,
int flags);
static int idt77252_proc_read(struct atm_dev *dev, loff_t * pos,
char *page);
static void idt77252_softint(void *dev_id);
static void idt77252_softint(struct work_struct *work);


static struct atmdev_ops idt77252_ops =
Expand Down Expand Up @@ -2866,9 +2866,10 @@ idt77252_interrupt(int irq, void *dev_id)
}

static void
idt77252_softint(void *dev_id)
idt77252_softint(struct work_struct *work)
{
struct idt77252_dev *card = dev_id;
struct idt77252_dev *card =
container_of(work, struct idt77252_dev, tqueue);
u32 stat;
int done;

Expand Down Expand Up @@ -3697,7 +3698,7 @@ idt77252_init_one(struct pci_dev *pcidev, const struct pci_device_id *id)
card->pcidev = pcidev;
sprintf(card->name, "idt77252-%d", card->index);

INIT_WORK(&card->tqueue, idt77252_softint, (void *)card);
INIT_WORK(&card->tqueue, idt77252_softint);

membase = pci_resource_start(pcidev, 1);
srambase = pci_resource_start(pcidev, 2);
Expand Down
2 changes: 1 addition & 1 deletion drivers/block/aoe/aoe.h
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ void aoecmd_work(struct aoedev *d);
void aoecmd_cfg(ushort aoemajor, unsigned char aoeminor);
void aoecmd_ata_rsp(struct sk_buff *);
void aoecmd_cfg_rsp(struct sk_buff *);
void aoecmd_sleepwork(void *vp);
void aoecmd_sleepwork(struct work_struct *);
struct sk_buff *new_skb(ulong);

int aoedev_init(void);
Expand Down
4 changes: 2 additions & 2 deletions drivers/block/aoe/aoecmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -408,9 +408,9 @@ rexmit_timer(ulong vp)
/* this function performs work that has been deferred until sleeping is OK
*/
void
aoecmd_sleepwork(void *vp)
aoecmd_sleepwork(struct work_struct *work)
{
struct aoedev *d = (struct aoedev *) vp;
struct aoedev *d = container_of(work, struct aoedev, work);

if (d->flags & DEVFL_GDALLOC)
aoeblk_gdalloc(d);
Expand Down
2 changes: 1 addition & 1 deletion drivers/block/aoe/aoedev.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ aoedev_newdev(ulong nframes)
kfree(d);
return NULL;
}
INIT_WORK(&d->work, aoecmd_sleepwork, d);
INIT_WORK(&d->work, aoecmd_sleepwork);
spin_lock_init(&d->lock);
init_timer(&d->timer);
d->timer.data = (ulong) d;
Expand Down
8 changes: 4 additions & 4 deletions drivers/block/paride/pd.c
Original file line number Diff line number Diff line change
Expand Up @@ -352,19 +352,19 @@ static enum action (*phase)(void);

static void run_fsm(void);

static void ps_tq_int( void *data);
static void ps_tq_int(struct work_struct *work);

static DECLARE_WORK(fsm_tq, ps_tq_int, NULL);
static DECLARE_DELAYED_WORK(fsm_tq, ps_tq_int);

static void schedule_fsm(void)
{
if (!nice)
schedule_work(&fsm_tq);
schedule_delayed_work(&fsm_tq, 0);
else
schedule_delayed_work(&fsm_tq, nice-1);
}

static void ps_tq_int(void *data)
static void ps_tq_int(struct work_struct *work)
{
run_fsm();
}
Expand Down
10 changes: 5 additions & 5 deletions drivers/block/paride/pseudo.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <linux/sched.h>
#include <linux/workqueue.h>

static void ps_tq_int( void *data);
static void ps_tq_int(struct work_struct *work);

static void (* ps_continuation)(void);
static int (* ps_ready)(void);
Expand All @@ -45,7 +45,7 @@ static int ps_nice = 0;

static DEFINE_SPINLOCK(ps_spinlock __attribute__((unused)));

static DECLARE_WORK(ps_tq, ps_tq_int, NULL);
static DECLARE_DELAYED_WORK(ps_tq, ps_tq_int);

static void ps_set_intr(void (*continuation)(void),
int (*ready)(void),
Expand All @@ -63,14 +63,14 @@ static void ps_set_intr(void (*continuation)(void),
if (!ps_tq_active) {
ps_tq_active = 1;
if (!ps_nice)
schedule_work(&ps_tq);
schedule_delayed_work(&ps_tq, 0);
else
schedule_delayed_work(&ps_tq, ps_nice-1);
}
spin_unlock_irqrestore(&ps_spinlock,flags);
}

static void ps_tq_int(void *data)
static void ps_tq_int(struct work_struct *work)
{
void (*con)(void);
unsigned long flags;
Expand All @@ -92,7 +92,7 @@ static void ps_tq_int(void *data)
}
ps_tq_active = 1;
if (!ps_nice)
schedule_work(&ps_tq);
schedule_delayed_work(&ps_tq, 0);
else
schedule_delayed_work(&ps_tq, ps_nice-1);
spin_unlock_irqrestore(&ps_spinlock,flags);
Expand Down
7 changes: 4 additions & 3 deletions drivers/block/sx8.c
Original file line number Diff line number Diff line change
Expand Up @@ -1244,9 +1244,10 @@ static irqreturn_t carm_interrupt(int irq, void *__host)
return IRQ_RETVAL(handled);
}

static void carm_fsm_task (void *_data)
static void carm_fsm_task (struct work_struct *work)
{
struct carm_host *host = _data;
struct carm_host *host =
container_of(work, struct carm_host, fsm_task);
unsigned long flags;
unsigned int state;
int rc, i, next_dev;
Expand Down Expand Up @@ -1619,7 +1620,7 @@ static int carm_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
host->pdev = pdev;
host->flags = pci_dac ? FL_DAC : 0;
spin_lock_init(&host->lock);
INIT_WORK(&host->fsm_task, carm_fsm_task, host);
INIT_WORK(&host->fsm_task, carm_fsm_task);
init_completion(&host->probe_comp);

for (i = 0; i < ARRAY_SIZE(host->req); i++)
Expand Down
8 changes: 4 additions & 4 deletions drivers/block/ub.c
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ static int ub_submit_clear_stall(struct ub_dev *sc, struct ub_scsi_cmd *cmd,
int stalled_pipe);
static void ub_top_sense_done(struct ub_dev *sc, struct ub_scsi_cmd *scmd);
static void ub_reset_enter(struct ub_dev *sc, int try);
static void ub_reset_task(void *arg);
static void ub_reset_task(struct work_struct *work);
static int ub_sync_tur(struct ub_dev *sc, struct ub_lun *lun);
static int ub_sync_read_cap(struct ub_dev *sc, struct ub_lun *lun,
struct ub_capacity *ret);
Expand Down Expand Up @@ -1558,9 +1558,9 @@ static void ub_reset_enter(struct ub_dev *sc, int try)
schedule_work(&sc->reset_work);
}

static void ub_reset_task(void *arg)
static void ub_reset_task(struct work_struct *work)
{
struct ub_dev *sc = arg;
struct ub_dev *sc = container_of(work, struct ub_dev, reset_work);
unsigned long flags;
struct list_head *p;
struct ub_lun *lun;
Expand Down Expand Up @@ -2179,7 +2179,7 @@ static int ub_probe(struct usb_interface *intf,
usb_init_urb(&sc->work_urb);
tasklet_init(&sc->tasklet, ub_scsi_action, (unsigned long)sc);
atomic_set(&sc->poison, 0);
INIT_WORK(&sc->reset_work, ub_reset_task, sc);
INIT_WORK(&sc->reset_work, ub_reset_task);
init_waitqueue_head(&sc->reset_wait);

init_timer(&sc->work_timer);
Expand Down
7 changes: 4 additions & 3 deletions drivers/bluetooth/bcm203x.c
Original file line number Diff line number Diff line change
Expand Up @@ -157,9 +157,10 @@ static void bcm203x_complete(struct urb *urb)
}
}

static void bcm203x_work(void *user_data)
static void bcm203x_work(struct work_struct *work)
{
struct bcm203x_data *data = user_data;
struct bcm203x_data *data =
container_of(work, struct bcm203x_data, work);

if (usb_submit_urb(data->urb, GFP_ATOMIC) < 0)
BT_ERR("Can't submit URB");
Expand Down Expand Up @@ -246,7 +247,7 @@ static int bcm203x_probe(struct usb_interface *intf, const struct usb_device_id

release_firmware(firmware);

INIT_WORK(&data->work, bcm203x_work, (void *) data);
INIT_WORK(&data->work, bcm203x_work);

usb_set_intfdata(intf, data);

Expand Down
9 changes: 5 additions & 4 deletions drivers/char/cyclades.c
Original file line number Diff line number Diff line change
Expand Up @@ -926,9 +926,10 @@ cy_sched_event(struct cyclades_port *info, int event)
* had to poll every port to see if that port needed servicing.
*/
static void
do_softint(void *private_)
do_softint(struct work_struct *work)
{
struct cyclades_port *info = (struct cyclades_port *) private_;
struct cyclades_port *info =
container_of(work, struct cyclades_port, tqueue);
struct tty_struct *tty;

tty = info->tty;
Expand Down Expand Up @@ -5328,7 +5329,7 @@ cy_init(void)
info->blocked_open = 0;
info->default_threshold = 0;
info->default_timeout = 0;
INIT_WORK(&info->tqueue, do_softint, info);
INIT_WORK(&info->tqueue, do_softint);
init_waitqueue_head(&info->open_wait);
init_waitqueue_head(&info->close_wait);
init_waitqueue_head(&info->shutdown_wait);
Expand Down Expand Up @@ -5403,7 +5404,7 @@ cy_init(void)
info->blocked_open = 0;
info->default_threshold = 0;
info->default_timeout = 0;
INIT_WORK(&info->tqueue, do_softint, info);
INIT_WORK(&info->tqueue, do_softint);
init_waitqueue_head(&info->open_wait);
init_waitqueue_head(&info->close_wait);
init_waitqueue_head(&info->shutdown_wait);
Expand Down
6 changes: 3 additions & 3 deletions drivers/char/drm/via_dmablit.c
Original file line number Diff line number Diff line change
Expand Up @@ -500,9 +500,9 @@ via_dmablit_timer(unsigned long data)


static void
via_dmablit_workqueue(void *data)
via_dmablit_workqueue(struct work_struct *work)
{
drm_via_blitq_t *blitq = (drm_via_blitq_t *) data;
drm_via_blitq_t *blitq = container_of(work, drm_via_blitq_t, wq);
drm_device_t *dev = blitq->dev;
unsigned long irqsave;
drm_via_sg_info_t *cur_sg;
Expand Down Expand Up @@ -571,7 +571,7 @@ via_init_dmablit(drm_device_t *dev)
DRM_INIT_WAITQUEUE(blitq->blit_queue + j);
}
DRM_INIT_WAITQUEUE(&blitq->busy_queue);
INIT_WORK(&blitq->wq, via_dmablit_workqueue, blitq);
INIT_WORK(&blitq->wq, via_dmablit_workqueue);
init_timer(&blitq->poll_timer);
blitq->poll_timer.function = &via_dmablit_timer;
blitq->poll_timer.data = (unsigned long) blitq;
Expand Down
8 changes: 4 additions & 4 deletions drivers/char/epca.c
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ static int pc_ioctl(struct tty_struct *, struct file *,
static int info_ioctl(struct tty_struct *, struct file *,
unsigned int, unsigned long);
static void pc_set_termios(struct tty_struct *, struct termios *);
static void do_softint(void *);
static void do_softint(struct work_struct *work);
static void pc_stop(struct tty_struct *);
static void pc_start(struct tty_struct *);
static void pc_throttle(struct tty_struct * tty);
Expand Down Expand Up @@ -1505,7 +1505,7 @@ static void post_fep_init(unsigned int crd)

ch->brdchan = bc;
ch->mailbox = gd;
INIT_WORK(&ch->tqueue, do_softint, ch);
INIT_WORK(&ch->tqueue, do_softint);
ch->board = &boards[crd];

spin_lock_irqsave(&epca_lock, flags);
Expand Down Expand Up @@ -2566,9 +2566,9 @@ static void pc_set_termios(struct tty_struct *tty, struct termios *old_termios)

/* --------------------- Begin do_softint ----------------------- */

static void do_softint(void *private_)
static void do_softint(struct work_struct *work)
{ /* Begin do_softint */
struct channel *ch = (struct channel *) private_;
struct channel *ch = container_of(work, struct channel, tqueue);
/* Called in response to a modem change event */
if (ch && ch->magic == EPCA_MAGIC) { /* Begin EPCA_MAGIC */
struct tty_struct *tty = ch->tty;
Expand Down
Loading

0 comments on commit c402895

Please sign in to comment.