linux-4.4.1/snd_soc_component_update_bits_legacy()
をテンプレートにして作成
[
トップ
] [
新規
|
一覧
|
検索
|
最終更新
|
ヘルプ
|
ログイン
]
開始行:
*参照元 [#m191827a]
#backlinks
*説明 [#ufbe42be]
-パス: [[linux-4.4.1/sound/soc/soc-io.c]]
-FIXME: これは何?
--説明
**引数 [#fe479580]
-struct snd_soc_component *component
--
--[[linux-4.4.1/snd_soc_component]]
-unsigned int reg
--
-unsigned int mask
--
-unsigned int val
--
-bool *change
--
**返り値 [#g7813de4]
-int
--
**参考 [#mdd44bee]
*実装 [#vc1fa542]
static int snd_soc_component_update_bits_legacy(
struct snd_soc_component *component, unsigned in...
unsigned int mask, unsigned int val, bool *change)
{
unsigned int old, new;
int ret;
if (!component->read || !component->write)
return -EIO;
mutex_lock(&component->io_mutex);
-
--[[linux-4.4.1/mutex_lock()]]
ret = component->read(component, reg, &old);
if (ret < 0)
goto out_unlock;
new = (old & ~mask) | (val & mask);
*change = old != new;
if (*change)
ret = component->write(component, reg, n...
out_unlock:
mutex_unlock(&component->io_mutex);
-
--[[linux-4.4.1/mutex_unlock()]]
return ret;
}
*コメント [#od6883f0]
終了行:
*参照元 [#m191827a]
#backlinks
*説明 [#ufbe42be]
-パス: [[linux-4.4.1/sound/soc/soc-io.c]]
-FIXME: これは何?
--説明
**引数 [#fe479580]
-struct snd_soc_component *component
--
--[[linux-4.4.1/snd_soc_component]]
-unsigned int reg
--
-unsigned int mask
--
-unsigned int val
--
-bool *change
--
**返り値 [#g7813de4]
-int
--
**参考 [#mdd44bee]
*実装 [#vc1fa542]
static int snd_soc_component_update_bits_legacy(
struct snd_soc_component *component, unsigned in...
unsigned int mask, unsigned int val, bool *change)
{
unsigned int old, new;
int ret;
if (!component->read || !component->write)
return -EIO;
mutex_lock(&component->io_mutex);
-
--[[linux-4.4.1/mutex_lock()]]
ret = component->read(component, reg, &old);
if (ret < 0)
goto out_unlock;
new = (old & ~mask) | (val & mask);
*change = old != new;
if (*change)
ret = component->write(component, reg, n...
out_unlock:
mutex_unlock(&component->io_mutex);
-
--[[linux-4.4.1/mutex_unlock()]]
return ret;
}
*コメント [#od6883f0]
ページ名: