git: 5eb1ab19a359 - stable/13 - Revert "LinuxKPI: Automatically enable drm support for devices named "drmn""

From: Vladimir Kondratyev <wulf_at_FreeBSD.org>
Date: Thu, 01 Aug 2024 23:18:05 UTC
The branch stable/13 has been updated by wulf:

URL: https://cgit.FreeBSD.org/src/commit/?id=5eb1ab19a359a9639627686ba6af6c02d6ce1cf8

commit 5eb1ab19a359a9639627686ba6af6c02d6ce1cf8
Author:     Vladimir Kondratyev <wulf@FreeBSD.org>
AuthorDate: 2024-08-01 23:12:32 +0000
Commit:     Vladimir Kondratyev <wulf@FreeBSD.org>
CommitDate: 2024-08-01 23:12:32 +0000

    Revert "LinuxKPI: Automatically enable drm support for devices named "drmn""
    
    This reverts commit 85da0abada244f90dc6e9ce36c75492f0aa9bf02.
    
    It is based on other not MFC-ed commit.
---
 sys/compat/linuxkpi/common/src/linux_pci.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c
index 459f03f7e2a4..5f7296d66ee9 100644
--- a/sys/compat/linuxkpi/common/src/linux_pci.c
+++ b/sys/compat/linuxkpi/common/src/linux_pci.c
@@ -752,8 +752,7 @@ linux_pci_register_driver(struct pci_driver *pdrv)
 {
 	devclass_t dc;
 
-	pdrv->isdrm = strcmp(pdrv->name, "drmn") == 0;
-	dc = pdrv->isdrm ? devclass_create("vgapci") : devclass_find("pci");
+	dc = devclass_find("pci");
 	if (dc == NULL)
 		return (-ENXIO);
 	return (_linux_pci_register_driver(pdrv, dc));
@@ -908,7 +907,7 @@ linux_pci_unregister_driver(struct pci_driver *pdrv)
 {
 	devclass_t bus;
 
-	bus = devclass_find(pdrv->isdrm ? "vgapci" : "pci");
+	bus = devclass_find("pci");
 
 	spin_lock(&pci_lock);
 	list_del(&pdrv->node);