PERFORCE change 42612 for review

Peter Wemm peter at FreeBSD.org
Sun Nov 16 19:06:54 PST 2003


http://perforce.freebsd.org/chv.cgi?CH=42612

Change 42612 by peter at peter_freefall on 2003/11/16 19:06:45

	make alpha compile

Affected files ...

.. //depot/projects/hammer/sys/alpha/alpha/interrupt.c#7 edit
.. //depot/projects/hammer/sys/alpha/include/intr.h#3 edit
.. //depot/projects/hammer/sys/alpha/isa/isa.c#6 edit
.. //depot/projects/hammer/sys/alpha/pci/t2.c#5 edit

Differences ...

==== //depot/projects/hammer/sys/alpha/alpha/interrupt.c#7 (text+ko) ====

@@ -321,13 +321,13 @@
 	return (mc_received);
 }
 
-#define HASHVEC(vector)	((vector) % 31)
+#define HASHVEC(vector)	(((uintptr_t)(vector)) % 31)
 
 LIST_HEAD(alpha_intr_list, alpha_intr);
 
 struct alpha_intr {
     LIST_ENTRY(alpha_intr) list; /* chain handlers in this hash bucket */
-    int			vector;	/* vector to match */
+    void		*vector;	/* vector to match */
     struct ithd		*ithd;  /* interrupt thread */
     volatile long	*cntp;  /* interrupt counter */
 };
@@ -346,7 +346,7 @@
 SYSINIT(ithds_init, SI_SUB_INTR, SI_ORDER_SECOND, ithds_init, NULL);
 
 int
-alpha_setup_intr(const char *name, int vector, driver_intr_t handler, void *arg,
+alpha_setup_intr(const char *name, void *vector, driver_intr_t handler, void *arg,
 		 enum intr_type flags, void **cookiep, volatile long *cntp,
     		 void (*disable)(void *), void (*enable)(void *))
 {
@@ -411,7 +411,8 @@
 	 * Walk the hash bucket for this vector looking for this vector's
 	 * interrupt thread.
 	 */
-	for (i = LIST_FIRST(&alpha_intr_hash[h]); i && i->vector != vector;
+	for (i = LIST_FIRST(&alpha_intr_hash[h]);
+	    i && i->vector != (void *)(uintptr_t)vector;
 	    i = LIST_NEXT(i, list))
 		;	/* nothing */
 	if (i == NULL)

==== //depot/projects/hammer/sys/alpha/include/intr.h#3 (text+ko) ====

@@ -31,7 +31,7 @@
 
 extern struct mtx icu_lock;
 
-int	alpha_setup_intr(const char *name, int vector, driver_intr_t handler,
+int	alpha_setup_intr(const char *name, void *vector, driver_intr_t handler,
 	    void *arg, enum intr_type flags, void **cookiep,
 	    volatile long *cntp, void (*disable)(void *), void (*enable)(void *));
 int	alpha_teardown_intr(void *cookie);

==== //depot/projects/hammer/sys/alpha/isa/isa.c#6 (text+ko) ====

@@ -329,7 +329,7 @@
 isa_enable_intr(void *cookie)
 {
 	int vector = (uintptr_t)cookie;
-	int irq
+	int irq;
 
 	irq = (vector - 0x800) >> 4;
 	mtx_lock_spin(&icu_lock);

==== //depot/projects/hammer/sys/alpha/pci/t2.c#5 (text+ko) ====

@@ -572,7 +572,7 @@
 		return error;
 
 	/* Enable interrupt */
-	t2_enable_vec(vector);
+	t2_enable_vec((void *)(uintptr_t)vector);
 	
 	if (bootverbose != 0) 
 		device_printf(child, 


More information about the p4-projects mailing list