• Home
  • Raw
  • Download

Lines Matching refs:sc

34 	struct octeon_soft_command *sc;  in octeon_alloc_soft_command_resp()  local
40 sc = (struct octeon_soft_command *) in octeon_alloc_soft_command_resp()
43 if (!sc) in octeon_alloc_soft_command_resp()
47 memcpy(&sc->cmd, cmd, sizeof(union octeon_instr_64B)); in octeon_alloc_soft_command_resp()
53 ih3 = (struct octeon_instr_ih3 *)&sc->cmd.cmd3.ih3; in octeon_alloc_soft_command_resp()
54 rdp = (struct octeon_instr_rdp *)&sc->cmd.cmd3.rdp; in octeon_alloc_soft_command_resp()
55 irh = (struct octeon_instr_irh *)&sc->cmd.cmd3.irh; in octeon_alloc_soft_command_resp()
59 ih2 = (struct octeon_instr_ih2 *)&sc->cmd.cmd2.ih2; in octeon_alloc_soft_command_resp()
60 rdp = (struct octeon_instr_rdp *)&sc->cmd.cmd2.rdp; in octeon_alloc_soft_command_resp()
61 irh = (struct octeon_instr_irh *)&sc->cmd.cmd2.irh; in octeon_alloc_soft_command_resp()
71 *sc->status_word = COMPLETION_WORD_INIT; in octeon_alloc_soft_command_resp()
74 sc->cmd.cmd3.rptr = sc->dmarptr; in octeon_alloc_soft_command_resp()
76 sc->cmd.cmd2.rptr = sc->dmarptr; in octeon_alloc_soft_command_resp()
78 sc->expiry_time = jiffies + msecs_to_jiffies(LIO_SC_MAX_TMO_MS); in octeon_alloc_soft_command_resp()
80 return sc; in octeon_alloc_soft_command_resp()
98 struct octeon_soft_command *sc = NULL; in octnic_alloc_ctrl_pkt_sc() local
108 sc = (struct octeon_soft_command *) in octnic_alloc_ctrl_pkt_sc()
111 if (!sc) in octnic_alloc_ctrl_pkt_sc()
114 data = (u8 *)sc->virtdptr; in octnic_alloc_ctrl_pkt_sc()
125 sc->iq_no = (u32)nctrl->iq_no; in octnic_alloc_ctrl_pkt_sc()
127 octeon_prepare_soft_command(oct, sc, OPCODE_NIC, OPCODE_NIC_CMD, in octnic_alloc_ctrl_pkt_sc()
130 init_completion(&sc->complete); in octnic_alloc_ctrl_pkt_sc()
131 sc->sc_status = OCTEON_REQUEST_PENDING; in octnic_alloc_ctrl_pkt_sc()
133 return sc; in octnic_alloc_ctrl_pkt_sc()
141 struct octeon_soft_command *sc = NULL; in octnet_send_nic_ctrl_pkt() local
156 sc = octnic_alloc_ctrl_pkt_sc(oct, nctrl); in octnet_send_nic_ctrl_pkt()
157 if (!sc) { in octnet_send_nic_ctrl_pkt()
164 retval = octeon_send_soft_command(oct, sc); in octnet_send_nic_ctrl_pkt()
166 octeon_free_soft_command(oct, sc); in octnet_send_nic_ctrl_pkt()
181 WRITE_ONCE(sc->caller_is_done, true); in octnet_send_nic_ctrl_pkt()
186 retval = wait_for_sc_completion_timeout(oct, sc, 0); in octnet_send_nic_ctrl_pkt()
190 nctrl->sc_status = sc->sc_status; in octnet_send_nic_ctrl_pkt()
195 WRITE_ONCE(sc->caller_is_done, true); in octnet_send_nic_ctrl_pkt()