ib_cancel_rmpp_recvs(mad_agent_priv);
static void unregister_mad_agent(struct ib_mad_agent_private *mad_agent_priv){	struct ib_mad_port_private *port_priv;	unsigned long flags;	/* Note that we could still be handling received MADs */	/*	 * Canceling all sends results in dropping received response	 * MADs, preventing us from queuing additional work	 */	cancel_mads(mad_agent_priv);	port_priv = mad_agent_priv->qp_info->port_priv;	cancel_delayed_work(&mad_agent_priv->timed_work);	spin_lock_irqsave(&port_priv->reg_lock, flags);	remove_mad_reg_req(mad_agent_priv);	list_del(&mad_agent_priv->agent_list);	spin_unlock_irqrestore(&port_priv->reg_lock, flags);	flush_workqueue(port_priv->wq);	atomic_dec(&mad_agent_priv->refcount);	wait_event(mad_agent_priv->wait,		   !atomic_read(&mad_agent_priv->refcount));	if (mad_agent_priv->reg_req)		kfree(mad_agent_priv->reg_req);	ib_dereg_mr(mad_agent_priv->agent.mr);	kfree(mad_agent_priv);}