Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a9acfa42 authored by Sathya Perla's avatar Sathya Perla Committed by Greg Kroah-Hartman
Browse files

Staging: benet: fix problems reported by checkpatch

parent 998c15b1
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
TODO:
	- fix minor checkpatch.pl issues
	- remove wrappers around common iowrite functions
	- full netdev audit of common problems/issues

+0 −16
Original line number Diff line number Diff line
@@ -62,22 +62,6 @@ struct ASYNC_EVENT_TRAILER_AMAP {
 * port. The ARM firmware does not attempt to 'fail back' traffic to
 * the restored port.
 */
#if 0
struct BE_ASYNC_EVENT_LINK_STATE_AMAP {
	struct BE_UEXACT8_AMAP port0_link_status;
	struct BE_UEXACT8_AMAP port1_link_status;
	struct BE_UEXACT8_AMAP active_port;
	u8 rsvd0[8];	/* DWORD 0 */
	struct BE_UEXACT8_AMAP port0_duplex;
	struct BE_UEXACT8_AMAP port0_speed;
	struct BE_UEXACT8_AMAP port1_duplex;
	struct BE_UEXACT8_AMAP port1_speed;
	struct BE_UEXACT8_AMAP port0_fault;
	struct BE_UEXACT8_AMAP port1_fault;
	u8 rsvd1[2][8];	/* DWORD 2 */
	struct BE_ASYNC_EVENT_TRAILER_AMAP trailer;
} __packed;
#endif
struct BE_ASYNC_EVENT_LINK_STATE_AMAP {
	u8 port0_link_status[8];
	u8 port1_link_status[8];
+2 −1
Original line number Diff line number Diff line
@@ -1083,7 +1083,8 @@ static int be_probe(struct pci_dev *pdev, const struct pci_device_id *pdev_id)
	netif_napi_add(netdev, &pnob->napi, be_poll, 64);

	/* if the rx_frag size if 2K, one page is shared as two RX frags */
	pnob->rx_pg_shared = (pnob->rx_buf_size <= PAGE_SIZE / 2)? true : false;
	pnob->rx_pg_shared =
		(pnob->rx_buf_size <= PAGE_SIZE / 2) ? true : false;
	if (pnob->rx_buf_size != rxbuf_size) {
		printk(KERN_WARNING
		       "Could not set Rx buffer size to %d. Using %d\n",
+4 −2
Original line number Diff line number Diff line
@@ -156,7 +156,8 @@ static inline int process_nic_rx_completion(struct be_net_object *pnob,
	va = page_address(rx_page_info->page) + rx_page_info->page_offset;
	prefetch(va);

	skb->len = skb->data_len = n;
	skb->len = n;
	skb->data_len = n;
	if (n <= BE_HDR_LEN) {
		memcpy(skb->data, va, n);
		put_page(rx_page_info->page);
@@ -717,7 +718,8 @@ irqreturn_t be_int(int irq, void *dev)
 */
int be_poll(struct napi_struct *napi, int budget)
{
	struct be_net_object *pnob = container_of(napi, struct be_net_object, napi);
	struct be_net_object *pnob =
			container_of(napi, struct be_net_object, napi);
	u32 work_done;

	pnob->adapter->be_stat.bes_polls++;
+2 −1
Original line number Diff line number Diff line
@@ -386,7 +386,8 @@ static void wrb_fill(struct ETH_WRB_AMAP *wrb, u64 addr, int len)
static void wrb_fill_extra(struct ETH_WRB_AMAP *wrb, struct sk_buff *skb,
			   struct be_net_object *pnob)
{
	wrb->dw[2] = wrb->dw[3] = 0;
	wrb->dw[2] = 0;
	wrb->dw[3] = 0;
	AMAP_SET_BITS_PTR(ETH_WRB, crc, wrb, 1);
	if (skb_shinfo(skb)->gso_segs > 1 && skb_shinfo(skb)->gso_size) {
		AMAP_SET_BITS_PTR(ETH_WRB, lso, wrb, 1);
Loading