isp_pci.c (9bffbcd4f5706e9ccfe7446bf29a8b6bdf2d09ea) | isp_pci.c (b97fc9487396ea5f41fd28ea6266057508425646) |
---|---|
1/* $FreeBSD$ */ | 1/* $FreeBSD$ */ |
2/* $Id: isp_pci.c,v 1.1 1998/04/22 18:10:34 mjacob Exp $ */ | 2/* $Id: isp_pci.c,v 1.2 1998/07/13 09:53:09 bde Exp $ */ |
3/* 4 * PCI specific probe and attach routines for Qlogic ISP SCSI adapters. 5 * FreeBSD Version. 6 * 7 *--------------------------------------- 8 * Copyright (c) 1997, 1998 by Matthew Jacob 9 * NASA/Ames Research Center 10 * All rights reserved. --- 110 unchanged lines hidden (view full) --- 121 122 123#define I386_BUS_SPACE_IO 0 124#define I386_BUS_SPACE_MEM 1 125typedef int bus_space_tag_t; 126typedef u_long bus_space_handle_t; 127#define bus_space_read_2(st, sh, offset) \ 128 (st == I386_BUS_SPACE_IO)? \ | 3/* 4 * PCI specific probe and attach routines for Qlogic ISP SCSI adapters. 5 * FreeBSD Version. 6 * 7 *--------------------------------------- 8 * Copyright (c) 1997, 1998 by Matthew Jacob 9 * NASA/Ames Research Center 10 * All rights reserved. --- 110 unchanged lines hidden (view full) --- 121 122 123#define I386_BUS_SPACE_IO 0 124#define I386_BUS_SPACE_MEM 1 125typedef int bus_space_tag_t; 126typedef u_long bus_space_handle_t; 127#define bus_space_read_2(st, sh, offset) \ 128 (st == I386_BUS_SPACE_IO)? \ |
129 inw((u_int16_t)sh + offset) : *((u_int16_t *) sh) | 129 inw((u_int16_t)sh + offset) : *((u_int16_t *)(uintptr_t)sh) |
130#define bus_space_write_2(st, sh, offset, val) \ 131 if (st == I386_BUS_SPACE_IO) outw((u_int16_t)sh + offset, val); else \ | 130#define bus_space_write_2(st, sh, offset, val) \ 131 if (st == I386_BUS_SPACE_IO) outw((u_int16_t)sh + offset, val); else \ |
132 *((u_int16_t *) sh) = val | 132 *((u_int16_t *)(uintptr_t)sh) = val |
133 134 135struct isp_pcisoftc { 136 struct ispsoftc pci_isp; 137 pcici_t pci_id; 138 bus_space_tag_t pci_st; 139 bus_space_handle_t pci_sh; 140 union { --- 419 unchanged lines hidden --- | 133 134 135struct isp_pcisoftc { 136 struct ispsoftc pci_isp; 137 pcici_t pci_id; 138 bus_space_tag_t pci_st; 139 bus_space_handle_t pci_sh; 140 union { --- 419 unchanged lines hidden --- |