Index: hw/mthca/kernel/hca_verbs.c
===================================================================
--- hw/mthca/kernel/hca_verbs.c	(revision 1047)
+++ hw/mthca/kernel/hca_verbs.c	(working copy)
@@ -43,7 +43,6 @@
 #include "mx_abi.h"
 #include "mt_pa_cash.h"
 
-#define PTR_ALIGN(size)	(((size) + sizeof(void*) - 1) & ~(sizeof(void*) - 1))
 
 
 // Local declarations
Index: inc/mthca/mthca_vc.h
===================================================================
--- inc/mthca/mthca_vc.h	(revision 1047)
+++ inc/mthca/mthca_vc.h	(working copy)
@@ -33,6 +33,8 @@
 #ifndef MTHCA_VC_H
 #define MTHCA_VC_H
 
+#define PTR_ALIGN(size)	(((size) + sizeof(void*) - 1) & ~(sizeof(void*) - 1))
+
 typedef
 struct _map_crspace {
 	unsigned __int64	va;		/* address of CRSPACE, mapped to user space */
@@ -78,12 +80,12 @@
 
 inline char* mthca_get_board_id(ib_ca_attr_t *ca_attr)
 {
-    return (char*)(ca_attr)+(ca_attr->size - MTHCA_BRD_ID_LEN - sizeof(uplink_info_t));
+	return (char*)(ca_attr) + (ca_attr->size - PTR_ALIGN(MTHCA_BRD_ID_LEN) - PTR_ALIGN(sizeof(uplink_info_t)));
 }
 
 inline void* mthca_get_uplink_info(ib_ca_attr_t *ca_attr)
 {
-    return (char*)(ca_attr)+(ca_attr->size - sizeof(uplink_info_t));
+	return (char*)(ca_attr) + (ca_attr->size - PTR_ALIGN(sizeof(uplink_info_t)));
 }
 
 #endif
