Port-xen archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Intel X11 driver doesn't load on zen current



On 23 November 2014 at 00:01, Andrew Cagney <andrew.cagney%gmail.com@localhost> wrote:
> On 21 November 2014 at 23:21, Cherry G. Mathew
> <cherry.g.mathew%gmail.com@localhost> wrote:
>>
>> i915drmkms isn't available in the dom0 kernel yet, afaict.
>
> Yes, I figured that out last night.  The immediate problem is that the
> code assumes that:
>
>         pci_intr_handle_t ih_pih;
>         int ih_int;
>
> are the same type, where as for XEN that isn't so:
>
> struct xen_intr_handle {
>         int pirq; /* also contains the  APIC_INT_* flags if NIOAPIC > 0 */
>         int evtch;
> };

There's a few more problems ... I have some preliminary patches if you
want to play with them:

-- 
~Cherry
diff -r 36574bc96b55 sys/arch/amd64/conf/XEN3_DOM0
--- a/sys/arch/amd64/conf/XEN3_DOM0	Thu Nov 20 15:32:01 2014 +0530
+++ b/sys/arch/amd64/conf/XEN3_DOM0	Sun Nov 23 07:31:21 2014 +0530
@@ -537,6 +537,7 @@
 options 	PMS_SYNAPTICS_TOUCHPAD	# Enable support for Synaptics Touchpads
 #vga0		at isa?
 vga*		at pci? dev ? function ?
+genfb*		at pci? dev ? function ?
 #pcdisplay0	at isa?			# CGA, MDA, EGA, HGA
 #machfb* 	at pci? dev ? function ? # ATI Mach64 framebuffer driver
 wsdisplay*	at vga? console ?
diff -r 36574bc96b55 sys/arch/amd64/conf/XEN3_DOM0_DRMKMS
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/arch/amd64/conf/XEN3_DOM0_DRMKMS	Sun Nov 23 07:31:21 2014 +0530
@@ -0,0 +1,23 @@
+include "arch/amd64/conf/XEN3_DOM0"
+
+i915drmkms* 	at pci? dev ? function ?
+intelfb*	at intelfbbus?
+
+radeon*		at pci? dev ? function ?
+radeondrmkmsfb* at radeonfbbus?
+
+#nouveau*	at pci? dev ? function ?
+#nouveaufb*	at nouveaufbbus
+
+no options 	DIAGNOSTIC
+options 	DIAGNOSTIC	# inexpensive kernel consistency checks
+options 	DEBUG		# expensive debugging checks/support
+options 	LOCKDEBUG	# debug locks
+makeoptions 	DEBUG="-g"	# compile full symbol table
+
+#options 	ACPIVERBOSE	# verbose ACPI device autoconfig messages
+options 	PCIVERBOSE	# verbose PCI device autoconfig messages
+options 	USBVERBOSE	# verbose USB device autoconfig messages
+
+# XXX: Investigate if we actually need this ?
+#options 	VGA_POST		# in-kernel support for VGA POST
diff -r 36574bc96b55 sys/arch/x86/pci/pci_machdep.c
--- a/sys/arch/x86/pci/pci_machdep.c	Thu Nov 20 15:32:01 2014 +0530
+++ b/sys/arch/x86/pci/pci_machdep.c	Sun Nov 23 07:31:21 2014 +0530
@@ -811,6 +811,7 @@
 	}
 
 # if NACPICA > 0 && defined(VGA_POST)
+	(void) curmode;
 	curmode = newmode;
 # endif
 #endif
diff -r 36574bc96b55 sys/external/bsd/drm2/pci/drm_pci.c
--- a/sys/external/bsd/drm2/pci/drm_pci.c	Thu Nov 20 15:32:01 2014 +0530
+++ b/sys/external/bsd/drm2/pci/drm_pci.c	Sun Nov 23 07:31:21 2014 +0530
@@ -217,6 +217,7 @@
 drm_pci_get_irq(struct drm_device *dev)
 {
 	pci_intr_handle_t ih_pih;
+
 	int ih_int;
 
 	/*
@@ -224,12 +225,19 @@
 	 * this fails, we have to change a bunch of drm code that uses
 	 * int for intr handles.
 	 */
+ #ifndef DOM0OPS
 	KASSERT(&ih_pih != &ih_int);
+#endif  /* DOM0OPS */
 
 	if (pci_intr_map(drm_pci_attach_args(dev), &ih_pih))
 		return -1;	/* XXX Hope -1 is an invalid intr handle.  */
 
+#ifndef DOM0OPS
 	ih_int = ih_pih;
+#else
+	ih_int = ih_pih.pirq;
+#endif  /* DOM0OPS */
+
 	return ih_int;
 }
 


Home | Main Index | Thread Index | Old Index