参照元

説明

引数

返り値

参考

実装

static snd_pcm_uframes_t
snd_pcm_update_hw_ptr_pos(struct snd_pcm_substream *substream,
			  struct snd_pcm_runtime *runtime)
{
	snd_pcm_uframes_t pos;
	pos = substream->ops->pointer(substream);
	if (pos == SNDRV_PCM_POS_XRUN)
		return pos; /* XRUN */
	if (pos >= runtime->buffer_size) {
		if (printk_ratelimit()) {
			char name[16];
			pcm_debug_name(substream, name, sizeof(name));
			snd_printd(KERN_ERR  "BUG: %s, pos = 0x%lx, "
				   "buffer size = 0x%lx, period size = 0x%lx\n",
				   name, pos, runtime->buffer_size,
				   runtime->period_size);
		}
		pos = 0;
	}
	pos -= pos % runtime->min_align;
	return pos;
}

コメント


トップ   編集 凍結 差分 履歴 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2014-09-13 (土) 08:26:43