Lines Matching full:cap
30 struct vfio_device_info_cap_zpci_base cap = { in zpci_base_cap() local
42 return vfio_info_add_capability(caps, &cap.header, sizeof(cap)); in zpci_base_cap()
51 struct vfio_device_info_cap_zpci_group cap = { in zpci_group_cap() local
63 return vfio_info_add_capability(caps, &cap.header, sizeof(cap)); in zpci_group_cap()
72 struct vfio_device_info_cap_zpci_util *cap; in zpci_util_cap() local
73 int cap_size = sizeof(*cap) + CLP_UTIL_STR_LEN; in zpci_util_cap()
76 cap = kmalloc(cap_size, GFP_KERNEL); in zpci_util_cap()
78 cap->header.id = VFIO_DEVICE_INFO_CAP_ZPCI_UTIL; in zpci_util_cap()
79 cap->header.version = 1; in zpci_util_cap()
80 cap->size = CLP_UTIL_STR_LEN; in zpci_util_cap()
81 memcpy(cap->util_str, zdev->util_str, cap->size); in zpci_util_cap()
83 ret = vfio_info_add_capability(caps, &cap->header, cap_size); in zpci_util_cap()
85 kfree(cap); in zpci_util_cap()
96 struct vfio_device_info_cap_zpci_pfip *cap; in zpci_pfip_cap() local
97 int cap_size = sizeof(*cap) + CLP_PFIP_NR_SEGMENTS; in zpci_pfip_cap()
100 cap = kmalloc(cap_size, GFP_KERNEL); in zpci_pfip_cap()
102 cap->header.id = VFIO_DEVICE_INFO_CAP_ZPCI_PFIP; in zpci_pfip_cap()
103 cap->header.version = 1; in zpci_pfip_cap()
104 cap->size = CLP_PFIP_NR_SEGMENTS; in zpci_pfip_cap()
105 memcpy(cap->pfip, zdev->pfip, cap->size); in zpci_pfip_cap()
107 ret = vfio_info_add_capability(caps, &cap->header, cap_size); in zpci_pfip_cap()
109 kfree(cap); in zpci_pfip_cap()