projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[PATCH] Fix 2.6.18-rc6 IDE breakage, add missing ident needed for current VIA boards
[powerpc.git]
/
sound
/
pci
/
rme32.c
diff --git
a/sound/pci/rme32.c
b/sound/pci/rme32.c
index
cd313af
..
2a71499
100644
(file)
--- a/
sound/pci/rme32.c
+++ b/
sound/pci/rme32.c
@@
-192,7
+192,7
@@
MODULE_SUPPORTED_DEVICE("{{RME,Digi32}," "{RME,Digi32/8}," "{RME,Digi32 PRO}}");
#define RME32_PRO_REVISION_WITH_8414 150
#define RME32_PRO_REVISION_WITH_8414 150
-
typedef struct snd_
rme32 {
+
struct
rme32 {
spinlock_t lock;
int irq;
unsigned long port;
spinlock_t lock;
int irq;
unsigned long port;
@@
-205,8
+205,8
@@
typedef struct snd_rme32 {
u8 rev; /* card revision number */
u8 rev; /* card revision number */
- s
nd_pcm_substream_t
*playback_substream;
- s
nd_pcm_substream_t
*capture_substream;
+ s
truct snd_pcm_substream
*playback_substream;
+ s
truct snd_pcm_substream
*capture_substream;
int playback_frlog; /* log2 of framesize */
int capture_frlog;
int playback_frlog; /* log2 of framesize */
int capture_frlog;
@@
-217,15
+217,15
@@
typedef struct snd_rme32 {
unsigned int fullduplex_mode;
int running;
unsigned int fullduplex_mode;
int running;
- s
nd_pcm_indirect_
t playback_pcm;
- s
nd_pcm_indirect_
t capture_pcm;
+ s
truct snd_pcm_indirec
t playback_pcm;
+ s
truct snd_pcm_indirec
t capture_pcm;
- s
nd_card_t
*card;
- s
nd_pcm_t
*spdif_pcm;
- s
nd_pcm_t
*adat_pcm;
+ s
truct snd_card
*card;
+ s
truct snd_pcm
*spdif_pcm;
+ s
truct snd_pcm
*adat_pcm;
struct pci_dev *pci;
struct pci_dev *pci;
- s
nd_kcontrol_t
*spdif_ctl;
-}
rme32_t
;
+ s
truct snd_kcontrol
*spdif_ctl;
+};
static struct pci_device_id snd_rme32_ids[] = {
{PCI_VENDOR_ID_XILINX_RME, PCI_DEVICE_ID_RME_DIGI32,
static struct pci_device_id snd_rme32_ids[] = {
{PCI_VENDOR_ID_XILINX_RME, PCI_DEVICE_ID_RME_DIGI32,
@@
-242,17
+242,17
@@
MODULE_DEVICE_TABLE(pci, snd_rme32_ids);
#define RME32_ISWORKING(rme32) ((rme32)->wcreg & RME32_WCR_START)
#define RME32_PRO_WITH_8414(rme32) ((rme32)->pci->device == PCI_DEVICE_ID_RME_DIGI32_PRO && (rme32)->rev == RME32_PRO_REVISION_WITH_8414)
#define RME32_ISWORKING(rme32) ((rme32)->wcreg & RME32_WCR_START)
#define RME32_PRO_WITH_8414(rme32) ((rme32)->pci->device == PCI_DEVICE_ID_RME_DIGI32_PRO && (rme32)->rev == RME32_PRO_REVISION_WITH_8414)
-static int snd_rme32_playback_prepare(s
nd_pcm_substream_t *
substream);
+static int snd_rme32_playback_prepare(s
truct snd_pcm_substream *
substream);
-static int snd_rme32_capture_prepare(s
nd_pcm_substream_t *
substream);
+static int snd_rme32_capture_prepare(s
truct snd_pcm_substream *
substream);
-static int snd_rme32_pcm_trigger(s
nd_pcm_substream_t *
substream, int cmd);
+static int snd_rme32_pcm_trigger(s
truct snd_pcm_substream *
substream, int cmd);
-static void snd_rme32_proc_init(
rme32_t
* rme32);
+static void snd_rme32_proc_init(
struct rme32
* rme32);
-static int snd_rme32_create_switches(s
nd_card_t * card, rme32_t
* rme32);
+static int snd_rme32_create_switches(s
truct snd_card *card, struct rme32
* rme32);
-static inline unsigned int snd_rme32_pcm_byteptr(
rme32_t
* rme32)
+static inline unsigned int snd_rme32_pcm_byteptr(
struct rme32
* rme32)
{
return (readl(rme32->iobase + RME32_IO_GET_POS)
& RME32_RCR_AUDIO_ADDR_MASK);
{
return (readl(rme32->iobase + RME32_IO_GET_POS)
& RME32_RCR_AUDIO_ADDR_MASK);
@@
-272,11
+272,11
@@
static int snd_rme32_ratecode(int rate)
}
/* silence callback for halfduplex mode */
}
/* silence callback for halfduplex mode */
-static int snd_rme32_playback_silence(s
nd_pcm_substream_t * substream, int channel,
/* not used (interleaved data) */
+static int snd_rme32_playback_silence(s
truct snd_pcm_substream *substream, int channel,
/* not used (interleaved data) */
snd_pcm_uframes_t pos,
snd_pcm_uframes_t count)
{
snd_pcm_uframes_t pos,
snd_pcm_uframes_t count)
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
count <<= rme32->playback_frlog;
pos <<= rme32->playback_frlog;
memset_io(rme32->iobase + RME32_IO_DATA_BUFFER + pos, 0, count);
count <<= rme32->playback_frlog;
pos <<= rme32->playback_frlog;
memset_io(rme32->iobase + RME32_IO_DATA_BUFFER + pos, 0, count);
@@
-284,11
+284,11
@@
static int snd_rme32_playback_silence(snd_pcm_substream_t * substream, int chann
}
/* copy callback for halfduplex mode */
}
/* copy callback for halfduplex mode */
-static int snd_rme32_playback_copy(s
nd_pcm_substream_t * substream, int channel,
/* not used (interleaved data) */
+static int snd_rme32_playback_copy(s
truct snd_pcm_substream *substream, int channel,
/* not used (interleaved data) */
snd_pcm_uframes_t pos,
void __user *src, snd_pcm_uframes_t count)
{
snd_pcm_uframes_t pos,
void __user *src, snd_pcm_uframes_t count)
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
count <<= rme32->playback_frlog;
pos <<= rme32->playback_frlog;
if (copy_from_user_toio(rme32->iobase + RME32_IO_DATA_BUFFER + pos,
count <<= rme32->playback_frlog;
pos <<= rme32->playback_frlog;
if (copy_from_user_toio(rme32->iobase + RME32_IO_DATA_BUFFER + pos,
@@
-298,11
+298,11
@@
static int snd_rme32_playback_copy(snd_pcm_substream_t * substream, int channel,
}
/* copy callback for halfduplex mode */
}
/* copy callback for halfduplex mode */
-static int snd_rme32_capture_copy(s
nd_pcm_substream_t * substream, int channel,
/* not used (interleaved data) */
+static int snd_rme32_capture_copy(s
truct snd_pcm_substream *substream, int channel,
/* not used (interleaved data) */
snd_pcm_uframes_t pos,
void __user *dst, snd_pcm_uframes_t count)
{
snd_pcm_uframes_t pos,
void __user *dst, snd_pcm_uframes_t count)
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
count <<= rme32->capture_frlog;
pos <<= rme32->capture_frlog;
if (copy_to_user_fromio(dst,
count <<= rme32->capture_frlog;
pos <<= rme32->capture_frlog;
if (copy_to_user_fromio(dst,
@@
-313,9
+313,9
@@
static int snd_rme32_capture_copy(snd_pcm_substream_t * substream, int channel,
}
/*
}
/*
- * SPDIF I/O capabilites (half-duplex mode)
+ * SPDIF I/O capabilit
i
es (half-duplex mode)
*/
*/
-static s
nd_pcm_hardware_t
snd_rme32_spdif_info = {
+static s
truct snd_pcm_hardware
snd_rme32_spdif_info = {
.info = (SNDRV_PCM_INFO_MMAP_IOMEM |
SNDRV_PCM_INFO_MMAP_VALID |
SNDRV_PCM_INFO_INTERLEAVED |
.info = (SNDRV_PCM_INFO_MMAP_IOMEM |
SNDRV_PCM_INFO_MMAP_VALID |
SNDRV_PCM_INFO_INTERLEAVED |
@@
-339,9
+339,9
@@
static snd_pcm_hardware_t snd_rme32_spdif_info = {
};
/*
};
/*
- * ADAT I/O capabilites (half-duplex mode)
+ * ADAT I/O capabilit
i
es (half-duplex mode)
*/
*/
-static s
nd_pcm_hardware_t
snd_rme32_adat_info =
+static s
truct snd_pcm_hardware
snd_rme32_adat_info =
{
.info = (SNDRV_PCM_INFO_MMAP_IOMEM |
SNDRV_PCM_INFO_MMAP_VALID |
{
.info = (SNDRV_PCM_INFO_MMAP_IOMEM |
SNDRV_PCM_INFO_MMAP_VALID |
@@
-364,9
+364,9
@@
static snd_pcm_hardware_t snd_rme32_adat_info =
};
/*
};
/*
- * SPDIF I/O capabilites (full-duplex mode)
+ * SPDIF I/O capabilit
i
es (full-duplex mode)
*/
*/
-static s
nd_pcm_hardware_t
snd_rme32_spdif_fd_info = {
+static s
truct snd_pcm_hardware
snd_rme32_spdif_fd_info = {
.info = (SNDRV_PCM_INFO_MMAP |
SNDRV_PCM_INFO_MMAP_VALID |
SNDRV_PCM_INFO_INTERLEAVED |
.info = (SNDRV_PCM_INFO_MMAP |
SNDRV_PCM_INFO_MMAP_VALID |
SNDRV_PCM_INFO_INTERLEAVED |
@@
-390,9
+390,9
@@
static snd_pcm_hardware_t snd_rme32_spdif_fd_info = {
};
/*
};
/*
- * ADAT I/O capabilites (full-duplex mode)
+ * ADAT I/O capabilit
i
es (full-duplex mode)
*/
*/
-static s
nd_pcm_hardware_t
snd_rme32_adat_fd_info =
+static s
truct snd_pcm_hardware
snd_rme32_adat_fd_info =
{
.info = (SNDRV_PCM_INFO_MMAP |
SNDRV_PCM_INFO_MMAP_VALID |
{
.info = (SNDRV_PCM_INFO_MMAP |
SNDRV_PCM_INFO_MMAP_VALID |
@@
-414,14
+414,14
@@
static snd_pcm_hardware_t snd_rme32_adat_fd_info =
.fifo_size = 0,
};
.fifo_size = 0,
};
-static void snd_rme32_reset_dac(
rme32_t
*rme32)
+static void snd_rme32_reset_dac(
struct rme32
*rme32)
{
writel(rme32->wcreg | RME32_WCR_PD,
rme32->iobase + RME32_IO_CONTROL_REGISTER);
writel(rme32->wcreg, rme32->iobase + RME32_IO_CONTROL_REGISTER);
}
{
writel(rme32->wcreg | RME32_WCR_PD,
rme32->iobase + RME32_IO_CONTROL_REGISTER);
writel(rme32->wcreg, rme32->iobase + RME32_IO_CONTROL_REGISTER);
}
-static int snd_rme32_playback_getrate(
rme32_t
* rme32)
+static int snd_rme32_playback_getrate(
struct rme32
* rme32)
{
int rate;
{
int rate;
@@
-443,7
+443,7
@@
static int snd_rme32_playback_getrate(rme32_t * rme32)
return (rme32->wcreg & RME32_WCR_DS_BM) ? rate << 1 : rate;
}
return (rme32->wcreg & RME32_WCR_DS_BM) ? rate << 1 : rate;
}
-static int snd_rme32_capture_getrate(
rme32_t
* rme32, int *is_adat)
+static int snd_rme32_capture_getrate(
struct rme32
* rme32, int *is_adat)
{
int n;
{
int n;
@@
-505,7
+505,7
@@
static int snd_rme32_capture_getrate(rme32_t * rme32, int *is_adat)
return -1;
}
return -1;
}
-static int snd_rme32_playback_setrate(
rme32_t
* rme32, int rate)
+static int snd_rme32_playback_setrate(
struct rme32
* rme32, int rate)
{
int ds;
{
int ds;
@@
-561,7
+561,7
@@
static int snd_rme32_playback_setrate(rme32_t * rme32, int rate)
return 0;
}
return 0;
}
-static int snd_rme32_setclockmode(
rme32_t
* rme32, int mode)
+static int snd_rme32_setclockmode(
struct rme32
* rme32, int mode)
{
switch (mode) {
case RME32_CLOCKMODE_SLAVE:
{
switch (mode) {
case RME32_CLOCKMODE_SLAVE:
@@
-591,13
+591,13
@@
static int snd_rme32_setclockmode(rme32_t * rme32, int mode)
return 0;
}
return 0;
}
-static int snd_rme32_getclockmode(
rme32_t
* rme32)
+static int snd_rme32_getclockmode(
struct rme32
* rme32)
{
return ((rme32->wcreg >> RME32_WCR_BITPOS_FREQ_0) & 1) +
(((rme32->wcreg >> RME32_WCR_BITPOS_FREQ_1) & 1) << 1);
}
{
return ((rme32->wcreg >> RME32_WCR_BITPOS_FREQ_0) & 1) +
(((rme32->wcreg >> RME32_WCR_BITPOS_FREQ_1) & 1) << 1);
}
-static int snd_rme32_setinputtype(
rme32_t
* rme32, int type)
+static int snd_rme32_setinputtype(
struct rme32
* rme32, int type)
{
switch (type) {
case RME32_INPUT_OPTICAL:
{
switch (type) {
case RME32_INPUT_OPTICAL:
@@
-623,14
+623,14
@@
static int snd_rme32_setinputtype(rme32_t * rme32, int type)
return 0;
}
return 0;
}
-static int snd_rme32_getinputtype(
rme32_t
* rme32)
+static int snd_rme32_getinputtype(
struct rme32
* rme32)
{
return ((rme32->wcreg >> RME32_WCR_BITPOS_INP_0) & 1) +
(((rme32->wcreg >> RME32_WCR_BITPOS_INP_1) & 1) << 1);
}
static void
{
return ((rme32->wcreg >> RME32_WCR_BITPOS_INP_0) & 1) +
(((rme32->wcreg >> RME32_WCR_BITPOS_INP_1) & 1) << 1);
}
static void
-snd_rme32_setframelog(
rme32_t
* rme32, int n_channels, int is_playback)
+snd_rme32_setframelog(
struct rme32
* rme32, int n_channels, int is_playback)
{
int frlog;
{
int frlog;
@@
-649,7
+649,7
@@
snd_rme32_setframelog(rme32_t * rme32, int n_channels, int is_playback)
}
}
}
}
-static int snd_rme32_setformat(
rme32_t
* rme32, int format)
+static int snd_rme32_setformat(
struct rme32
* rme32, int format)
{
switch (format) {
case SNDRV_PCM_FORMAT_S16_LE:
{
switch (format) {
case SNDRV_PCM_FORMAT_S16_LE:
@@
-666,12
+666,12
@@
static int snd_rme32_setformat(rme32_t * rme32, int format)
}
static int
}
static int
-snd_rme32_playback_hw_params(s
nd_pcm_substream_t *
substream,
- s
nd_pcm_hw_params_t *
params)
+snd_rme32_playback_hw_params(s
truct snd_pcm_substream *
substream,
+ s
truct snd_pcm_hw_params *
params)
{
int err, rate, dummy;
{
int err, rate, dummy;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
if (rme32->fullduplex_mode) {
err = snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(params));
if (rme32->fullduplex_mode) {
err = snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(params));
@@
-721,12
+721,12
@@
snd_rme32_playback_hw_params(snd_pcm_substream_t * substream,
}
static int
}
static int
-snd_rme32_capture_hw_params(s
nd_pcm_substream_t *
substream,
- s
nd_pcm_hw_params_t *
params)
+snd_rme32_capture_hw_params(s
truct snd_pcm_substream *
substream,
+ s
truct snd_pcm_hw_params *
params)
{
int err, isadat, rate;
{
int err, isadat, rate;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
if (rme32->fullduplex_mode) {
err = snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(params));
if (rme32->fullduplex_mode) {
err = snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(params));
@@
-782,15
+782,15
@@
snd_rme32_capture_hw_params(snd_pcm_substream_t * substream,
return 0;
}
return 0;
}
-static int snd_rme32_pcm_hw_free(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_pcm_hw_free(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
if (! rme32->fullduplex_mode)
return 0;
return snd_pcm_lib_free_pages(substream);
}
if (! rme32->fullduplex_mode)
return 0;
return snd_pcm_lib_free_pages(substream);
}
-static void snd_rme32_pcm_start(
rme32_t
* rme32, int from_pause)
+static void snd_rme32_pcm_start(
struct rme32
* rme32, int from_pause)
{
if (!from_pause) {
writel(0, rme32->iobase + RME32_IO_RESET_POS);
{
if (!from_pause) {
writel(0, rme32->iobase + RME32_IO_RESET_POS);
@@
-800,7
+800,7
@@
static void snd_rme32_pcm_start(rme32_t * rme32, int from_pause)
writel(rme32->wcreg, rme32->iobase + RME32_IO_CONTROL_REGISTER);
}
writel(rme32->wcreg, rme32->iobase + RME32_IO_CONTROL_REGISTER);
}
-static void snd_rme32_pcm_stop(
rme32_t
* rme32, int to_pause)
+static void snd_rme32_pcm_stop(
struct rme32
* rme32, int to_pause)
{
/*
* Check if there is an unconfirmed IRQ, if so confirm it, or else
{
/*
* Check if there is an unconfirmed IRQ, if so confirm it, or else
@@
-821,7
+821,7
@@
static void snd_rme32_pcm_stop(rme32_t * rme32, int to_pause)
static irqreturn_t
snd_rme32_interrupt(int irq, void *dev_id, struct pt_regs *regs)
{
static irqreturn_t
snd_rme32_interrupt(int irq, void *dev_id, struct pt_regs *regs)
{
-
rme32_t *rme32 = (rme32_t
*) dev_id;
+
struct rme32 *rme32 = (struct rme32
*) dev_id;
rme32->rcreg = readl(rme32->iobase + RME32_IO_CONTROL_REGISTER);
if (!(rme32->rcreg & RME32_RCR_IRQ)) {
rme32->rcreg = readl(rme32->iobase + RME32_IO_CONTROL_REGISTER);
if (!(rme32->rcreg & RME32_RCR_IRQ)) {
@@
-841,13
+841,13
@@
snd_rme32_interrupt(int irq, void *dev_id, struct pt_regs *regs)
static unsigned int period_bytes[] = { RME32_BLOCK_SIZE };
static unsigned int period_bytes[] = { RME32_BLOCK_SIZE };
-static s
nd_pcm_hw_constraint_list_
t hw_constraints_period_bytes = {
+static s
truct snd_pcm_hw_constraint_lis
t hw_constraints_period_bytes = {
.count = ARRAY_SIZE(period_bytes),
.list = period_bytes,
.mask = 0
};
.count = ARRAY_SIZE(period_bytes),
.list = period_bytes,
.mask = 0
};
-static void snd_rme32_set_buffer_constraint(
rme32_t *rme32, snd_pcm_runtime_t
*runtime)
+static void snd_rme32_set_buffer_constraint(
struct rme32 *rme32, struct snd_pcm_runtime
*runtime)
{
if (! rme32->fullduplex_mode) {
snd_pcm_hw_constraint_minmax(runtime,
{
if (! rme32->fullduplex_mode) {
snd_pcm_hw_constraint_minmax(runtime,
@@
-859,11
+859,11
@@
static void snd_rme32_set_buffer_constraint(rme32_t *rme32, snd_pcm_runtime_t *r
}
}
}
}
-static int snd_rme32_playback_spdif_open(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_playback_spdif_open(s
truct snd_pcm_substream *
substream)
{
int rate, dummy;
{
int rate, dummy;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
snd_pcm_set_sync(substream);
snd_pcm_set_sync(substream);
@@
-902,11
+902,11
@@
static int snd_rme32_playback_spdif_open(snd_pcm_substream_t * substream)
return 0;
}
return 0;
}
-static int snd_rme32_capture_spdif_open(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_capture_spdif_open(s
truct snd_pcm_substream *
substream)
{
int isadat, rate;
{
int isadat, rate;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
snd_pcm_set_sync(substream);
snd_pcm_set_sync(substream);
@@
-941,11
+941,11
@@
static int snd_rme32_capture_spdif_open(snd_pcm_substream_t * substream)
}
static int
}
static int
-snd_rme32_playback_adat_open(s
nd_pcm_substream_t
*substream)
+snd_rme32_playback_adat_open(s
truct snd_pcm_substream
*substream)
{
int rate, dummy;
{
int rate, dummy;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
snd_pcm_set_sync(substream);
snd_pcm_set_sync(substream);
@@
-976,11
+976,11
@@
snd_rme32_playback_adat_open(snd_pcm_substream_t *substream)
}
static int
}
static int
-snd_rme32_capture_adat_open(s
nd_pcm_substream_t
*substream)
+snd_rme32_capture_adat_open(s
truct snd_pcm_substream
*substream)
{
int isadat, rate;
{
int isadat, rate;
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_runtime_t
*runtime = substream->runtime;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_runtime
*runtime = substream->runtime;
if (rme32->fullduplex_mode)
runtime->hw = snd_rme32_adat_fd_info;
if (rme32->fullduplex_mode)
runtime->hw = snd_rme32_adat_fd_info;
@@
-1009,9
+1009,9
@@
snd_rme32_capture_adat_open(snd_pcm_substream_t *substream)
return 0;
}
return 0;
}
-static int snd_rme32_playback_close(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_playback_close(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
int spdif = 0;
spin_lock_irq(&rme32->lock);
int spdif = 0;
spin_lock_irq(&rme32->lock);
@@
-1028,9
+1028,9
@@
static int snd_rme32_playback_close(snd_pcm_substream_t * substream)
return 0;
}
return 0;
}
-static int snd_rme32_capture_close(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_capture_close(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
spin_lock_irq(&rme32->lock);
rme32->capture_substream = NULL;
spin_lock_irq(&rme32->lock);
rme32->capture_substream = NULL;
@@
-1039,9
+1039,9
@@
static int snd_rme32_capture_close(snd_pcm_substream_t * substream)
return 0;
}
return 0;
}
-static int snd_rme32_playback_prepare(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_playback_prepare(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
spin_lock_irq(&rme32->lock);
if (rme32->fullduplex_mode) {
spin_lock_irq(&rme32->lock);
if (rme32->fullduplex_mode) {
@@
-1058,9
+1058,9
@@
static int snd_rme32_playback_prepare(snd_pcm_substream_t * substream)
return 0;
}
return 0;
}
-static int snd_rme32_capture_prepare(s
nd_pcm_substream_t *
substream)
+static int snd_rme32_capture_prepare(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
spin_lock_irq(&rme32->lock);
if (rme32->fullduplex_mode) {
spin_lock_irq(&rme32->lock);
if (rme32->fullduplex_mode) {
@@
-1076,11
+1076,11
@@
static int snd_rme32_capture_prepare(snd_pcm_substream_t * substream)
}
static int
}
static int
-snd_rme32_pcm_trigger(s
nd_pcm_substream_t *
substream, int cmd)
+snd_rme32_pcm_trigger(s
truct snd_pcm_substream *
substream, int cmd)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
struct list_head *pos;
struct list_head *pos;
- s
nd_pcm_substream_t
*s;
+ s
truct snd_pcm_substream
*s;
spin_lock(&rme32->lock);
snd_pcm_group_for_each(pos, substream) {
spin_lock(&rme32->lock);
snd_pcm_group_for_each(pos, substream) {
@@
-1144,33
+1144,33
@@
snd_rme32_pcm_trigger(snd_pcm_substream_t * substream, int cmd)
/* pointer callback for halfduplex mode */
static snd_pcm_uframes_t
/* pointer callback for halfduplex mode */
static snd_pcm_uframes_t
-snd_rme32_playback_pointer(s
nd_pcm_substream_t *
substream)
+snd_rme32_playback_pointer(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
return snd_rme32_pcm_byteptr(rme32) >> rme32->playback_frlog;
}
static snd_pcm_uframes_t
return snd_rme32_pcm_byteptr(rme32) >> rme32->playback_frlog;
}
static snd_pcm_uframes_t
-snd_rme32_capture_pointer(s
nd_pcm_substream_t *
substream)
+snd_rme32_capture_pointer(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
return snd_rme32_pcm_byteptr(rme32) >> rme32->capture_frlog;
}
/* ack and pointer callbacks for fullduplex mode */
return snd_rme32_pcm_byteptr(rme32) >> rme32->capture_frlog;
}
/* ack and pointer callbacks for fullduplex mode */
-static void snd_rme32_pb_trans_copy(s
nd_pcm_substream_t
*substream,
- s
nd_pcm_indirect_
t *rec, size_t bytes)
+static void snd_rme32_pb_trans_copy(s
truct snd_pcm_substream
*substream,
+ s
truct snd_pcm_indirec
t *rec, size_t bytes)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
memcpy_toio(rme32->iobase + RME32_IO_DATA_BUFFER + rec->hw_data,
substream->runtime->dma_area + rec->sw_data, bytes);
}
memcpy_toio(rme32->iobase + RME32_IO_DATA_BUFFER + rec->hw_data,
substream->runtime->dma_area + rec->sw_data, bytes);
}
-static int snd_rme32_playback_fd_ack(s
nd_pcm_substream_t
*substream)
+static int snd_rme32_playback_fd_ack(s
truct snd_pcm_substream
*substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
- s
nd_pcm_indirect_
t *rec, *cprec;
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
+ s
truct snd_pcm_indirec
t *rec, *cprec;
rec = &rme32->playback_pcm;
cprec = &rme32->capture_pcm;
rec = &rme32->playback_pcm;
cprec = &rme32->capture_pcm;
@@
-1184,41
+1184,41
@@
static int snd_rme32_playback_fd_ack(snd_pcm_substream_t *substream)
return 0;
}
return 0;
}
-static void snd_rme32_cp_trans_copy(s
nd_pcm_substream_t
*substream,
- s
nd_pcm_indirect_
t *rec, size_t bytes)
+static void snd_rme32_cp_trans_copy(s
truct snd_pcm_substream
*substream,
+ s
truct snd_pcm_indirec
t *rec, size_t bytes)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
memcpy_fromio(substream->runtime->dma_area + rec->sw_data,
rme32->iobase + RME32_IO_DATA_BUFFER + rec->hw_data,
bytes);
}
memcpy_fromio(substream->runtime->dma_area + rec->sw_data,
rme32->iobase + RME32_IO_DATA_BUFFER + rec->hw_data,
bytes);
}
-static int snd_rme32_capture_fd_ack(s
nd_pcm_substream_t
*substream)
+static int snd_rme32_capture_fd_ack(s
truct snd_pcm_substream
*substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
snd_pcm_indirect_capture_transfer(substream, &rme32->capture_pcm,
snd_rme32_cp_trans_copy);
return 0;
}
static snd_pcm_uframes_t
snd_pcm_indirect_capture_transfer(substream, &rme32->capture_pcm,
snd_rme32_cp_trans_copy);
return 0;
}
static snd_pcm_uframes_t
-snd_rme32_playback_fd_pointer(s
nd_pcm_substream_t *
substream)
+snd_rme32_playback_fd_pointer(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
return snd_pcm_indirect_playback_pointer(substream, &rme32->playback_pcm,
snd_rme32_pcm_byteptr(rme32));
}
static snd_pcm_uframes_t
return snd_pcm_indirect_playback_pointer(substream, &rme32->playback_pcm,
snd_rme32_pcm_byteptr(rme32));
}
static snd_pcm_uframes_t
-snd_rme32_capture_fd_pointer(s
nd_pcm_substream_t *
substream)
+snd_rme32_capture_fd_pointer(s
truct snd_pcm_substream *
substream)
{
{
-
rme32_t
*rme32 = snd_pcm_substream_chip(substream);
+
struct rme32
*rme32 = snd_pcm_substream_chip(substream);
return snd_pcm_indirect_capture_pointer(substream, &rme32->capture_pcm,
snd_rme32_pcm_byteptr(rme32));
}
/* for halfduplex mode */
return snd_pcm_indirect_capture_pointer(substream, &rme32->capture_pcm,
snd_rme32_pcm_byteptr(rme32));
}
/* for halfduplex mode */
-static s
nd_pcm_ops_t
snd_rme32_playback_spdif_ops = {
+static s
truct snd_pcm_ops
snd_rme32_playback_spdif_ops = {
.open = snd_rme32_playback_spdif_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_playback_spdif_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1232,7
+1232,7
@@
static snd_pcm_ops_t snd_rme32_playback_spdif_ops = {
.mmap = snd_pcm_lib_mmap_iomem,
};
.mmap = snd_pcm_lib_mmap_iomem,
};
-static s
nd_pcm_ops_t
snd_rme32_capture_spdif_ops = {
+static s
truct snd_pcm_ops
snd_rme32_capture_spdif_ops = {
.open = snd_rme32_capture_spdif_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_capture_spdif_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1245,7
+1245,7
@@
static snd_pcm_ops_t snd_rme32_capture_spdif_ops = {
.mmap = snd_pcm_lib_mmap_iomem,
};
.mmap = snd_pcm_lib_mmap_iomem,
};
-static s
nd_pcm_ops_t
snd_rme32_playback_adat_ops = {
+static s
truct snd_pcm_ops
snd_rme32_playback_adat_ops = {
.open = snd_rme32_playback_adat_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_playback_adat_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1258,7
+1258,7
@@
static snd_pcm_ops_t snd_rme32_playback_adat_ops = {
.mmap = snd_pcm_lib_mmap_iomem,
};
.mmap = snd_pcm_lib_mmap_iomem,
};
-static s
nd_pcm_ops_t
snd_rme32_capture_adat_ops = {
+static s
truct snd_pcm_ops
snd_rme32_capture_adat_ops = {
.open = snd_rme32_capture_adat_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_capture_adat_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1271,7
+1271,7
@@
static snd_pcm_ops_t snd_rme32_capture_adat_ops = {
};
/* for fullduplex mode */
};
/* for fullduplex mode */
-static s
nd_pcm_ops_t
snd_rme32_playback_spdif_fd_ops = {
+static s
truct snd_pcm_ops
snd_rme32_playback_spdif_fd_ops = {
.open = snd_rme32_playback_spdif_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_playback_spdif_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1283,7
+1283,7
@@
static snd_pcm_ops_t snd_rme32_playback_spdif_fd_ops = {
.ack = snd_rme32_playback_fd_ack,
};
.ack = snd_rme32_playback_fd_ack,
};
-static s
nd_pcm_ops_t
snd_rme32_capture_spdif_fd_ops = {
+static s
truct snd_pcm_ops
snd_rme32_capture_spdif_fd_ops = {
.open = snd_rme32_capture_spdif_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_capture_spdif_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1295,7
+1295,7
@@
static snd_pcm_ops_t snd_rme32_capture_spdif_fd_ops = {
.ack = snd_rme32_capture_fd_ack,
};
.ack = snd_rme32_capture_fd_ack,
};
-static s
nd_pcm_ops_t
snd_rme32_playback_adat_fd_ops = {
+static s
truct snd_pcm_ops
snd_rme32_playback_adat_fd_ops = {
.open = snd_rme32_playback_adat_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_playback_adat_open,
.close = snd_rme32_playback_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1306,7
+1306,7
@@
static snd_pcm_ops_t snd_rme32_playback_adat_fd_ops = {
.ack = snd_rme32_playback_fd_ack,
};
.ack = snd_rme32_playback_fd_ack,
};
-static s
nd_pcm_ops_t
snd_rme32_capture_adat_fd_ops = {
+static s
truct snd_pcm_ops
snd_rme32_capture_adat_fd_ops = {
.open = snd_rme32_capture_adat_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
.open = snd_rme32_capture_adat_open,
.close = snd_rme32_capture_close,
.ioctl = snd_pcm_lib_ioctl,
@@
-1319,7
+1319,7
@@
static snd_pcm_ops_t snd_rme32_capture_adat_fd_ops = {
static void snd_rme32_free(void *private_data)
{
static void snd_rme32_free(void *private_data)
{
-
rme32_t *rme32 = (rme32_t
*) private_data;
+
struct rme32 *rme32 = (struct rme32
*) private_data;
if (rme32 == NULL) {
return;
if (rme32 == NULL) {
return;
@@
-1340,20
+1340,20
@@
static void snd_rme32_free(void *private_data)
pci_disable_device(rme32->pci);
}
pci_disable_device(rme32->pci);
}
-static void snd_rme32_free_spdif_pcm(s
nd_pcm_t *
pcm)
+static void snd_rme32_free_spdif_pcm(s
truct snd_pcm *
pcm)
{
{
-
rme32_t *rme32 = (rme32_t
*) pcm->private_data;
+
struct rme32 *rme32 = (struct rme32
*) pcm->private_data;
rme32->spdif_pcm = NULL;
}
static void
rme32->spdif_pcm = NULL;
}
static void
-snd_rme32_free_adat_pcm(s
nd_pcm_t
*pcm)
+snd_rme32_free_adat_pcm(s
truct snd_pcm
*pcm)
{
{
-
rme32_t *rme32 = (rme32_t
*) pcm->private_data;
+
struct rme32 *rme32 = (struct rme32
*) pcm->private_data;
rme32->adat_pcm = NULL;
}
rme32->adat_pcm = NULL;
}
-static int __devinit snd_rme32_create(
rme32_t
* rme32)
+static int __devinit snd_rme32_create(
struct rme32
* rme32)
{
struct pci_dev *pci = rme32->pci;
int err;
{
struct pci_dev *pci = rme32->pci;
int err;
@@
-1368,18
+1368,18
@@
static int __devinit snd_rme32_create(rme32_t * rme32)
return err;
rme32->port = pci_resource_start(rme32->pci, 0);
return err;
rme32->port = pci_resource_start(rme32->pci, 0);
- if (request_irq(pci->irq, snd_rme32_interrupt, SA_INTERRUPT | SA_SHIRQ, "RME32", (void *) rme32)) {
- snd_printk("unable to grab IRQ %d\n", pci->irq);
- return -EBUSY;
- }
- rme32->irq = pci->irq;
-
if ((rme32->iobase = ioremap_nocache(rme32->port, RME32_IO_SIZE)) == 0) {
if ((rme32->iobase = ioremap_nocache(rme32->port, RME32_IO_SIZE)) == 0) {
- snd_printk("unable to remap memory region 0x%lx-0x%lx\n",
+ snd_printk(
KERN_ERR
"unable to remap memory region 0x%lx-0x%lx\n",
rme32->port, rme32->port + RME32_IO_SIZE - 1);
return -ENOMEM;
}
rme32->port, rme32->port + RME32_IO_SIZE - 1);
return -ENOMEM;
}
+ if (request_irq(pci->irq, snd_rme32_interrupt, IRQF_DISABLED | IRQF_SHARED, "RME32", (void *) rme32)) {
+ snd_printk(KERN_ERR "unable to grab IRQ %d\n", pci->irq);
+ return -EBUSY;
+ }
+ rme32->irq = pci->irq;
+
/* read the card's revision number */
pci_read_config_byte(pci, 8, &rme32->rev);
/* read the card's revision number */
pci_read_config_byte(pci, 8, &rme32->rev);
@@
-1479,10
+1479,10
@@
static int __devinit snd_rme32_create(rme32_t * rme32)
*/
static void
*/
static void
-snd_rme32_proc_read(s
nd_info_entry_t * entry, snd_info_buffer_t *
buffer)
+snd_rme32_proc_read(s
truct snd_info_entry * entry, struct snd_info_buffer *
buffer)
{
int n;
{
int n;
-
rme32_t *rme32 = (rme32_t
*) entry->private_data;
+
struct rme32 *rme32 = (struct rme32
*) entry->private_data;
rme32->rcreg = readl(rme32->iobase + RME32_IO_CONTROL_REGISTER);
rme32->rcreg = readl(rme32->iobase + RME32_IO_CONTROL_REGISTER);
@@
-1573,12
+1573,12
@@
snd_rme32_proc_read(snd_info_entry_t * entry, snd_info_buffer_t * buffer)
}
}
}
}
-static void __devinit snd_rme32_proc_init(
rme32_t
* rme32)
+static void __devinit snd_rme32_proc_init(
struct rme32
* rme32)
{
{
- s
nd_info_entry_t
*entry;
+ s
truct snd_info_entry
*entry;
if (! snd_card_proc_new(rme32->card, "rme32", &entry))
if (! snd_card_proc_new(rme32->card, "rme32", &entry))
- snd_info_set_text_ops(entry, rme32,
1024,
snd_rme32_proc_read);
+ snd_info_set_text_ops(entry, rme32, snd_rme32_proc_read);
}
/*
}
/*
@@
-1586,8
+1586,8
@@
static void __devinit snd_rme32_proc_init(rme32_t * rme32)
*/
static int
*/
static int
-snd_rme32_info_loopback_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+snd_rme32_info_loopback_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_BOOLEAN;
uinfo->count = 1;
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_BOOLEAN;
uinfo->count = 1;
@@
-1596,10
+1596,10
@@
snd_rme32_info_loopback_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_get_loopback_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_get_loopback_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
spin_lock_irq(&rme32->lock);
ucontrol->value.integer.value[0] =
spin_lock_irq(&rme32->lock);
ucontrol->value.integer.value[0] =
@@
-1608,10
+1608,10
@@
snd_rme32_get_loopback_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_put_loopback_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_put_loopback_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
unsigned int val;
int change;
unsigned int val;
int change;
@@
-1630,10
+1630,10
@@
snd_rme32_put_loopback_control(snd_kcontrol_t * kcontrol,
}
static int
}
static int
-snd_rme32_info_inputtype_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+snd_rme32_info_inputtype_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
static char *texts[4] = { "Optical", "Coaxial", "Internal", "XLR" };
uinfo->type = SNDRV_CTL_ELEM_TYPE_ENUMERATED;
static char *texts[4] = { "Optical", "Coaxial", "Internal", "XLR" };
uinfo->type = SNDRV_CTL_ELEM_TYPE_ENUMERATED;
@@
-1660,10
+1660,10
@@
snd_rme32_info_inputtype_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_get_inputtype_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_get_inputtype_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
unsigned int items = 3;
spin_lock_irq(&rme32->lock);
unsigned int items = 3;
spin_lock_irq(&rme32->lock);
@@
-1689,10
+1689,10
@@
snd_rme32_get_inputtype_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_put_inputtype_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_put_inputtype_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
unsigned int val;
int change, items = 3;
unsigned int val;
int change, items = 3;
@@
-1718,8
+1718,8
@@
snd_rme32_put_inputtype_control(snd_kcontrol_t * kcontrol,
}
static int
}
static int
-snd_rme32_info_clockmode_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+snd_rme32_info_clockmode_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
static char *texts[4] = { "AutoSync",
"Internal 32.0kHz",
{
static char *texts[4] = { "AutoSync",
"Internal 32.0kHz",
@@
-1737,10
+1737,10
@@
snd_rme32_info_clockmode_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_get_clockmode_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_get_clockmode_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
spin_lock_irq(&rme32->lock);
ucontrol->value.enumerated.item[0] = snd_rme32_getclockmode(rme32);
spin_lock_irq(&rme32->lock);
ucontrol->value.enumerated.item[0] = snd_rme32_getclockmode(rme32);
@@
-1748,10
+1748,10
@@
snd_rme32_get_clockmode_control(snd_kcontrol_t * kcontrol,
return 0;
}
static int
return 0;
}
static int
-snd_rme32_put_clockmode_control(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+snd_rme32_put_clockmode_control(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
unsigned int val;
int change;
unsigned int val;
int change;
@@
-1763,7
+1763,7
@@
snd_rme32_put_clockmode_control(snd_kcontrol_t * kcontrol,
return change;
}
return change;
}
-static u32 snd_rme32_convert_from_aes(s
nd_aes_iec958_t
* aes)
+static u32 snd_rme32_convert_from_aes(s
truct snd_aes_iec958
* aes)
{
u32 val = 0;
val |= (aes->status[0] & IEC958_AES0_PROFESSIONAL) ? RME32_WCR_PRO : 0;
{
u32 val = 0;
val |= (aes->status[0] & IEC958_AES0_PROFESSIONAL) ? RME32_WCR_PRO : 0;
@@
-1774,7
+1774,7
@@
static u32 snd_rme32_convert_from_aes(snd_aes_iec958_t * aes)
return val;
}
return val;
}
-static void snd_rme32_convert_to_aes(s
nd_aes_iec958_t
* aes, u32 val)
+static void snd_rme32_convert_to_aes(s
truct snd_aes_iec958
* aes, u32 val)
{
aes->status[0] = ((val & RME32_WCR_PRO) ? IEC958_AES0_PROFESSIONAL : 0);
if (val & RME32_WCR_PRO)
{
aes->status[0] = ((val & RME32_WCR_PRO) ? IEC958_AES0_PROFESSIONAL : 0);
if (val & RME32_WCR_PRO)
@@
-1783,28
+1783,28
@@
static void snd_rme32_convert_to_aes(snd_aes_iec958_t * aes, u32 val)
aes->status[0] |= (val & RME32_WCR_EMP) ? IEC958_AES0_CON_EMPHASIS_5015 : 0;
}
aes->status[0] |= (val & RME32_WCR_EMP) ? IEC958_AES0_CON_EMPHASIS_5015 : 0;
}
-static int snd_rme32_control_spdif_info(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+static int snd_rme32_control_spdif_info(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
-static int snd_rme32_control_spdif_get(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+static int snd_rme32_control_spdif_get(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
snd_rme32_convert_to_aes(&ucontrol->value.iec958,
rme32->wcreg_spdif);
return 0;
}
snd_rme32_convert_to_aes(&ucontrol->value.iec958,
rme32->wcreg_spdif);
return 0;
}
-static int snd_rme32_control_spdif_put(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t *
ucontrol)
+static int snd_rme32_control_spdif_put(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value *
ucontrol)
{
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
int change;
u32 val;
int change;
u32 val;
@@
-1816,30
+1816,30
@@
static int snd_rme32_control_spdif_put(snd_kcontrol_t * kcontrol,
return change;
}
return change;
}
-static int snd_rme32_control_spdif_stream_info(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+static int snd_rme32_control_spdif_stream_info(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
-static int snd_rme32_control_spdif_stream_get(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t
*
+static int snd_rme32_control_spdif_stream_get(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value
*
ucontrol)
{
ucontrol)
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
snd_rme32_convert_to_aes(&ucontrol->value.iec958,
rme32->wcreg_spdif_stream);
return 0;
}
snd_rme32_convert_to_aes(&ucontrol->value.iec958,
rme32->wcreg_spdif_stream);
return 0;
}
-static int snd_rme32_control_spdif_stream_put(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t
*
+static int snd_rme32_control_spdif_stream_put(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value
*
ucontrol)
{
ucontrol)
{
-
rme32_t
*rme32 = snd_kcontrol_chip(kcontrol);
+
struct rme32
*rme32 = snd_kcontrol_chip(kcontrol);
int change;
u32 val;
int change;
u32 val;
@@
-1854,23
+1854,23
@@
static int snd_rme32_control_spdif_stream_put(snd_kcontrol_t * kcontrol,
return change;
}
return change;
}
-static int snd_rme32_control_spdif_mask_info(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_info_t *
uinfo)
+static int snd_rme32_control_spdif_mask_info(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_info *
uinfo)
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_IEC958;
uinfo->count = 1;
return 0;
}
-static int snd_rme32_control_spdif_mask_get(s
nd_kcontrol_t *
kcontrol,
- s
nd_ctl_elem_value_t
*
+static int snd_rme32_control_spdif_mask_get(s
truct snd_kcontrol *
kcontrol,
+ s
truct snd_ctl_elem_value
*
ucontrol)
{
ucontrol->value.iec958.status[0] = kcontrol->private_value;
return 0;
}
ucontrol)
{
ucontrol->value.iec958.status[0] = kcontrol->private_value;
return 0;
}
-static s
nd_kcontrol_new_t
snd_rme32_controls[] = {
+static s
truct snd_kcontrol_new
snd_rme32_controls[] = {
{
.iface = SNDRV_CTL_ELEM_IFACE_PCM,
.name = SNDRV_CTL_NAME_IEC958("", PLAYBACK, DEFAULT),
{
.iface = SNDRV_CTL_ELEM_IFACE_PCM,
.name = SNDRV_CTL_NAME_IEC958("", PLAYBACK, DEFAULT),
@@
-1925,10
+1925,10
@@
static snd_kcontrol_new_t snd_rme32_controls[] = {
}
};
}
};
-static int snd_rme32_create_switches(s
nd_card_t * card, rme32_t
* rme32)
+static int snd_rme32_create_switches(s
truct snd_card *card, struct rme32
* rme32)
{
int idx, err;
{
int idx, err;
- s
nd_kcontrol_t
*kctl;
+ s
truct snd_kcontrol
*kctl;
for (idx = 0; idx < (int)ARRAY_SIZE(snd_rme32_controls); idx++) {
if ((err = snd_ctl_add(card, kctl = snd_ctl_new1(&snd_rme32_controls[idx], rme32))) < 0)
for (idx = 0; idx < (int)ARRAY_SIZE(snd_rme32_controls); idx++) {
if ((err = snd_ctl_add(card, kctl = snd_ctl_new1(&snd_rme32_controls[idx], rme32))) < 0)
@@
-1944,7
+1944,7
@@
static int snd_rme32_create_switches(snd_card_t * card, rme32_t * rme32)
* Card initialisation
*/
* Card initialisation
*/
-static void snd_rme32_card_free(s
nd_card_t *
card)
+static void snd_rme32_card_free(s
truct snd_card *
card)
{
snd_rme32_free(card->private_data);
}
{
snd_rme32_free(card->private_data);
}
@@
-1953,8
+1953,8
@@
static int __devinit
snd_rme32_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
{
static int dev;
snd_rme32_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
{
static int dev;
-
rme32_t
*rme32;
- s
nd_card_t
*card;
+
struct rme32
*rme32;
+ s
truct snd_card
*card;
int err;
if (dev >= SNDRV_CARDS) {
int err;
if (dev >= SNDRV_CARDS) {
@@
-1966,10
+1966,10
@@
snd_rme32_probe(struct pci_dev *pci, const struct pci_device_id *pci_id)
}
if ((card = snd_card_new(index[dev], id[dev], THIS_MODULE,
}
if ((card = snd_card_new(index[dev], id[dev], THIS_MODULE,
- sizeof(
rme32_t
))) == NULL)
+ sizeof(
struct rme32
))) == NULL)
return -ENOMEM;
card->private_free = snd_rme32_card_free;
return -ENOMEM;
card->private_free = snd_rme32_card_free;
- rme32 = (
rme32_t
*) card->private_data;
+ rme32 = (
struct rme32
*) card->private_data;
rme32->card = card;
rme32->pci = pci;
snd_card_set_dev(card, &pci->dev);
rme32->card = card;
rme32->pci = pci;
snd_card_set_dev(card, &pci->dev);
@@
-2012,7
+2012,6
@@
static void __devexit snd_rme32_remove(struct pci_dev *pci)
static struct pci_driver driver = {
.name = "RME Digi32",
static struct pci_driver driver = {
.name = "RME Digi32",
- .owner = THIS_MODULE,
.id_table = snd_rme32_ids,
.probe = snd_rme32_probe,
.remove = __devexit_p(snd_rme32_remove),
.id_table = snd_rme32_ids,
.probe = snd_rme32_probe,
.remove = __devexit_p(snd_rme32_remove),