* [PATCH] checkpatch: look for common misspellings
@ 2014-08-21 16:20 Kees Cook
2014-08-21 17:18 ` Joe Perches
0 siblings, 1 reply; 8+ messages in thread
From: Kees Cook @ 2014-08-21 16:20 UTC (permalink / raw)
To: linux-kernel
Cc: Andy Whitcroft, Joe Perches, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari
Check for misspellings, based on Debian's lintian list. Several false
positives were removed, and several additional words added that were
common in the kernel:
backword backwords
invalide valide
recieves
singed unsinged
While going back and fixing existing spelling mistakes isn't a high
priority, it'd be nice to try to catch them before they hit the tree.
Between 3.15 and 3.16-rc7, the script would have noticed the following 46
mistakes:
6 prefered
6 endianess
5 recieve
4 changable
3 sytem
3 synchonized
3 splitted
3 informations
2 unconditionaly
2 sucessfully
2 seperate
2 recieved
2 preceeding
2 paramters
2 managment
2 fuction
2 accesing
1 writting
1 targetting
1 syncronize
1 supress
1 succesful
1 specifed
1 serveral
1 repectively
1 registerd
1 paramter
1 overriden
1 neccessary
1 lenght
1 intial
1 initalize
1 dependant
1 dependancy
1 correspoding
1 correponds
1 contraints
1 compatibilty
1 childs
1 begining
1 becomming
1 bandwith
1 availble
1 amoung
1 alot
1 addreses
For additional context, here are the top 15 spelling mistakes in the entire
tree:
131 informations
96 ressize
80 prefered
68 endianess
61 transfered
60 childs
59 overriden
55 treshold
46 capabilites
40 splitted
39 commited
33 continous
31 ouput
29 lenght
29 explicitely
Signed-off-by: Kees Cook <keescook@chromium.org>
---
MAINTAINERS | 1 +
scripts/checkpatch.pl | 37 +++-
scripts/spelling.txt | 595 ++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 632 insertions(+), 1 deletion(-)
create mode 100644 scripts/spelling.txt
diff --git a/MAINTAINERS b/MAINTAINERS
index aefa94841ff3..b20d7bde5403 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2311,6 +2311,7 @@ M: Andy Whitcroft <apw@canonical.com>
M: Joe Perches <joe@perches.com>
S: Maintained
F: scripts/checkpatch.pl
+F: scripts/spelling.txt
CHINESE DOCUMENTATION
M: Harry Wei <harryxiyou@gmail.com>
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 31a731e06f50..8a338e2a5a59 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -9,7 +9,8 @@ use strict;
use POSIX;
my $P = $0;
-$P =~ s@.*/@@g;
+$P =~ s@(.*)/@@g;
+my $D = $1;
my $V = '0.32';
@@ -43,6 +44,7 @@ my $configuration_file = ".checkpatch.conf";
my $max_line_length = 80;
my $ignore_perl_version = 0;
my $minimum_perl_version = 5.10.0;
+my $spelling_file = "$D/spelling.txt";
sub help {
my ($exitcode) = @_;
@@ -429,6 +431,32 @@ our $allowed_asm_includes = qr{(?x:
)};
# memory.h: ARM has a custom one
+# Load common spelling mistakes and build regular expression list.
+my $spelling_re;
+my @spelling_list;
+my %spelling_fix;
+open(my $spelling, '<', $spelling_file)
+ or die "$P: Can't open $spelling_file for reading: $!\n";
+while (<$spelling>) {
+ my $line = $_;
+
+ $line =~ s/\s*\n?$//g;
+ $line =~ s/^\s*//g;
+
+ next if ($line =~ m/^\s*#/);
+ next if ($line =~ m/^\s*$/);
+
+ my ($suspect, $fix) = split(/\|\|/, $line);
+
+ push(@spelling_list, $suspect);
+ $spelling_fix{$suspect} = $fix;
+}
+close($spelling);
+# $edge can't be "\b" because that includes things like "_". And we should
+# not treat "@" as a boundary so we don't trip on email addresses.
+my $edge = "[^[:alpha:]@]";
+$spelling_re = "(?:^|$edge)(" . join("|", @spelling_list) . ")(?:\$|$edge)";
+
sub build_types {
my $mods = "(?x: \n" . join("|\n ", @modifierList) . "\n)";
my $all = "(?x: \n" . join("|\n ", @typeList) . "\n)";
@@ -5048,6 +5076,13 @@ sub process {
}
}
}
+
+# Check for several spelling mistakes.
+ if ($rawline =~ $spelling_re) {
+ my $typo = "The word '$1' may be misspelled";
+ $typo .= " (perhaps you want '$spelling_fix{$1}'?)\n";
+ WARN("TYPO_SPELLING", $typo . $herecurr);
+ }
}
# If we have no input at all, then there is nothing to report on
diff --git a/scripts/spelling.txt b/scripts/spelling.txt
new file mode 100644
index 000000000000..03c6234464ee
--- /dev/null
+++ b/scripts/spelling.txt
@@ -0,0 +1,595 @@
+# Originally from Debian's Lintian tool. Various false positives have been
+# removed, and various additions have been made as they've been discovered
+# in the kernel source.
+#
+# License: GPLv2
+#
+# The format of each line is:
+# mistake||correction
+#
+abandonning||abandoning
+abigious||ambiguous
+abitrate||arbitrate
+abov||above
+absense||absence
+absolut||absolute
+absoulte||absolute
+acceleratoin||acceleration
+accelleration||acceleration
+accesing||accessing
+accesnt||accent
+accessable||accessible
+accesss||access
+accidentaly||accidentally
+accidentually||accidentally
+accomodate||accommodate
+accomodates||accommodates
+accout||account
+acessable||accessible
+acess||access
+acient||ancient
+acknowldegement||acknowldegement
+ackowledge||acknowledge
+ackowledged||acknowledged
+acording||according
+activete||activate
+acumulating||accumulating
+addional||additional
+additionaly||additionally
+addreses||addresses
+aditional||additional
+aditionally||additionally
+aditionaly||additionally
+adress||address
+adresses||addresses
+adviced||advised
+afecting||affecting
+albumns||albums
+alegorical||allegorical
+algorith||algorithm
+algorithmical||algorithmically
+algoritm||algorithm
+algoritms||algorithms
+algorrithm||algorithm
+algorritm||algorithm
+allpication||application
+alogirhtms||algorithms
+alot||a lot
+alow||allow
+alows||allows
+altough||although
+ambigious||ambiguous
+amoung||among
+amout||amount
+analysator||analyzer
+ang||and
+anniversery||anniversary
+annoucement||announcement
+anomolies||anomalies
+anomoly||anomaly
+aplication||application
+appearence||appearance
+appliction||application
+applictions||applications
+appropiate||appropriate
+appropriatly||appropriately
+aquired||acquired
+arbitary||arbitrary
+architechture||architecture
+arguement||argument
+arguements||arguments
+aritmetic||arithmetic
+arne't||aren't
+arraival||arrival
+artifical||artificial
+artillary||artillery
+assigment||assignment
+assigments||assignments
+assistent||assistant
+asuming||assuming
+asycronous||asynchronous
+atomatically||automatically
+attachement||attachment
+attemps||attempts
+attruibutes||attributes
+authentification||authentication
+automaticaly||automatically
+automaticly||automatically
+automatize||automate
+automatized||automated
+automatizes||automates
+autonymous||autonomous
+auxilliary||auxiliary
+avaiable||available
+availabled||available
+availablity||availability
+availale||available
+availavility||availability
+availble||available
+availble||available
+availiable||available
+avaliable||available
+avaliable||available
+backgroud||background
+backword||backward
+backwords||backwards
+bahavior||behavior
+baloon||balloon
+baloons||balloons
+bandwith||bandwidth
+batery||battery
+becomming||becoming
+becuase||because
+begining||beginning
+bianries||binaries
+calender||calendar
+cancelation||cancellation
+capabilites||capabilities
+capatibilities||capabilities
+cariage||carriage
+challange||challenge
+challanges||challenges
+changable||changeable
+charachter||character
+charachters||characters
+charater||character
+charaters||characters
+charcter||character
+childs||children
+chnage||change
+chnages||changes
+choosen||chosen
+collapsable||collapsible
+colorfull||colorful
+comand||command
+comit||commit
+commerical||commercial
+comminucation||communication
+commited||committed
+commiting||committing
+committ||commit
+commoditiy||commodity
+compability||compatibility
+compatability||compatibility
+compatable||compatible
+compatibiliy||compatibility
+compatibilty||compatibility
+compilant||compliant
+compleatly||completely
+completly||completely
+complient||compliant
+compres||compress
+compresion||compression
+comression||compression
+conditionaly||conditionally
+configuratoin||configuration
+conjuction||conjunction
+connectinos||connections
+connnection||connection
+connnections||connections
+consistancy||consistency
+consistant||consistent
+containes||contains
+containts||contains
+contaisn||contains
+contence||contents
+continous||continuous
+continously||continuously
+continueing||continuing
+contraints||constraints
+convertor||converter
+convinient||convenient
+corected||corrected
+correponding||corresponding
+correponds||corresponds
+correspoding||corresponding
+cryptocraphic||cryptographic
+curently||currently
+dafault||default
+deafult||default
+deamon||daemon
+decompres||decompress
+definate||definite
+definately||definitely
+delared||declared
+delare||declare
+delares||declares
+delaring||declaring
+delemiter||delimiter
+dependancies||dependencies
+dependancy||dependency
+dependant||dependent
+depreacted||deprecated
+depreacte||deprecate
+desactivate||deactivate
+detabase||database
+developement||development
+developped||developed
+developpement||development
+developper||developer
+developpment||development
+deveolpment||development
+devided||divided
+dictionnary||dictionary
+diplay||display
+disapeared||disappeared
+dispertion||dispersion
+dissapears||disappears
+docuentation||documentation
+documantation||documentation
+documentaion||documentation
+downlad||download
+downlads||downloads
+easilly||easily
+ecspecially||especially
+edditable||editable
+editting||editing
+efficently||efficiently
+eletronic||electronic
+enchanced||enhanced
+encorporating||incorporating
+endianess||endianness
+enhaced||enhanced
+enlightnment||enlightenment
+enocded||encoded
+enterily||entirely
+enviroiment||environment
+enviroment||environment
+environement||environment
+environent||environment
+equiped||equipped
+equivelant||equivalent
+equivilant||equivalent
+estbalishment||establishment
+etsablishment||establishment
+etsbalishment||establishment
+excecutable||executable
+exceded||exceeded
+excellant||excellent
+exlcude||exclude
+exlcusive||exclusive
+expecially||especially
+explicitely||explicitly
+explict||explicit
+explictly||explicitly
+expresion||expression
+exprimental||experimental
+extensability||extensibility
+extention||extension
+extracter||extractor
+failuer||failure
+familar||familiar
+fatser||faster
+feauture||feature
+feautures||features
+fetaure||feature
+fetaures||features
+forse||force
+fortan||fortran
+forwardig||forwarding
+framwork||framework
+fuction||function
+fuctions||functions
+functionallity||functionality
+functionaly||functionally
+functionnality||functionality
+functonality||functionality
+futhermore||furthermore
+generiously||generously
+grabing||grabbing
+grahical||graphical
+grahpical||graphical
+grapic||graphic
+guage||gauge
+halfs||halves
+handfull||handful
+heirarchically||hierarchically
+helpfull||helpful
+hierachy||hierarchy
+hierarchie||hierarchy
+howver||however
+immeadiately||immediately
+implemantation||implementation
+implemention||implementation
+incomming||incoming
+incompatabilities||incompatibilities
+incompatable||incompatible
+inconsistant||inconsistent
+indendation||indentation
+indended||intended
+independant||independent
+independed||independent
+informatiom||information
+informations||information
+infromation||information
+initalize||initialize
+initators||initiators
+initializiation||initialization
+inofficial||unofficial
+integreated||integrated
+integrety||integrity
+integrey||integrity
+intendet||intended
+interchangable||interchangeable
+intermittant||intermittent
+interupted||interrupted
+intial||initial
+intregral||integral
+intuative||intuitive
+invalde||invald
+invokation||invocation
+invokations||invocations
+jave||java
+langage||language
+langauage||language
+langauge||language
+langugage||language
+lauch||launch
+leightweight||lightweight
+lenght||length
+lesstiff||lesstif
+libaries||libraries
+libary||library
+librairies||libraries
+libraris||libraries
+licenceing||licencing
+loggging||logging
+loggin||login
+logile||logfile
+machinary||machinery
+maintainance||maintenance
+maintainence||maintenance
+maintan||maintain
+makeing||making
+malplaced||misplaced
+malplace||misplace
+managable||manageable
+managment||management
+manoeuvering||maneuvering
+mathimatical||mathematical
+mathimatic||mathematic
+mathimatics||mathematics
+ment||meant
+messsage||message
+messsages||messages
+microprocesspr||microprocessor
+milliseonds||milliseconds
+miscelleneous||miscellaneous
+misformed||malformed
+mispelled||misspelled
+mispelt||misspelt
+mmnemonic||mnemonic
+modulues||modules
+monochorome||monochrome
+monochromo||monochrome
+monocrome||monochrome
+mroe||more
+mulitplied||multiplied
+multidimensionnal||multidimensional
+mutiple||multiple
+nam||name
+nams||names
+navagating||navigating
+nead||need
+neccesary||necessary
+neccessary||necessary
+necesary||necessary
+negotation||negotiation
+nescessary||necessary
+nessessary||necessary
+noticable||noticeable
+notications||notifications
+occationally||occasionally
+omitt||omit
+ommitted||omitted
+onself||oneself
+optionnal||optional
+optmizations||optimizations
+orientatied||orientated
+orientied||oriented
+ouput||output
+overaall||overall
+overriden||overridden
+pacakge||package
+pachage||package
+packacge||package
+packege||package
+packge||package
+pakage||package
+pallette||palette
+paramameters||parameters
+paramater||parameter
+parametes||parameters
+parametised||parametrised
+paramter||parameter
+paramters||parameters
+particularily||particularly
+pased||passed
+pendantic||pedantic
+peprocessor||preprocessor
+perfoming||performing
+permissons||permissions
+persistant||persistent
+plattform||platform
+pleaes||please
+ploting||plotting
+poinnter||pointer
+posible||possible
+possibilites||possibilities
+powerfull||powerful
+preceeded||preceded
+preceeding||preceding
+precendence||precedence
+precission||precision
+prefered||preferred
+prefferably||preferably
+prepaired||prepared
+primative||primitive
+princliple||principle
+priorty||priority
+priviledge||privilege
+priviledges||privileges
+procceed||proceed
+proccesors||processors
+proces||process
+processessing||processing
+processess||processes
+processpr||processor
+processsing||processing
+progams||programs
+programers||programmers
+programm||program
+programms||programs
+promps||prompts
+pronnounced||pronounced
+prononciation||pronunciation
+pronouce||pronounce
+pronunce||pronounce
+propery||property
+propigate||propagate
+propigation||propagation
+prosess||process
+protable||portable
+protcol||protocol
+protecion||protection
+protocoll||protocol
+psychadelic||psychedelic
+quering||querying
+reasearcher||researcher
+reasearchers||researchers
+reasearch||research
+recieved||received
+recieve||receive
+reciever||receiver
+recieves||receives
+recogniced||recognised
+recognizeable||recognizable
+recommanded||recommended
+redircet||redirect
+redirectrion||redirection
+refence||reference
+registerd||registered
+registraration||registration
+regulamentations||regulations
+remoote||remote
+removeable||removable
+repectively||respectively
+replacments||replacements
+replys||replies
+requiere||require
+requred||required
+requried||required
+resizeable||resizable
+ressize||resize
+ressource||resource
+ressources||resources
+retransmited||retransmitted
+retreive||retrieve
+retreived||retrieved
+rmeoved||removed
+rmeove||remove
+rmeoves||removes
+runned||ran
+runnning||running
+sacrifying||sacrificing
+safly||safely
+savable||saveable
+searchs||searches
+secund||second
+separatly||separately
+sepcify||specify
+seperated||separated
+seperately||separately
+seperate||separate
+seperatly||separately
+seperator||separator
+sepperate||separate
+sequencial||sequential
+serveral||several
+setts||sets
+similiar||similar
+simliar||similar
+singed||signed
+softwares||software
+speach||speech
+speciefied||specified
+specifed||specified
+specificatin||specification
+specificaton||specification
+specifing||specifying
+speficied||specified
+speling||spelling
+splitted||split
+spreaded||spread
+staically||statically
+standardss||standards
+standart||standard
+staticly||statically
+subdirectoires||subdirectories
+suble||subtle
+succesfully||successfully
+succesful||successful
+sucessfully||successfully
+superflous||superfluous
+superseeded||superseded
+suplied||supplied
+suport||support
+suppored||supported
+supportin||supporting
+suppoted||supported
+suppported||supported
+suppport||support
+supress||suppress
+surpresses||suppresses
+suspicously||suspiciously
+synax||syntax
+synchonized||synchronized
+syncronize||synchronize
+syncronizing||synchronizing
+syncronus||synchronous
+syste||system
+sytem||system
+sythesis||synthesis
+taht||that
+targetted||targeted
+targetting||targeting
+teh||the
+throught||through
+transfered||transferred
+transfering||transferring
+trasmission||transmission
+treshold||threshold
+trigerring||triggering
+unconditionaly||unconditionally
+unecessary||unnecessary
+unexecpted||unexpected
+unfortunatelly||unfortunately
+unknonw||unknown
+unkown||unknown
+unneedingly||unnecessarily
+unsinged||unsigned
+unuseful||useless
+usefule||useful
+usefull||useful
+usege||usage
+usera||users
+usualy||usually
+utilites||utilities
+utillities||utilities
+utilties||utilities
+utiltity||utility
+utitlty||utility
+valide||valid
+variantions||variations
+varient||variant
+verbse||verbose
+verisons||versions
+verison||version
+verson||version
+vicefersa||vice-versa
+visiters||visitors
+vitual||virtual
+whataver||whatever
+wheter||whether
+wierd||weird
+writting||writing
--
1.9.1
--
Kees Cook
Chrome OS Security
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-21 16:20 [PATCH] checkpatch: look for common misspellings Kees Cook
@ 2014-08-21 17:18 ` Joe Perches
2014-08-21 23:01 ` Kees Cook
0 siblings, 1 reply; 8+ messages in thread
From: Joe Perches @ 2014-08-21 17:18 UTC (permalink / raw)
To: Kees Cook
Cc: linux-kernel, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari
On Thu, 2014-08-21 at 09:20 -0700, Kees Cook wrote:
> Check for misspellings, based on Debian's lintian list. Several false
> positives were removed, and several additional words added that were
> common in the kernel:
[]
> diff --git a/MAINTAINERS b/MAINTAINERS
[]
> @@ -2311,6 +2311,7 @@ M: Andy Whitcroft <apw@canonical.com>
> M: Joe Perches <joe@perches.com>
> S: Maintained
> F: scripts/checkpatch.pl
> +F: scripts/spelling.txt
I don't want to be responsible for misspellings.
Maybe this should be moved to another section
and you could be added as a maintainer for that.
> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
[]
> +# Check for several spelling mistakes.
> + if ($rawline =~ $spelling_re) {
$spelling_re has a rather hidden ( ... ) use so I think
it'd be better to not use spelling_re at all and have a
variable like:
our $misspellings = join('|', @spelling_list);
and also use while so all misspellings are found so this
could be:
while ($rawline =~ /(?:^|$edge)($misspellings)(?:\$|$edge)/g) {
> + my $typo = "The word '$1' may be misspelled";
> + $typo .= " (perhaps you want '$spelling_fix{$1}'?)\n";
> + WARN("TYPO_SPELLING", $typo . $herecurr);
> + }
> }
Seems sensible, but this checks only .c and .h files.
Any of the Kconfig/.txt files are skipped.
I'd probably leave out "The word "
Maybe add a $fix too?
Maybe:
while ($rawline =~ /(?:^|$edge)($misspellings)(?:\$|$edge)/g) {
my $typo = $1;
if (WARN("TYPO_SPELLING",
"$typo may be misspelled - Use '$spelling_fix($typo)'?\n" . $herecurr) &&
$fix) {
$fixed[$fixlinenr] =~ s/(?:^|$edge)($typo)(?:\$|$edge)/$spelling_fix($typo)/;
}
}
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-21 17:18 ` Joe Perches
@ 2014-08-21 23:01 ` Kees Cook
2014-08-22 0:10 ` Joe Perches
0 siblings, 1 reply; 8+ messages in thread
From: Kees Cook @ 2014-08-21 23:01 UTC (permalink / raw)
To: Joe Perches
Cc: LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari
On Thu, Aug 21, 2014 at 12:18 PM, Joe Perches <joe@perches.com> wrote:
> On Thu, 2014-08-21 at 09:20 -0700, Kees Cook wrote:
>> Check for misspellings, based on Debian's lintian list. Several false
>> positives were removed, and several additional words added that were
>> common in the kernel:
> []
>> diff --git a/MAINTAINERS b/MAINTAINERS
> []
>> @@ -2311,6 +2311,7 @@ M: Andy Whitcroft <apw@canonical.com>
>> M: Joe Perches <joe@perches.com>
>> S: Maintained
>> F: scripts/checkpatch.pl
>> +F: scripts/spelling.txt
>
> I don't want to be responsible for misspellings.
>
> Maybe this should be moved to another section
> and you could be added as a maintainer for that.
Okay, sure. Happy to do so. Or maybe some -docs folks want to join me? :)
>
>> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> []
>> +# Check for several spelling mistakes.
>> + if ($rawline =~ $spelling_re) {
>
> $spelling_re has a rather hidden ( ... ) use so I think
> it'd be better to not use spelling_re at all and have a
> variable like:
> our $misspellings = join('|', @spelling_list);
>
> and also use while so all misspellings are found so this
> could be:
>
> while ($rawline =~ /(?:^|$edge)($misspellings)(?:\$|$edge)/g) {
>
>> + my $typo = "The word '$1' may be misspelled";
>> + $typo .= " (perhaps you want '$spelling_fix{$1}'?)\n";
>> + WARN("TYPO_SPELLING", $typo . $herecurr);
>> + }
>> }
>
> Seems sensible, but this checks only .c and .h files.
> Any of the Kconfig/.txt files are skipped.
Oh, hm. Yes, seems like this should be relocated then.
> I'd probably leave out "The word "
Fair enough.
> Maybe add a $fix too?
>
> Maybe:
>
> while ($rawline =~ /(?:^|$edge)($misspellings)(?:\$|$edge)/g) {
> my $typo = $1;
> if (WARN("TYPO_SPELLING",
> "$typo may be misspelled - Use '$spelling_fix($typo)'?\n" . $herecurr) &&
> $fix) {
> $fixed[$fixlinenr] =~ s/(?:^|$edge)($typo)(?:\$|$edge)/$spelling_fix($typo)/;
> }
> }
>
>
Cool, let me grok your suggested patch and reply. Thanks for looking this over!
-Kees
--
Kees Cook
Chrome OS Security
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-21 23:01 ` Kees Cook
@ 2014-08-22 0:10 ` Joe Perches
2014-08-22 22:37 ` Joe Perches
0 siblings, 1 reply; 8+ messages in thread
From: Joe Perches @ 2014-08-22 0:10 UTC (permalink / raw)
To: Kees Cook
Cc: LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari,
Masanari Iida, Geert Uytterhoeven, linux-doc
On Thu, 2014-08-21 at 18:01 -0500, Kees Cook wrote:
> On Thu, Aug 21, 2014 at 12:18 PM, Joe Perches <joe@perches.com> wrote:
> > On Thu, 2014-08-21 at 09:20 -0700, Kees Cook wrote:
> >> Check for misspellings, based on Debian's lintian list. Several false
> >> positives were removed, and several additional words added that were
> >> common in the kernel:
> > []
> >> diff --git a/MAINTAINERS b/MAINTAINERS
> > []
> >> @@ -2311,6 +2311,7 @@ M: Andy Whitcroft <apw@canonical.com>
> >> M: Joe Perches <joe@perches.com>
> >> S: Maintained
> >> F: scripts/checkpatch.pl
> >> +F: scripts/spelling.txt
> >
> > I don't want to be responsible for misspellings.
> >
> > Maybe this should be moved to another section
> > and you could be added as a maintainer for that.
>
> Okay, sure. Happy to do so. Or maybe some -docs folks want to join me? :)
Masanari Iida does a lot of these (added to cc)
Maybe he's interested in helping out or adding
his collection of misspellings to spelling.txt.
Maybe Geert Uytterhoeven too (also cc'd)
Maybe the lintian list should also be added if it's
around somewhere instead of trying to duplicate it.
http://anonscm.debian.org/cgit/lintian/lintian.git/tree/data/spelling/corrections
[]
> Cool, let me grok your suggested patch and reply. Thanks for looking this over!
A defect was it checked only for all lower-case uses.
Here's what I have now. It:
o relocates the check above specific file extension tests
o checks lines in the commit log and any added lines
o checks case-insensitive misspellings
o does Proper case corrections for start of sentences
o adds a working --fix option.
Maybe you could merge it with your other changes.
You could add some tag like improved-by: / signed-off-by,
acked-by: for me if you want.
---
scripts/checkpatch.pl | 41 ++++++++++++++++++++++++++++++++++++++++-
1 file changed, 40 insertions(+), 1 deletion(-)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index b385bcb..9075ed5 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -9,7 +9,8 @@ use strict;
use POSIX;
my $P = $0;
-$P =~ s@.*/@@g;
+$P =~ s@(.*)/@@g;
+my $D = $1;
my $V = '0.32';
@@ -43,6 +44,7 @@ my $configuration_file = ".checkpatch.conf";
my $max_line_length = 80;
my $ignore_perl_version = 0;
my $minimum_perl_version = 5.10.0;
+my $spelling_file = "$D/spelling.txt";
sub help {
my ($exitcode) = @_;
@@ -429,6 +431,29 @@ our $allowed_asm_includes = qr{(?x:
)};
# memory.h: ARM has a custom one
+# Load common spelling mistakes and build regular expression list.
+my $misspellings;
+my @spelling_list;
+my %spelling_fix;
+open(my $spelling, '<', $spelling_file)
+ or die "$P: Can't open $spelling_file for reading: $!\n";
+while (<$spelling>) {
+ my $line = $_;
+
+ $line =~ s/\s*\n?$//g;
+ $line =~ s/^\s*//g;
+
+ next if ($line =~ m/^\s*#/);
+ next if ($line =~ m/^\s*$/);
+
+ my ($suspect, $fix) = split(/\|\|/, $line);
+
+ push(@spelling_list, $suspect);
+ $spelling_fix{$suspect} = $fix;
+}
+close($spelling);
+$misspellings = join("|", @spelling_list);
+
sub build_types {
my $mods = "(?x: \n" . join("|\n ", @modifierList) . "\n)";
my $all = "(?x: \n" . join("|\n ", @typeList) . "\n)";
@@ -2337,6 +2362,20 @@ sub process {
}
}
+# Check for various spelling / typo mistakes
+ if ($in_commit_log || $line =~ /^\+/) {
+ while ($rawline =~ /(?:^|[^a-z@])($misspellings)(?:\$|[^a-z@])/gi) {
+ my $typo = $1;
+ my $fixed = $spelling_fix{lc($typo)};
+ $fixed = ucfirst($fixed) if ($typo =~ /^[A-Z]/);
+ if (WARN("TYPO_SPELLING",
+ "'$typo' may be misspelled - perhaps '$fixed'?\n" . $herecurr) &&
+ $fix) {
+ $fixed[$fixlinenr] =~ s/(^|[^A-Za-z@])($typo)(\$|[^A-Za-z@])/$1$fixed$3/;
+ }
+ }
+ }
+
# check we are in a valid source file if not then ignore this hunk
next if ($realfile !~ /\.(h|c|s|S|pl|sh)$/);
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-22 0:10 ` Joe Perches
@ 2014-08-22 22:37 ` Joe Perches
2014-08-22 23:00 ` Elliott, Robert (Server Storage)
0 siblings, 1 reply; 8+ messages in thread
From: Joe Perches @ 2014-08-22 22:37 UTC (permalink / raw)
To: Kees Cook
Cc: LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari,
Masanari Iida, Geert Uytterhoeven, linux-doc
On Thu, 2014-08-21 at 17:10 -0700, Joe Perches wrote:
> On Thu, 2014-08-21 at 18:01 -0500, Kees Cook wrote:
> > On Thu, Aug 21, 2014 at 12:18 PM, Joe Perches <joe@perches.com> wrote:
> > > On Thu, 2014-08-21 at 09:20 -0700, Kees Cook wrote:
> > >> Check for misspellings, based on Debian's lintian list. Several false
> > >> positives were removed, and several additional words added that were
> > >> common in the kernel:
> > > []
> > >> diff --git a/MAINTAINERS b/MAINTAINERS
> > > []
> > >> @@ -2311,6 +2311,7 @@ M: Andy Whitcroft <apw@canonical.com>
> > >> M: Joe Perches <joe@perches.com>
> > >> S: Maintained
> > >> F: scripts/checkpatch.pl
> > >> +F: scripts/spelling.txt
> > >
> > > I don't want to be responsible for misspellings.
> > >
> > > Maybe this should From 62adeee9bcc2015257834a0cbc88290a44fcf315 Mon Sep 17 00:00:00 2001
From: Joe Perches <joe@perches.com>
Date: Fri, 22 Aug 2014 14:57:39 -0700
Subject: [PATCH] scripts/spelling.txt: Add some of Masanari Iida's spelling corrections
Masanari has done several spelling/typo fixes.
I wrote a little script to sift his last 100 spelling patches
from the git logs and added his corrections to this file with
a little typing afterwards to clean up some false positives.
Signed-off-by: Joe Perches <joe@perches.com>
---
scripts/spelling.txt | 458 ++++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 455 insertions(+), 3 deletions(-)
diff --git a/scripts/spelling.txt b/scripts/spelling.txt
index 03c6234..cd5bacc 100644
--- a/scripts/spelling.txt
+++ b/scripts/spelling.txt
@@ -11,9 +11,11 @@ abandonning||abandoning
abigious||ambiguous
abitrate||arbitrate
abov||above
+abreviated||abbreviated
absense||absence
absolut||absolute
absoulte||absolute
+acccess||access
acceleratoin||acceleration
accelleration||acceleration
accesing||accessing
@@ -22,28 +24,42 @@ accessable||accessible
accesss||access
accidentaly||accidentally
accidentually||accidentally
+accoding||according
accomodate||accommodate
accomodates||accommodates
+accordign||according
+accoring||according
accout||account
+accquire||acquire
+accquired||acquired
acessable||accessible
acess||access
+achitecture||architecture
acient||ancient
+acitions||actions
+acitve||active
acknowldegement||acknowldegement
+acknowledgement||acknowledgment
ackowledge||acknowledge
ackowledged||acknowledged
acording||according
activete||activate
acumulating||accumulating
+adapater||adapter
addional||additional
additionaly||additionally
+addres||address
addreses||addresses
+addresss||address
aditional||additional
aditionally||additionally
aditionaly||additionally
+adminstrative||administrative
adress||address
adresses||addresses
adviced||advised
afecting||affecting
+agaist||against
albumns||albums
alegorical||allegorical
algorith||algorithm
@@ -52,12 +68,18 @@ algoritm||algorithm
algoritms||algorithms
algorrithm||algorithm
algorritm||algorithm
+allign||align
+allocatrd||allocated
+allocte||allocate
allpication||application
+alocate||allocate
alogirhtms||algorithms
+alogrithm||algorithm
alot||a lot
alow||allow
alows||allows
altough||although
+alue||value
ambigious||ambiguous
amoung||among
amout||amount
@@ -67,12 +89,18 @@ anniversery||anniversary
annoucement||announcement
anomolies||anomalies
anomoly||anomaly
+anway||anyway
aplication||application
appearence||appearance
+applicaion||application
appliction||application
applictions||applications
+appplications||applications
appropiate||appropriate
appropriatly||appropriately
+approriate||appropriate
+approriately||appropriately
+aquainted||acquainted
aquired||acquired
arbitary||arbitrary
architechture||architecture
@@ -83,13 +111,22 @@ arne't||aren't
arraival||arrival
artifical||artificial
artillary||artillery
+assiged||assigned
assigment||assignment
assigments||assignments
assistent||assistant
+assocation||association
+associcated||associated
+assotiated||associated
+assum||assume
+assumtpion||assumption
asuming||assuming
asycronous||asynchronous
+asynchnous||asynchronous
atomatically||automatically
+atomicly||atomically
attachement||attachment
+attched||attached
attemps||attempts
attruibutes||attributes
authentification||authentication
@@ -101,55 +138,96 @@ automatizes||automates
autonymous||autonomous
auxilliary||auxiliary
avaiable||available
+avaible||available
+availabe||available
availabled||available
availablity||availability
availale||available
availavility||availability
availble||available
-availble||available
availiable||available
+avalable||available
avaliable||available
-avaliable||available
+aysnc||async
backgroud||background
backword||backward
backwords||backwards
bahavior||behavior
+bakup||backup
baloon||balloon
baloons||balloons
bandwith||bandwidth
batery||battery
+beacuse||because
+becasue||because
becomming||becoming
becuase||because
+beeing||being
+befor||before
begining||beginning
+beter||better
+betweeen||between
bianries||binaries
+bitmast||bitmask
+boardcast||broadcast
+borad||board
+boundry||boundary
+brievely||briefly
+broadcat||broadcast
+cacluated||calculated
+caculation||calculation
calender||calendar
+calle||called
+calucate||calculate
+calulate||calculate
cancelation||cancellation
capabilites||capabilities
+capabitilies||capabilities
capatibilities||capabilities
+carefuly||carefully
cariage||carriage
+catagory||category
challange||challenge
challanges||challenges
+chanell||channel
changable||changeable
+chang||change
+channle||channel
+channnel||channel
charachter||character
charachters||characters
+charactor||character
charater||character
charaters||characters
charcter||character
+checksuming||checksumming
+childern||children
childs||children
+chiled||child
+chked||checked
chnage||change
chnages||changes
+chnnel||channel
choosen||chosen
+chouse||chose
+circumvernt||circumvent
+claread||cleared
+clared||cleared
+closeing||closing
+clustred||clustered
collapsable||collapsible
colorfull||colorful
comand||command
comit||commit
commerical||commercial
+comming||coming
comminucation||communication
commited||committed
commiting||committing
committ||commit
commoditiy||commodity
compability||compatibility
+compaibility||compatibility
compatability||compatibility
compatable||compatible
compatibiliy||compatibility
@@ -158,11 +236,18 @@ compilant||compliant
compleatly||completely
completly||completely
complient||compliant
+componnents||components
compres||compress
compresion||compression
comression||compression
+comunication||communication
+conbination||combination
conditionaly||conditionally
+conected||connected
configuratoin||configuration
+configuraton||configuration
+configuretion||configuration
+conider||consider
conjuction||conjunction
connectinos||connections
connnection||connection
@@ -172,25 +257,44 @@ consistant||consistent
containes||contains
containts||contains
contaisn||contains
+contant||contact
contence||contents
continous||continuous
continously||continuously
continueing||continuing
contraints||constraints
+controled||controlled
+controler||controller
+controll||control
+contruction||construction
+contry||country
+convertion||conversion
convertor||converter
+convienient||convenient
convinient||convenient
corected||corrected
correponding||corresponding
correponds||corresponds
correspoding||corresponding
+cotrol||control
+couter||counter
+coutner||counter
cryptocraphic||cryptographic
+cunter||counter
curently||currently
dafault||default
deafult||default
deamon||daemon
decompres||decompress
+decription||description
+defailt||default
+defferred||deferred
definate||definite
definately||definitely
+defintion||definition
+defualt||default
+defult||default
+deivce||device
delared||declared
delare||declare
delares||declares
@@ -202,7 +306,18 @@ dependant||dependent
depreacted||deprecated
depreacte||deprecate
desactivate||deactivate
+desciptors||descriptors
+descrition||description
+descritptor||descriptor
+desctiptor||descriptor
+desriptor||descriptor
+desriptors||descriptors
+destory||destroy
+destoryed||destroyed
+destorys||destroys
+destroied||destroyed
detabase||database
+develope||develop
developement||development
developped||developed
developpement||development
@@ -210,24 +325,45 @@ developper||developer
developpment||development
deveolpment||development
devided||divided
+deviece||device
+diable||disable
dictionnary||dictionary
+diferent||different
+differrence||difference
+difinition||definition
diplay||display
+direectly||directly
+disapear||disappear
disapeared||disappeared
+disappared||disappeared
+disconnet||disconnect
+discontinous||discontinuous
dispertion||dispersion
dissapears||disappears
+distiction||distinction
docuentation||documentation
documantation||documentation
documentaion||documentation
+documment||document
+dorp||drop
+dosen||doesn
downlad||download
downlads||downloads
+druing||during
+dynmaic||dynamic
easilly||easily
ecspecially||especially
edditable||editable
editting||editing
efficently||efficiently
+ehther||ether
+eigth||eight
eletronic||electronic
+enabledi||enabled
enchanced||enhanced
encorporating||incorporating
+encrupted||encrypted
+encrypiton||encryption
endianess||endianness
enhaced||enhanced
enlightnment||enlightenment
@@ -237,96 +373,196 @@ enviroiment||environment
enviroment||environment
environement||environment
environent||environment
+eqivalent||equivalent
equiped||equipped
equivelant||equivalent
equivilant||equivalent
+eror||error
estbalishment||establishment
etsablishment||establishment
etsbalishment||establishment
excecutable||executable
exceded||exceeded
excellant||excellent
+existance||existence
+existant||existent
+exixt||exist
exlcude||exclude
exlcusive||exclusive
+exmaple||example
expecially||especially
+explicite||explicit
explicitely||explicitly
explict||explicit
explictly||explicitly
expresion||expression
exprimental||experimental
+extened||extended
extensability||extensibility
extention||extension
extracter||extractor
+faild||failed
+faill||fail
+failue||failure
failuer||failure
+faireness||fairness
+faliure||failure
familar||familiar
fatser||faster
feauture||feature
feautures||features
fetaure||feature
fetaures||features
+fileystem||filesystem
+finanize||finalize
+findn||find
+finilizes||finalizes
+finsih||finish
+flusing||flushing
+folloing||following
+followign||following
+follwing||following
+forseeable||foreseeable
forse||force
fortan||fortran
forwardig||forwarding
framwork||framework
+frequncy||frequency
+frome||from
+fucntion||function
fuction||function
fuctions||functions
+funcion||function
functionallity||functionality
functionaly||functionally
functionnality||functionality
functonality||functionality
+funtion||function
+funtions||functions
+furthur||further
futhermore||furthermore
+futrue||future
+gaurenteed||guaranteed
generiously||generously
+genric||generic
+globel||global
grabing||grabbing
grahical||graphical
grahpical||graphical
grapic||graphic
guage||gauge
+guarentee||guarantee
halfs||halves
+hander||handler
handfull||handful
+hanled||handled
+harware||hardware
heirarchically||hierarchically
helpfull||helpful
hierachy||hierarchy
hierarchie||hierarchy
howver||however
+hsould||should
+hypter||hyper
+identidier||identifier
+imblance||imbalance
immeadiately||immediately
+immedaite||immediate
+immediatelly||immediately
+immediatly||immediately
+immidiate||immediate
+impelentation||implementation
+impementated||implemented
implemantation||implementation
+implemenation||implementation
+implementaiton||implementation
+implementated||implemented
implemention||implementation
+implemetation||implementation
+implemntation||implementation
+implentation||implementation
+implmentation||implementation
+implmenting||implementing
incomming||incoming
incompatabilities||incompatibilities
incompatable||incompatible
inconsistant||inconsistent
+increas||increase
+incrment||increment
indendation||indentation
indended||intended
independant||independent
+independantly||independently
independed||independent
+indiate||indicate
+inexpect||inexpected
+infomation||information
informatiom||information
informations||information
+informtion||information
infromation||information
+ingore||ignore
+inital||initial
+initalised||initialized
+initalise||initialize
initalize||initialize
+initation||initiation
initators||initiators
initializiation||initialization
+initialzed||initialized
+initilization||initialization
+initilize||initialize
inofficial||unofficial
+instal||install
+inteface||interface
integreated||integrated
integrety||integrity
integrey||integrity
intendet||intended
+intented||intended
+interanl||internal
interchangable||interchangeable
+interferring||interfering
+interger||integer
intermittant||intermittent
+internel||internal
+interoprability||interoperability
+interrface||interface
+interrrupt||interrupt
+interrup||interrupt
+interrups||interrupts
+interruptted||interrupted
interupted||interrupted
+interupt||interrupt
intial||initial
+intialized||initialized
+intialize||initialize
intregral||integral
+intrrupt||interrupt
intuative||intuitive
+invaid||invalid
invalde||invald
+invalide||invalid
+invididual||individual
invokation||invocation
invokations||invocations
+irrelevent||irrelevant
+isssue||issue
+itslef||itself
jave||java
+jeffies||jiffies
+juse||just
+jus||just
+kown||known
langage||language
langauage||language
langauge||language
langugage||language
lauch||launch
leightweight||lightweight
+lengh||length
lenght||length
+lenth||length
lesstiff||lesstif
libaries||libraries
libary||library
@@ -336,6 +572,8 @@ licenceing||licencing
loggging||logging
loggin||login
logile||logfile
+loosing||losing
+losted||lost
machinary||machinery
maintainance||maintenance
maintainence||maintenance
@@ -345,101 +583,169 @@ malplaced||misplaced
malplace||misplace
managable||manageable
managment||management
+mangement||management
manoeuvering||maneuvering
+mappping||mapping
mathimatical||mathematical
mathimatic||mathematic
mathimatics||mathematics
+maxium||maximum
+mechamism||mechanism
+meetign||meeting
ment||meant
+mergable||mergeable
+mesage||message
+messags||messages
+messgaes||messages
messsage||message
messsages||messages
microprocesspr||microprocessor
milliseonds||milliseconds
+minumum||minimum
miscelleneous||miscellaneous
misformed||malformed
mispelled||misspelled
mispelt||misspelt
+miximum||maximum
mmnemonic||mnemonic
+mnay||many
+modeled||modelled
modulues||modules
monochorome||monochrome
monochromo||monochrome
monocrome||monochrome
+mopdule||module
mroe||more
mulitplied||multiplied
multidimensionnal||multidimensional
+multple||multiple
+mumber||number
+muticast||multicast
mutiple||multiple
+mutli||multi
nam||name
nams||names
navagating||navigating
nead||need
+neccecary||necessary
neccesary||necessary
neccessary||necessary
necesary||necessary
+negaive||negative
+negoitation||negotiation
negotation||negotiation
+nerver||never
nescessary||necessary
nessessary||necessary
noticable||noticeable
notications||notifications
+notifed||notified
+numebr||number
+numner||number
+obtaion||obtain
+occassionally||occasionally
occationally||occasionally
+occurance||occurrence
+occurances||occurrences
+occured||occurred
+occurence||occurrence
+occure||occurred
+occuring||occurring
+offet||offset
omitt||omit
+ommiting||omitting
ommitted||omitted
onself||oneself
+ony||only
+operatione||operation
+opertaions||operations
optionnal||optional
optmizations||optimizations
orientatied||orientated
orientied||oriented
+otherise||otherwise
ouput||output
overaall||overall
+overhread||overhead
+overlaping||overlapping
overriden||overridden
+overun||overrun
pacakge||package
pachage||package
packacge||package
packege||package
packge||package
+packtes||packets
pakage||package
pallette||palette
+paln||plan
paramameters||parameters
paramater||parameter
parametes||parameters
parametised||parametrised
paramter||parameter
paramters||parameters
+particuarly||particularly
particularily||particularly
pased||passed
+passin||passing
+pathes||paths
+pecularities||peculiarities
+peformance||performance
+peice||piece
pendantic||pedantic
peprocessor||preprocessor
perfoming||performing
permissons||permissions
+peroid||period
+persistance||persistence
persistant||persistent
+platfrom||platform
plattform||platform
pleaes||please
ploting||plotting
+plugable||pluggable
poinnter||pointer
+poiter||pointer
posible||possible
+positon||position
possibilites||possibilities
powerfull||powerful
preceeded||preceded
preceeding||preceding
+preceed||precede
precendence||precedence
precission||precision
prefered||preferred
prefferably||preferably
+premption||preemption
prepaired||prepared
+pressre||pressure
primative||primitive
princliple||principle
priorty||priority
+privilaged||privileged
+privilage||privilege
priviledge||privilege
priviledges||privileges
+probaly||probably
procceed||proceed
proccesors||processors
+procesed||processed
proces||process
processessing||processing
processess||processes
processpr||processor
+processsed||processed
processsing||processing
+procteted||protected
+prodecure||procedure
progams||programs
+progess||progress
programers||programmers
programm||program
programms||programs
+progresss||progress
promps||prompts
pronnounced||pronounced
prononciation||pronunciation
@@ -448,16 +754,23 @@ pronunce||pronounce
propery||property
propigate||propagate
propigation||propagation
+propogate||propagate
prosess||process
protable||portable
protcol||protocol
protecion||protection
protocoll||protocol
+psudo||pseudo
+psuedo||pseudo
psychadelic||psychedelic
+pwoer||power
quering||querying
+raoming||roaming
reasearcher||researcher
reasearchers||researchers
reasearch||research
+recepient||recipient
+receving||receiving
recieved||received
recieve||receive
reciever||receiver
@@ -465,74 +778,155 @@ recieves||receives
recogniced||recognised
recognizeable||recognizable
recommanded||recommended
+recyle||recycle
redircet||redirect
redirectrion||redirection
+refcounf||refcount
refence||reference
+refered||referred
+referenace||reference
+refering||referring
+refernces||references
+refernnce||reference
+refrence||reference
registerd||registered
+registeresd||registered
+registes||registers
registraration||registration
+regster||register
+regualar||regular
+reguator||regulator
regulamentations||regulations
+reigstration||registration
+releated||related
+relevent||relevant
remoote||remote
+remore||remote
removeable||removable
repectively||respectively
+replacable||replaceable
replacments||replacements
replys||replies
+reponse||response
+representaion||representation
+reqeust||request
requiere||require
+requirment||requirement
requred||required
requried||required
+requst||request
+reseting||resetting
resizeable||resizable
+resouces||resources
+resoures||resources
ressize||resize
+ressizes||resizes
ressource||resource
ressources||resources
retransmited||retransmitted
-retreive||retrieve
retreived||retrieved
+retreive||retrieve
+retrive||retrieve
+retuned||returned
+reuest||request
+reuqest||request
+reutnred||returned
rmeoved||removed
rmeove||remove
rmeoves||removes
+rountine||routine
+routins||routines
+rquest||request
+runing||running
runned||ran
runnning||running
+runtine||runtime
sacrifying||sacrificing
safly||safely
+safty||safety
savable||saveable
+scaned||scanned
+scaning||scanning
+scarch||search
+seach||search
searchs||searches
+secquence||sequence
secund||second
+segement||segment
+senarios||scenarios
+sentivite||sensitive
separatly||separately
sepcify||specify
+sepc||spec
seperated||separated
seperately||separately
seperate||separate
seperatly||separately
seperator||separator
sepperate||separate
+sequece||sequence
sequencial||sequential
serveral||several
setts||sets
+settting||setting
+shotdown||shutdown
+shoud||should
+shoule||should
+shrinked||shrunk
+siginificantly||significantly
+signabl||signal
+similary||similarly
similiar||similar
+simlar||similar
simliar||similar
+simpified||simplified
+singaled||signaled
+singal||signal
singed||signed
+sleeped||slept
softwares||software
speach||speech
+specfic||specific
speciefied||specified
+specifc||specific
specifed||specified
specificatin||specification
specificaton||specification
specifing||specifying
+specifiying||specifying
speficied||specified
+speicify||specify
speling||spelling
+spinlcok||spinlock
+spinock||spinlock
splitted||split
spreaded||spread
+sructure||structure
+stablilization||stabilization
staically||statically
+staion||station
standardss||standards
+standartization||standardization
standart||standard
staticly||statically
+stoped||stopped
+stoppped||stopped
+straming||streaming
+struc||struct
+structres||structures
+stuct||struct
+sturcture||structure
subdirectoires||subdirectories
suble||subtle
succesfully||successfully
succesful||successful
+successfull||successful
sucessfully||successfully
+sucess||success
superflous||superfluous
superseeded||superseded
suplied||supplied
+suported||supported
suport||support
suppored||supported
supportin||supporting
@@ -541,7 +935,11 @@ suppported||supported
suppport||support
supress||suppress
surpresses||suppresses
+susbsystem||subsystem
suspicously||suspiciously
+swaping||swapping
+switchs||switches
+symetric||symmetric
synax||syntax
synchonized||synchronized
syncronize||synchronize
@@ -554,21 +952,56 @@ taht||that
targetted||targeted
targetting||targeting
teh||the
+temorary||temporary
+temproarily||temporarily
+thier||their
+threds||threads
+threshhold||threshold
throught||through
+thses||these
+ths||the
+tiggered||triggered
+tipically||typically
+tmis||this
+torerable||tolerable
+tramsmitted||transmitted
+tramsmit||transmit
+tranfer||transfer
+transciever||transceiver
+transferd||transferrd
transfered||transferred
transfering||transferring
+transision||transition
+transmittd||transmitted
+transormed||transformed
trasmission||transmission
treshold||threshold
trigerring||triggering
+trun||turn
+ture||true
+tyep||type
+udpate||update
+uesd||used
unconditionaly||unconditionally
+underun||underrun
unecessary||unnecessary
unexecpted||unexpected
+unexpectd||unexpected
+unexpeted||unexpected
unfortunatelly||unfortunately
+unifiy||unify
unknonw||unknown
+unknow||unknown
unkown||unknown
unneedingly||unnecessarily
+unresgister||unregister
unsinged||unsigned
+unstabel||unstable
+unsuccessfull||unsuccessful
+unsuported||unsupported
+untill||until
unuseful||useless
+upate||update
usefule||useful
usefull||useful
usege||usage
@@ -578,18 +1011,37 @@ utilites||utilities
utillities||utilities
utilties||utilities
utiltity||utility
+utitity||utility
utitlty||utility
+vaid||valid
+vaild||valid
+validate||size
valide||valid
variantions||variations
varient||variant
+vaule||value
verbse||verbose
verisons||versions
verison||version
verson||version
vicefersa||vice-versa
+virtal||virtual
+virtaul||virtual
+virtiual||virtual
visiters||visitors
vitual||virtual
+wating||waiting
whataver||whatever
+whenver||whenever
wheter||whether
+whe||when
wierd||weird
+wiil||will
+wirte||write
+withing||within
+wnat||want
+workarould||workaround
+writeing||writing
writting||writing
+zombe||zombie
+zomebie||zombie
--
1.8.1.2.459.gbcd45b4.dirty
^ permalink raw reply [flat|nested] 8+ messages in thread
* RE: [PATCH] checkpatch: look for common misspellings
2014-08-22 22:37 ` Joe Perches
@ 2014-08-22 23:00 ` Elliott, Robert (Server Storage)
2014-08-22 23:22 ` Joe Perches
0 siblings, 1 reply; 8+ messages in thread
From: Elliott, Robert (Server Storage) @ 2014-08-22 23:00 UTC (permalink / raw)
To: Joe Perches, Kees Cook
Cc: LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari,
Masanari Iida, Geert Uytterhoeven, linux-doc
> From: linux-kernel-owner@vger.kernel.org [mailto:linux-kernel-
> owner@vger.kernel.org] On Behalf Of Joe Perches
...
> +chang||change
Although there are at least 2 misuses in the current kernel,
that's also a fairly common name.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-22 23:00 ` Elliott, Robert (Server Storage)
@ 2014-08-22 23:22 ` Joe Perches
2014-08-22 23:31 ` Kees Cook
0 siblings, 1 reply; 8+ messages in thread
From: Joe Perches @ 2014-08-22 23:22 UTC (permalink / raw)
To: Elliott, Robert (Server Storage)
Cc: Kees Cook, LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari,
Masanari Iida, Geert Uytterhoeven, linux-doc
On Fri, 2014-08-22 at 23:00 +0000, Elliott, Robert (Server Storage)
wrote:
> > From: linux-kernel-owner@vger.kernel.org [mailto:linux-kernel-
> > owner@vger.kernel.org] On Behalf Of Joe Perches
> ...
> > +chang||change
>
> Although there are at least 2 misuses in the current kernel,
> that's also a fairly common name.
True. Thanks.
That one should likely be removed.
There are dozens of Chang name uses in the kernel.
I'm not attached at all to any of these btw.
Any others you think should not be used or
should be added?
One I thought kind of iffy was
contant||contact
Maybe that should be content instead.
Another thing the script might do is to check
if the $typo match is all upper case and then
substitute an all upper case $typo_fix.
It's also kind of noisy when run using -f,
so maybe this test should be --strict check with
files and a warning with patches.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] checkpatch: look for common misspellings
2014-08-22 23:22 ` Joe Perches
@ 2014-08-22 23:31 ` Kees Cook
0 siblings, 0 replies; 8+ messages in thread
From: Kees Cook @ 2014-08-22 23:31 UTC (permalink / raw)
To: Joe Perches
Cc: Elliott, Robert (Server Storage),
LKML, Andy Whitcroft, Andrew Morton, David S. Miller,
Greg Kroah-Hartman, Mauro Carvalho Chehab, Antti Palosaari,
Masanari Iida, Geert Uytterhoeven, linux-doc
On Fri, Aug 22, 2014 at 4:22 PM, Joe Perches <joe@perches.com> wrote:
> On Fri, 2014-08-22 at 23:00 +0000, Elliott, Robert (Server Storage)
> wrote:
>> > From: linux-kernel-owner@vger.kernel.org [mailto:linux-kernel-
>> > owner@vger.kernel.org] On Behalf Of Joe Perches
>> ...
>> > +chang||change
>>
>> Although there are at least 2 misuses in the current kernel,
>> that's also a fairly common name.
>
> True. Thanks.
>
> That one should likely be removed.
> There are dozens of Chang name uses in the kernel.
Right, I removed a bunch similar things like this.
> I'm not attached at all to any of these btw.
>
> Any others you think should not be used or
> should be added?
>
> One I thought kind of iffy was
>
> contant||contact
>
> Maybe that should be content instead.
Or "constant". I'll go through the list and see if anything stands out.
> Another thing the script might do is to check
> if the $typo match is all upper case and then
> substitute an all upper case $typo_fix.
That might be a good idea.
> It's also kind of noisy when run using -f,
> so maybe this test should be --strict check with
> files and a warning with patches.
Sure, seems reasonable. I'll get a v2 spun up.
-Kees
--
Kees Cook
Chrome OS Security
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2014-08-22 23:31 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-21 16:20 [PATCH] checkpatch: look for common misspellings Kees Cook
2014-08-21 17:18 ` Joe Perches
2014-08-21 23:01 ` Kees Cook
2014-08-22 0:10 ` Joe Perches
2014-08-22 22:37 ` Joe Perches
2014-08-22 23:00 ` Elliott, Robert (Server Storage)
2014-08-22 23:22 ` Joe Perches
2014-08-22 23:31 ` Kees Cook
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®