diff --git a/srpt/src/ib_srpt.c b/srpt/src/ib_srpt.c index 0b81a7267..014e28d00 100644 --- a/srpt/src/ib_srpt.c +++ b/srpt/src/ib_srpt.c @@ -341,6 +341,7 @@ static void srpt_event_handler(struct ib_event_handler *handler, case IB_EVENT_PKEY_CHANGE: case IB_EVENT_SM_CHANGE: case IB_EVENT_CLIENT_REREGISTER: + case IB_EVENT_GID_CHANGE: /* Refresh port data asynchronously. */ port_num = event->element.port_num - 1; if (port_num < sdev->device->phys_port_cnt) { diff --git a/srpt/src/ib_srpt.h b/srpt/src/ib_srpt.h index 5e635c2ff..ddaa80f62 100644 --- a/srpt/src/ib_srpt.h +++ b/srpt/src/ib_srpt.h @@ -132,6 +132,13 @@ enum { RDMA_COMPL_TIMEOUT_S = 80, }; +#if LINUX_VERSION_CODE < KERNEL_VERSION(3, 1, 0) && \ + !(defined(CONFIG_SUSE_KERNEL) && \ + LINUX_VERSION_CODE >= KERNEL_VERSION(3, 0, 76)) +/* See also patch "IB/core: Add GID change event" (commit 761d90ed4). */ +enum { IB_EVENT_GID_CHANGE = 18 }; +#endif + enum srpt_opcode { SRPT_RECV, SRPT_SEND,