Message ID | 20200331225708.52822-1-michelesr@autistici.org (mailing list archive) |
---|---|
State | Rejected |
Headers | show |
Series | drivers/hwmon/dell-smm-hwmon.c: fix blank line | expand |
On 4/1/20 12:02 AM, Pali Rohár wrote: > Hello! I'm fine with any coding style which is consistent. With or also > without this blank line. So if Jean and Guenter as subsystem maintainers > want this change I'm fine with it too and in this case you can add my > Acked-by: Pali Rohár <pali@kernel.org> I'm just wandering why this warnings are appearing? WARNING: Missing a blank line after declarations #122: FILE: drivers/hwmon/dell-smm-hwmon.c:122: + unsigned int eax; + unsigned int ebx __packed; WARNING: Missing a blank line after declarations #123: FILE: drivers/hwmon/dell-smm-hwmon.c:123: + unsigned int ebx __packed; + unsigned int ecx __packed; WARNING: Missing a blank line after declarations #124: FILE: drivers/hwmon/dell-smm-hwmon.c:124: + unsigned int ecx __packed; + unsigned int edx __packed; WARNING: Missing a blank line after declarations #125: FILE: drivers/hwmon/dell-smm-hwmon.c:125: + unsigned int edx __packed; + unsigned int esi __packed; WARNING: Missing a blank line after declarations #126: FILE: drivers/hwmon/dell-smm-hwmon.c:126: + unsigned int esi __packed; + unsigned int edi __packed; They definitely look false positives, so maybe this behavior should be reported to the maintainers of the checkpatch.pl script?
On 3/31/20 4:02 PM, Pali Rohár wrote: > On Tuesday 31 March 2020 23:57:08 Michele Sorcinelli wrote: >> Fix missing blank line after declaration: reported by checkpatch.pl >> >> There are other missing blank lines reported in the declaration of >> struct smm_regs fields (line 120) but they are probably false positives >> so I don't think they need to be changed. >> >> Signed-off-by: Michele Sorcinelli <michelesr@autistici.org> > > Hello! I'm fine with any coding style which is consistent. With or also > without this blank line. So if Jean and Guenter as subsystem maintainers > want this change I'm fine with it too and in this case you can add my > Acked-by: Pali Rohár <pali@kernel.org> I'll have to think about it. I don't mind cleanup patches as part of a patch series that actually improves something, but standalone patches like this are pretty much pointless and only a source of future failed backports (and, yes, my thinking on this has evolved over time). Guenter > >> --- >> drivers/hwmon/dell-smm-hwmon.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/hwmon/dell-smm-hwmon.c b/drivers/hwmon/dell-smm-hwmon.c >> index ab719d372b0d..7b61b613aff6 100644 >> --- a/drivers/hwmon/dell-smm-hwmon.c >> +++ b/drivers/hwmon/dell-smm-hwmon.c >> @@ -1276,6 +1276,7 @@ static int __init i8k_probe(void) >> id = dmi_first_match(i8k_dmi_table); >> if (id && id->driver_data) { >> const struct i8k_config_data *conf = id->driver_data; >> + >> if (!fan_mult && conf->fan_mult) >> fan_mult = conf->fan_mult; >> if (!fan_max && conf->fan_max) >> -- >> 2.26.0 >>
diff --git a/drivers/hwmon/dell-smm-hwmon.c b/drivers/hwmon/dell-smm-hwmon.c index ab719d372b0d..7b61b613aff6 100644 --- a/drivers/hwmon/dell-smm-hwmon.c +++ b/drivers/hwmon/dell-smm-hwmon.c @@ -1276,6 +1276,7 @@ static int __init i8k_probe(void) id = dmi_first_match(i8k_dmi_table); if (id && id->driver_data) { const struct i8k_config_data *conf = id->driver_data; + if (!fan_mult && conf->fan_mult) fan_mult = conf->fan_mult; if (!fan_max && conf->fan_max)
Fix missing blank line after declaration: reported by checkpatch.pl There are other missing blank lines reported in the declaration of struct smm_regs fields (line 120) but they are probably false positives so I don't think they need to be changed. Signed-off-by: Michele Sorcinelli <michelesr@autistici.org> --- drivers/hwmon/dell-smm-hwmon.c | 1 + 1 file changed, 1 insertion(+)