Deleted Added
full compact
cmi.c (142890) cmi.c (148590)
1/*-
2 * Copyright (c) 2000 Orion Hodson <O.Hodson@cs.ucl.ac.uk>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

46
47#include <dev/pci/pcireg.h>
48#include <dev/pci/pcivar.h>
49
50#include <sys/sysctl.h>
51
52#include "mixer_if.h"
53
1/*-
2 * Copyright (c) 2000 Orion Hodson <O.Hodson@cs.ucl.ac.uk>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

46
47#include <dev/pci/pcireg.h>
48#include <dev/pci/pcivar.h>
49
50#include <sys/sysctl.h>
51
52#include "mixer_if.h"
53
54SND_DECLARE_FILE("$FreeBSD: head/sys/dev/sound/pci/cmi.c 142890 2005-03-01 08:58:06Z imp $");
54SND_DECLARE_FILE("$FreeBSD: head/sys/dev/sound/pci/cmi.c 148590 2005-07-31 12:38:22Z netchild $");
55
56/* Supported chip ID's */
57#define CMI8338A_PCI_ID 0x010013f6
58#define CMI8338B_PCI_ID 0x010113f6
59#define CMI8738_PCI_ID 0x011113f6
60#define CMI8738B_PCI_ID 0x011213f6
61
62/* Buffer size max is 64k for permitted DMA boundaries */

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

871 sc->bufsz = pcm_getbuffersize(dev, 4096, CMI_DEFAULT_BUFSZ, 65536);
872
873 if (bus_dma_tag_create(/*parent*/NULL, /*alignment*/2, /*boundary*/0,
874 /*lowaddr*/BUS_SPACE_MAXADDR_32BIT,
875 /*highaddr*/BUS_SPACE_MAXADDR,
876 /*filter*/NULL, /*filterarg*/NULL,
877 /*maxsize*/sc->bufsz, /*nsegments*/1,
878 /*maxsegz*/0x3ffff, /*flags*/0,
55
56/* Supported chip ID's */
57#define CMI8338A_PCI_ID 0x010013f6
58#define CMI8338B_PCI_ID 0x010113f6
59#define CMI8738_PCI_ID 0x011113f6
60#define CMI8738B_PCI_ID 0x011213f6
61
62/* Buffer size max is 64k for permitted DMA boundaries */

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

871 sc->bufsz = pcm_getbuffersize(dev, 4096, CMI_DEFAULT_BUFSZ, 65536);
872
873 if (bus_dma_tag_create(/*parent*/NULL, /*alignment*/2, /*boundary*/0,
874 /*lowaddr*/BUS_SPACE_MAXADDR_32BIT,
875 /*highaddr*/BUS_SPACE_MAXADDR,
876 /*filter*/NULL, /*filterarg*/NULL,
877 /*maxsize*/sc->bufsz, /*nsegments*/1,
878 /*maxsegz*/0x3ffff, /*flags*/0,
879 /*lockfunc*/busdma_lock_mutex,
880 /*lockfunc*/&Giant,
879 /*lockfunc*/NULL,
880 /*lockfunc*/NULL,
881 &sc->parent_dmat) != 0) {
882 device_printf(dev, "cmi_attach: Unable to create dma tag\n");
883 goto bad;
884 }
885
886 cmi_power(sc, 0);
887 if (cmi_init(sc))
888 goto bad;

--- 124 unchanged lines hidden ---
881 &sc->parent_dmat) != 0) {
882 device_printf(dev, "cmi_attach: Unable to create dma tag\n");
883 goto bad;
884 }
885
886 cmi_power(sc, 0);
887 if (cmi_init(sc))
888 goto bad;

--- 124 unchanged lines hidden ---