diff options
Diffstat (limited to 'sound/pci/hda/hda_beep.c')
-rw-r--r-- | sound/pci/hda/hda_beep.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/pci/hda/hda_beep.c b/sound/pci/hda/hda_beep.c index b0275a050870..3f51a981e604 100644 --- a/sound/pci/hda/hda_beep.c +++ b/sound/pci/hda/hda_beep.c | |||
@@ -24,6 +24,7 @@ | |||
24 | #include <linux/workqueue.h> | 24 | #include <linux/workqueue.h> |
25 | #include <sound/core.h> | 25 | #include <sound/core.h> |
26 | #include "hda_beep.h" | 26 | #include "hda_beep.h" |
27 | #include "hda_local.h" | ||
27 | 28 | ||
28 | enum { | 29 | enum { |
29 | DIGBEEP_HZ_STEP = 46875, /* 46.875 Hz */ | 30 | DIGBEEP_HZ_STEP = 46875, /* 46.875 Hz */ |
@@ -118,6 +119,9 @@ int snd_hda_attach_beep_device(struct hda_codec *codec, int nid) | |||
118 | struct hda_beep *beep; | 119 | struct hda_beep *beep; |
119 | int err; | 120 | int err; |
120 | 121 | ||
122 | if (!snd_hda_get_bool_hint(codec, "beep")) | ||
123 | return 0; /* disabled explicitly */ | ||
124 | |||
121 | beep = kzalloc(sizeof(*beep), GFP_KERNEL); | 125 | beep = kzalloc(sizeof(*beep), GFP_KERNEL); |
122 | if (beep == NULL) | 126 | if (beep == NULL) |
123 | return -ENOMEM; | 127 | return -ENOMEM; |