[openib-general] [PATCH] [TRIVIAL] ib_mad: Eliminate up variable in port structure
Hal Rosenstock
halr at voltaire.com
Sat Sep 11 11:29:11 PDT 2004
ib_mad: Eliminate up variable in port structure
Index: ib_mad.c
===================================================================
--- ib_mad.c (revision 784)
+++ ib_mad.c (working copy)
@@ -971,7 +971,6 @@
static int ib_mad_port_start(struct ib_mad_port_private *priv)
{
int ret, i;
- unsigned long flags;
for (i = 0; i < 2; i++) {
ret = ib_mad_change_qp_state_to_init(priv->qp[i], priv->port);
@@ -1007,9 +1006,6 @@
}
}
- spin_lock_irqsave(&ib_mad_port_list_lock, flags);
- priv->up = 1;
- spin_unlock_irqrestore(&ib_mad_port_list_lock, flags);
return 0;
error:
ib_mad_return_posted_recv_mads(priv);
@@ -1026,12 +1022,7 @@
static void ib_mad_port_stop(struct ib_mad_port_private *priv)
{
int i;
- unsigned long flags;
- spin_lock_irqsave(&ib_mad_port_list_lock, flags);
- priv->up = 0;
- spin_unlock_irqrestore(&ib_mad_port_list_lock, flags);
-
for (i = 0; i < 2; i++) {
ib_mad_change_qp_state_to_reset(priv->qp[i]);
}
Index: ib_mad_priv.h
===================================================================
--- ib_mad_priv.h (revision 784)
+++ ib_mad_priv.h (working copy)
@@ -122,7 +122,6 @@
struct ib_mad_port_private *next;
struct ib_device *device;
int port;
- int up;
struct ib_mad_mgmt_class_table *version[MAX_MGMT_VERSION];
struct ib_qp *qp[2];
struct ib_cq *cq;
More information about the general
mailing list