forked from Minki/linux
staging: octeon: Fix block comments
Remove commented source code. Checkpatch detected these issues. Signed-off-by: Laura Garcia Liebana <nevola@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
e8a4e572c4
commit
b4ede7922e
@ -114,17 +114,11 @@ static inline int cvm_oct_check_rcv_error(cvmx_wqe_t *work)
|
||||
}
|
||||
|
||||
if (*ptr == 0xd5) {
|
||||
/*
|
||||
printk_ratelimited("Port %d received 0xd5 preamble\n",
|
||||
port);
|
||||
*/
|
||||
/* Port received 0xd5 preamble */
|
||||
work->packet_ptr.s.addr += i + 1;
|
||||
work->word1.len -= i + 5;
|
||||
} else if ((*ptr & 0xf) == 0xd) {
|
||||
/*
|
||||
printk_ratelimited("Port %d received 0x?d preamble\n",
|
||||
port);
|
||||
*/
|
||||
/* Port received 0xd preamble */
|
||||
work->packet_ptr.s.addr += i;
|
||||
work->word1.len -= i + 4;
|
||||
for (i = 0; i < work->word1.len; i++) {
|
||||
@ -136,9 +130,6 @@ static inline int cvm_oct_check_rcv_error(cvmx_wqe_t *work)
|
||||
} else {
|
||||
printk_ratelimited("Port %d unknown preamble, packet dropped\n",
|
||||
port);
|
||||
/*
|
||||
cvmx_helper_dump_packet(work);
|
||||
*/
|
||||
cvm_oct_free_work(work);
|
||||
return 1;
|
||||
}
|
||||
@ -367,11 +358,10 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget)
|
||||
}
|
||||
netif_receive_skb(skb);
|
||||
} else {
|
||||
/* Drop any packet received for a device that isn't up */
|
||||
/*
|
||||
printk_ratelimited("%s: Device not up, packet dropped\n",
|
||||
dev->name);
|
||||
*/
|
||||
* Drop any packet received for a device that
|
||||
* isn't up.
|
||||
*/
|
||||
priv->stats.rx_dropped++;
|
||||
dev_kfree_skb_irq(skb);
|
||||
}
|
||||
|
@ -309,55 +309,38 @@ int cvm_oct_xmit(struct sk_buff *skb, struct net_device *dev)
|
||||
#if REUSE_SKBUFFS_WITHOUT_FREE
|
||||
fpa_head = skb->head + 256 - ((unsigned long)skb->head & 0x7f);
|
||||
if (unlikely(skb->data < fpa_head)) {
|
||||
/*
|
||||
* printk("TX buffer beginning can't meet FPA
|
||||
* alignment constraints\n");
|
||||
*/
|
||||
/* TX buffer beginning can't meet FPA alignment constraints */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely
|
||||
((skb_end_pointer(skb) - fpa_head) < CVMX_FPA_PACKET_POOL_SIZE)) {
|
||||
/*
|
||||
printk("TX buffer isn't large enough for the FPA\n");
|
||||
*/
|
||||
/* TX buffer isn't large enough for the FPA */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely(skb_shared(skb))) {
|
||||
/*
|
||||
printk("TX buffer sharing data with someone else\n");
|
||||
*/
|
||||
/* TX buffer sharing data with someone else */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely(skb_cloned(skb))) {
|
||||
/*
|
||||
printk("TX buffer has been cloned\n");
|
||||
*/
|
||||
/* TX buffer has been cloned */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely(skb_header_cloned(skb))) {
|
||||
/*
|
||||
printk("TX buffer header has been cloned\n");
|
||||
*/
|
||||
/* TX buffer header has been cloned */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely(skb->destructor)) {
|
||||
/*
|
||||
printk("TX buffer has a destructor\n");
|
||||
*/
|
||||
/* TX buffer has a destructor */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely(skb_shinfo(skb)->nr_frags)) {
|
||||
/*
|
||||
printk("TX buffer has fragments\n");
|
||||
*/
|
||||
/* TX buffer has fragments */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
if (unlikely
|
||||
(skb->truesize !=
|
||||
sizeof(*skb) + skb_end_offset(skb))) {
|
||||
/*
|
||||
printk("TX buffer truesize has been changed\n");
|
||||
*/
|
||||
/* TX buffer truesize has been changed */
|
||||
goto dont_put_skbuff_in_hw;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user