From: Hannes Reinecke <hare@suse.de>
To: Damien LeMoal <damien.lemoal@wdc.com>
Cc: linux-ide@vger.kernel.org, Hannes Reinecke <hare@suse.de>
Subject: [PATCH 33/68] sata_nv: drop pointless VPRINTK() calls and convert remaining ones
Date: Tue, 21 Dec 2021 08:20:56 +0100 [thread overview]
Message-ID: <20211221072131.46673-34-hare@suse.de> (raw)
In-Reply-To: <20211221072131.46673-1-hare@suse.de>
Quite some information from the VPRINTK() is already covered by
tracepoints, so remove the pointless calls and convert the remaining
ones to structured logging.
Signed-off-by: Hannes Reinecke <hare@suse.de>
---
drivers/ata/sata_nv.c | 38 ++++++++++++++------------------------
1 file changed, 14 insertions(+), 24 deletions(-)
diff --git a/drivers/ata/sata_nv.c b/drivers/ata/sata_nv.c
index 06d381b9764e..7f14d0d31057 100644
--- a/drivers/ata/sata_nv.c
+++ b/drivers/ata/sata_nv.c
@@ -809,7 +809,7 @@ static int nv_adma_check_cpb(struct ata_port *ap, int cpb_num, int force_err)
struct nv_adma_port_priv *pp = ap->private_data;
u8 flags = pp->cpb[cpb_num].resp_flags;
- VPRINTK("CPB %d, flags=0x%x\n", cpb_num, flags);
+ ata_port_dbg(ap, "CPB %d, flags=0x%x\n", cpb_num, flags);
if (unlikely((force_err ||
flags & (NV_CPB_RESP_ATA_ERR |
@@ -1101,8 +1101,6 @@ static int nv_adma_port_start(struct ata_port *ap)
struct pci_dev *pdev = to_pci_dev(dev);
u16 tmp;
- VPRINTK("ENTER\n");
-
/*
* Ensure DMA mask is set to 32-bit before allocating legacy PRD and
* pad buffers.
@@ -1191,7 +1189,6 @@ static void nv_adma_port_stop(struct ata_port *ap)
struct nv_adma_port_priv *pp = ap->private_data;
void __iomem *mmio = pp->ctl_block;
- VPRINTK("ENTER\n");
writew(0, mmio + NV_ADMA_CTL);
}
@@ -1253,8 +1250,6 @@ static void nv_adma_setup_port(struct ata_port *ap)
void __iomem *mmio = ap->host->iomap[NV_MMIO_BAR];
struct ata_ioports *ioport = &ap->ioaddr;
- VPRINTK("ENTER\n");
-
mmio += NV_ADMA_PORT + ap->port_no * NV_ADMA_PORT_SIZE;
ioport->cmd_addr = mmio;
@@ -1375,8 +1370,6 @@ static enum ata_completion_errors nv_adma_qc_prep(struct ata_queued_cmd *qc)
if (qc->tf.protocol == ATA_PROT_NCQ)
ctl_flags |= NV_CPB_CTL_QUEUE | NV_CPB_CTL_FPDMA;
- VPRINTK("qc->flags = 0x%lx\n", qc->flags);
-
nv_adma_tf_to_cpb(&qc->tf, cpb->tf);
if (qc->flags & ATA_QCFLAG_DMAMAP) {
@@ -1401,8 +1394,6 @@ static unsigned int nv_adma_qc_issue(struct ata_queued_cmd *qc)
void __iomem *mmio = pp->ctl_block;
int curr_ncq = (qc->tf.protocol == ATA_PROT_NCQ);
- VPRINTK("ENTER\n");
-
/* We can't handle result taskfile with NCQ commands, since
retrieving the taskfile switches us out of ADMA mode and would abort
existing commands. */
@@ -1414,7 +1405,6 @@ static unsigned int nv_adma_qc_issue(struct ata_queued_cmd *qc)
if (nv_adma_use_reg_mode(qc)) {
/* use ATA register mode */
- VPRINTK("using ATA register mode: 0x%lx\n", qc->flags);
BUG_ON(!(pp->flags & NV_ADMA_ATAPI_SETUP_COMPLETE) &&
(qc->flags & ATA_QCFLAG_DMAMAP));
nv_adma_register_mode(qc->ap);
@@ -1866,12 +1856,12 @@ static void nv_swncq_host_init(struct ata_host *host)
/* enable swncq */
tmp = readl(mmio + NV_CTL_MCP55);
- VPRINTK("HOST_CTL:0x%X\n", tmp);
+ dev_dbg(&pdev->dev, "HOST_CTL:0x%X\n", tmp);
writel(tmp | NV_CTL_PRI_SWNCQ | NV_CTL_SEC_SWNCQ, mmio + NV_CTL_MCP55);
/* enable irq intr */
tmp = readl(mmio + NV_INT_ENABLE_MCP55);
- VPRINTK("HOST_ENABLE:0x%X\n", tmp);
+ dev_dbg(&pdev->dev, "HOST_ENABLE:0x%X\n", tmp);
writel(tmp | 0x00fd00fd, mmio + NV_INT_ENABLE_MCP55);
/* clear port irq */
@@ -2101,7 +2091,7 @@ static int nv_swncq_sdbfis(struct ata_port *ap)
ata_qc_complete_multiple(ap, ata_qc_get_active(ap) ^ done_mask);
if (!ap->qc_active) {
- DPRINTK("over\n");
+ ata_port_dbg(ap, "over\n");
nv_swncq_pp_reinit(ap);
return 0;
}
@@ -2116,12 +2106,12 @@ static int nv_swncq_sdbfis(struct ata_port *ap)
*/
lack_dhfis = 1;
- DPRINTK("id 0x%x QC: qc_active 0x%llx,"
- "SWNCQ:qc_active 0x%X defer_bits %X "
- "dhfis 0x%X dmafis 0x%X last_issue_tag %x\n",
- ap->print_id, ap->qc_active, pp->qc_active,
- pp->defer_queue.defer_bits, pp->dhfis_bits,
- pp->dmafis_bits, pp->last_issue_tag);
+ ata_port_dbg(ap, "QC: qc_active 0x%llx,"
+ "SWNCQ:qc_active 0x%X defer_bits %X "
+ "dhfis 0x%X dmafis 0x%X last_issue_tag %x\n",
+ ap->qc_active, pp->qc_active,
+ pp->defer_queue.defer_bits, pp->dhfis_bits,
+ pp->dmafis_bits, pp->last_issue_tag);
nv_swncq_fis_reinit(ap);
@@ -2161,7 +2151,7 @@ static void nv_swncq_dmafis(struct ata_port *ap)
__ata_bmdma_stop(ap);
tag = nv_swncq_tag(ap);
- DPRINTK("dma setup tag 0x%x\n", tag);
+ ata_port_dbg(ap, "dma setup tag 0x%x\n", tag);
qc = ata_qc_from_tag(ap, tag);
if (unlikely(!qc))
@@ -2229,9 +2219,9 @@ static void nv_swncq_host_interrupt(struct ata_port *ap, u16 fis)
if (fis & NV_SWNCQ_IRQ_SDBFIS) {
pp->ncq_flags |= ncq_saw_sdb;
- DPRINTK("id 0x%x SWNCQ: qc_active 0x%X "
+ ata_port_dbg(ap, "SWNCQ: qc_active 0x%X "
"dhfis 0x%X dmafis 0x%X sactive 0x%X\n",
- ap->print_id, pp->qc_active, pp->dhfis_bits,
+ pp->qc_active, pp->dhfis_bits,
pp->dmafis_bits, readl(pp->sactive_block));
if (nv_swncq_sdbfis(ap) < 0)
goto irq_error;
@@ -2257,7 +2247,7 @@ static void nv_swncq_host_interrupt(struct ata_port *ap, u16 fis)
goto irq_exit;
if (pp->defer_queue.defer_bits) {
- DPRINTK("send next command\n");
+ ata_port_dbg(ap, "send next command\n");
qc = nv_swncq_qc_from_dq(ap);
nv_swncq_issue_atacmd(ap, qc);
}
--
2.29.2
next prev parent reply other threads:[~2021-12-21 7:22 UTC|newest]
Thread overview: 81+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-21 7:20 [PATCHv3 00/68] libata: rework logging, take II Hannes Reinecke
2021-12-21 7:20 ` [PATCH 01/68] libata: remove pointless debugging messages Hannes Reinecke
2021-12-21 7:20 ` [PATCH 02/68] libata: whitespace cleanup Hannes Reinecke
2021-12-21 7:20 ` [PATCH 03/68] libata: Add ata_port_classify() helper Hannes Reinecke
2021-12-30 5:12 ` Damien Le Moal
2021-12-21 7:20 ` [PATCH 04/68] libata: move ata_dump_id() to dynamic debugging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 05/68] libata: sanitize ATA_HORKAGE_DUMP_ID Hannes Reinecke
2021-12-21 7:20 ` [PATCH 06/68] libata: add reset tracepoints Hannes Reinecke
2021-12-21 7:20 ` [PATCH 07/68] libata: add qc_prep tracepoint Hannes Reinecke
2021-12-21 7:20 ` [PATCH 08/68] libata: tracepoints for bus-master DMA Hannes Reinecke
2021-12-30 5:13 ` Damien Le Moal
2021-12-21 7:20 ` [PATCH 09/68] libata-sff: tracepoints for HSM state machine Hannes Reinecke
2021-12-21 7:20 ` [PATCH 10/68] libata-scsi: drop DPRINTK calls for cdb translation Hannes Reinecke
2021-12-21 7:20 ` [PATCH 11/68] libata: add tracepoints for ATA error handling Hannes Reinecke
2021-12-21 7:20 ` [PATCH 12/68] libata: move ata_{port,link,dev}_dbg to standard dev_XXX() macros Hannes Reinecke
2021-12-21 7:20 ` [PATCH 13/68] libata: revamp ata_get_cmd_descript() Hannes Reinecke
2021-12-30 5:13 ` Damien Le Moal
2021-12-21 7:20 ` [PATCH 14/68] libata: move DPRINTK to ata debugging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 15/68] sata_mv: kill 'port' argument in mv_dump_all_regs() Hannes Reinecke
2021-12-21 7:20 ` [PATCH 16/68] sata_mv: replace DPRINTK with dynamic debugging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 17/68] pata_octeon_cf: remove DPRINTK() macro in interrupt context Hannes Reinecke
2021-12-21 7:20 ` [PATCH 18/68] pdc_adma: Remove DPRINTK call Hannes Reinecke
2021-12-21 7:20 ` [PATCH 19/68] sata_fsl: move DPRINTK to ata debugging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 20/68] sata_rcar: replace DPRINTK() with ata_port_dbg() Hannes Reinecke
2021-12-21 7:20 ` [PATCH 21/68] sata_qstor: " Hannes Reinecke
2021-12-21 7:20 ` [PATCH 22/68] pata_pdc2027x: Replace PDPRINTK() with standard ata logging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 23/68] libata: remove pointless VPRINTK() calls Hannes Reinecke
2021-12-21 7:20 ` [PATCH 24/68] ahci: Drop pointless VPRINTK() calls and convert the remaining ones Hannes Reinecke
2021-12-21 7:20 ` [PATCH 25/68] pdc_adma: Drop pointless VPRINTK() calls and remove disabled NCQ debugging Hannes Reinecke
2021-12-21 7:20 ` [PATCH 26/68] pata_octeon_cf: Drop pointless VPRINTK() calls and convert the remaining one Hannes Reinecke
2021-12-21 7:20 ` [PATCH 27/68] pata_via: Drop pointless VPRINTK() calls Hannes Reinecke
2021-12-21 7:20 ` [PATCH 28/68] sata_promise: Drop pointless VPRINTK() calls and convert the remaining ones Hannes Reinecke
2021-12-21 7:20 ` [PATCH 29/68] sata_qstor: Drop pointless VPRINTK() calls Hannes Reinecke
2021-12-21 7:20 ` [PATCH 30/68] sata_rcar: " Hannes Reinecke
2021-12-21 7:20 ` [PATCH 31/68] sata_inic162x: " Hannes Reinecke
2021-12-21 7:20 ` [PATCH 32/68] sata_mv: Drop pointless VPRINTK() call and convert the remaining one Hannes Reinecke
2021-12-21 7:20 ` Hannes Reinecke [this message]
2021-12-21 7:20 ` [PATCH 34/68] sata_fsl: convert VPRINTK() calls to ata_port_dbg() Hannes Reinecke
2021-12-21 7:20 ` [PATCH 35/68] sata_sil: Drop pointless VPRINTK() calls Hannes Reinecke
2021-12-21 7:20 ` [PATCH 36/68] sata_sx4: Drop pointless VPRINTK() calls and convert the remaining ones Hannes Reinecke
2021-12-21 7:21 ` [PATCH 37/68] sata_sx4: add module parameter 'dimm_test' Hannes Reinecke
2021-12-21 7:21 ` [PATCH 38/68] libata: drop ata_msg_error() and ata_msg_intr() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 39/68] libata: drop ata_msg_ctl() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 40/68] libata: drop ata_msg_malloc() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 41/68] libata: drop ata_msg_warn() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 42/68] libata: drop ata_msg_probe() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 43/68] libata: drop ata_msg_info() Hannes Reinecke
2021-12-23 9:48 ` Sergey Shtylyov
2021-12-23 18:47 ` Sergey Shtylyov
2021-12-30 5:20 ` Damien Le Moal
2021-12-21 7:21 ` [PATCH 44/68] libata: drop ata_msg_drv() Hannes Reinecke
2021-12-21 7:21 ` [PATCH 45/68] libata: remove 'new' ata message handling Hannes Reinecke
2021-12-21 7:21 ` [PATCH 46/68] libata: remove debug compilation switches Hannes Reinecke
2021-12-21 7:21 ` [PATCH 47/68] pata_atp867x: convert printk() calls Hannes Reinecke
2021-12-21 7:21 ` [PATCH 48/68] pata_cmd640: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 49/68] pata_cmd64x: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 50/68] pata_cs5520: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 51/68] pata_cs5536: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 52/68] pata_cypress: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 53/68] pata_it821x: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 54/68] pata_marvell: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 55/68] pata_rz1000: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 56/68] pata_serverworks: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 57/68] pata_sil680: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 58/68] sata_sx4: " Hannes Reinecke
2021-12-21 7:21 ` [PATCH 59/68] sata_mv: convert remaining printk() to structured logging Hannes Reinecke
2021-12-21 7:21 ` [PATCH 60/68] pata_hpt37x: convert pr_XXX() calls Hannes Reinecke
2021-12-21 7:21 ` [PATCH 61/68] pata_octeon_cf: Replace pr_XXX() calls with structured logging Hannes Reinecke
2021-12-21 7:21 ` [PATCH 62/68] pata_hpt3x2n: convert pr_XXX() calls Hannes Reinecke
2021-12-21 7:21 ` [PATCH 63/68] sata_gemini: convert pr_err() calls Hannes Reinecke
2021-12-21 7:21 ` [PATCH 64/68] pata_hpt366: convert pr_warn() calls Hannes Reinecke
2021-12-21 7:21 ` [PATCH 65/68] libata-scsi: rework ata_dump_status to avoid using pr_cont() Hannes Reinecke
2021-12-30 5:13 ` Damien Le Moal
2021-12-21 7:21 ` [PATCH 66/68] sata_dwc_460ex: drop DEBUG_NCQ Hannes Reinecke
2021-12-21 7:21 ` [PATCH 67/68] sata_dwc_460ex: remove 'check_status' argument Hannes Reinecke
2021-12-21 7:21 ` [PATCH 68/68] sata_dwc_460ex: Remove debug compile options Hannes Reinecke
2021-12-30 5:19 ` [PATCHv3 00/68] libata: rework logging, take II Damien Le Moal
2021-12-30 13:47 ` Hannes Reinecke
2021-12-31 4:49 ` Damien Le Moal
2021-12-31 9:45 ` Hannes Reinecke
-- strict thread matches above, loose matches on Subject: below --
2021-12-10 7:27 [PATCHv2 " Hannes Reinecke
2021-12-10 7:28 ` [PATCH 33/68] sata_nv: drop pointless VPRINTK() calls and convert remaining ones Hannes Reinecke
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211221072131.46673-34-hare@suse.de \
--to=hare@suse.de \
--cc=damien.lemoal@wdc.com \
--cc=linux-ide@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).