summaryrefslogtreecommitdiff
path: root/sys/dev/pci/drm/radeon/radeon_kms.c
diff options
context:
space:
mode:
authorMartin Pieuchot <mpieuchot@nolizard.org>2013-08-09 18:57:19 +0200
committerJonathan Gray <jsg@jsg.id.au>2013-08-12 10:47:39 +1000
commited00ac0090464a5340ef57bd975f7fce1c142cee (patch)
tree1ef6e18bfdde6c62d60c9c628329e79af2633667 /sys/dev/pci/drm/radeon/radeon_kms.c
parent58bbe25523e607f5c22411107a6db9f517712cef (diff)
Match the macppc's framebuffer device with its OpenFirmware node likekms/radeon
on sparc64.
Diffstat (limited to 'sys/dev/pci/drm/radeon/radeon_kms.c')
-rw-r--r--sys/dev/pci/drm/radeon/radeon_kms.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sys/dev/pci/drm/radeon/radeon_kms.c b/sys/dev/pci/drm/radeon/radeon_kms.c
index d8eefdac7c4..86515ecbf60 100644
--- a/sys/dev/pci/drm/radeon/radeon_kms.c
+++ b/sys/dev/pci/drm/radeon/radeon_kms.c
@@ -40,10 +40,6 @@
extern int vga_console_attached;
#endif
-#ifdef __macppc__
-#include "vgafb_pci.h"
-#endif
-
#define DRIVER_NAME "radeon"
#define DRIVER_DESC "ATI Radeon"
#define DRIVER_DATE "20080613"
@@ -1558,7 +1554,7 @@ radeondrm_attach_kms(struct device *parent, struct device *self, void *aux)
pcireg_t type;
uint8_t iobar;
-#ifdef __sparc64__
+#if defined(__sparc64__) || defined(__macppc__)
extern int fbnode;
#endif
@@ -1571,13 +1567,9 @@ radeondrm_attach_kms(struct device *parent, struct device *self, void *aux)
rdev->memt = pa->pa_memt;
rdev->dmat = pa->pa_dmat;
-#ifdef __sparc64__
+#if defined(__sparc64__) || defined(__macppc__)
if (fbnode == PCITAG_NODE(rdev->pa_tag))
rdev->console = 1;
-#elif NVGAFB_PCI > 0
- extern pcitag_t vgafb_pci_console_tag;
- if (!bcmp(&rdev->pa_tag, &vgafb_pci_console_tag, sizeof(rdev->pa_tag)))
- rdev->console = 1;
#else
if (PCI_CLASS(pa->pa_class) == PCI_CLASS_DISPLAY &&
PCI_SUBCLASS(pa->pa_class) == PCI_SUBCLASS_DISPLAY_VGA &&