diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2007-05-02 02:20:38 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2007-05-02 02:20:38 +0000 |
commit | 845d9d09285f28e135e5cf44c1c3059c33d0392d (patch) | |
tree | 10383304fd989555e6e51821e598cdaf62cf1c45 /sys/dev/ic/aic7xxx.c | |
parent | a86646f40726d8cec2ccf31f7052394e901118bc (diff) |
Eliminate unused inline functions and replace ahc_lock() which
resolves to s = splbio() and ahc_unlock() which resolves to splx(s)
with splbio/splx calls.
ok marco@ dlg@
Diffstat (limited to 'sys/dev/ic/aic7xxx.c')
-rw-r--r-- | sys/dev/ic/aic7xxx.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/sys/dev/ic/aic7xxx.c b/sys/dev/ic/aic7xxx.c index 7853327eea3..b6bce03ac1e 100644 --- a/sys/dev/ic/aic7xxx.c +++ b/sys/dev/ic/aic7xxx.c @@ -1,4 +1,4 @@ -/* $OpenBSD: aic7xxx.c,v 1.73 2006/07/30 14:21:14 krw Exp $ */ +/* $OpenBSD: aic7xxx.c,v 1.74 2007/05/02 02:20:36 krw Exp $ */ /* $NetBSD: aic7xxx.c,v 1.108 2003/11/02 11:07:44 wiz Exp $ */ /* @@ -40,7 +40,7 @@ * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGES. * - * $Id: aic7xxx.c,v 1.73 2006/07/30 14:21:14 krw Exp $ + * $Id: aic7xxx.c,v 1.74 2007/05/02 02:20:36 krw Exp $ */ /* * Ported from FreeBSD by Pascal Renauld, Network Storage Solutions, Inc. - April 2003 @@ -6898,10 +6898,10 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) ahc_flag saved_flags; printf("Configuring Target Mode\n"); - ahc_lock(ahc, &s); + s = splbio(); if (LIST_FIRST(&ahc->pending_scbs) != NULL) { ccb->ccb_h.status = CAM_BUSY; - ahc_unlock(ahc, &s); + splx(s); return; } saved_flags = ahc->flags; @@ -6922,12 +6922,12 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) ahc->flags = saved_flags; (void)ahc_loadseq(ahc); ahc_restart(ahc); - ahc_unlock(ahc, &s); + splx(s); ccb->ccb_h.status = CAM_FUNC_NOTAVAIL; return; } ahc_restart(ahc); - ahc_unlock(ahc, &s); + splx(s); } cel = &ccb->cel; target = ccb->ccb_h.target_id; @@ -6993,7 +6993,7 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) } SLIST_INIT(&lstate->accept_tios); SLIST_INIT(&lstate->immed_notifies); - ahc_lock(ahc, &s); + s = splbio(); ahc_pause(ahc); if (target != CAM_TARGET_WILDCARD) { tstate->enabled_luns[lun] = lstate; @@ -7059,7 +7059,7 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) ahc_outb(ahc, SCSISEQ, scsiseq); } ahc_unpause(ahc); - ahc_unlock(ahc, &s); + splx(s); ccb->ccb_h.status = CAM_REQ_CMP; xpt_print_path(ccb->ccb_h.path); printf("Lun now enabled for target mode\n"); @@ -7072,8 +7072,8 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) return; } - ahc_lock(ahc, &s); - + s = splbio(); + ccb->ccb_h.status = CAM_REQ_CMP; LIST_FOREACH(scb, &ahc->pending_scbs, pending_links) { struct ccb_hdr *ccbh; @@ -7083,7 +7083,7 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) && !xpt_path_comp(ccbh->path, ccb->ccb_h.path)){ printf("CTIO pending\n"); ccb->ccb_h.status = CAM_REQ_INVALID; - ahc_unlock(ahc, &s); + splx(s); return; } } @@ -7099,7 +7099,7 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) } if (ccb->ccb_h.status != CAM_REQ_CMP) { - ahc_unlock(ahc, &s); + splx(s); return; } @@ -7174,7 +7174,7 @@ ahc_handle_en_lun(struct ahc_softc *ahc, struct cam_sim *sim, union ccb *ccb) } } ahc_unpause(ahc); - ahc_unlock(ahc, &s); + splx(s); } } |