Commit a1f4064b authored by Ivan Vecera's avatar Ivan Vecera Committed by David S. Miller

bna: remove useless linked list

Remove global variable bnad_list and bnad->list_entry that are used
as list of bna driver instances. It is not necessary and useless.
Signed-off-by: default avatarIvan Vecera <ivecera@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9f3377ef
...@@ -56,7 +56,6 @@ MODULE_PARM_DESC(bna_debugfs_enable, "Enables debugfs feature, default=1," ...@@ -56,7 +56,6 @@ MODULE_PARM_DESC(bna_debugfs_enable, "Enables debugfs feature, default=1,"
static u32 bnad_rxqs_per_cq = 2; static u32 bnad_rxqs_per_cq = 2;
static u32 bna_id; static u32 bna_id;
static struct mutex bnad_list_mutex; static struct mutex bnad_list_mutex;
static LIST_HEAD(bnad_list);
static const u8 bnad_bcast_addr[] __aligned(2) = static const u8 bnad_bcast_addr[] __aligned(2) =
{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff };
...@@ -80,7 +79,6 @@ static void ...@@ -80,7 +79,6 @@ static void
bnad_add_to_list(struct bnad *bnad) bnad_add_to_list(struct bnad *bnad)
{ {
mutex_lock(&bnad_list_mutex); mutex_lock(&bnad_list_mutex);
list_add_tail(&bnad->list_entry, &bnad_list);
bnad->id = bna_id++; bnad->id = bna_id++;
mutex_unlock(&bnad_list_mutex); mutex_unlock(&bnad_list_mutex);
} }
...@@ -89,7 +87,6 @@ static void ...@@ -89,7 +87,6 @@ static void
bnad_remove_from_list(struct bnad *bnad) bnad_remove_from_list(struct bnad *bnad)
{ {
mutex_lock(&bnad_list_mutex); mutex_lock(&bnad_list_mutex);
list_del(&bnad->list_entry);
mutex_unlock(&bnad_list_mutex); mutex_unlock(&bnad_list_mutex);
} }
......
...@@ -288,7 +288,6 @@ struct bnad_rx_unmap_q { ...@@ -288,7 +288,6 @@ struct bnad_rx_unmap_q {
struct bnad { struct bnad {
struct net_device *netdev; struct net_device *netdev;
u32 id; u32 id;
struct list_head list_entry;
/* Data path */ /* Data path */
struct bnad_tx_info tx_info[BNAD_MAX_TX]; struct bnad_tx_info tx_info[BNAD_MAX_TX];
......
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