Lines Matching refs:lif

213 static void ionic_adminq_flush(struct ionic_lif *lif)  in ionic_adminq_flush()  argument
219 spin_lock_irqsave(&lif->adminq_lock, irqflags); in ionic_adminq_flush()
220 if (!lif->adminqcq) { in ionic_adminq_flush()
221 spin_unlock_irqrestore(&lif->adminq_lock, irqflags); in ionic_adminq_flush()
225 q = &lif->adminqcq->q; in ionic_adminq_flush()
234 spin_unlock_irqrestore(&lif->adminq_lock, irqflags); in ionic_adminq_flush()
237 void ionic_adminq_netdev_err_print(struct ionic_lif *lif, u8 opcode, in ionic_adminq_netdev_err_print() argument
245 netdev_err(lif->netdev, "%s (%d) failed: %s (%d)\n", in ionic_adminq_netdev_err_print()
249 static int ionic_adminq_check_err(struct ionic_lif *lif, in ionic_adminq_check_err() argument
261 ionic_adminq_netdev_err_print(lif, ctx->cmd.cmd.opcode, in ionic_adminq_check_err()
265 ionic_adminq_flush(lif); in ionic_adminq_check_err()
292 int ionic_adminq_post(struct ionic_lif *lif, struct ionic_admin_ctx *ctx) in ionic_adminq_post() argument
299 spin_lock_irqsave(&lif->adminq_lock, irqflags); in ionic_adminq_post()
300 if (!lif->adminqcq) { in ionic_adminq_post()
301 spin_unlock_irqrestore(&lif->adminq_lock, irqflags); in ionic_adminq_post()
305 q = &lif->adminqcq->q; in ionic_adminq_post()
312 err = ionic_heartbeat_check(lif->ionic); in ionic_adminq_post()
319 dev_dbg(&lif->netdev->dev, "post admin queue command:\n"); in ionic_adminq_post()
326 spin_unlock_irqrestore(&lif->adminq_lock, irqflags); in ionic_adminq_post()
331 int ionic_adminq_wait(struct ionic_lif *lif, struct ionic_admin_ctx *ctx, in ionic_adminq_wait() argument
334 struct net_device *netdev = lif->netdev; in ionic_adminq_wait()
344 if (do_msg && !test_bit(IONIC_LIF_F_FW_RESET, lif->state)) in ionic_adminq_wait()
362 (void)ionic_heartbeat_check(lif->ionic); in ionic_adminq_wait()
363 if ((test_bit(IONIC_LIF_F_FW_RESET, lif->state) && in ionic_adminq_wait()
364 !lif->ionic->idev.fw_status_ready) || in ionic_adminq_wait()
365 test_bit(IONIC_LIF_F_FW_STOPPING, lif->state)) { in ionic_adminq_wait()
376 dev_dbg(lif->ionic->dev, "%s: elapsed %d msecs\n", in ionic_adminq_wait()
379 return ionic_adminq_check_err(lif, ctx, in ionic_adminq_wait()
384 int ionic_adminq_post_wait(struct ionic_lif *lif, struct ionic_admin_ctx *ctx) in ionic_adminq_post_wait() argument
388 err = ionic_adminq_post(lif, ctx); in ionic_adminq_post_wait()
390 return ionic_adminq_wait(lif, ctx, err, true); in ionic_adminq_post_wait()
393 int ionic_adminq_post_wait_nomsg(struct ionic_lif *lif, struct ionic_admin_ctx *ctx) in ionic_adminq_post_wait_nomsg() argument
397 err = ionic_adminq_post(lif, ctx); in ionic_adminq_post_wait_nomsg()
399 return ionic_adminq_wait(lif, ctx, err, false); in ionic_adminq_post_wait_nomsg()
562 &ionic->ident.lif); in ionic_identify()