aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Morgenstein <jackm@mellanox.co.il>2006-05-08 16:15:05 +0000
committerRoland Dreier <rolandd@cisco.com>2006-11-09 19:57:06 -0800
commit57dda5d21b527c45d069724b02834c16a8abee04 (patch)
treefa44e37cc30d96e36adc92aa9361a59d99b68411
parentbb2033af5ebe1026175a323d1777ae4a957f27ed (diff)
downloadlibmthca-57dda5d21b527c45d069724b02834c16a8abee04.tar.gz
Fix build against new (1.1 series) libibverbs
Add include files needed in the case where libibverbs does not implement the function ibv_read_sysfs_file(). Signed-off-by: Jack Morgenstein <jackm@mellanox.co.il> Signed-off-by: Roland Dreier <rolandd@cisco.com>
-rw-r--r--ChangeLog6
-rw-r--r--src/mthca.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index fcdd775..95baaaa 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-05-08 Jack Morgenstein <jackm@mellanox.co.il>
+
+ * src/mthca.c: Add include files needed for open() if
+ HAVE_IBV_READ_SYSFS_FILE is not defined (so libmthca includes a
+ private local definition of ibv_read_sysfs_file()).
+
2006-04-11 Roland Dreier <rdreier@cisco.com>
* src/mthca.c (ibv_driver_init, openib_driver_init): Add new
diff --git a/src/mthca.c b/src/mthca.c
index 5bbc981..7c9da18 100644
--- a/src/mthca.c
+++ b/src/mthca.c
@@ -44,6 +44,12 @@
#include <sys/mman.h>
#include <pthread.h>
+#ifndef HAVE_IBV_READ_SYSFS_FILE
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#endif
+
#include "mthca.h"
#include "mthca-abi.h"