1 /* bnx2fc_debug.c: QLogic Linux FCoE offload driver.
2 * Handles operations such as session offload/upload etc, and manages
3 * session resources such as connection id and qp resources.
5 * Copyright (c) 2008-2013 Broadcom Corporation
6 * Copyright (c) 2014-2015 QLogic Corporation
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation.
16 void BNX2FC_IO_DBG(const struct bnx2fc_cmd *io_req, const char *fmt, ...)
21 if (likely(!(bnx2fc_debug_level & LOG_IO)))
29 if (io_req && io_req->port && io_req->port->lport &&
30 io_req->port->lport->host)
31 shost_printk(KERN_INFO, io_req->port->lport->host,
35 pr_info("NULL %pV", &vaf);
40 void BNX2FC_TGT_DBG(const struct bnx2fc_rport *tgt, const char *fmt, ...)
45 if (likely(!(bnx2fc_debug_level & LOG_TGT)))
53 if (tgt && tgt->port && tgt->port->lport && tgt->port->lport->host &&
55 shost_printk(KERN_INFO, tgt->port->lport->host,
57 tgt->rport->port_id, &vaf);
59 pr_info("NULL %pV", &vaf);
64 void BNX2FC_HBA_DBG(const struct fc_lport *lport, const char *fmt, ...)
69 if (likely(!(bnx2fc_debug_level & LOG_HBA)))
77 if (lport && lport->host)
78 shost_printk(KERN_INFO, lport->host, PFX "%pV", &vaf);
80 pr_info("NULL %pV", &vaf);