Loading sound/pci/hda/hda_beep.h +1 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ struct hda_beep { int snd_hda_attach_beep_device(struct hda_codec *codec, int nid); void snd_hda_detach_beep_device(struct hda_codec *codec); #else #define snd_hda_attach_beep_device(...) #define snd_hda_attach_beep_device(...) 0 #define snd_hda_detach_beep_device(...) #endif #endif sound/pci/hda/patch_realtek.c +62 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,7 @@ #include <sound/core.h> #include "hda_codec.h" #include "hda_local.h" #include "hda_beep.h" #define ALC880_FRONT_EVENT 0x01 #define ALC880_DCVOL_EVENT 0x02 Loading Loading @@ -3187,6 +3188,7 @@ static void alc_free(struct hda_codec *codec) alc_free_kctls(codec); kfree(spec); snd_hda_detach_beep_device(codec); codec->spec = NULL; /* to be sure */ } Loading Loading @@ -4355,6 +4357,12 @@ static int patch_alc880(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC880_AUTO) setup_preset(spec, &alc880_presets[board_config]); Loading Loading @@ -5882,6 +5890,12 @@ static int patch_alc260(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC260_AUTO) setup_preset(spec, &alc260_presets[board_config]); Loading Loading @@ -7093,6 +7107,12 @@ static int patch_alc882(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC882_AUTO) setup_preset(spec, &alc882_presets[board_config]); Loading Loading @@ -9093,6 +9113,12 @@ static int patch_alc883(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC883_AUTO) setup_preset(spec, &alc883_presets[board_config]); Loading Loading @@ -11013,6 +11039,12 @@ static int patch_alc262(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC262_AUTO) setup_preset(spec, &alc262_presets[board_config]); Loading Loading @@ -12051,6 +12083,12 @@ static int patch_alc268(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC268_AUTO) setup_preset(spec, &alc268_presets[board_config]); Loading Loading @@ -12885,6 +12923,12 @@ static int patch_alc269(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC269_AUTO) setup_preset(spec, &alc269_presets[board_config]); Loading Loading @@ -13978,6 +14022,12 @@ static int patch_alc861(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x23); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC861_AUTO) setup_preset(spec, &alc861_presets[board_config]); Loading Loading @@ -14924,6 +14974,12 @@ static int patch_alc861vd(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x23); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC861VD_AUTO) setup_preset(spec, &alc861vd_presets[board_config]); Loading Loading @@ -16733,6 +16789,12 @@ static int patch_alc662(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC662_AUTO) setup_preset(spec, &alc662_presets[board_config]); Loading
sound/pci/hda/hda_beep.h +1 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,7 @@ struct hda_beep { int snd_hda_attach_beep_device(struct hda_codec *codec, int nid); void snd_hda_detach_beep_device(struct hda_codec *codec); #else #define snd_hda_attach_beep_device(...) #define snd_hda_attach_beep_device(...) 0 #define snd_hda_detach_beep_device(...) #endif #endif
sound/pci/hda/patch_realtek.c +62 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,7 @@ #include <sound/core.h> #include "hda_codec.h" #include "hda_local.h" #include "hda_beep.h" #define ALC880_FRONT_EVENT 0x01 #define ALC880_DCVOL_EVENT 0x02 Loading Loading @@ -3187,6 +3188,7 @@ static void alc_free(struct hda_codec *codec) alc_free_kctls(codec); kfree(spec); snd_hda_detach_beep_device(codec); codec->spec = NULL; /* to be sure */ } Loading Loading @@ -4355,6 +4357,12 @@ static int patch_alc880(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC880_AUTO) setup_preset(spec, &alc880_presets[board_config]); Loading Loading @@ -5882,6 +5890,12 @@ static int patch_alc260(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC260_AUTO) setup_preset(spec, &alc260_presets[board_config]); Loading Loading @@ -7093,6 +7107,12 @@ static int patch_alc882(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC882_AUTO) setup_preset(spec, &alc882_presets[board_config]); Loading Loading @@ -9093,6 +9113,12 @@ static int patch_alc883(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC883_AUTO) setup_preset(spec, &alc883_presets[board_config]); Loading Loading @@ -11013,6 +11039,12 @@ static int patch_alc262(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC262_AUTO) setup_preset(spec, &alc262_presets[board_config]); Loading Loading @@ -12051,6 +12083,12 @@ static int patch_alc268(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC268_AUTO) setup_preset(spec, &alc268_presets[board_config]); Loading Loading @@ -12885,6 +12923,12 @@ static int patch_alc269(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC269_AUTO) setup_preset(spec, &alc269_presets[board_config]); Loading Loading @@ -13978,6 +14022,12 @@ static int patch_alc861(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x23); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC861_AUTO) setup_preset(spec, &alc861_presets[board_config]); Loading Loading @@ -14924,6 +14974,12 @@ static int patch_alc861vd(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x23); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC861VD_AUTO) setup_preset(spec, &alc861vd_presets[board_config]); Loading Loading @@ -16733,6 +16789,12 @@ static int patch_alc662(struct hda_codec *codec) } } err = snd_hda_attach_beep_device(codec, 0x1); if (err < 0) { alc_free(codec); return err; } if (board_config != ALC662_AUTO) setup_preset(spec, &alc662_presets[board_config]);