isp_sbus.c (103823) | isp_sbus.c (109623) |
---|---|
1/* $FreeBSD: head/sys/dev/isp/isp_sbus.c 103823 2002-09-23 05:03:34Z mjacob $ */ | 1/* $FreeBSD: head/sys/dev/isp/isp_sbus.c 109623 2003-01-21 08:56:16Z alfred $ */ |
2/* 3 * PCI specific probe and attach routines for Qlogic ISP SCSI adapters. 4 * FreeBSD Version. 5 * 6 * Copyright (c) 1997, 1998, 1999, 2000, 2001 by Matthew Jacob 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions --- 483 unchanged lines hidden (view full) --- 493 NULL, NULL, BUS_SPACE_MAXSIZE_32BIT, ISP_NSEGS, 494 BUS_SPACE_MAXADDR_24BIT, 0, &sbs->dmat)) { 495 isp_prt(isp, ISP_LOGERR, "could not create master dma tag"); 496 ISP_LOCK(isp); 497 return(1); 498 } 499 500 len = sizeof (XS_T **) * isp->isp_maxcmds; | 2/* 3 * PCI specific probe and attach routines for Qlogic ISP SCSI adapters. 4 * FreeBSD Version. 5 * 6 * Copyright (c) 1997, 1998, 1999, 2000, 2001 by Matthew Jacob 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions --- 483 unchanged lines hidden (view full) --- 493 NULL, NULL, BUS_SPACE_MAXSIZE_32BIT, ISP_NSEGS, 494 BUS_SPACE_MAXADDR_24BIT, 0, &sbs->dmat)) { 495 isp_prt(isp, ISP_LOGERR, "could not create master dma tag"); 496 ISP_LOCK(isp); 497 return(1); 498 } 499 500 len = sizeof (XS_T **) * isp->isp_maxcmds; |
501 isp->isp_xflist = (XS_T **) malloc(len, M_DEVBUF, M_WAITOK | M_ZERO); | 501 isp->isp_xflist = (XS_T **) malloc(len, M_DEVBUF, M_ZERO); |
502 if (isp->isp_xflist == NULL) { 503 isp_prt(isp, ISP_LOGERR, "cannot alloc xflist array"); 504 ISP_LOCK(isp); 505 return (1); 506 } 507 len = sizeof (bus_dmamap_t) * isp->isp_maxcmds; | 502 if (isp->isp_xflist == NULL) { 503 isp_prt(isp, ISP_LOGERR, "cannot alloc xflist array"); 504 ISP_LOCK(isp); 505 return (1); 506 } 507 len = sizeof (bus_dmamap_t) * isp->isp_maxcmds; |
508 sbs->dmaps = (bus_dmamap_t *) malloc(len, M_DEVBUF, M_WAITOK); | 508 sbs->dmaps = (bus_dmamap_t *) malloc(len, M_DEVBUF, 0); |
509 if (sbs->dmaps == NULL) { 510 isp_prt(isp, ISP_LOGERR, "can't alloc dma map storage"); 511 free(isp->isp_xflist, M_DEVBUF); 512 ISP_LOCK(isp); 513 return (1); 514 } 515 516 /* --- 336 unchanged lines hidden --- | 509 if (sbs->dmaps == NULL) { 510 isp_prt(isp, ISP_LOGERR, "can't alloc dma map storage"); 511 free(isp->isp_xflist, M_DEVBUF); 512 ISP_LOCK(isp); 513 return (1); 514 } 515 516 /* --- 336 unchanged lines hidden --- |