selftest.c (0bbe06493b9526f2513ace902d55aa0e141dba73) | selftest.c (6dc5774deefe38d9ab385a5dafbe6614ae63d166) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-only 2/**************************************************************************** 3 * Driver for Solarflare network controllers and boards 4 * Copyright 2005-2006 Fen Systems Ltd. 5 * Copyright 2006-2012 Solarflare Communications Inc. 6 */ 7 8#include <linux/netdevice.h> --- 414 unchanged lines hidden (view full) --- 423 struct sk_buff *skb; 424 int i; 425 netdev_tx_t rc; 426 427 /* Transmit N copies of buffer */ 428 for (i = 0; i < state->packet_count; i++) { 429 /* Allocate an skb, holding an extra reference for 430 * transmit completion counting */ | 1// SPDX-License-Identifier: GPL-2.0-only 2/**************************************************************************** 3 * Driver for Solarflare network controllers and boards 4 * Copyright 2005-2006 Fen Systems Ltd. 5 * Copyright 2006-2012 Solarflare Communications Inc. 6 */ 7 8#include <linux/netdevice.h> --- 414 unchanged lines hidden (view full) --- 423 struct sk_buff *skb; 424 int i; 425 netdev_tx_t rc; 426 427 /* Transmit N copies of buffer */ 428 for (i = 0; i < state->packet_count; i++) { 429 /* Allocate an skb, holding an extra reference for 430 * transmit completion counting */ |
431 skb = alloc_skb(EF4_LOOPBACK_PAYLOAD_LEN, GFP_KERNEL); | 431 skb = alloc_skb(sizeof(state->payload), GFP_KERNEL); |
432 if (!skb) 433 return -ENOMEM; 434 state->skbs[i] = skb; 435 skb_get(skb); 436 437 /* Copy the payload in, incrementing the source address to 438 * exercise the rss vectors */ 439 payload = skb_put(skb, sizeof(state->payload)); --- 377 unchanged lines hidden --- | 432 if (!skb) 433 return -ENOMEM; 434 state->skbs[i] = skb; 435 skb_get(skb); 436 437 /* Copy the payload in, incrementing the source address to 438 * exercise the rss vectors */ 439 payload = skb_put(skb, sizeof(state->payload)); --- 377 unchanged lines hidden --- |