Skip to contentSkip to conversation

scsi: aic7xxx: Adjust indentation in ahc_find_syncrate

PATCH Applied Nathan Chancellor 2 participants 2 messages Dec 18, 2019 – Dec 19, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scsi: aic7xxx: Adjust indentation in ahc_find_syncrate

Clang warns:

../drivers/scsi/aic7xxx/aic7xxx_core.c:2317:5: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]

                        if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
                        ^
../drivers/scsi/aic7xxx/aic7xxx_core.c:2310:4: note: previous statement
is here
                        if (syncrate == &ahc_syncrates[maxsync])
                        ^

1 warning generated.

This warning occurs because there is a space amongst the tabs on this line. Remove it so that the indentation is consistent with the Linux kernel coding style and clang no longer warns.

This has been a problem since the beginning of git history hence no fixes tag.

---
 drivers/scsi/aic7xxx/aic7xxx_core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/scsi/aic7xxx/aic7xxx_core.c +1 -1
index a9d40d3b90ef..4190a025381a 100644
@@ -2314,7 +2314,7 @@ ahc_find_syncrate(struct ahc_softc *ahc, u_int *period,
 			 * At some speeds, we only support
 			 * ST transfers.
 			 */
-		 	if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
+			if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
 				*ppr_options &= ~MSG_EXT_PPR_DT_REQ;
 			break;
 		}
Signature · 1 line
2.24.1
#1 lore raw

Nathan,

Quoted 8 lines

Clang warns:

../drivers/scsi/aic7xxx/aic7xxx_core.c:2317:5: warning: misleading indentation; statement is not part of the previous 'if' [-Wmisleading-indentation]

                        if ((syncrate->sxfr_u2 & ST_SXFR) != 0)
                        ^

../drivers/scsi/aic7xxx/aic7xxx_core.c:2310:4: note: previous statement

Applied to 5.6/scsi-queue, thanks!

Signature · 1 line
Martin K. Petersen	Oracle Linux Engineering