Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-17 Thread Pali Rohár
On Tuesday 17 April 2018 04:38:29 Lukas Wunner wrote: > On Mon, Apr 16, 2018 at 04:25:12PM +0200, Pali Rohár wrote: > > On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > > > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > > > On Saturday 14 April 2018 13:17:11 Lukas Wunner

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-17 Thread Pali Rohár
On Tuesday 17 April 2018 04:38:29 Lukas Wunner wrote: > On Mon, Apr 16, 2018 at 04:25:12PM +0200, Pali Rohár wrote: > > On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > > > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > > > On Saturday 14 April 2018 13:17:11 Lukas Wunner

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-16 Thread Lukas Wunner
On Mon, Apr 16, 2018 at 04:25:12PM +0200, Pali Rohár wrote: > On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-16 Thread Lukas Wunner
On Mon, Apr 16, 2018 at 04:25:12PM +0200, Pali Rohár wrote: > On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-16 Thread Pali Rohár
On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > > > On Saturday 14 April 2018 12:45:12 Lukas Wunner

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-16 Thread Pali Rohár
On Sunday 15 April 2018 21:05:23 Lukas Wunner wrote: > On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > > > On Saturday 14 April 2018 12:45:12 Lukas Wunner

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-15 Thread Lukas Wunner
On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > > > On Thu, Apr 12, 2018 at 10:15:41PM +0800,

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-15 Thread Lukas Wunner
On Sun, Apr 15, 2018 at 07:17:46PM +0200, Pali Rohár wrote: > On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > > > On Thu, Apr 12, 2018 at 10:15:41PM +0800,

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-15 Thread Pali Rohár
On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > > Do you have any suggestion to check if it

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-15 Thread Pali Rohár
On Saturday 14 April 2018 13:17:11 Lukas Wunner wrote: > On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > > Do you have any suggestion to check if it

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Thu, Apr 12, 2018 at 10:12:49PM +0800, Kai-Heng Feng wrote: > at 6:50 PM, Takashi Iwai wrote: > > On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: > > > When SG is enabled, the unused AMD audio controller still exposes its > > > sysfs, so userspace still opens the

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Thu, Apr 12, 2018 at 10:12:49PM +0800, Kai-Heng Feng wrote: > at 6:50 PM, Takashi Iwai wrote: > > On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: > > > When SG is enabled, the unused AMD audio controller still exposes its > > > sysfs, so userspace still opens the control file and

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > Do you have any suggestion to check if it connects to the system via > > > Thunderbolt? > > > > Just use

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Sat, Apr 14, 2018 at 12:49:50PM +0200, Pali Rohár wrote: > On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > Do you have any suggestion to check if it connects to the system via > > > Thunderbolt? > > > > Just use

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Pali Rohár
On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > >>@@ -1711,6 +1745,11 @@ static int azx_create(struct snd_card *card, > > > >>struct pci_dev *pci, > > > >>if (err < 0) > > > >>return err; > > > >>

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Pali Rohár
On Saturday 14 April 2018 12:45:12 Lukas Wunner wrote: > On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > > >>@@ -1711,6 +1745,11 @@ static int azx_create(struct snd_card *card, > > > >>struct pci_dev *pci, > > > >>if (err < 0) > > > >>return err; > > > >>

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > >>@@ -1711,6 +1745,11 @@ static int azx_create(struct snd_card *card, > > >>struct pci_dev *pci, > > >> if (err < 0) > > >> return err; > > >> > > >>+ if (check_dell_switchable_gfx(pci)) { > > >>+

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-14 Thread Lukas Wunner
On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > > >>@@ -1711,6 +1745,11 @@ static int azx_create(struct snd_card *card, > > >>struct pci_dev *pci, > > >> if (err < 0) > > >> return err; > > >> > > >>+ if (check_dell_switchable_gfx(pci)) { > > >>+

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-13 Thread Darren Hart
On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > at 6:59 PM, Pali Rohár wrote: > > > On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: > > > > +#if IS_ENABLED(CONFIG_DELL_LAPTOP) > > > > +static bool check_dell_switchable_gfx(struct pci_dev *pdev) > > >

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-13 Thread Darren Hart
On Thu, Apr 12, 2018 at 10:15:41PM +0800, Kai-Heng Feng wrote: > at 6:59 PM, Pali Rohár wrote: > > > On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: > > > > +#if IS_ENABLED(CONFIG_DELL_LAPTOP) > > > > +static bool check_dell_switchable_gfx(struct pci_dev *pdev) > > > > +{ > > > > +

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
at 6:59 PM, Pali Rohár wrote: On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: +#if IS_ENABLED(CONFIG_DELL_LAPTOP) +static bool check_dell_switchable_gfx(struct pci_dev *pdev) +{ + bool (*dell_switchable_gfx_is_enabled_func)(void); + bool enabled; + +

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
at 6:59 PM, Pali Rohár wrote: On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: +#if IS_ENABLED(CONFIG_DELL_LAPTOP) +static bool check_dell_switchable_gfx(struct pci_dev *pdev) +{ + bool (*dell_switchable_gfx_is_enabled_func)(void); + bool enabled; + + /* Only need to

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
at 6:50 PM, Takashi Iwai wrote: On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option "Switchable Graphics" (SG). When SG is enabled, we have: 00:02.0 VGA compatible controller: Intel Corporation Device

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
at 6:50 PM, Takashi Iwai wrote: On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option "Switchable Graphics" (SG). When SG is enabled, we have: 00:02.0 VGA compatible controller: Intel Corporation Device 591b (rev 04)

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Pali Rohár
On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: > > +#if IS_ENABLED(CONFIG_DELL_LAPTOP) > > +static bool check_dell_switchable_gfx(struct pci_dev *pdev) > > +{ > > + bool (*dell_switchable_gfx_is_enabled_func)(void); > > + bool enabled; > > + > > + /* Only need to check for Dell

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Pali Rohár
On Thursday 12 April 2018 12:50:02 Takashi Iwai wrote: > > +#if IS_ENABLED(CONFIG_DELL_LAPTOP) > > +static bool check_dell_switchable_gfx(struct pci_dev *pdev) > > +{ > > + bool (*dell_switchable_gfx_is_enabled_func)(void); > > + bool enabled; > > + > > + /* Only need to check for Dell

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Takashi Iwai
On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: > > Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option > "Switchable Graphics" (SG). > > When SG is enabled, we have: > 00:02.0 VGA compatible controller: Intel Corporation Device 591b (rev 04) > 00:1f.3 Audio device:

Re: [PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Takashi Iwai
On Thu, 12 Apr 2018 12:42:39 +0200, Kai-Heng Feng wrote: > > Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option > "Switchable Graphics" (SG). > > When SG is enabled, we have: > 00:02.0 VGA compatible controller: Intel Corporation Device 591b (rev 04) > 00:1f.3 Audio device:

[PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option "Switchable Graphics" (SG). When SG is enabled, we have: 00:02.0 VGA compatible controller: Intel Corporation Device 591b (rev 04) 00:1f.3 Audio device: Intel Corporation CM238 HD Audio Controller (rev 31) 01:00.0 VGA

[PATCH v3 3/3] ALSA: hda: Disabled unused audio controller for Dell platforms with Switchable Graphics

2018-04-12 Thread Kai-Heng Feng
Some Dell platforms (Preicsion 7510/7710/7520/7720) have a BIOS option "Switchable Graphics" (SG). When SG is enabled, we have: 00:02.0 VGA compatible controller: Intel Corporation Device 591b (rev 04) 00:1f.3 Audio device: Intel Corporation CM238 HD Audio Controller (rev 31) 01:00.0 VGA