diff options
| author | Scott Long <scottl@FreeBSD.org> | 2002-12-01 07:50:56 +0000 |
|---|---|---|
| committer | Scott Long <scottl@FreeBSD.org> | 2002-12-01 07:50:56 +0000 |
| commit | 481a41742f0cf3f887dbdc064990af6243d3b002 (patch) | |
| tree | dc7410f752702403d78df884b40f3dee632ae35f /sys/dev | |
| parent | 38857e7f73e3beffb707caa1694f1e87f0cf42e8 (diff) | |
Notes
Diffstat (limited to 'sys/dev')
| -rw-r--r-- | sys/dev/aic7xxx/aic79xx_osm.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/sys/dev/aic7xxx/aic79xx_osm.h b/sys/dev/aic7xxx/aic79xx_osm.h index b645010b22b42..6379a02740b49 100644 --- a/sys/dev/aic7xxx/aic79xx_osm.h +++ b/sys/dev/aic7xxx/aic79xx_osm.h @@ -30,7 +30,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#14 $ + * $Id: //depot/aic7xxx/freebsd/dev/aic7xxx/aic79xx_osm.h#18 $ * * $FreeBSD$ */ @@ -222,6 +222,7 @@ typedef struct callout ahd_timer_t; #include <dev/aic7xxx/aic79xx.h> /***************************** Timer Facilities *******************************/ +timeout_t ahd_timeout; #if __FreeBSD_version >= 500000 #define ahd_timer_init(timer) callout_init(timer, /*mpsafe*/0) #else @@ -230,11 +231,18 @@ typedef struct callout ahd_timer_t; #define ahd_timer_stop callout_stop static __inline void -ahd_timer_reset(ahd_timer_t *timer, int usec, ahd_callback_t *func, void *arg) +ahd_timer_reset(ahd_timer_t *timer, u_int usec, ahd_callback_t *func, void *arg) { callout_reset(timer, (usec * hz)/1000000, func, arg); } +static __inline void +ahd_scb_timer_reset(struct scb *scb, u_int usec) +{ + callout_reset(scb->io_ctx->ccb_h.timeout_ch.callout, + (usec * hz)/1000000, ahd_timeout, scb); +} + /*************************** Device Access ************************************/ #define ahd_inb(ahd, port) \ bus_space_read_1((ahd)->tags[(port) >> 8], \ @@ -580,6 +588,8 @@ int ahd_map_int(struct ahd_softc *ahd); int ahd_attach(struct ahd_softc *); int ahd_softc_comp(struct ahd_softc *lahd, struct ahd_softc *rahd); int ahd_detach(device_t); +#define ahd_platform_init(arg) + /****************************** Interrupts ************************************/ void ahd_platform_intr(void *); @@ -590,7 +600,6 @@ ahd_platform_flushwork(struct ahd_softc *ahd) } /************************ Misc Function Declarations **************************/ -timeout_t ahd_timeout; void ahd_done(struct ahd_softc *ahd, struct scb *scb); void ahd_send_async(struct ahd_softc *, char /*channel*/, u_int /*target*/, u_int /*lun*/, ac_code, void *arg); |
