参照元

説明

引数

返り値

参考

実装

CONFIG_SND_JACK 有効: sound/core/jack.c

/**
 * snd_jack_report - Report the current status of a jack
 *
 * @jack:   The jack to report status for
 * @status: The current status of the jack
 */
void snd_jack_report(struct snd_jack *jack, int status)
{
        struct snd_jack_kctl *jack_kctl;
        int i;
        if (!jack)
                return;

        list_for_each_entry(jack_kctl, &jack->kctl_list, list)
                snd_kctl_jack_report(jack->card, jack_kctl->kctl,
                                            status & jack_kctl->mask_bits);
        if (!jack->input_dev)
                return;

        for (i = 0; i < ARRAY_SIZE(jack->key); i++) {
                int testbit = SND_JACK_BTN_0 >> i;

                if (jack->type & testbit)
                        input_report_key(jack->input_dev, jack->key[i],
                                         status & testbit);
        }

        for (i = 0; i < ARRAY_SIZE(jack_switch_types); i++) {
                int testbit = 1 << i;
                if (jack->type & testbit)
                        input_report_switch(jack->input_dev,
                                            jack_switch_types[i],
                                            status & testbit);
        }

        input_sync(jack->input_dev);
}
EXPORT_SYMBOL(snd_jack_report);

CONFIG_SND_JACK 無効: include/sound/jack.h

static inline void snd_jack_report(struct snd_jack *jack, int status)
{
}

コメント


トップ   編集 凍結 差分 履歴 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS
Last-modified: 2016-07-27 (水) 15:50:34