Methods sometimes need to get a flexible set of IDRs and not a strict set as can be achieved today by the conventional IDR attribute. Add a new IDRS_ARRAY attribute to the generic uverbs ioctl layer. IDRS_ARRAY points to array of idrs of the same object type and same access rights, only write and read are supported.
Showing the changes to include/uapi (1 of 4 files). Show all
Unified · Split
| @@ -53,7 +53,7 @@ enum { · 52 unmodified lines | ||
| 53 | 53 | |
| 54 | 54 | struct ib_uverbs_attr { |
| 55 | 55 | __u16 attr_id; /* command specific type attribute */ |
| 56 | − __u16 len; /* only for pointers */ | |
| 56 | + __u16 len; /* only for pointers and IDRs array */ | |
| 57 | 57 | __u16 flags; /* combination of UVERBS_ATTR_F_XXXX */ |
| 58 | 58 | union { |
| 59 | 59 | struct { |
| @@ -63,7 +63,10 @@ struct ib_uverbs_attr { · 3 unmodified lines | ||
| 63 | 63 | __u16 reserved; |
| 64 | 64 | } attr_data; |
| 65 | 65 | union { |
| 66 | − /* Used by PTR_IN/OUT, ENUM_IN and IDR */ | |
| 66 | + /* | |
| 67 | + * ptr to command, inline data, idr/fd or | |
| 68 | + * ptr to __u32 array of IDRs | |
| 69 | + */ | |
| 67 | 70 | __aligned_u64 data; |
| 68 | 71 | /* Used by FD_IN and FD_OUT */ |
| 69 | 72 | __s64 data_s64; |