ida.c (111337) | ida.c (111748) |
---|---|
1/*- 2 * Copyright (c) 1999,2000 Jonathan Lemon 3 * All rights reserved. 4 * 5 # Derived from the original IDA Compaq RAID driver, which is 6 * Copyright (c) 1996, 1997, 1998, 1999 7 * Mark Dawson and David James. All rights reserved. 8 * --- 13 unchanged lines hidden (view full) --- 22 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 28 * SUCH DAMAGE. 29 * | 1/*- 2 * Copyright (c) 1999,2000 Jonathan Lemon 3 * All rights reserved. 4 * 5 # Derived from the original IDA Compaq RAID driver, which is 6 * Copyright (c) 1996, 1997, 1998, 1999 7 * Mark Dawson and David James. All rights reserved. 8 * --- 13 unchanged lines hidden (view full) --- 22 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 28 * SUCH DAMAGE. 29 * |
30 * $FreeBSD: head/sys/dev/ida/ida.c 111337 2003-02-23 18:45:50Z phk $ | 30 * $FreeBSD: head/sys/dev/ida/ida.c 111748 2003-03-02 16:54:40Z des $ |
31 */ 32 33/* 34 * Generic driver for Compaq SMART RAID adapters. 35 * 36 * Specific probe routines are in: 37 * pci/ida_pci.c 38 * i386/eisa/ida_eisa.c --- 401 unchanged lines hidden (view full) --- 440static int 441ida_wait(struct ida_softc *ida, struct ida_qcb *qcb) 442{ 443 struct ida_qcb *qcb_done = NULL; 444 bus_addr_t completed; 445 int delay; 446 447 if (ida->flags & IDA_INTERRUPTS) { | 31 */ 32 33/* 34 * Generic driver for Compaq SMART RAID adapters. 35 * 36 * Specific probe routines are in: 37 * pci/ida_pci.c 38 * i386/eisa/ida_eisa.c --- 401 unchanged lines hidden (view full) --- 440static int 441ida_wait(struct ida_softc *ida, struct ida_qcb *qcb) 442{ 443 struct ida_qcb *qcb_done = NULL; 444 bus_addr_t completed; 445 int delay; 446 447 if (ida->flags & IDA_INTERRUPTS) { |
448 if (tsleep((caddr_t)qcb, PRIBIO, "idacmd", 5 * hz)) | 448 if (tsleep(qcb, PRIBIO, "idacmd", 5 * hz)) |
449 return (ETIMEDOUT); 450 return (0); 451 } 452 453again: 454 delay = 5 * 1000 * 100; /* 5 sec delay */ 455 while ((completed = ida->cmd.done(ida)) == 0) { 456 if (delay-- == 0) --- 80 unchanged lines hidden --- | 449 return (ETIMEDOUT); 450 return (0); 451 } 452 453again: 454 delay = 5 * 1000 * 100; /* 5 sec delay */ 455 while ((completed = ida->cmd.done(ida)) == 0) { 456 if (delay-- == 0) --- 80 unchanged lines hidden --- |