Skip to content

Commit

Permalink
Merge branch 'topic/misc' into for-linus
Browse files Browse the repository at this point in the history
  • Loading branch information
tiwai committed Mar 23, 2009
2 parents d807500 + c468ac2 commit e0d2054
Show file tree
Hide file tree
Showing 60 changed files with 491 additions and 277 deletions.
2 changes: 1 addition & 1 deletion include/sound/pcm.h
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ struct snd_pcm_notify {

extern const struct file_operations snd_pcm_f_ops[2];

int snd_pcm_new(struct snd_card *card, char *id, int device,
int snd_pcm_new(struct snd_card *card, const char *id, int device,
int playback_count, int capture_count,
struct snd_pcm **rpcm);
int snd_pcm_new_stream(struct snd_pcm *pcm, int stream, int substream_count);
Expand Down
2 changes: 1 addition & 1 deletion include/sound/version.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
/* include/version.h */
#define CONFIG_SND_VERSION "1.0.18a"
#define CONFIG_SND_VERSION "1.0.19"
#define CONFIG_SND_DATE ""
2 changes: 1 addition & 1 deletion sound/arm/sa11xx-uda1341.c
Original file line number Diff line number Diff line change
Expand Up @@ -915,7 +915,7 @@ static int __devinit sa11xx_uda1341_probe(struct platform_device *devptr)
snd_card_set_dev(card, &devptr->dev);

if ((err = snd_card_register(card)) == 0) {
printk( KERN_INFO "iPAQ audio support initialized\n" );
printk(KERN_INFO "iPAQ audio support initialized\n");
platform_set_drvdata(devptr, card);
return 0;
}
Expand Down
49 changes: 31 additions & 18 deletions sound/core/oss/pcm_oss.c
Original file line number Diff line number Diff line change
Expand Up @@ -1160,9 +1160,11 @@ snd_pcm_sframes_t snd_pcm_oss_write3(struct snd_pcm_substream *substream, const
runtime->status->state == SNDRV_PCM_STATE_SUSPENDED) {
#ifdef OSS_DEBUG
if (runtime->status->state == SNDRV_PCM_STATE_XRUN)
printk("pcm_oss: write: recovering from XRUN\n");
printk(KERN_DEBUG "pcm_oss: write: "
"recovering from XRUN\n");
else
printk("pcm_oss: write: recovering from SUSPEND\n");
printk(KERN_DEBUG "pcm_oss: write: "
"recovering from SUSPEND\n");
#endif
ret = snd_pcm_oss_prepare(substream);
if (ret < 0)
Expand Down Expand Up @@ -1196,9 +1198,11 @@ snd_pcm_sframes_t snd_pcm_oss_read3(struct snd_pcm_substream *substream, char *p
runtime->status->state == SNDRV_PCM_STATE_SUSPENDED) {
#ifdef OSS_DEBUG
if (runtime->status->state == SNDRV_PCM_STATE_XRUN)
printk("pcm_oss: read: recovering from XRUN\n");
printk(KERN_DEBUG "pcm_oss: read: "
"recovering from XRUN\n");
else
printk("pcm_oss: read: recovering from SUSPEND\n");
printk(KERN_DEBUG "pcm_oss: read: "
"recovering from SUSPEND\n");
#endif
ret = snd_pcm_kernel_ioctl(substream, SNDRV_PCM_IOCTL_DRAIN, NULL);
if (ret < 0)
Expand Down Expand Up @@ -1242,9 +1246,11 @@ snd_pcm_sframes_t snd_pcm_oss_writev3(struct snd_pcm_substream *substream, void
runtime->status->state == SNDRV_PCM_STATE_SUSPENDED) {
#ifdef OSS_DEBUG
if (runtime->status->state == SNDRV_PCM_STATE_XRUN)
printk("pcm_oss: writev: recovering from XRUN\n");
printk(KERN_DEBUG "pcm_oss: writev: "
"recovering from XRUN\n");
else
printk("pcm_oss: writev: recovering from SUSPEND\n");
printk(KERN_DEBUG "pcm_oss: writev: "
"recovering from SUSPEND\n");
#endif
ret = snd_pcm_oss_prepare(substream);
if (ret < 0)
Expand Down Expand Up @@ -1278,9 +1284,11 @@ snd_pcm_sframes_t snd_pcm_oss_readv3(struct snd_pcm_substream *substream, void *
runtime->status->state == SNDRV_PCM_STATE_SUSPENDED) {
#ifdef OSS_DEBUG
if (runtime->status->state == SNDRV_PCM_STATE_XRUN)
printk("pcm_oss: readv: recovering from XRUN\n");
printk(KERN_DEBUG "pcm_oss: readv: "
"recovering from XRUN\n");
else
printk("pcm_oss: readv: recovering from SUSPEND\n");
printk(KERN_DEBUG "pcm_oss: readv: "
"recovering from SUSPEND\n");
#endif
ret = snd_pcm_kernel_ioctl(substream, SNDRV_PCM_IOCTL_DRAIN, NULL);
if (ret < 0)
Expand Down Expand Up @@ -1533,7 +1541,7 @@ static int snd_pcm_oss_sync1(struct snd_pcm_substream *substream, size_t size)
init_waitqueue_entry(&wait, current);
add_wait_queue(&runtime->sleep, &wait);
#ifdef OSS_DEBUG
printk("sync1: size = %li\n", size);
printk(KERN_DEBUG "sync1: size = %li\n", size);
#endif
while (1) {
result = snd_pcm_oss_write2(substream, runtime->oss.buffer, size, 1);
Expand Down Expand Up @@ -1590,7 +1598,7 @@ static int snd_pcm_oss_sync(struct snd_pcm_oss_file *pcm_oss_file)
mutex_lock(&runtime->oss.params_lock);
if (runtime->oss.buffer_used > 0) {
#ifdef OSS_DEBUG
printk("sync: buffer_used\n");
printk(KERN_DEBUG "sync: buffer_used\n");
#endif
size = (8 * (runtime->oss.period_bytes - runtime->oss.buffer_used) + 7) / width;
snd_pcm_format_set_silence(format,
Expand All @@ -1603,7 +1611,7 @@ static int snd_pcm_oss_sync(struct snd_pcm_oss_file *pcm_oss_file)
}
} else if (runtime->oss.period_ptr > 0) {
#ifdef OSS_DEBUG
printk("sync: period_ptr\n");
printk(KERN_DEBUG "sync: period_ptr\n");
#endif
size = runtime->oss.period_bytes - runtime->oss.period_ptr;
snd_pcm_format_set_silence(format,
Expand Down Expand Up @@ -1952,7 +1960,7 @@ static int snd_pcm_oss_set_trigger(struct snd_pcm_oss_file *pcm_oss_file, int tr
int err, cmd;

#ifdef OSS_DEBUG
printk("pcm_oss: trigger = 0x%x\n", trigger);
printk(KERN_DEBUG "pcm_oss: trigger = 0x%x\n", trigger);
#endif

psubstream = pcm_oss_file->streams[SNDRV_PCM_STREAM_PLAYBACK];
Expand Down Expand Up @@ -2170,7 +2178,9 @@ static int snd_pcm_oss_get_space(struct snd_pcm_oss_file *pcm_oss_file, int stre
}

#ifdef OSS_DEBUG
printk("pcm_oss: space: bytes = %i, fragments = %i, fragstotal = %i, fragsize = %i\n", info.bytes, info.fragments, info.fragstotal, info.fragsize);
printk(KERN_DEBUG "pcm_oss: space: bytes = %i, fragments = %i, "
"fragstotal = %i, fragsize = %i\n",
info.bytes, info.fragments, info.fragstotal, info.fragsize);
#endif
if (copy_to_user(_info, &info, sizeof(info)))
return -EFAULT;
Expand Down Expand Up @@ -2473,7 +2483,7 @@ static long snd_pcm_oss_ioctl(struct file *file, unsigned int cmd, unsigned long
if (((cmd >> 8) & 0xff) != 'P')
return -EINVAL;
#ifdef OSS_DEBUG
printk("pcm_oss: ioctl = 0x%x\n", cmd);
printk(KERN_DEBUG "pcm_oss: ioctl = 0x%x\n", cmd);
#endif
switch (cmd) {
case SNDCTL_DSP_RESET:
Expand Down Expand Up @@ -2627,7 +2637,8 @@ static ssize_t snd_pcm_oss_read(struct file *file, char __user *buf, size_t coun
#else
{
ssize_t res = snd_pcm_oss_read1(substream, buf, count);
printk("pcm_oss: read %li bytes (returned %li bytes)\n", (long)count, (long)res);
printk(KERN_DEBUG "pcm_oss: read %li bytes "
"(returned %li bytes)\n", (long)count, (long)res);
return res;
}
#endif
Expand All @@ -2646,7 +2657,8 @@ static ssize_t snd_pcm_oss_write(struct file *file, const char __user *buf, size
substream->f_flags = file->f_flags & O_NONBLOCK;
result = snd_pcm_oss_write1(substream, buf, count);
#ifdef OSS_DEBUG
printk("pcm_oss: write %li bytes (wrote %li bytes)\n", (long)count, (long)result);
printk(KERN_DEBUG "pcm_oss: write %li bytes (wrote %li bytes)\n",
(long)count, (long)result);
#endif
return result;
}
Expand Down Expand Up @@ -2720,7 +2732,7 @@ static int snd_pcm_oss_mmap(struct file *file, struct vm_area_struct *area)
int err;

#ifdef OSS_DEBUG
printk("pcm_oss: mmap begin\n");
printk(KERN_DEBUG "pcm_oss: mmap begin\n");
#endif
pcm_oss_file = file->private_data;
switch ((area->vm_flags & (VM_READ | VM_WRITE))) {
Expand Down Expand Up @@ -2770,7 +2782,8 @@ static int snd_pcm_oss_mmap(struct file *file, struct vm_area_struct *area)
runtime->silence_threshold = 0;
runtime->silence_size = 0;
#ifdef OSS_DEBUG
printk("pcm_oss: mmap ok, bytes = 0x%x\n", runtime->oss.mmap_bytes);
printk(KERN_DEBUG "pcm_oss: mmap ok, bytes = 0x%x\n",
runtime->oss.mmap_bytes);
#endif
/* In mmap mode we never stop */
runtime->stop_threshold = runtime->boundary;
Expand Down
4 changes: 2 additions & 2 deletions sound/core/oss/pcm_plugin.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,9 @@ static inline int snd_pcm_plug_slave_format(int format, struct snd_mask *format_
#endif

#ifdef PLUGIN_DEBUG
#define pdprintf( fmt, args... ) printk( "plugin: " fmt, ##args)
#define pdprintf(fmt, args...) printk(KERN_DEBUG "plugin: " fmt, ##args)
#else
#define pdprintf( fmt, args... )
#define pdprintf(fmt, args...)
#endif

#endif /* __PCM_PLUGIN_H */
2 changes: 1 addition & 1 deletion sound/core/pcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -691,7 +691,7 @@ EXPORT_SYMBOL(snd_pcm_new_stream);
*
* Returns zero if successful, or a negative error code on failure.
*/
int snd_pcm_new(struct snd_card *card, char *id, int device,
int snd_pcm_new(struct snd_card *card, const char *id, int device,
int playback_count, int capture_count,
struct snd_pcm ** rpcm)
{
Expand Down
6 changes: 3 additions & 3 deletions sound/core/pcm_native.c
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ int snd_pcm_hw_refine(struct snd_pcm_substream *substream,
if (!(params->rmask & (1 << k)))
continue;
#ifdef RULES_DEBUG
printk("%s = ", snd_pcm_hw_param_names[k]);
printk(KERN_DEBUG "%s = ", snd_pcm_hw_param_names[k]);
printk("%04x%04x%04x%04x -> ", m->bits[3], m->bits[2], m->bits[1], m->bits[0]);
#endif
changed = snd_mask_refine(m, constrs_mask(constrs, k));
Expand All @@ -206,7 +206,7 @@ int snd_pcm_hw_refine(struct snd_pcm_substream *substream,
if (!(params->rmask & (1 << k)))
continue;
#ifdef RULES_DEBUG
printk("%s = ", snd_pcm_hw_param_names[k]);
printk(KERN_DEBUG "%s = ", snd_pcm_hw_param_names[k]);
if (i->empty)
printk("empty");
else
Expand Down Expand Up @@ -251,7 +251,7 @@ int snd_pcm_hw_refine(struct snd_pcm_substream *substream,
if (!doit)
continue;
#ifdef RULES_DEBUG
printk("Rule %d [%p]: ", k, r->func);
printk(KERN_DEBUG "Rule %d [%p]: ", k, r->func);
if (r->var >= 0) {
printk("%s = ", snd_pcm_hw_param_names[r->var]);
if (hw_is_mask(r->var)) {
Expand Down
2 changes: 1 addition & 1 deletion sound/core/seq/oss/seq_oss_device.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ char *enabled_str(int bool);
/* for debug */
#ifdef SNDRV_SEQ_OSS_DEBUG
extern int seq_oss_debug;
#define debug_printk(x) do { if (seq_oss_debug > 0) snd_printk x; } while (0)
#define debug_printk(x) do { if (seq_oss_debug > 0) snd_printd x; } while (0)
#else
#define debug_printk(x) /**/
#endif
Expand Down
3 changes: 2 additions & 1 deletion sound/core/seq/seq_prioq.c
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,8 @@ void snd_seq_prioq_leave(struct snd_seq_prioq * f, int client, int timestamp)
freeprev = cell;
} else {
#if 0
printk("type = %i, source = %i, dest = %i, client = %i\n",
printk(KERN_DEBUG "type = %i, source = %i, dest = %i, "
"client = %i\n",
cell->event.type,
cell->event.source.client,
cell->event.dest.client,
Expand Down
12 changes: 7 additions & 5 deletions sound/drivers/mtpav.c
Original file line number Diff line number Diff line change
Expand Up @@ -303,8 +303,10 @@ static void snd_mtpav_output_port_write(struct mtpav *mtp_card,

snd_mtpav_send_byte(mtp_card, 0xf5);
snd_mtpav_send_byte(mtp_card, portp->hwport);
//snd_printk("new outport: 0x%x\n", (unsigned int) portp->hwport);

/*
snd_printk(KERN_DEBUG "new outport: 0x%x\n",
(unsigned int) portp->hwport);
*/
if (!(outbyte & 0x80) && portp->running_status)
snd_mtpav_send_byte(mtp_card, portp->running_status);
}
Expand Down Expand Up @@ -540,7 +542,7 @@ static void snd_mtpav_read_bytes(struct mtpav *mcrd)

u8 sbyt = snd_mtpav_getreg(mcrd, SREG);

//printk("snd_mtpav_read_bytes() sbyt: 0x%x\n", sbyt);
/* printk(KERN_DEBUG "snd_mtpav_read_bytes() sbyt: 0x%x\n", sbyt); */

if (!(sbyt & SIGS_BYTE))
return;
Expand Down Expand Up @@ -585,12 +587,12 @@ static irqreturn_t snd_mtpav_irqh(int irq, void *dev_id)
static int __devinit snd_mtpav_get_ISA(struct mtpav * mcard)
{
if ((mcard->res_port = request_region(port, 3, "MotuMTPAV MIDI")) == NULL) {
snd_printk("MTVAP port 0x%lx is busy\n", port);
snd_printk(KERN_ERR "MTVAP port 0x%lx is busy\n", port);
return -EBUSY;
}
mcard->port = port;
if (request_irq(irq, snd_mtpav_irqh, IRQF_DISABLED, "MOTU MTPAV", mcard)) {
snd_printk("MTVAP IRQ %d busy\n", irq);
snd_printk(KERN_ERR "MTVAP IRQ %d busy\n", irq);
return -EBUSY;
}
mcard->irq = irq;
Expand Down
2 changes: 1 addition & 1 deletion sound/drivers/mts64.c
Original file line number Diff line number Diff line change
Expand Up @@ -1015,7 +1015,7 @@ static int __devinit snd_mts64_probe(struct platform_device *pdev)
goto __err;
}

snd_printk("ESI Miditerminal 4140 on 0x%lx\n", p->base);
snd_printk(KERN_INFO "ESI Miditerminal 4140 on 0x%lx\n", p->base);
return 0;

__err:
Expand Down
2 changes: 1 addition & 1 deletion sound/drivers/opl3/opl3_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ void snd_opl3_interrupt(struct snd_hwdep * hw)
opl3 = hw->private_data;
status = inb(opl3->l_port);
#if 0
snd_printk("AdLib IRQ status = 0x%x\n", status);
snd_printk(KERN_DEBUG "AdLib IRQ status = 0x%x\n", status);
#endif
if (!(status & 0x80))
return;
Expand Down
Loading

0 comments on commit e0d2054

Please sign in to comment.