Lines Matching refs:buf
23 char *buf) in caia_version_show() argument
27 return scnprintf(buf, PAGE_SIZE, "%i.%i\n", adapter->caia_major, in caia_version_show()
33 char *buf) in psl_revision_show() argument
37 return scnprintf(buf, PAGE_SIZE, "%i\n", adapter->psl_rev); in psl_revision_show()
42 char *buf) in base_image_show() argument
46 return scnprintf(buf, PAGE_SIZE, "%i\n", adapter->base_image); in base_image_show()
51 char *buf) in image_loaded_show() argument
56 return scnprintf(buf, PAGE_SIZE, "user\n"); in image_loaded_show()
57 return scnprintf(buf, PAGE_SIZE, "factory\n"); in image_loaded_show()
62 const char *buf, size_t count) in reset_adapter_store() argument
68 rc = sscanf(buf, "%i", &val); in reset_adapter_store()
79 char *buf) in load_image_on_perst_show() argument
84 return scnprintf(buf, PAGE_SIZE, "none\n"); in load_image_on_perst_show()
87 return scnprintf(buf, PAGE_SIZE, "user\n"); in load_image_on_perst_show()
88 return scnprintf(buf, PAGE_SIZE, "factory\n"); in load_image_on_perst_show()
93 const char *buf, size_t count) in load_image_on_perst_store() argument
98 if (!strncmp(buf, "none", 4)) in load_image_on_perst_store()
100 else if (!strncmp(buf, "user", 4)) { in load_image_on_perst_store()
103 } else if (!strncmp(buf, "factory", 7)) { in load_image_on_perst_store()
117 char *buf) in perst_reloads_same_image_show() argument
121 return scnprintf(buf, PAGE_SIZE, "%i\n", adapter->perst_same_image); in perst_reloads_same_image_show()
126 const char *buf, size_t count) in perst_reloads_same_image_store() argument
132 rc = sscanf(buf, "%i", &val); in perst_reloads_same_image_store()
155 char *buf) in mmio_size_show_master() argument
159 return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->adapter->ps_size); in mmio_size_show_master()
164 char *buf) in pp_mmio_off_show() argument
168 return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->pp_offset); in pp_mmio_off_show()
173 char *buf) in pp_mmio_len_show() argument
177 return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->pp_size); in pp_mmio_len_show()
191 char *buf) in mmio_size_show() argument
196 return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->pp_size); in mmio_size_show()
197 return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->adapter->ps_size); in mmio_size_show()
202 const char *buf, size_t count) in reset_store_afu() argument
225 char *buf) in irqs_min_show() argument
229 return scnprintf(buf, PAGE_SIZE, "%i\n", afu->pp_irqs); in irqs_min_show()
234 char *buf) in irqs_max_show() argument
238 return scnprintf(buf, PAGE_SIZE, "%i\n", afu->irqs_max); in irqs_max_show()
243 const char *buf, size_t count) in irqs_max_store() argument
249 ret = sscanf(buf, "%i", &irqs_max); in irqs_max_store()
264 struct device_attribute *attr, char *buf) in modes_supported_show() argument
267 char *p = buf, *end = buf + PAGE_SIZE; in modes_supported_show()
273 return (p - buf); in modes_supported_show()
278 char *buf) in prefault_mode_show() argument
284 return scnprintf(buf, PAGE_SIZE, "work_element_descriptor\n"); in prefault_mode_show()
286 return scnprintf(buf, PAGE_SIZE, "all\n"); in prefault_mode_show()
288 return scnprintf(buf, PAGE_SIZE, "none\n"); in prefault_mode_show()
294 const char *buf, size_t count) in prefault_mode_store() argument
299 if (!strncmp(buf, "work_element_descriptor", 23)) in prefault_mode_store()
301 if (!strncmp(buf, "all", 3)) in prefault_mode_store()
303 if (!strncmp(buf, "none", 4)) in prefault_mode_store()
315 char *buf) in mode_show() argument
320 return scnprintf(buf, PAGE_SIZE, "dedicated_process\n"); in mode_show()
322 return scnprintf(buf, PAGE_SIZE, "afu_directed\n"); in mode_show()
323 return scnprintf(buf, PAGE_SIZE, "none\n"); in mode_show()
327 const char *buf, size_t count) in mode_store() argument
338 if (!strncmp(buf, "dedicated_process", 17)) in mode_store()
340 if (!strncmp(buf, "afu_directed", 12)) in mode_store()
342 if (!strncmp(buf, "none", 4)) in mode_store()
373 char *buf) in api_version_show() argument
375 return scnprintf(buf, PAGE_SIZE, "%i\n", CXL_API_VERSION); in api_version_show()
380 char *buf) in api_version_compatible_show() argument
382 return scnprintf(buf, PAGE_SIZE, "%i\n", CXL_API_VERSION_COMPATIBLE); in api_version_compatible_show()
386 struct bin_attribute *bin_attr, char *buf, in afu_eb_read() argument
392 return cxl_afu_read_err_buffer(afu, buf, off, count); in afu_eb_read()
442 struct kobj_attribute *attr, char *buf) in vendor_show() argument
446 return scnprintf(buf, PAGE_SIZE, "0x%.4x\n", cr->vendor); in vendor_show()
450 struct kobj_attribute *attr, char *buf) in device_show() argument
454 return scnprintf(buf, PAGE_SIZE, "0x%.4x\n", cr->device); in device_show()
458 struct kobj_attribute *attr, char *buf) in class_show() argument
462 return scnprintf(buf, PAGE_SIZE, "0x%.6x\n", cr->class); in class_show()
466 struct bin_attribute *bin_attr, char *buf, in afu_read_config() argument
477 buf[i] = (val >> (j * 8)) & 0xff; in afu_read_config()