All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] PCI: cpqphp: Format if-statement code block correctly
@ 2021-10-13  1:14 Krzysztof Wilczyński
  2021-10-13  1:27 ` Krzysztof Wilczyński
  2021-10-13  1:50 ` Bjorn Helgaas
  0 siblings, 2 replies; 3+ messages in thread
From: Krzysztof Wilczyński @ 2021-10-13  1:14 UTC (permalink / raw)
  To: Bjorn Helgaas; +Cc: linux-pci

The if-statement code block as seen in the cpqhp_s

The code block related to the if-statement in cpqhp_set_irq() is
somewhat awkwardly formatted making the code hard to read.

Thus, update the code to match preferred code formatting style.

No change to functionality intended.

Signed-off-by: Krzysztof Wilczyński <kw@linux.com>
---
 drivers/pci/hotplug/cpqphp_pci.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c
index 1b2b3f3b648b..9038039ad6db 100644
--- a/drivers/pci/hotplug/cpqphp_pci.c
+++ b/drivers/pci/hotplug/cpqphp_pci.c
@@ -189,8 +189,10 @@ int cpqhp_set_irq(u8 bus_num, u8 dev_num, u8 int_pin, u8 irq_num)
 		/* This should only be for x86 as it sets the Edge Level
 		 * Control Register
 		 */
-		outb((u8) (temp_word & 0xFF), 0x4d0); outb((u8) ((temp_word &
-		0xFF00) >> 8), 0x4d1); rc = 0; }
+		outb((u8)(temp_word & 0xFF), 0x4d0);
+		outb((u8)((temp_word & 0xFF00) >> 8), 0x4d1);
+		rc = 0;
+	}
 
 	return rc;
 }
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] PCI: cpqphp: Format if-statement code block correctly
  2021-10-13  1:14 [PATCH] PCI: cpqphp: Format if-statement code block correctly Krzysztof Wilczyński
@ 2021-10-13  1:27 ` Krzysztof Wilczyński
  2021-10-13  1:50 ` Bjorn Helgaas
  1 sibling, 0 replies; 3+ messages in thread
From: Krzysztof Wilczyński @ 2021-10-13  1:27 UTC (permalink / raw)
  To: Bjorn Helgaas; +Cc: linux-pci

Hi Bjorn,

> The if-statement code block as seen in the cpqhp_s

This incomplete sentence above should be removed from the commit message.

Looks like I must have accidentally undo previous edit before sending the
patch through.  Apologies!

> The code block related to the if-statement in cpqhp_set_irq() is
> somewhat awkwardly formatted making the code hard to read.
> 
> Thus, update the code to match preferred code formatting style.
> 
> No change to functionality intended.

	Krzysztof

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] PCI: cpqphp: Format if-statement code block correctly
  2021-10-13  1:14 [PATCH] PCI: cpqphp: Format if-statement code block correctly Krzysztof Wilczyński
  2021-10-13  1:27 ` Krzysztof Wilczyński
@ 2021-10-13  1:50 ` Bjorn Helgaas
  1 sibling, 0 replies; 3+ messages in thread
From: Bjorn Helgaas @ 2021-10-13  1:50 UTC (permalink / raw)
  To: Krzysztof Wilczyński; +Cc: Bjorn Helgaas, linux-pci

On Wed, Oct 13, 2021 at 01:14:12AM +0000, Krzysztof Wilczyński wrote:
> The if-statement code block as seen in the cpqhp_s
> 
> The code block related to the if-statement in cpqhp_set_irq() is
> somewhat awkwardly formatted making the code hard to read.
> 
> Thus, update the code to match preferred code formatting style.
> 
> No change to functionality intended.
> 
> Signed-off-by: Krzysztof Wilczyński <kw@linux.com>
> ---
>  drivers/pci/hotplug/cpqphp_pci.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)

Applied with the commit log touchup to pci/misc for v5.16, thanks!

Looks like somebody's "J" key got stuck in vi :)

> diff --git a/drivers/pci/hotplug/cpqphp_pci.c b/drivers/pci/hotplug/cpqphp_pci.c
> index 1b2b3f3b648b..9038039ad6db 100644
> --- a/drivers/pci/hotplug/cpqphp_pci.c
> +++ b/drivers/pci/hotplug/cpqphp_pci.c
> @@ -189,8 +189,10 @@ int cpqhp_set_irq(u8 bus_num, u8 dev_num, u8 int_pin, u8 irq_num)
>  		/* This should only be for x86 as it sets the Edge Level
>  		 * Control Register
>  		 */
> -		outb((u8) (temp_word & 0xFF), 0x4d0); outb((u8) ((temp_word &
> -		0xFF00) >> 8), 0x4d1); rc = 0; }
> +		outb((u8)(temp_word & 0xFF), 0x4d0);
> +		outb((u8)((temp_word & 0xFF00) >> 8), 0x4d1);
> +		rc = 0;
> +	}
>  
>  	return rc;
>  }
> -- 
> 2.33.0
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-13  1:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-13  1:14 [PATCH] PCI: cpqphp: Format if-statement code block correctly Krzysztof Wilczyński
2021-10-13  1:27 ` Krzysztof Wilczyński
2021-10-13  1:50 ` Bjorn Helgaas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.