Lines Matching refs:rpc
1162 struct rpc { struct
1275 struct rpc *rpc, *tmp; in process_rpc_calls() local
1282 list_for_each_entry_safe(rpc, tmp, &calls, list) { in process_rpc_calls()
1283 rpc->result = rpc->fn0 ? rpc->fn0(era->md) : rpc->fn1(era->md, rpc->arg); in process_rpc_calls()
1290 list_for_each_entry_safe(rpc, tmp, &calls, list) in process_rpc_calls()
1291 rpc->result = r; in process_rpc_calls()
1294 list_for_each_entry_safe(rpc, tmp, &calls, list) in process_rpc_calls()
1295 complete(&rpc->complete); in process_rpc_calls()
1328 static int perform_rpc(struct era *era, struct rpc *rpc) in perform_rpc() argument
1330 rpc->result = 0; in perform_rpc()
1331 init_completion(&rpc->complete); in perform_rpc()
1334 list_add(&rpc->list, &era->rpc_calls); in perform_rpc()
1338 wait_for_completion(&rpc->complete); in perform_rpc()
1340 return rpc->result; in perform_rpc()
1345 struct rpc rpc; in in_worker0() local
1346 rpc.fn0 = fn; in in_worker0()
1347 rpc.fn1 = NULL; in in_worker0()
1349 return perform_rpc(era, &rpc); in in_worker0()
1355 struct rpc rpc; in in_worker1() local
1356 rpc.fn0 = NULL; in in_worker1()
1357 rpc.fn1 = fn; in in_worker1()
1358 rpc.arg = arg; in in_worker1()
1360 return perform_rpc(era, &rpc); in in_worker1()