Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 316150
b: refs/heads/master
c: 3fd877d
h: refs/heads/master
v: v3
  • Loading branch information
Takashi Iwai committed Jul 3, 2012
1 parent 9e1fa0c commit 46e5a78
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 257dfb410070b48e377c7894222b73ca41d662e0
refs/heads/master: 3fd877d32cac31292628fb8f443543fc1989b49b
5 changes: 3 additions & 2 deletions trunk/sound/pci/hda/hda_beep.c
Original file line number Diff line number Diff line change
Expand Up @@ -165,12 +165,13 @@ static int snd_hda_do_attach(struct hda_beep *beep)
int snd_hda_enable_beep_device(struct hda_codec *codec, int enable)
{
struct hda_beep *beep = codec->beep;
enable = !!enable;
if (beep == NULL)
if (!beep)
return 0;
enable = !!enable;
if (beep->enabled != enable) {
beep->enabled = enable;
if (!enable) {
cancel_work_sync(&beep->beep_work);
/* turn off beep */
snd_hda_codec_write(beep->codec, beep->nid, 0,
AC_VERB_SET_BEEP_CONTROL, 0);
Expand Down

0 comments on commit 46e5a78

Please sign in to comment.