Deleted Added
full compact
ips_pci.c (196403) ips_pci.c (200620)
1/*-
2 * Copyright (c) 2002 Adaptec Inc.
3 * All rights reserved.
4 *
5 * Written by: David Jeffery
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 13 unchanged lines hidden (view full) ---

22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 * SUCH DAMAGE.
27 */
28
29#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2002 Adaptec Inc.
3 * All rights reserved.
4 *
5 * Written by: David Jeffery
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 13 unchanged lines hidden (view full) ---

22 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
23 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
24 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
25 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
26 * SUCH DAMAGE.
27 */
28
29#include <sys/cdefs.h>
30__FBSDID("$FreeBSD: head/sys/dev/ips/ips_pci.c 196403 2009-08-20 19:17:53Z jhb $");
30__FBSDID("$FreeBSD: head/sys/dev/ips/ips_pci.c 200620 2009-12-17 00:21:12Z mjacob $");
31
32#include <dev/ips/ipsreg.h>
33#include <dev/ips/ips.h>
34
35#include <dev/pci/pcireg.h>
36#include <dev/pci/pcivar.h>
37
38static int ips_pci_free(ips_softc_t *sc);

--- 110 unchanged lines hidden (view full) ---

149 /* lockfunc */ NULL,
150 /* lockarg */ NULL,
151 &sc->adapter_dmatag) != 0) {
152 printf("IPS can't alloc dma tag\n");
153 goto error;
154 }
155 sc->ips_ich.ich_func = ips_intrhook;
156 sc->ips_ich.ich_arg = sc;
31
32#include <dev/ips/ipsreg.h>
33#include <dev/ips/ips.h>
34
35#include <dev/pci/pcireg.h>
36#include <dev/pci/pcivar.h>
37
38static int ips_pci_free(ips_softc_t *sc);

--- 110 unchanged lines hidden (view full) ---

149 /* lockfunc */ NULL,
150 /* lockarg */ NULL,
151 &sc->adapter_dmatag) != 0) {
152 printf("IPS can't alloc dma tag\n");
153 goto error;
154 }
155 sc->ips_ich.ich_func = ips_intrhook;
156 sc->ips_ich.ich_arg = sc;
157 mtx_init(&sc->queue_mtx, "IPS bioqueue lock", MTX_DEF, 0);
157 mtx_init(&sc->queue_mtx, "IPS bioqueue lock", NULL, MTX_DEF);
158 sema_init(&sc->cmd_sema, 0, "IPS Command Semaphore");
159 bioq_init(&sc->queue);
160 if (config_intrhook_establish(&sc->ips_ich) != 0) {
161 printf("IPS can't establish configuration hook\n");
162 goto error;
163 }
164 return 0;
165error:

--- 73 unchanged lines hidden ---
158 sema_init(&sc->cmd_sema, 0, "IPS Command Semaphore");
159 bioq_init(&sc->queue);
160 if (config_intrhook_establish(&sc->ips_ich) != 0) {
161 printf("IPS can't establish configuration hook\n");
162 goto error;
163 }
164 return 0;
165error:

--- 73 unchanged lines hidden ---