• Home
  • Raw
  • Download

Lines Matching refs:agent

115 	struct ib_mad_agent    *agent[IB_UMAD_MAX_AGENTS];  member
160 return file->agents_dead ? NULL : file->agent[id]; in __get_agent()
164 struct ib_mad_agent *agent, in queue_packet() argument
174 if (agent == __get_agent(file, packet->mad.hdr.id)) { in queue_packet()
194 static void send_handler(struct ib_mad_agent *agent, in send_handler() argument
197 struct ib_umad_file *file = agent->context; in send_handler()
207 if (!queue_packet(file, agent, packet)) in send_handler()
213 static void recv_handler(struct ib_mad_agent *agent, in recv_handler() argument
216 struct ib_umad_file *file = agent->context; in recv_handler()
240 ib_init_ah_from_wc(agent->device, agent->port_num, in recv_handler()
251 if (queue_packet(file, agent, packet)) in recv_handler()
456 struct ib_mad_agent *agent; in ib_umad_write() local
490 agent = __get_agent(file, packet->mad.hdr.id); in ib_umad_write()
491 if (!agent) { in ib_umad_write()
510 ah = ib_create_ah(agent->qp->pd, &ah_attr); in ib_umad_write()
520 && ib_mad_kernel_rmpp_agent(agent)) { in ib_umad_write()
531 packet->msg = ib_create_send_mad(agent, in ib_umad_write()
569 *tid = cpu_to_be64(((u64) agent->hi_tid) << 32 | in ib_umad_write()
574 if (!ib_mad_kernel_rmpp_agent(agent) in ib_umad_write()
632 struct ib_mad_agent *agent = NULL; in ib_umad_reg_agent() local
688 agent = ib_register_mad_agent(file->port->ib_dev, file->port->port_num, in ib_umad_reg_agent()
693 if (IS_ERR(agent)) { in ib_umad_reg_agent()
694 ret = PTR_ERR(agent); in ib_umad_reg_agent()
695 agent = NULL; in ib_umad_reg_agent()
716 file->agent[agent_id] = agent; in ib_umad_reg_agent()
722 if (ret && agent) in ib_umad_reg_agent()
723 ib_unregister_mad_agent(agent); in ib_umad_reg_agent()
734 struct ib_mad_agent *agent = NULL; in ib_umad_reg_agent2() local
804 agent = ib_register_mad_agent(file->port->ib_dev, file->port->port_num, in ib_umad_reg_agent2()
810 if (IS_ERR(agent)) { in ib_umad_reg_agent2()
811 ret = PTR_ERR(agent); in ib_umad_reg_agent2()
812 agent = NULL; in ib_umad_reg_agent2()
828 file->agent[agent_id] = agent; in ib_umad_reg_agent2()
834 if (ret && agent) in ib_umad_reg_agent2()
835 ib_unregister_mad_agent(agent); in ib_umad_reg_agent2()
845 struct ib_mad_agent *agent = NULL; in ib_umad_unreg_agent() local
863 agent = file->agent[id]; in ib_umad_unreg_agent()
864 file->agent[id] = NULL; in ib_umad_unreg_agent()
869 if (agent) in ib_umad_unreg_agent()
870 ib_unregister_mad_agent(agent); in ib_umad_unreg_agent()
1005 if (file->agent[i]) in ib_umad_close()
1006 ib_unregister_mad_agent(file->agent[i]); in ib_umad_close()
1274 if (file->agent[id]) in ib_umad_kill_port()
1275 ib_unregister_mad_agent(file->agent[id]); in ib_umad_kill_port()