X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=blobdiff_plain;f=lustre%2Fautoconf%2Flustre-core.m4;h=40c6a0f9412d51c085a445a3ed96dced55fce7d1;hp=15c8a9935ed69d09890e9dd05db9e2ad51c88880;hb=49b74e8ab7c0bf76a4ff5b0b2cce15314b1ca8f8;hpb=97941a4de15d8b2939a7b8c8460dbe39e4dff0d8 diff --git a/lustre/autoconf/lustre-core.m4 b/lustre/autoconf/lustre-core.m4 index 15c8a99..40c6a0f 100644 --- a/lustre/autoconf/lustre-core.m4 +++ b/lustre/autoconf/lustre-core.m4 @@ -1901,6 +1901,15 @@ AC_DEFUN([LC_EXPORT_ADD_TO_PAGE_CACHE_LRU], # 2.6.31 +# 2.6.30 x86 node_to_cpumask has been removed. must use cpumask_of_node +AC_DEFUN([LC_EXPORT_CPUMASK_OF_NODE], + [LB_CHECK_SYMBOL_EXPORT([node_to_cpumask_map], + [arch/$LINUX_ARCH/mm/numa.c], + [AC_DEFINE(HAVE_CPUMASK_OF_NODE, 1, + [node_to_cpumask_map is exported by + the kernel])]) # x86_64 + ]) + # 2.6.31 replaces blk_queue_hardsect_size by blk_queue_logical_block_size function AC_DEFUN([LC_BLK_QUEUE_LOG_BLK_SIZE], [AC_MSG_CHECKING([if blk_queue_logical_block_size is defined]) @@ -2037,6 +2046,19 @@ EXTRA_KCFLAGS="-I$LINUX/fs" EXTRA_KCFLAGS=$tmp_flags ]) +# 2.6.32 set_cpus_allowed is no more defined if CONFIG_CPUMASK_OFFSTACK=yes +AC_DEFUN([LC_SET_CPUS_ALLOWED], + [AC_MSG_CHECKING([if kernel defines set_cpus_allowed]) + LB_LINUX_TRY_COMPILE( + [#include ], + [struct task_struct *p = NULL; + cpumask_t mask = { { 0 } }; + (void) set_cpus_allowed(p, mask);], + [AC_MSG_RESULT([yes]) + AC_DEFINE(HAVE_SET_CPUS_ALLOWED, 1, + [set_cpus_allowed is exported by the kernel])], + [AC_MSG_RESULT([no])] )]) + # # LC_D_OBTAIN_ALIAS # starting from 2.6.28 kernel replaces d_alloc_anon() with @@ -2058,6 +2080,18 @@ LB_LINUX_TRY_COMPILE([ ]) # +# 2.6.38 export blkdev_get_by_dev +# +AC_DEFUN([LC_BLKDEV_GET_BY_DEV], +[LB_CHECK_SYMBOL_EXPORT([blkdev_get_by_dev], +[fs/block_dev.c],[ +AC_DEFINE(HAVE_BLKDEV_GET_BY_DEV, 1, + [blkdev_get_by_dev is exported by the kernel]) +],[ +]) +]) + +# # 2.6.39 remove unplug_fn from request_queue. # AC_DEFUN([LC_REQUEST_QUEUE_UNPLUG_FN], @@ -2069,7 +2103,7 @@ LB_LINUX_TRY_COMPILE([ memset(rq.unplug_fn, 0, sizeof(rq.unplug_fn)); ],[ AC_DEFINE(HAVE_REQUEST_QUEUE_UNPLUG_FN, 1, - [request_queue has unplug_fn field]), + [request_queue has unplug_fn field]), AC_MSG_RESULT([yes]) ],[ AC_MSG_RESULT([no]) @@ -2217,6 +2251,9 @@ AC_DEFUN([LC_PROG_LINUX], LC_SB_HAS_QUOTA_ACTIVE LC_EXPORT_ADD_TO_PAGE_CACHE_LRU + # 2.6.30 + LC_EXPORT_CPUMASK_OF_NODE + # 2.6.31 LC_BLK_QUEUE_LOG_BLK_SIZE @@ -2226,6 +2263,10 @@ AC_DEFUN([LC_PROG_LINUX], LC_SB_BDI LC_BLK_QUEUE_MAX_SECTORS LC_BLK_QUEUE_MAX_SEGMENTS + LC_SET_CPUS_ALLOWED + + # 2.6.38 + LC_BLKDEV_GET_BY_DEV # 2.6.39 LC_REQUEST_QUEUE_UNPLUG_FN