Commit 186c426d authored by Mark Einon's avatar Mark Einon Committed by Greg Kroah-Hartman

staging: et131x: Remove unnecessary NULL pointer assignments

During a previous refactoring excerise, two NULL pointer assingments
were moved to their respective pointer declarations. Dan Carpenter
correctly points out that these assignments are not needed.
Removing them.

Also two small whitespace changes - rejoining split lines, as they are
now less than 80 chars.
Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarMark Einon <mark.einon@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 96d39278
...@@ -2681,8 +2681,7 @@ static void nic_return_rfd(struct et131x_adapter *adapter, struct rfd *rfd) ...@@ -2681,8 +2681,7 @@ static void nic_return_rfd(struct et131x_adapter *adapter, struct rfd *rfd)
/* We don't use any of the OOB data besides status. Otherwise, we /* We don't use any of the OOB data besides status. Otherwise, we
* need to clean up OOB data * need to clean up OOB data
*/ */
if ( if ((ring_index == 0 && buff_index < rx_local->fbr[1]->num_entries) ||
(ring_index == 0 && buff_index < rx_local->fbr[1]->num_entries) ||
(ring_index == 1 && buff_index < rx_local->fbr[0]->num_entries)) { (ring_index == 1 && buff_index < rx_local->fbr[0]->num_entries)) {
u32 *offset; u32 *offset;
u8 id; u8 id;
...@@ -2709,8 +2708,7 @@ static void nic_return_rfd(struct et131x_adapter *adapter, struct rfd *rfd) ...@@ -2709,8 +2708,7 @@ static void nic_return_rfd(struct et131x_adapter *adapter, struct rfd *rfd)
next->addr_lo = rx_local->fbr[id]->bus_low[buff_index]; next->addr_lo = rx_local->fbr[id]->bus_low[buff_index];
next->word2 = buff_index; next->word2 = buff_index;
writel(bump_free_buff_ring( writel(bump_free_buff_ring(&rx_local->fbr[id]->local_full,
&rx_local->fbr[id]->local_full,
rx_local->fbr[id]->num_entries - 1), rx_local->fbr[id]->num_entries - 1),
offset); offset);
...@@ -2747,7 +2745,7 @@ static struct rfd *nic_rx_pkts(struct et131x_adapter *adapter) ...@@ -2747,7 +2745,7 @@ static struct rfd *nic_rx_pkts(struct et131x_adapter *adapter)
struct rx_ring *rx_local = &adapter->rx_ring; struct rx_ring *rx_local = &adapter->rx_ring;
struct rx_status_block *status; struct rx_status_block *status;
struct pkt_stat_desc *psr; struct pkt_stat_desc *psr;
struct rfd *rfd = NULL; struct rfd *rfd;
u32 i; u32 i;
u8 *buf; u8 *buf;
unsigned long flags; unsigned long flags;
...@@ -2757,7 +2755,7 @@ static struct rfd *nic_rx_pkts(struct et131x_adapter *adapter) ...@@ -2757,7 +2755,7 @@ static struct rfd *nic_rx_pkts(struct et131x_adapter *adapter)
u32 len; u32 len;
u32 word0; u32 word0;
u32 word1; u32 word1;
struct sk_buff *skb = NULL; struct sk_buff *skb;
/* RX Status block is written by the DMA engine prior to every /* RX Status block is written by the DMA engine prior to every
* interrupt. It contains the next to be used entry in the Packet * interrupt. It contains the next to be used entry in the Packet
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment