[PATCH V2 1/1] [PATCH 1/1] Ibacm: default pkey for partitioned fabrics

2015-12-10 Thread kaike . wan
From: Kaike Wan <kaike@intel.com> In an insecure IB fabric, the default pkey in a port is 0x, where each node is allowed to talk to any other node in the fabric, including the SA node. However, in a secure fabric, to limit member access, not all nodes can have the full-member defaul

[PATCH 1/1] Ibacm: default pkey for partitioned fabrics

2015-12-08 Thread kaike . wan
From: Kaike Wan <kaike@intel.com> In an insecure IB fabric, the default pkey in a port is 0x, where each node is allowed to talk to any other node in the fabric, including the SA node. However, in a secure fabric, to limit member access, not all nodes can have the full-member defaul

[PATCH v2 1/1] IB/sa: Put netlink request into the request list before sending

2015-10-30 Thread kaike . wan
From: Kaike Wan <kaike@intel.com> It was found by Saurabh Sengar that the netlink code tried to allocate memory with GFP_KERNEL while holding a spinlock. While it is possible to fix the issue by replacing GFP_KERNEL with GFP_ATOMIC, it is better to get rid of the spinlock while s

[PATCH 1/1] IB/sa: Put netlink request into the request list before sending

2015-10-28 Thread kaike . wan
From: Kaike Wan <kaike@intel.com> It was found by Saurabh Sengar that the netlink code tried to allocate memory with GFP_KERNEL while holding a spinlock. While it is possible to fix the issue by replacing GFP_KERNEL with GFP_ATOMIC, it is better to get rid of the spinlock while s

[PATCH v9 1/1] ibacm: Add support for pathrecord query through netlink

2015-08-14 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v9 0/4] Sending kernel pathrecord query to user cache server

2015-08-14 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v9 2/4] IB/core: Add rdma netlink helper functions

2015-08-14 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. It also adds a function to receive netlink response messages. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off

[PATCH v9 1/4] IB/netlink: Add defines for local service requests through netlink

2015-08-14 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for local service client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we

[PATCH v8 1/4] IB/netlink: Add defines for local service requests through netlink

2015-07-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for local service client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we

[PATCH v8 2/4] IB/core: Add rdma netlink helper functions

2015-07-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. It also adds a function to receive netlink response messages. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off

[PATCH v3 3/4] IB/sa: Allocate SA query with kzalloc

2015-07-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v8 4/4] IB/sa: Route SA pathrecord query through netlink

2015-07-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v8 1/1] ibacm: Add support for pathrecord query through netlink

2015-07-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v7 4/4] IB/sa: Route SA pathrecord query through netlink

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v7 0/4] Sending kernel pathrecord query to user cache server

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v7 3/4] IB/sa: Allocate SA query with kzalloc

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v7 1/1] ibacm: Add support for pathrecord query through netlink

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v7 2/4] IB/core: Check the presence of netlink multicast group listeners

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com Reviewed-by: Sean Hefty sean.he

[PATCH v7 1/4] IB/netlink: Add defines for local service requests through netlink

2015-06-30 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for SA client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com

[PATCH v6 4/4] IB/sa: Route SA pathrecord query through netlink

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v6 1/1] ibacm: Add support for pathrecord query through netlink

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v6 2/4] IB/core: Check the presence of netlink multicast group listeners

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com Reviewed-by: Sean Hefty sean.he

[PATCH v6 1/4] IB/netlink: Add defines for local service requests through netlink

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for SA client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com

[PATCH v6 0/4] Sending kernel pathrecord query to user cache server

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v6 3/4] IB/sa: Allocate SA query with kzalloc

2015-06-12 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v5 1/4] IB/netlink: Add defines for local service requests through netlink

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for SA client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com

[PATCH v5 2/4] IB/core: Check the presence of netlink multicast group listeners

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com Reviewed-by: Sean Hefty sean.he

[PATCH v5 3/4] IB/sa: Allocate SA query with kzalloc

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v5 0/4] Sending kernel pathrecord query to user cache server

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v5 4/4] IB/sa: Route SA pathrecord query through netlink

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v5 1/1] ibacm: Add support for pathrecord query through netlink

2015-06-11 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v4 0/4] Sending kernel pathrecord query to user cache server

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v4 2/4] IB/core: Check the presence of netlink multicast group listeners

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds a function to check if listeners for a netlink multicast group are present. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com Reviewed-by: Sean Hefty sean.he

[PATCH v4 3/4] IB/sa: Allocate SA query with kzalloc

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v4 1/4] IB/netlink: Add defines for local service requests through netlink

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch adds netlink defines for SA client, local service group, local service operations, and related attributes. Signed-off-by: Kaike Wan kaike@intel.com Signed-off-by: John Fleck john.fl...@intel.com Signed-off-by: Ira Weiny ira.we...@intel.com

[PATCH v4 4/4] IB/sa: Route SA pathrecord query through netlink

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v4 1/1] ibacm: Add support for pathrecord query through netlink

2015-06-09 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v3 1/1] ibacm: Add support for pathrecord query through netlink

2015-06-04 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch enables ibacm to process pathrecord queries through netlink. Since ibacm can cache pathrecords, this implementation provides an easy pathrecord cache for kernel components and therefore offers great performance advantage on large fabric systems

[PATCH v3 0/4] Sending kernel pathrecord query to user cache server

2015-06-04 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH v3 4/4] IB/sa: Route SA pathrecord query through netlink

2015-06-04 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch routes a SA pathrecord query to netlink first and processes the response appropriately. If a failure is returned, the request will be sent through IB. The decision whether to route the request to netlink first is determined by the presence

[PATCH v3 3/4] IB/sa: Allocate SA query with kzalloc

2015-06-04 Thread kaike . wan
From: Kaike Wan kaike@intel.com Replace kmalloc with kzalloc so that all uninitialized fields in SA query will be zero-ed out to avoid unintentional consequence. This prepares the SA query structure to accept new fields in the future. Signed-off-by: Kaike Wan kaike@intel.com Signed-off

[PATCH v2 0/4] Sending kernel pathrecord query to user cache server

2015-05-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com A SA cache is undeniably critical for fabric scalability and performance. In user space, the ibacm application provides a good example of pathrecord cache for address and route resolution. With the recent implementation of the provider architecture, ibacm

[PATCH 1/1] ibacm: Use pkey 0xffff or 0x7fff for SA query

2015-03-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com Currently, ibacm uses the first pkey on the local port to query SA. More appropriately, it should use either 0x or 0x7fff for SA query. However, if the local port is not configured with either pkey, ibacm will continue to use the first pkey. Signed-off

[PATCH 1/1] ibacm: open only prov endpoints with name/addr configured

2015-01-07 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch modifies the ibacm core so that it will request the provider to open those endpoints that have been assigned with at least one name or address. This change will avoid unnecessary endpoint open and close for those without any name/address configured

[PATCH 1/1] ibacm: incorrect ifc_len is specified in SIOCGIFCONF request

2014-12-03 Thread kaike . wan
From: Kaike Wan kaike@intel.com The ifc-ifs_len in the ioctl SIOCGIFCONF request should only specify the associated ifreq buffer length and not include the ifc header length. This bug was found by running ibacm with Valgrind: ==8201== Syscall param ioctl(SIOCGIFCONF).ifc_buf points

[PATCH 0/3] Ibacm/ibacmp bug fixes

2014-11-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch series fixes a print format error and two bugs related to SM restart. Kaike Wan (3): ibacmp: missing '%' in acm_log format ibacm: close the provider endpoint when it fails to assign a name to a core endpoint ibacm/ibacmp: fix a crash when

[PATCH 2/3] ibacm: close the provider endpoint when it fails to assign a name to a core endpoint

2014-11-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com In function acm_ep_up(), when it fails to assign any name to an endpoint, the endpoint in the provider is not properly closed before the core endpoint is freed. This may cause segfault when ibacmp tries to join multicast group with a stale core endpoint

[PATCH 3/3] ibacm/ibacmp: fix a crash when SM restarts

2014-11-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com Ibacm may cause segfault when the SM restarts: when the SM restarts, ibacm will receive P_Key change event and instruct ibacmp to close all endpoints. However, ibacmp only resets the core endpoint pointer in its ep structure and keeps the ep in the port's

[PATCH 1/3] ibacmp: missing '%' in acm_log format

2014-11-19 Thread kaike . wan
From: Kaike Wan kaike@intel.com This debugging print is in function acmp_get_ep(). Signed-off-by: Kaike Wan kaike@intel.com --- prov/acmp/src/acmp.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/prov/acmp/src/acmp.c b/prov/acmp/src/acmp.c index 2dd356d

[PATCH 1/1] ibacm: define prov_lib_path as a char array

2014-07-02 Thread kaike . wan
From: Kaike Wan kaike@intel.com This patch fixes a segfault error when the option file defines the provider lib path. The variable prov_lib_path should be a buffer (char array) instead of a char pointer. This allows a string to be copied into it during option parsing. Signed-off-by: Kaike

[PATCH 1/2] ibacm/prov: export a function to return config file name

2014-06-20 Thread kaike . wan
From: Kaike Wan kaike@intel.com Instead of exposing the ibacm configuration file name directly, this patch exports a function to return the configuration file name. This provides better encapsulation. Signed-off-by: Kaike Wan kaike@intel.com --- include/infiniband/acm_prov.h |3

[PATCH 2/2] ibacm/prov: export a function to increment performance counters

2014-06-20 Thread kaike . wan
From: Kaike Wan kaike@intel.com Instead of exposing the combined counters directly, this patch exports a function to providers to increment the combined counters. This offers better encapsulation and avoids exposing the private type atomic_t. Signed-off-by: Kaike Wan kaike@intel.com