Re: [PATCH rdma-next v3 01/11] RDMA: Add EFA related definitions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 14-Mar-19 16:35, Leon Romanovsky wrote:
> On Thu, Mar 14, 2019 at 01:45:12PM +0200, Gal Pressman wrote:
>> Add EFA driver ID to the IOCTL interface uapi.
>> This patch also adds unspecified node/transport type that will be used
>> by EFA (usnic is left unchanged as it's already part of our ABI).
>>
>> Signed-off-by: Gal Pressman <galpress@xxxxxxxxxx>
>> Reviewed-by: Shiraz Saleem <shiraz.saleem@xxxxxxxxx>
>> Reviewed-by: Steve Wise <swise@xxxxxxxxxxxxxxxxxxxxx>
>> ---
>>  drivers/infiniband/core/sysfs.c          | 1 +
>>  drivers/infiniband/core/verbs.c          | 2 ++
>>  include/rdma/ib_verbs.h                  | 4 +++-
>>  include/uapi/rdma/rdma_user_ioctl_cmds.h | 1 +
>>  4 files changed, 7 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/infiniband/core/sysfs.c b/drivers/infiniband/core/sysfs.c
>> index 9b6a065bdfa5..bc3f67ce5934 100644
>> --- a/drivers/infiniband/core/sysfs.c
>> +++ b/drivers/infiniband/core/sysfs.c
>> @@ -1194,6 +1194,7 @@ static ssize_t node_type_show(struct device *device,
>>  	case RDMA_NODE_RNIC:	  return sprintf(buf, "%d: RNIC\n", dev->node_type);
>>  	case RDMA_NODE_USNIC:	  return sprintf(buf, "%d: usNIC\n", dev->node_type);
>>  	case RDMA_NODE_USNIC_UDP: return sprintf(buf, "%d: usNIC UDP\n", dev->node_type);
>> +	case RDMA_NODE_UNSPECIFIED: return sprintf(buf, "%d: unspecified\n", dev->node_type);
>>  	case RDMA_NODE_IB_SWITCH: return sprintf(buf, "%d: switch\n", dev->node_type);
>>  	case RDMA_NODE_IB_ROUTER: return sprintf(buf, "%d: router\n", dev->node_type);
>>  	default:		  return sprintf(buf, "%d: <unknown>\n", dev->node_type);
>> diff --git a/drivers/infiniband/core/verbs.c b/drivers/infiniband/core/verbs.c
>> index 5a5e83f5f0fc..b3fb8abf6950 100644
>> --- a/drivers/infiniband/core/verbs.c
>> +++ b/drivers/infiniband/core/verbs.c
>> @@ -218,6 +218,8 @@ rdma_node_get_transport(enum rdma_node_type node_type)
>>  		return RDMA_TRANSPORT_USNIC_UDP;
>>  	if (node_type == RDMA_NODE_RNIC)
>>  		return RDMA_TRANSPORT_IWARP;
>> +	if (node_type == RDMA_NODE_UNSPECIFIED)
>> +		return RDMA_TRANSPORT_UNSPECIFIED;
>>
>>  	return RDMA_TRANSPORT_IB;
>>  }
>> diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
>> index 9b9e17bcc201..b5be093c5474 100644
>> --- a/include/rdma/ib_verbs.h
>> +++ b/include/rdma/ib_verbs.h
>> @@ -108,6 +108,7 @@ enum rdma_node_type {
>>  	RDMA_NODE_RNIC,
>>  	RDMA_NODE_USNIC,
>>  	RDMA_NODE_USNIC_UDP,
>> +	RDMA_NODE_UNSPECIFIED,
>>  };
>>
>>  enum {
>> @@ -119,7 +120,8 @@ enum rdma_transport_type {
>>  	RDMA_TRANSPORT_IB,
>>  	RDMA_TRANSPORT_IWARP,
>>  	RDMA_TRANSPORT_USNIC,
>> -	RDMA_TRANSPORT_USNIC_UDP
>> +	RDMA_TRANSPORT_USNIC_UDP,
>> +	RDMA_TRANSPORT_UNSPECIFIED,
> 
> Please prepare rdmatool patch too.

Will do.



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux