* [PATCH] serial: icom: fix inconsistent indenting warning
@ 2025-03-05 8:37 Charles Han
2025-03-05 8:45 ` Jiri Slaby
2025-03-05 9:51 ` [PATCH v2] serial: icom: fix code format problems Charles Han
0 siblings, 2 replies; 3+ messages in thread
From: Charles Han @ 2025-03-05 8:37 UTC (permalink / raw)
To: gregkh, jirislaby; +Cc: linux-kernel, linux-serial, Charles Han
Fix below inconsistent indenting smatch warning.
smatch warnings:
drivers/tty/serial/icom.c:1768 icom_probe() warn: inconsistent indenting
Signed-off-by: Charles Han <hanchunchao@inspur.com>
---
drivers/tty/serial/icom.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/tty/serial/icom.c b/drivers/tty/serial/icom.c
index 29e42831df39..6779d8ea1487 100644
--- a/drivers/tty/serial/icom.c
+++ b/drivers/tty/serial/icom.c
@@ -1764,11 +1764,11 @@ static int icom_probe(struct pci_dev *dev,
goto probe_exit1;
}
- /* save off irq and request irq line */
- retval = request_irq(dev->irq, icom_interrupt, IRQF_SHARED, ICOM_DRIVER_NAME, (void *)icom_adapter);
- if (retval) {
- goto probe_exit2;
- }
+ /* save off irq and request irq line */
+ retval = request_irq(dev->irq, icom_interrupt,
+ IRQF_SHARED, ICOM_DRIVER_NAME, (void *)icom_adapter);
+ if (retval)
+ goto probe_exit2;
retval = icom_load_ports(icom_adapter);
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] serial: icom: fix inconsistent indenting warning
2025-03-05 8:37 [PATCH] serial: icom: fix inconsistent indenting warning Charles Han
@ 2025-03-05 8:45 ` Jiri Slaby
2025-03-05 9:51 ` [PATCH v2] serial: icom: fix code format problems Charles Han
1 sibling, 0 replies; 3+ messages in thread
From: Jiri Slaby @ 2025-03-05 8:45 UTC (permalink / raw)
To: Charles Han, gregkh; +Cc: linux-kernel, linux-serial
On 05. 03. 25, 9:37, Charles Han wrote:
> Fix below inconsistent indenting smatch warning.
> smatch warnings:
> drivers/tty/serial/icom.c:1768 icom_probe() warn: inconsistent indenting
>
> Signed-off-by: Charles Han <hanchunchao@inspur.com>
> ---
> drivers/tty/serial/icom.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/tty/serial/icom.c b/drivers/tty/serial/icom.c
> index 29e42831df39..6779d8ea1487 100644
> --- a/drivers/tty/serial/icom.c
> +++ b/drivers/tty/serial/icom.c
> @@ -1764,11 +1764,11 @@ static int icom_probe(struct pci_dev *dev,
> goto probe_exit1;
> }
>
> - /* save off irq and request irq line */
> - retval = request_irq(dev->irq, icom_interrupt, IRQF_SHARED, ICOM_DRIVER_NAME, (void *)icom_adapter);
> - if (retval) {
> - goto probe_exit2;
> - }
> + /* save off irq and request irq line */
> + retval = request_irq(dev->irq, icom_interrupt,
> + IRQF_SHARED, ICOM_DRIVER_NAME, (void *)icom_adapter);
In fact, if you removed that useless (void *) too, the code would fit on
a single 100c line.
> + if (retval)
> + goto probe_exit2;
You removed also { and }. That has nothing to do with the $SUBJECT or
commit log.
thanks,
--
js
suse labs
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH v2] serial: icom: fix code format problems
2025-03-05 8:37 [PATCH] serial: icom: fix inconsistent indenting warning Charles Han
2025-03-05 8:45 ` Jiri Slaby
@ 2025-03-05 9:51 ` Charles Han
1 sibling, 0 replies; 3+ messages in thread
From: Charles Han @ 2025-03-05 9:51 UTC (permalink / raw)
To: gregkh, jirislaby; +Cc: linux-kernel, linux-serial, Charles Han
Fix below inconsistent indenting smatch warning.
smatch warnings:
drivers/tty/serial/icom.c:1768 icom_probe() warn: inconsistent indenting
Removed that useless (void *), the code would fit on a single 100c line
Removed '{' and '}'.
Signed-off-by: Charles Han <hanchunchao@inspur.com>
---
drivers/tty/serial/icom.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/drivers/tty/serial/icom.c b/drivers/tty/serial/icom.c
index 29e42831df39..7fb995a8490e 100644
--- a/drivers/tty/serial/icom.c
+++ b/drivers/tty/serial/icom.c
@@ -1764,11 +1764,10 @@ static int icom_probe(struct pci_dev *dev,
goto probe_exit1;
}
- /* save off irq and request irq line */
- retval = request_irq(dev->irq, icom_interrupt, IRQF_SHARED, ICOM_DRIVER_NAME, (void *)icom_adapter);
- if (retval) {
- goto probe_exit2;
- }
+ /* save off irq and request irq line */
+ retval = request_irq(dev->irq, icom_interrupt, IRQF_SHARED, ICOM_DRIVER_NAME, icom_adapter);
+ if (retval)
+ goto probe_exit2;
retval = icom_load_ports(icom_adapter);
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-03-05 9:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-05 8:37 [PATCH] serial: icom: fix inconsistent indenting warning Charles Han
2025-03-05 8:45 ` Jiri Slaby
2025-03-05 9:51 ` [PATCH v2] serial: icom: fix code format problems Charles Han
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®