diff mbox series

[07/46] libata-core: remove pointless debugging messages

Message ID 20200204165547.115220-8-hare@suse.de
State Not Applicable
Delegated to: David Miller
Headers show
Series ata: kill ATA_DEBUG | expand

Commit Message

Hannes Reinecke Feb. 4, 2020, 4:55 p.m. UTC
The bus probe is better tracked with the actual calls, and the
resulting taskfile will be printed with tracepoints anyway.

Signed-off-by: Hannes Reinecke <hare@suse.de>
---
 drivers/ata/libata-core.c | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

Comments

Sergei Shtylyov Feb. 5, 2020, 8:08 a.m. UTC | #1
Hello!

On 04.02.2020 19:55, Hannes Reinecke wrote:

> The bus probe is better tracked with the actual calls, and the
> resulting taskfile will be printed with tracepoints anyway.
> 
> Signed-off-by: Hannes Reinecke <hare@suse.de>
> ---
>   drivers/ata/libata-core.c | 8 +-------
>   1 file changed, 1 insertion(+), 7 deletions(-)
> 
> diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
> index cea065fb6282..0f5715cfa1c4 100644
> --- a/drivers/ata/libata-core.c
> +++ b/drivers/ata/libata-core.c
[...]
> @@ -6475,11 +6472,8 @@ int ata_port_probe(struct ata_port *ap)
>   	if (ap->ops->error_handler) {
>   		__ata_port_probe(ap);
>   		ata_port_wait_eh(ap);
> -	} else {
> -		DPRINTK("ata%u: bus probe begin\n", ap->print_id);
> +	} else

    You shousd keep {} here, according to the CodingStyle. {} should be
used in all branches if used in any.

>   		rc = ata_bus_probe(ap);
> -		DPRINTK("ata%u: bus probe end\n", ap->print_id);
> -	}
>   	return rc;
>   }
>   

MBR, Sergei
Bartlomiej Zolnierkiewicz Feb. 10, 2020, 12:37 p.m. UTC | #2
On 2/4/20 5:55 PM, Hannes Reinecke wrote:
> The bus probe is better tracked with the actual calls, and the
> resulting taskfile will be printed with tracepoints anyway.
> 
> Signed-off-by: Hannes Reinecke <hare@suse.de>

Reviewed-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

> ---
>  drivers/ata/libata-core.c | 8 +-------
>  1 file changed, 1 insertion(+), 7 deletions(-)
> 
> diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
> index cea065fb6282..0f5715cfa1c4 100644
> --- a/drivers/ata/libata-core.c
> +++ b/drivers/ata/libata-core.c
> @@ -825,9 +825,6 @@ int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev,
>  		head  = track % dev->heads;
>  		sect  = (u32)block % dev->sectors + 1;
>  
> -		DPRINTK("block %u track %u cyl %u head %u sect %u\n",
> -			(u32)block, track, cyl, head, sect);
> -
>  		/* Check whether the converted CHS can fit.
>  		   Cylinder: 0-65535
>  		   Head: 0-15
> @@ -6475,11 +6472,8 @@ int ata_port_probe(struct ata_port *ap)
>  	if (ap->ops->error_handler) {
>  		__ata_port_probe(ap);
>  		ata_port_wait_eh(ap);
> -	} else {
> -		DPRINTK("ata%u: bus probe begin\n", ap->print_id);
> +	} else
>  		rc = ata_bus_probe(ap);
> -		DPRINTK("ata%u: bus probe end\n", ap->print_id);
> -	}
>  	return rc;
>  }
>
diff mbox series

Patch

diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
index cea065fb6282..0f5715cfa1c4 100644
--- a/drivers/ata/libata-core.c
+++ b/drivers/ata/libata-core.c
@@ -825,9 +825,6 @@  int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev,
 		head  = track % dev->heads;
 		sect  = (u32)block % dev->sectors + 1;
 
-		DPRINTK("block %u track %u cyl %u head %u sect %u\n",
-			(u32)block, track, cyl, head, sect);
-
 		/* Check whether the converted CHS can fit.
 		   Cylinder: 0-65535
 		   Head: 0-15
@@ -6475,11 +6472,8 @@  int ata_port_probe(struct ata_port *ap)
 	if (ap->ops->error_handler) {
 		__ata_port_probe(ap);
 		ata_port_wait_eh(ap);
-	} else {
-		DPRINTK("ata%u: bus probe begin\n", ap->print_id);
+	} else
 		rc = ata_bus_probe(ap);
-		DPRINTK("ata%u: bus probe end\n", ap->print_id);
-	}
 	return rc;
 }