checkpatch false positive for "do not use assignment in if condition"
From: Ethan Nelson-Moore
Date: Sat May 09 2026 - 17:54:03 EST
Hello,
I got a strange error from checkpatch while preparing this patch for submission:
https://lore.kernel.org/all/20260509214622.38319-1-enelsonmoore@xxxxxxxxx/
ERROR: do not use assignment in if condition
#37: FILE: sound/soc/fsl/eukrea-tlv320.c:145:
+ if (of_machine_is_compatible("eukrea,cpuimx27") ||
ERROR: do not use assignment in if condition
#48: FILE: sound/soc/fsl/eukrea-tlv320.c:162:
+ } else if (of_machine_is_compatible("eukrea,cpuimx25") ||
These lines do not even contain =.
Could someone look into why this happened?
Have a nice day!
Ethan