diff options
| author | Matt Jacob <mjacob@FreeBSD.org> | 1999-11-21 03:14:04 +0000 |
|---|---|---|
| committer | Matt Jacob <mjacob@FreeBSD.org> | 1999-11-21 03:14:04 +0000 |
| commit | 840e8002a043a77c2b103db4c45708e68128cca6 (patch) | |
| tree | 597e81c22061ef66d5d7079c65a9f2ae9b870b25 /sys/dev/isp/isp_inline.h | |
| parent | 80ae565585bf814c9c4e0124132d30d31d5cd06c (diff) | |
Notes
Diffstat (limited to 'sys/dev/isp/isp_inline.h')
| -rw-r--r-- | sys/dev/isp/isp_inline.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/sys/dev/isp/isp_inline.h b/sys/dev/isp/isp_inline.h index c401a791f4ca..68acce3ef89f 100644 --- a/sys/dev/isp/isp_inline.h +++ b/sys/dev/isp/isp_inline.h @@ -217,4 +217,28 @@ isp_remove_handle(isp, xs) { isp_destroy_handle(isp, isp_find_handle(isp, xs)); } + +static INLINE int +isp_getrqentry __P((struct ispsoftc *, u_int16_t *, u_int16_t *, void **)); + +static INLINE int +isp_getrqentry(isp, iptrp, optrp, resultp) + struct ispsoftc *isp; + u_int16_t *iptrp; + u_int16_t *optrp; + void **resultp; +{ + volatile u_int16_t iptr, optr; + + optr = isp->isp_reqodx = ISP_READ(isp, OUTMAILBOX4); + iptr = isp->isp_reqidx; + *resultp = ISP_QUEUE_ENTRY(isp->isp_rquest, iptr); + iptr = ISP_NXT_QENTRY(iptr, RQUEST_QUEUE_LEN); + if (iptr == optr) { + return (1); + } + *optrp = optr; + *iptrp = iptr; + return (0); +} #endif /* _ISP_INLINE_H */ |
