Skip to content

Commit

Permalink
ALSA: hda - Fix unused warnings when !SND_HDA_NEEDS_RESUME
Browse files Browse the repository at this point in the history
When SND_HDA_NEEDS_RESUME is not defined, the compiler identifies that
the following symbols are static but not used:

 restore_shutup_pins
 hda_cleanup_all_streams

Fix warnings by adding SND_HDA_NEEDS_RESUME guards.

Signed-off-by: Mike Waychison <mikew@google.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Mike Waychison authored and Takashi Iwai committed Apr 20, 2011
1 parent 6981d18 commit 1c7276c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sound/pci/hda/hda_codec.c
Original file line number Diff line number Diff line change
Expand Up @@ -937,6 +937,7 @@ void snd_hda_shutup_pins(struct hda_codec *codec)
}
EXPORT_SYMBOL_HDA(snd_hda_shutup_pins);

#ifdef SND_HDA_NEEDS_RESUME
/* Restore the pin controls cleared previously via snd_hda_shutup_pins() */
static void restore_shutup_pins(struct hda_codec *codec)
{
Expand All @@ -953,6 +954,7 @@ static void restore_shutup_pins(struct hda_codec *codec)
}
codec->pins_shutup = 0;
}
#endif

static void init_hda_cache(struct hda_cache_rec *cache,
unsigned int record_size);
Expand Down Expand Up @@ -1329,6 +1331,7 @@ static void purify_inactive_streams(struct hda_codec *codec)
}
}

#ifdef SND_HDA_NEEDS_RESUME
/* clean up all streams; called from suspend */
static void hda_cleanup_all_streams(struct hda_codec *codec)
{
Expand All @@ -1340,6 +1343,7 @@ static void hda_cleanup_all_streams(struct hda_codec *codec)
really_cleanup_stream(codec, p);
}
}
#endif

/*
* amp access functions
Expand Down

0 comments on commit 1c7276c

Please sign in to comment.