Skip to contentSkip to conversation

checkpatch.pl false positive: FSF mailing address

DISCUSSION Brian Norris 2 participants 6 messages Mar 10, 2016 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

Hi Joe,

I found this false positive amusing:

$ curl http://patchwork.ozlabs.org/patch/577786/mbox/ | scripts/checkpatch.pl -
[...]
ERROR: Do not include the paragraph about writing to the Free Software
Foundation's mailing address from the sample GPL notice. The FSF has
changed addresses in the past, and may do so again. Linux already
includes a copy of the GPL.
#1489: FILE: drivers/mtd/nand/qcom_nandc.c:1335:
+^I^I * write to the free oob area.$
[...]

The patch is:
http://patchwork.ozlabs.org/patch/577786/
[PATCH v8,2/3] mtd: nand: Qualcomm NAND controller driver

and the comment text is:

"For the last codeword, we skip the bbm positions and write to the free oob area."

which matches on this:

# Check for FSF mailing addresses.

                if ($rawline =~ /\bwrite to the Free/i ||

I'm just writing as recommended by the closing text of your tool.

Regards,
Brian

#1 lore raw
Quoted 1 line · Brian Norris

Hi Joe,

Hi Brian.

Quoted 21 lines

I found this false positive amusing:

$ curl http://patchwork.ozlabs.org/patch/577786/mbox/ | scripts/checkpatch.pl -
[...]
ERROR: Do not include the paragraph about writing to the Free Software
Foundation's mailing address from the sample GPL notice. The FSF has
changed addresses in the past, and may do so again. Linux already
includes a copy of the GPL.
#1489: FILE: drivers/mtd/nand/qcom_nandc.c:1335:
+^I^I * write to the free oob area.$
[...]

The patch is:
  http://patchwork.ozlabs.org/patch/577786/
  [PATCH v8,2/3] mtd: nand: Qualcomm NAND controller driver

and the comment text is:

  "For the last codeword, we skip the bbm positions and write to the free oob area."

Quoted 6 lines

which matches on this:

# Check for FSF mailing addresses.
                if ($rawline =~ /\bwrite to the Free/i ||

I'm just writing as recommended by the closing text of your tool.

Thanks.

Yeah, it's amusing.  It's also likely not something worth bothering with though as the likelihood of fixing it is low and eventually the FSF warning will be minimized or removed as no longer necessary.

checkpatch is stupid, false positives will always exist.

cheers, Joe

#2 lore raw
Quoted 31 lines · Joe Perches
Quoted 1 line · Brian Norris

Hi Joe,

Hi Brian.

Quoted 26 lines

I found this false positive amusing:

$ curl http://patchwork.ozlabs.org/patch/577786/mbox/ | scripts/checkpatch.pl -
[...]
ERROR: Do not include the paragraph about writing to the Free Software
Foundation's mailing address from the sample GPL notice. The FSF has
changed addresses in the past, and may do so again. Linux already
includes a copy of the GPL.
#1489: FILE: drivers/mtd/nand/qcom_nandc.c:1335:
+^I^I * write to the free oob area.$
[...]

The patch is:
http://patchwork.ozlabs.org/patch/577786/
[PATCH v8,2/3] mtd: nand: Qualcomm NAND controller driver

and the comment text is:

"For the last codeword, we skip the bbm positions and write to the free oob area."

which matches on this:

# Check for FSF mailing addresses.

                if ($rawline =~ /\bwrite to the Free/i ||
Quoted 8 lines
Quoted 1 line

I'm just writing as recommended by the closing text of your tool.

Thanks.

Yeah, it's amusing. It's also likely not something worth bothering with though as the likelihood of fixing it is low and eventually the FSF warning will be minimized or removed as no longer necessary.

An easy improvement: don't use "ignore case" for the regex.

Quoted 1 line

checkpatch is stupid, false positives will always exist.

Regards,
Brian

#3 lore raw
Quoted 1 line · Brian Norris

On Thu, Mar 10, 2016 at 11:08 AM, Joe Perches <[email protected]> wrote:

Hey again Brian.

Quoted 5 lines
Quoted 4 lines

Yeah, it's amusing.  It's also likely not something worth bothering with though as the likelihood of fixing it is low and eventually the FSF warning will be minimized or removed as no longer necessary.

An easy improvement: don't use "ignore case" for the regex.

Maybe, but:

drivers/pcmcia/bfin_cf_pcmcia.c: * if not, write to the free software foundation,

Of course there's only one of those too.

Mostly, it's a "I just don't care very much" warning.

If you care enough to submit a patch removing the "/i" from the regex, please do and cc Andrew Morton too.

Quoted 1 line
Quoted 1 line

checkpatch is stupid, false positives will always exist.

I'd almost rather have people understand this.

#4 lore raw
Quoted 13 lines · Joe Perches
Quoted 1 line · Brian Norris

On Thu, Mar 10, 2016 at 11:08 AM, Joe Perches <[email protected]> wrote:

Hey again Brian.

Quoted 5 lines
Quoted 4 lines

Yeah, it's amusing.  It's also likely not something worth bothering with though as the likelihood of fixing it is low and eventually the FSF warning will be minimized or removed as no longer necessary.

An easy improvement: don't use "ignore case" for the regex.

Maybe, but:

Quoted 8 lines

drivers/pcmcia/bfin_cf_pcmcia.c: * if not, write to the free software foundation,

Of course there's only one of those too.

Mostly, it's a "I just don't care very much" warning.

If you care enough to submit a patch removing the "/i" from the regex, please do and cc Andrew Morton too.

Maybe I will.

Quoted 3 lines
Quoted 1 line
Quoted 1 line

checkpatch is stupid, false positives will always exist.

I'd almost rather have people understand this.

Then perhaps I'll also patch this note out:

NOTE: If any of the errors are false positives, please report
them to the maintainer, see CHECKPATCH in MAINTAINERS.

Regards,
Brian

#5 lore raw
Quoted 9 lines · Brian Norris
Quoted 4 lines · Joe Perches
Quoted 2 lines · Brian Norris
Quoted 1 line · Joe Perches

checkpatch is stupid, false positives will always exist.

I'd almost rather have people understand this.

Then perhaps I'll also patch this note out:

NOTE: If any of the errors are false positives, please report them to the maintainer, see CHECKPATCH in MAINTAINERS.

Maybe add: "but remember, CHECKPATCH is stupid, you're not".