* [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs
@ 2020-05-04 17:54 Ewan D. Milne
2020-05-04 18:00 ` Laurence Oberman
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Ewan D. Milne @ 2020-05-04 17:54 UTC (permalink / raw)
To: linux-scsi; +Cc: stable, njavali, himanshu.madhani
Calling ql_log() inside qla2x00_port_speed_show() is causing messages
to be output to the console for no particularly good reason. The sysfs
read routine should just return the information to userspace. The only
reason to log a message is when the port speed actually changes, and
this already occurs elsewhere.
Cc: <stable@vger.kernel.org> # v5.1+
Fixes: 4910b524ac9 ("scsi: qla2xxx: Add support for setting port speed")
Signed-off-by: Ewan D. Milne <emilne@redhat.com>
---
drivers/scsi/qla2xxx/qla_attr.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
index 3325596..2c9e5ac 100644
--- a/drivers/scsi/qla2xxx/qla_attr.c
+++ b/drivers/scsi/qla2xxx/qla_attr.c
@@ -1850,9 +1850,6 @@ qla2x00_port_speed_show(struct device *dev, struct device_attribute *attr,
return -EINVAL;
}
- ql_log(ql_log_info, vha, 0x70d6,
- "port speed:%d\n", ha->link_data_rate);
-
return scnprintf(buf, PAGE_SIZE, "%s\n", spd[ha->link_data_rate]);
}
--
2.1.0
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs
2020-05-04 17:54 [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs Ewan D. Milne
@ 2020-05-04 18:00 ` Laurence Oberman
2020-05-04 19:07 ` himanshu.madhani
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Laurence Oberman @ 2020-05-04 18:00 UTC (permalink / raw)
To: Ewan D. Milne, linux-scsi; +Cc: stable, njavali, himanshu.madhani
On Mon, 2020-05-04 at 13:54 -0400, Ewan D. Milne wrote:
> Calling ql_log() inside qla2x00_port_speed_show() is causing messages
> to be output to the console for no particularly good reason. The
> sysfs
> read routine should just return the information to userspace. The
> only
> reason to log a message is when the port speed actually changes, and
> this already occurs elsewhere.
>
> Cc: <stable@vger.kernel.org> # v5.1+
> Fixes: 4910b524ac9 ("scsi: qla2xxx: Add support for setting port
> speed")
> Signed-off-by: Ewan D. Milne <emilne@redhat.com>
> ---
> drivers/scsi/qla2xxx/qla_attr.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/scsi/qla2xxx/qla_attr.c
> b/drivers/scsi/qla2xxx/qla_attr.c
> index 3325596..2c9e5ac 100644
> --- a/drivers/scsi/qla2xxx/qla_attr.c
> +++ b/drivers/scsi/qla2xxx/qla_attr.c
> @@ -1850,9 +1850,6 @@ qla2x00_port_speed_show(struct device *dev,
> struct device_attribute *attr,
> return -EINVAL;
> }
>
> - ql_log(ql_log_info, vha, 0x70d6,
> - "port speed:%d\n", ha->link_data_rate);
> -
> return scnprintf(buf, PAGE_SIZE, "%s\n", spd[ha-
> >link_data_rate]);
> }
>
Looks good for me, and fixes an issue we dealt with last week.
In other words confusing log noise for customers.
Reviewed-by: Laurence Oberman <loberman@redhat.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs
2020-05-04 17:54 [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs Ewan D. Milne
2020-05-04 18:00 ` Laurence Oberman
@ 2020-05-04 19:07 ` himanshu.madhani
2020-05-05 15:30 ` Lee Duncan
2020-05-08 1:16 ` Martin K. Petersen
3 siblings, 0 replies; 5+ messages in thread
From: himanshu.madhani @ 2020-05-04 19:07 UTC (permalink / raw)
To: Ewan D. Milne, linux-scsi; +Cc: stable, njavali
On 5/4/20 12:54 PM, Ewan D. Milne wrote:
> Calling ql_log() inside qla2x00_port_speed_show() is causing messages
> to be output to the console for no particularly good reason. The sysfs
> read routine should just return the information to userspace. The only
> reason to log a message is when the port speed actually changes, and
> this already occurs elsewhere.
>
> Cc: <stable@vger.kernel.org> # v5.1+
> Fixes: 4910b524ac9 ("scsi: qla2xxx: Add support for setting port speed")
> Signed-off-by: Ewan D. Milne <emilne@redhat.com>
> ---
> drivers/scsi/qla2xxx/qla_attr.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
> index 3325596..2c9e5ac 100644
> --- a/drivers/scsi/qla2xxx/qla_attr.c
> +++ b/drivers/scsi/qla2xxx/qla_attr.c
> @@ -1850,9 +1850,6 @@ qla2x00_port_speed_show(struct device *dev, struct device_attribute *attr,
> return -EINVAL;
> }
>
> - ql_log(ql_log_info, vha, 0x70d6,
> - "port speed:%d\n", ha->link_data_rate);
> -
> return scnprintf(buf, PAGE_SIZE, "%s\n", spd[ha->link_data_rate]);
> }
>
>
Looks Good.
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
--
Himanshu Madhani
Oracle Linux Engineering
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs
2020-05-04 17:54 [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs Ewan D. Milne
2020-05-04 18:00 ` Laurence Oberman
2020-05-04 19:07 ` himanshu.madhani
@ 2020-05-05 15:30 ` Lee Duncan
2020-05-08 1:16 ` Martin K. Petersen
3 siblings, 0 replies; 5+ messages in thread
From: Lee Duncan @ 2020-05-05 15:30 UTC (permalink / raw)
To: Ewan D. Milne, linux-scsi; +Cc: stable, njavali, himanshu.madhani
On 5/4/20 10:54 AM, Ewan D. Milne wrote:
> Calling ql_log() inside qla2x00_port_speed_show() is causing messages
> to be output to the console for no particularly good reason. The sysfs
> read routine should just return the information to userspace. The only
> reason to log a message is when the port speed actually changes, and
> this already occurs elsewhere.
>
> Cc: <stable@vger.kernel.org> # v5.1+
> Fixes: 4910b524ac9 ("scsi: qla2xxx: Add support for setting port speed")
> Signed-off-by: Ewan D. Milne <emilne@redhat.com>
> ---
> drivers/scsi/qla2xxx/qla_attr.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/scsi/qla2xxx/qla_attr.c b/drivers/scsi/qla2xxx/qla_attr.c
> index 3325596..2c9e5ac 100644
> --- a/drivers/scsi/qla2xxx/qla_attr.c
> +++ b/drivers/scsi/qla2xxx/qla_attr.c
> @@ -1850,9 +1850,6 @@ qla2x00_port_speed_show(struct device *dev, struct device_attribute *attr,
> return -EINVAL;
> }
>
> - ql_log(ql_log_info, vha, 0x70d6,
> - "port speed:%d\n", ha->link_data_rate);
> -
> return scnprintf(buf, PAGE_SIZE, "%s\n", spd[ha->link_data_rate]);
> }
>
>
Reviewed-by: Lee Duncan <lduncan@suse.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs
2020-05-04 17:54 [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs Ewan D. Milne
` (2 preceding siblings ...)
2020-05-05 15:30 ` Lee Duncan
@ 2020-05-08 1:16 ` Martin K. Petersen
3 siblings, 0 replies; 5+ messages in thread
From: Martin K. Petersen @ 2020-05-08 1:16 UTC (permalink / raw)
To: linux-scsi, Ewan D. Milne
Cc: Martin K . Petersen, stable, himanshu.madhani, njavali
On Mon, 4 May 2020 13:54:16 -0400, Ewan D. Milne wrote:
> Calling ql_log() inside qla2x00_port_speed_show() is causing messages
> to be output to the console for no particularly good reason. The sysfs
> read routine should just return the information to userspace. The only
> reason to log a message is when the port speed actually changes, and
> this already occurs elsewhere.
Applied to 5.7/scsi-queue, thanks!
[1/1] scsi: qla2xxx: Do not log message when reading port speed via sysfs
https://git.kernel.org/mkp/scsi/c/0f3b2f3fb5dc
--
Martin K. Petersen Oracle Linux Engineering
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-05-08 1:19 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-04 17:54 [PATCH] scsi: qla2xxx: Do not log message when reading port speed via sysfs Ewan D. Milne
2020-05-04 18:00 ` Laurence Oberman
2020-05-04 19:07 ` himanshu.madhani
2020-05-05 15:30 ` Lee Duncan
2020-05-08 1:16 ` Martin K. Petersen
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).