diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2013-11-14 12:10:06 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2013-11-14 12:10:06 +0000 |
commit | 022a2c0428dcc6312014dc24f0be4a756f374019 (patch) | |
tree | 06be8d178e4119cd7c2c7a2cec64d9f950930444 /sys/dev | |
parent | 6bbcac4f3b51ed4714e2bf136f5f51c6880343b3 (diff) |
replace workqs with tasks for handling resume
from kimberley manning
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/cardbus/if_bwi_cardbus.c | 4 | ||||
-rw-r--r-- | sys/dev/ic/bwi.c | 4 | ||||
-rw-r--r-- | sys/dev/ic/bwivar.h | 4 | ||||
-rw-r--r-- | sys/dev/pci/if_bwi_pci.c | 9 |
4 files changed, 11 insertions, 10 deletions
diff --git a/sys/dev/cardbus/if_bwi_cardbus.c b/sys/dev/cardbus/if_bwi_cardbus.c index e4e5b3c90bf..763b919b6ee 100644 --- a/sys/dev/cardbus/if_bwi_cardbus.c +++ b/sys/dev/cardbus/if_bwi_cardbus.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_bwi_cardbus.c,v 1.13 2010/08/06 05:26:24 mglocker Exp $ */ +/* $OpenBSD: if_bwi_cardbus.c,v 1.14 2013/11/14 12:10:04 dlg Exp $ */ /* * Copyright (c) 2007 Marcus Glocker <mglocker@openbsd.org> @@ -24,7 +24,7 @@ #include "bpfilter.h" #include <sys/param.h> -#include <sys/workq.h> +#include <sys/task.h> #include <sys/mbuf.h> #include <sys/socket.h> #include <sys/systm.h> diff --git a/sys/dev/ic/bwi.c b/sys/dev/ic/bwi.c index ff4c68d3511..68f7ebd91ff 100644 --- a/sys/dev/ic/bwi.c +++ b/sys/dev/ic/bwi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bwi.c,v 1.98 2013/10/01 20:05:59 sf Exp $ */ +/* $OpenBSD: bwi.c,v 1.99 2013/11/14 12:10:04 dlg Exp $ */ /* * Copyright (c) 2007 The DragonFly Project. All rights reserved. @@ -44,7 +44,7 @@ #include <sys/device.h> #include <sys/kernel.h> #include <sys/malloc.h> -#include <sys/workq.h> +#include <sys/task.h> #include <sys/mbuf.h> #include <sys/proc.h> #include <sys/socket.h> diff --git a/sys/dev/ic/bwivar.h b/sys/dev/ic/bwivar.h index e7f428354bb..d00a147dbc7 100644 --- a/sys/dev/ic/bwivar.h +++ b/sys/dev/ic/bwivar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: bwivar.h,v 1.26 2010/08/06 05:26:24 mglocker Exp $ */ +/* $OpenBSD: bwivar.h,v 1.27 2013/11/14 12:10:05 dlg Exp $ */ /* * Copyright (c) 2007 The DragonFly Project. All rights reserved. @@ -620,7 +620,7 @@ struct bwi_softc { #define sc_txtap sc_txtapu.th int sc_txtap_len; #endif - struct workq_task sc_resume_wqt; + struct task sc_resume_t; }; #define BWI_F_BUS_INITED 0x1 diff --git a/sys/dev/pci/if_bwi_pci.c b/sys/dev/pci/if_bwi_pci.c index f2a2919062f..158e4eb5310 100644 --- a/sys/dev/pci/if_bwi_pci.c +++ b/sys/dev/pci/if_bwi_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_bwi_pci.c,v 1.12 2010/08/08 12:02:25 mglocker Exp $ */ +/* $OpenBSD: if_bwi_pci.c,v 1.13 2013/11/14 12:10:05 dlg Exp $ */ /* * Copyright (c) 2007 Marcus Glocker <mglocker@openbsd.org> @@ -24,7 +24,7 @@ #include <sys/param.h> #include <sys/sockio.h> -#include <sys/workq.h> +#include <sys/task.h> #include <sys/mbuf.h> #include <sys/kernel.h> #include <sys/socket.h> @@ -125,6 +125,8 @@ bwi_pci_attach(struct device *parent, struct device *self, void *aux) psc->psc_pc = pa->pa_pc; psc->psc_pcitag = pa->pa_tag; + task_set(&sc->sc_resume_t, bwi_pci_resume, sc, NULL); + /* map control / status registers */ memtype = pci_mapreg_type(pa->pa_pc, pa->pa_tag, BWI_PCI_BAR0); if (pci_mapreg_map(pa, BWI_PCI_BAR0, memtype, 0, &sc->sc_mem_bt, @@ -191,8 +193,7 @@ bwi_pci_activate(struct device *self, int act) bwi_stop(sc, 1); break; case DVACT_RESUME: - workq_queue_task(NULL, &sc->sc_resume_wqt, 0, - bwi_pci_resume, sc, NULL); + task_add(systq, &sc->sc_resume_t); break; } |