Skip to content

Commit

Permalink
rocker: Drop pointless static qualifier
Browse files Browse the repository at this point in the history
There is no need to have the 'struct rocker_desc_info *desc_info'
variable static since new value always be assigned before use it.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
YueHaibing authored and davem330 committed Oct 19, 2018
1 parent 1107a67 commit 9333f20
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/net/ethernet/rocker/rocker_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,7 @@ static void rocker_desc_cookie_ptr_set(const struct rocker_desc_info *desc_info,
static struct rocker_desc_info *
rocker_desc_head_get(const struct rocker_dma_ring_info *info)
{
static struct rocker_desc_info *desc_info;
struct rocker_desc_info *desc_info;
u32 head = __pos_inc(info->head, info->size);

desc_info = &info->desc_info[info->head];
Expand Down Expand Up @@ -402,7 +402,7 @@ static void rocker_desc_head_set(const struct rocker *rocker,
static struct rocker_desc_info *
rocker_desc_tail_get(struct rocker_dma_ring_info *info)
{
static struct rocker_desc_info *desc_info;
struct rocker_desc_info *desc_info;

if (info->tail == info->head)
return NULL; /* nothing to be done between head and tail */
Expand Down

0 comments on commit 9333f20

Please sign in to comment.