Skip to contentSkip to conversation

staging: hp100: Add spaces in if statement.

PATCH Superseded Soumyajit Deb 2 participants 2 messages Mar 25, 2020 Staging

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: hp100: Add spaces in if statement.

Add space between if and open parenthesis "(" in if statement to improve code readability and to adhere to the standard linux kernel coding style. Also, shift the next line to the right by a single space as it is the continuation of the above if statement.

---
 drivers/staging/hp/hp100.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/hp/hp100.c +2 -2
index 16fe9c7879cf..926d0b51ddb2 100644
@@ -556,8 +556,8 @@ static int hp100_probe1(struct net_device *dev, int ioaddr, u_char bus,
 			 * can map the full 32bit address space.
 			 * Also, we can have EISA Busmaster cards (not tested),
 			 * so beware !!! - Jean II */
-			if((bus == HP100_BUS_PCI) &&
-			   (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(32)))) {
+			if ((bus == HP100_BUS_PCI) &&
+			    (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(32)))) {
 				/* Gracefully fallback to shared memory */
 				goto busmasterfail;
 			}
Signature · 1 line
2.17.1
#1 lore raw
Quoted 4 lines · Soumyajit Deb

Add space between if and open parenthesis "(" in if statement to improve code readability and to adhere to the standard linux kernel coding style. Also, shift the next line to the right by a single space as it is the continuation of the above if statement.

The beginning of the log message seems to say the same thing twice. I think that you can drop ""(" in if statement".

julia

Quoted 29 lines
---
 drivers/staging/hp/hp100.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/hp/hp100.c +2 -3
index 16fe9c7879cf..926d0b51ddb2 100644
@@ -556,8 +556,8 @@ static int hp100_probe1(struct net_device *dev, int ioaddr, u_char bus,
 			 * can map the full 32bit address space.
 			 * Also, we can have EISA Busmaster cards (not tested),
 			 * so beware !!! - Jean II */
-			if((bus == HP100_BUS_PCI) &&
-			   (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(32)))) {
+			if ((bus == HP100_BUS_PCI) &&
+			    (pci_set_dma_mask(pci_dev, DMA_BIT_MASK(32)))) {
 				/* Gracefully fallback to shared memory */
 				goto busmasterfail;
 			}
--

2.17.1

--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20200325094951.33508-1-debsoumyajit100%40gmail.com.