diff mbox

[V2,1/2] ALSA: HDA: use PCI_BASE_CLASS_DISPLAY to replace PCI_CLASS_DISPLAY_VGA

Message ID 1531721195-4982-1-git-send-email-Jim.Qu@amd.com (mailing list archive)
State New, archived
Headers show

Commit Message

Qu, Jim July 16, 2018, 6:06 a.m. UTC
Except PCI_CLASS_DISPLAY_VGA, some PCI class is sometimes
PCI_CLASS_DISPLAY_3D or PCI_CLASS_DISPLAY_OTHER.

Signed-off-by: Jim Qu <Jim.Qu@amd.com>
---
 sound/pci/hda/hda_intel.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Takashi Iwai July 16, 2018, 12:52 p.m. UTC | #1
On Mon, 16 Jul 2018 08:06:34 +0200,
Jim Qu wrote:
> 
> Except PCI_CLASS_DISPLAY_VGA, some PCI class is sometimes
> PCI_CLASS_DISPLAY_3D or PCI_CLASS_DISPLAY_OTHER.
> 
> Signed-off-by: Jim Qu <Jim.Qu@amd.com>

Applied this one now, as it's basically an individual fix.


thanks,

Takashi
diff mbox

Patch

diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 1ae1850..14733ff 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -1429,7 +1429,7 @@  static struct pci_dev *get_bound_vga(struct pci_dev *pci)
 			p = pci_get_domain_bus_and_slot(pci_domain_nr(pci->bus),
 							pci->bus->number, 0);
 			if (p) {
-				if ((p->class >> 8) == PCI_CLASS_DISPLAY_VGA)
+				if ((p->class >> 16) == PCI_BASE_CLASS_DISPLAY)
 					return p;
 				pci_dev_put(p);
 			}