aac.c (138635) | aac.c (143838) |
---|---|
1/*- 2 * Copyright (c) 2000 Michael Smith 3 * Copyright (c) 2001 Scott Long 4 * Copyright (c) 2000 BSDi 5 * Copyright (c) 2001 Adaptec, Inc. 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 14 unchanged lines hidden (view full) --- 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 */ 29 30#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2000 Michael Smith 3 * Copyright (c) 2001 Scott Long 4 * Copyright (c) 2000 BSDi 5 * Copyright (c) 2001 Adaptec, Inc. 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 14 unchanged lines hidden (view full) --- 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 */ 29 30#include <sys/cdefs.h> |
31__FBSDID("$FreeBSD: head/sys/dev/aac/aac.c 138635 2004-12-09 22:20:25Z scottl $"); | 31__FBSDID("$FreeBSD: head/sys/dev/aac/aac.c 143838 2005-03-19 06:29:32Z scottl $"); |
32 33/* 34 * Driver for the Adaptec 'FSA' family of PCI/SCSI RAID adapters. 35 */ 36 37#include "opt_aac.h" 38 39/* #include <stddef.h> */ --- 9 unchanged lines hidden (view full) --- 49#include <sys/bus.h> 50#include <sys/conf.h> 51#include <sys/signalvar.h> 52#include <sys/time.h> 53#include <sys/eventhandler.h> 54 55#include <machine/bus_memio.h> 56#include <machine/bus.h> | 32 33/* 34 * Driver for the Adaptec 'FSA' family of PCI/SCSI RAID adapters. 35 */ 36 37#include "opt_aac.h" 38 39/* #include <stddef.h> */ --- 9 unchanged lines hidden (view full) --- 49#include <sys/bus.h> 50#include <sys/conf.h> 51#include <sys/signalvar.h> 52#include <sys/time.h> 53#include <sys/eventhandler.h> 54 55#include <machine/bus_memio.h> 56#include <machine/bus.h> |
57#include <sys/bus_dma.h> |
|
57#include <machine/resource.h> 58 59#include <dev/aac/aacreg.h> 60#include <sys/aac_ioctl.h> 61#include <dev/aac/aacvar.h> 62#include <dev/aac/aac_tables.h> 63 64static void aac_startup(void *arg); --- 2949 unchanged lines hidden (view full) --- 3014 3015 found = 0; 3016 for (i = 0; i < businfo.BusCount; i++) { 3017 if (businfo.BusValid[i] != AAC_BUS_VALID) 3018 continue; 3019 3020 caminf = (struct aac_sim *)malloc( sizeof(struct aac_sim), 3021 M_AACBUF, M_NOWAIT | M_ZERO); | 58#include <machine/resource.h> 59 60#include <dev/aac/aacreg.h> 61#include <sys/aac_ioctl.h> 62#include <dev/aac/aacvar.h> 63#include <dev/aac/aac_tables.h> 64 65static void aac_startup(void *arg); --- 2949 unchanged lines hidden (view full) --- 3015 3016 found = 0; 3017 for (i = 0; i < businfo.BusCount; i++) { 3018 if (businfo.BusValid[i] != AAC_BUS_VALID) 3019 continue; 3020 3021 caminf = (struct aac_sim *)malloc( sizeof(struct aac_sim), 3022 M_AACBUF, M_NOWAIT | M_ZERO); |
3022 if (caminf == NULL) 3023 continue; | 3023 if (caminf == NULL) { 3024 device_printf(sc->aac_dev, 3025 "No memory to add passthrough bus %d\n", i); 3026 break; 3027 } |
3024 3025 child = device_add_child(sc->aac_dev, "aacp", -1); 3026 if (child == NULL) { | 3028 3029 child = device_add_child(sc->aac_dev, "aacp", -1); 3030 if (child == NULL) { |
3027 device_printf(sc->aac_dev, "device_add_child failed\n"); 3028 continue; | 3031 device_printf(sc->aac_dev, 3032 "device_add_child failed for passthrough bus %d\n", 3033 i); 3034 free(caminf, M_AACBUF); 3035 break; |
3029 } 3030 3031 caminf->TargetsPerBus = businfo.TargetsPerBus; 3032 caminf->BusNumber = i; 3033 caminf->InitiatorBusId = businfo.InitiatorBusId[i]; 3034 caminf->aac_sc = sc; 3035 caminf->sim_dev = child; 3036 --- 12 unchanged lines hidden --- | 3036 } 3037 3038 caminf->TargetsPerBus = businfo.TargetsPerBus; 3039 caminf->BusNumber = i; 3040 caminf->InitiatorBusId = businfo.InitiatorBusId[i]; 3041 caminf->aac_sc = sc; 3042 caminf->sim_dev = child; 3043 --- 12 unchanged lines hidden --- |