IB/qib: Add optional NUMA affinity
[deliverable/linux.git] / drivers / infiniband / hw / qib / qib_file_ops.c
index b56c9428f3c5f5fbf574b0b9570ec2caa02cbee3..65b2fc3f957c8b50b3ba4a3991be669bae60813b 100644 (file)
@@ -1263,8 +1263,12 @@ static int setup_ctxt(struct qib_pportdata *ppd, int ctxt,
        struct qib_ctxtdata *rcd;
        void *ptmp = NULL;
        int ret;
+       int numa_id;
 
-       rcd = qib_create_ctxtdata(ppd, ctxt);
+       numa_id = qib_numa_aware ? numa_node_id() :
+               dd->assigned_node_id;
+
+       rcd = qib_create_ctxtdata(ppd, ctxt, numa_id);
 
        /*
         * Allocate memory for use in qib_tid_update() at open to
This page took 0.027366 seconds and 5 git commands to generate.