Lines Matching refs:payload
92 struct efx_loopback_payload payload; member
291 struct efx_loopback_payload *payload; in efx_siena_loopback_rx_packet() local
299 payload = &state->payload; in efx_siena_loopback_rx_packet()
303 received.ip.saddr = payload->ip.saddr; in efx_siena_loopback_rx_packet()
305 received.ip.check = payload->ip.check; in efx_siena_loopback_rx_packet()
316 if (memcmp(&received.header, &payload->header, ETH_HLEN) != 0) { in efx_siena_loopback_rx_packet()
333 if (memcmp(&received.ip, &payload->ip, sizeof(payload->ip)) != 0) { in efx_siena_loopback_rx_packet()
341 if (memcmp(&received.msg, &payload->msg, sizeof(received.msg)) != 0) { in efx_siena_loopback_rx_packet()
349 if (received.iteration != payload->iteration) { in efx_siena_loopback_rx_packet()
353 ntohs(payload->iteration), LOOPBACK_MODE(efx)); in efx_siena_loopback_rx_packet()
372 &state->payload.packet, EFX_LOOPBACK_PAYLOAD_LEN, in efx_siena_loopback_rx_packet()
384 struct efx_loopback_payload *payload = &state->payload; in efx_iterate_state() local
387 ether_addr_copy((u8 *)&payload->header.h_dest, net_dev->dev_addr); in efx_iterate_state()
388 ether_addr_copy((u8 *)&payload->header.h_source, payload_source); in efx_iterate_state()
389 payload->header.h_proto = htons(ETH_P_IP); in efx_iterate_state()
392 payload->ip.daddr = htonl(INADDR_LOOPBACK); in efx_iterate_state()
393 payload->ip.ihl = 5; in efx_iterate_state()
394 payload->ip.check = (__force __sum16) htons(0xdead); in efx_iterate_state()
395 payload->ip.tot_len = htons(sizeof(*payload) - in efx_iterate_state()
397 payload->ip.version = IPVERSION; in efx_iterate_state()
398 payload->ip.protocol = IPPROTO_UDP; in efx_iterate_state()
401 payload->udp.source = 0; in efx_iterate_state()
402 payload->udp.len = htons(sizeof(*payload) - in efx_iterate_state()
404 payload->udp.check = 0; /* checksum ignored */ in efx_iterate_state()
407 payload->iteration = htons(ntohs(payload->iteration) + 1); in efx_iterate_state()
408 memcpy(&payload->msg, payload_msg, sizeof(payload_msg)); in efx_iterate_state()
420 struct efx_loopback_payload *payload; in efx_begin_loopback() local
429 skb = alloc_skb(sizeof(state->payload), GFP_KERNEL); in efx_begin_loopback()
437 payload = skb_put(skb, sizeof(state->payload)); in efx_begin_loopback()
438 memcpy(payload, &state->payload, sizeof(state->payload)); in efx_begin_loopback()
439 payload->ip.saddr = htonl(INADDR_LOOPBACK | (i << 2)); in efx_begin_loopback()