aboutsummaryrefslogtreecommitdiff
path: root/sound/pci/hda/hda_intel.c
diff options
context:
space:
mode:
authorMatthias Kaehlcke <matthias.kaehlcke@gmail.com>2007-09-17 14:40:04 +0200
committerJaroslav Kysela <perex@perex.cz>2007-10-16 16:50:42 +0200
commit33206e862edb930615a586f5156c2760ddb4bac0 (patch)
tree6032705619187a785d2cbc459b49ca78fc922e4a /sound/pci/hda/hda_intel.c
parent50f47ff1b9295f126a1256d607e5b6e951d6f34e (diff)
[ALSA] Intel HD Audio: Use list_for_each_entry(_safe)
Intel HD Audio: Use list_for_each_entry(_safe) instead of list_for_each(_safe) Signed-off-by: Matthias Kaehlcke <matthias.kaehlcke@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/hda/hda_intel.c')
-rw-r--r--sound/pci/hda/hda_intel.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 68dc9a2e3cf..cbb3da408e8 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -1393,7 +1393,6 @@ static int __devinit create_codec_pcm(struct azx *chip, struct hda_codec *codec,
static int __devinit azx_pcm_create(struct azx *chip)
{
- struct list_head *p;
struct hda_codec *codec;
int c, err;
int pcm_dev;
@@ -1404,8 +1403,7 @@ static int __devinit azx_pcm_create(struct azx *chip)
/* create audio PCMs */
pcm_dev = 0;
- list_for_each(p, &chip->bus->codec_list) {
- codec = list_entry(p, struct hda_codec, list);
+ list_for_each_entry(codec, &chip->bus->codec_list, list) {
for (c = 0; c < codec->num_pcms; c++) {
if (codec->pcm_info[c].is_modem)
continue; /* create later */
@@ -1424,8 +1422,7 @@ static int __devinit azx_pcm_create(struct azx *chip)
/* create modem PCMs */
pcm_dev = AZX_MAX_AUDIO_PCMS;
- list_for_each(p, &chip->bus->codec_list) {
- codec = list_entry(p, struct hda_codec, list);
+ list_for_each_entry(codec, &chip->bus->codec_list, list) {
for (c = 0; c < codec->num_pcms; c++) {
if (!codec->pcm_info[c].is_modem)
continue; /* already created */