Lines Matching refs:templen

1910 	u16	templen, count;  in bfa_fcs_lport_fdmi_build_rhba_pyld()  local
1940 templen = sizeof(wwn_t); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1941 memcpy(attr->value, &bfa_fcs_lport_get_nwwn(port), templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1942 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1943 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1945 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
1946 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1953 templen = (u16) strlen(fcs_hba_attr->manufacturer); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1954 memcpy(attr->value, fcs_hba_attr->manufacturer, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1955 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1956 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1957 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1959 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
1960 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1967 templen = (u16) strlen(fcs_hba_attr->serial_num); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1968 memcpy(attr->value, fcs_hba_attr->serial_num, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1969 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1970 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1971 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1973 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
1974 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1981 templen = (u16) strlen(fcs_hba_attr->model); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1982 memcpy(attr->value, fcs_hba_attr->model, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1983 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1984 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1985 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1987 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
1988 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1995 templen = (u16) strlen(fcs_hba_attr->model_desc); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1996 memcpy(attr->value, fcs_hba_attr->model_desc, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1997 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
1998 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
1999 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2001 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2002 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2010 templen = (u16) strlen(fcs_hba_attr->hw_version); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2011 memcpy(attr->value, fcs_hba_attr->hw_version, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2012 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2013 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2014 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2016 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2017 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2025 templen = (u16) strlen(fcs_hba_attr->driver_version); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2026 memcpy(attr->value, fcs_hba_attr->driver_version, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2027 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2028 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2029 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2031 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2032 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2040 templen = (u16) strlen(fcs_hba_attr->option_rom_ver); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2041 memcpy(attr->value, fcs_hba_attr->option_rom_ver, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2042 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2043 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2044 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2046 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2047 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2052 templen = (u16) strlen(fcs_hba_attr->fw_version); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2053 memcpy(attr->value, fcs_hba_attr->fw_version, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2054 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2055 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2056 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2058 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2059 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2067 templen = (u16) strlen(fcs_hba_attr->os_name); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2068 memcpy(attr->value, fcs_hba_attr->os_name, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2069 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2070 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2071 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2073 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2074 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2082 templen = sizeof(fcs_hba_attr->max_ct_pyld); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2083 memcpy(attr->value, &fcs_hba_attr->max_ct_pyld, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2084 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2085 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2086 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2088 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2089 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2096 templen = sizeof(fcs_hba_attr->node_sym_name); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2097 memcpy(attr->value, &fcs_hba_attr->node_sym_name, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2098 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2099 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2100 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2102 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2103 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2107 templen = sizeof(fcs_hba_attr->vendor_info); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2108 memcpy(attr->value, &fcs_hba_attr->vendor_info, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2109 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2110 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2111 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2113 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2114 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2118 templen = sizeof(fcs_hba_attr->num_ports); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2119 memcpy(attr->value, &fcs_hba_attr->num_ports, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2120 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2121 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2122 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2124 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2125 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2129 templen = sizeof(fcs_hba_attr->fabric_name); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2130 memcpy(attr->value, &fcs_hba_attr->fabric_name, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2131 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2132 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2133 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2135 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2136 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2140 templen = sizeof(fcs_hba_attr->bios_ver); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2141 memcpy(attr->value, &fcs_hba_attr->bios_ver, templen); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2142 templen = fc_roundup(attr->len, sizeof(u32)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2143 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2144 len += templen; in bfa_fcs_lport_fdmi_build_rhba_pyld()
2146 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_rhba_pyld()
2147 sizeof(templen)); in bfa_fcs_lport_fdmi_build_rhba_pyld()
2253 u16 templen; in bfa_fcs_lport_fdmi_build_portattr_block() local
2272 templen = sizeof(fcs_port_attr.supp_fc4_types); in bfa_fcs_lport_fdmi_build_portattr_block()
2273 memcpy(attr->value, fcs_port_attr.supp_fc4_types, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2274 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2275 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2278 cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2279 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2286 templen = sizeof(fcs_port_attr.supp_speed); in bfa_fcs_lport_fdmi_build_portattr_block()
2287 memcpy(attr->value, &fcs_port_attr.supp_speed, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2288 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2289 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2292 cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2293 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2300 templen = sizeof(fcs_port_attr.curr_speed); in bfa_fcs_lport_fdmi_build_portattr_block()
2301 memcpy(attr->value, &fcs_port_attr.curr_speed, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2302 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2303 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2305 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2306 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2313 templen = sizeof(fcs_port_attr.max_frm_size); in bfa_fcs_lport_fdmi_build_portattr_block()
2314 memcpy(attr->value, &fcs_port_attr.max_frm_size, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2315 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2316 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2318 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2319 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2327 templen = (u16) strlen(fcs_port_attr.os_device_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2328 memcpy(attr->value, fcs_port_attr.os_device_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2329 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2330 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2331 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2333 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2334 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2342 templen = (u16) strlen(fcs_port_attr.host_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2343 memcpy(attr->value, fcs_port_attr.host_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2344 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2345 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2346 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2348 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2349 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2355 templen = sizeof(fcs_port_attr.node_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2356 memcpy(attr->value, &fcs_port_attr.node_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2357 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2358 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2359 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2361 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2362 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2366 templen = sizeof(fcs_port_attr.port_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2367 memcpy(attr->value, &fcs_port_attr.port_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2368 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2369 curr_ptr += sizeof(attr->type) + sizeof(attr->len) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2370 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2372 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2373 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2379 templen = sizeof(fcs_port_attr.port_sym_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2381 &fcs_port_attr.port_sym_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2382 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2384 sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2385 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2387 attr->len = cpu_to_be16(templen + in bfa_fcs_lport_fdmi_build_portattr_block()
2388 sizeof(attr->type) + sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2393 templen = sizeof(fcs_port_attr.port_type); in bfa_fcs_lport_fdmi_build_portattr_block()
2394 memcpy(attr->value, &fcs_port_attr.port_type, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2395 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2396 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2397 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2399 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2400 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2404 templen = sizeof(fcs_port_attr.scos); in bfa_fcs_lport_fdmi_build_portattr_block()
2405 memcpy(attr->value, &fcs_port_attr.scos, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2406 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2407 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2408 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2410 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2411 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2415 templen = sizeof(fcs_port_attr.port_fabric_name); in bfa_fcs_lport_fdmi_build_portattr_block()
2416 memcpy(attr->value, &fcs_port_attr.port_fabric_name, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2417 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2418 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2419 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2421 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2422 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2426 templen = sizeof(fcs_port_attr.port_act_fc4_type); in bfa_fcs_lport_fdmi_build_portattr_block()
2428 templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2429 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2430 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2431 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2433 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2434 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2438 templen = sizeof(fcs_port_attr.port_state); in bfa_fcs_lport_fdmi_build_portattr_block()
2439 memcpy(attr->value, &fcs_port_attr.port_state, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2440 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2441 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2442 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2444 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2445 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()
2449 templen = sizeof(fcs_port_attr.num_ports); in bfa_fcs_lport_fdmi_build_portattr_block()
2450 memcpy(attr->value, &fcs_port_attr.num_ports, templen); in bfa_fcs_lport_fdmi_build_portattr_block()
2451 templen = fc_roundup(templen, sizeof(u32)); in bfa_fcs_lport_fdmi_build_portattr_block()
2452 curr_ptr += sizeof(attr->type) + sizeof(templen) + templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2453 len += templen; in bfa_fcs_lport_fdmi_build_portattr_block()
2455 attr->len = cpu_to_be16(templen + sizeof(attr->type) + in bfa_fcs_lport_fdmi_build_portattr_block()
2456 sizeof(templen)); in bfa_fcs_lport_fdmi_build_portattr_block()