summaryrefslogtreecommitdiff
path: root/scripts
AgeCommit message (Collapse)Author
2008-07-30scripts/mod/modpost.c: fix spelling of module and happensBen Dooks
Spelling fixes in scripts/mod/modpost.c Signed-off-by: Ben Dooks <ben-linux@fluff.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Cc: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-27Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-nextLinus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-next: (25 commits) setlocalversion: do not describe if there is nothing to describe kconfig: fix typos: "Suport" -> "Support" kconfig: make defconfig is no longer chatty kconfig: make oldconfig is now less chatty kconfig: speed up all*config + randconfig kconfig: set all new symbols automatically kconfig: add diffconfig utility kbuild: remove Module.markers during mrproper kbuild: sparse needs CF not CHECKFLAGS kernel-doc: handle/strip __init vmlinux.lds: move __attribute__((__cold__)) functions back into final .text section init: fix URL of "The GNU Accounting Utilities" kbuild: add arch/$ARCH/include to search path kbuild: asm symlink support for arch/$ARCH/include kbuild: support arch/$ARCH/include for tags, cscope kbuild: prepare headers_* for arch/$ARCH/include kbuild: install all headers when arch is changed kbuild: make clean removes *.o.* as well kbuild: optimize headers_* targets kbuild: only one call for include/ in make headers_* ...
2008-07-25setlocalversion: do not describe if there is nothing to describeSebastian Siewior
Jan Engelhardt wrote: > Just a note that when you run git-describe, you should probably quiten it. > > fatal: cannot describe 'bd7364a0fd5a4a2878fe4a224be1b142a4e6698e' > > This happens when tags are not present, which can happen if Linus's tree > is sent upwards again, IOW: > > machine1$ git-clone torvalds/linux-2.6.git > machine1$ git push elsewhere master > > machine2$ git-clone elsewhere:/linux > machine2$ git-describe HEAD > fatal: cannot describe that Signed-off-by: Sebastian Siewior <sebastian@breakpoint.cc> Acked-by: Jan Engelhardt <jengelh@medozas.de> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kconfig: make defconfig is no longer chattySam Ravnborg
make defconfig generated a lot of output then noone actually read. Use conf_set_all_new_symbols() to generate the default configuration and avoid the chatty output. A typical run now looks like this: $ make defconfig *** Default configuration is based on 'i386_defconfig' arch/x86/configs/i386_defconfig:13:warning: trying to assign nonexistent symbol SEMAPHORE_SLEEPERS arch/x86/configs/i386_defconfig:176:warning: trying to assign nonexistent symbol PREEMPT_BKL ... arch/x86/configs/i386_defconfig:1386:warning: trying to assign nonexistent symbol INSTRUMENTATION $ As an added benefit we now clearly see the warnings generated in the start of the process. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Roman Zippel <zippel@linux-m68k.org>
2008-07-25kconfig: make oldconfig is now less chattySam Ravnborg
Previously when running "make oldconfig" we saw all the propmt lines from kconfig and noone actully read this. With this patch the user will only see output if there is new symbols. This will be seen as "make oldconfig" runs which does not generate any output. A typical run now looks like this: $ make oldconfig scripts/kconfig/conf -o arch/x86/Kconfig $ If a new symbol is found then we restart the config process like this: $ make oldconfig scripts/kconfig/conf -o arch/x86/Kconfig * * Restart config... * * * General setup * Prompt for development and/or incomplete code/drivers (EXPERIMENTAL) [Y/n/?] y Local version - append to kernel release (LOCALVERSION) [] ... The bahaviour is similar to what we know when running the implicit oldconfig target "make silentoldconfig". "make silentoldconfig" are run as part of the kernel build process if the configuration has changed. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Roman Zippel <zippel@linux-m68k.org>
2008-07-25kconfig: speed up all*config + randconfigSam Ravnborg
Drop the chatty mode when we generate the all*config, randconfig configurations. Ths speeds up the process considerably and noone looked at the output anyway. This patch uses the conf_set_all_new_symbols() function just added to kconfig. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: Roman Zippel <zippel@linux-m68k.org>
2008-07-25kconfig: set all new symbols automaticallyRoman Zippel
Add conf_set_all_new_symbols() which set all symbols (which don't have a value yet) to a specifed value. Signed-off-by: Roman Zippel <zippel@linux-m68k.org> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kconfig: add diffconfig utilityTim Bird
Diffconfig is a simple utility for comparing two kernel configuration files. See usage in the script for more info. Signed-off-by: Tim Bird <tim.bird@am.sony.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kernel-doc: handle/strip __initRandy Dunlap
Handle __init in functions with kernel-doc notation by stripping the __init away from the output doc. This is already being done for "__devinit". This patch fixes these kernel-doc error/aborts: Error(linux-next-20080619//drivers/usb/gadget/config.c:132): cannot understand prototype: 'struct usb_descriptor_header **__init usb_copy_descriptors(struct usb_descriptor_header **src) ' Error(linux-next-20080619//drivers/usb/gadget/config.c:182): cannot understand prototype: 'struct usb_endpoint_descriptor *__init usb_find_endpoint( struct usb_descriptor_header **src, struct usb_descriptor_header **copy, struct usb_endpoint_descriptor *match ) ' Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kbuild: prepare headers_* for arch/$ARCH/includeSam Ravnborg
Factor out the headers_*_all support to a seperate shell script and add support for arch specific header files can be located in either arch/$ARCH/include/asm or include/asm-$ARCH/ In "make help" always display the headers_* targets. Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kbuild: install all headers when arch is changedSam Ravnborg
We see some header files that are selected dependent on the actual architecture so force a reinstallation of all header files when the arch changes. This slows down "make headers_check_all" but then we better reflect reality. Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kbuild: optimize headers_* targetsSam Ravnborg
Move the core functionality of headers_install and headers_check to two small perl scripts. The makefile is adapted to use the perl scrip and changed to operate on all files in a directory. So if one file is changed then all files in the directory is processed. perl were chosen for the helper scripts because this is pure text processing which perl is good at and especially the headers_check.pl script are expected to see changes / new checks implmented. The speed is ~300% faster on this box. And the output generated to the screen is now down to two lines per directory (one for install, one for check) so it is easier to scroll back after a kernel build. The perl scripts has been brought to sanity by patient feedback from: Vegard Nossum <vegard.nossum@gmail.com> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kbuild: only one call for include/ in make headers_*Sam Ravnborg
Move it to the top-level file to decide if we install/check the generic headers or the arch specific headers. This revealed a long standing bug where "make headers_check_all" relied on the files in asm/ for the current architecture. So make headers_check_all is now broken by this commit. In addition: o add a simpler way to detect if an arch support exporting header files. o add 'set -e;' so we error out early if make headers_check_all fails. o add sparc64 and cris to arch we do not process in make headers_*_all because: sparc64 - use sparc to export headers cris - is know seriously broken Includes suggestions from: David Woodhouse <dwmw2@infradead.org>. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: David Woodhouse <dwmw2@infradead.org>
2008-07-25kbuild: code refactoring in Makefile.headerinstSam Ravnborg
No functional changes just improved readability Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
2008-07-25kbuild: drop support of ALTARCH for headers_*Sam Ravnborg
ALTARCH is no longer used by any arch(*) so drop support for this from Makefile.headerinst Dropping ALTARCH support simplifies Makefile.headerinst (*) sparc64 uses it but work is ongoing to drop it and no furter usage is planned. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: David Woodhouse <dwmw2@infradead.org> Cc: David Miller <davem@davemloft.net>
2008-07-25kbuild: always unifdef files in headers_install*Sam Ravnborg
unifdef utility is fast enough to warrant that we always run the scripts through unifdef. This patch runs all headers listed with header-y and unifdef-y through unifdef. Next step is to drop unifdef-y in all Kbuild files and that can now be done in smaller steps. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Cc: David Woodhouse <dwmw2@infradead.org> Cc: Adrian Bunk <bunk@kernel.org>
2008-07-25Merge git://git.infradead.org/~dwmw2/random-2.6Linus Torvalds
* git://git.infradead.org/~dwmw2/random-2.6: remove dummy asm/kvm.h files firmware: create firmware binaries during 'make modules'.
2008-07-25firmware: create firmware binaries during 'make modules'.David Woodhouse
This means that we no longer need write access to the source tree while doing 'make modules_install'. Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-25fix checkstack.pl arch detectionEric Sandeen
uname -m was leaving a newline in $arch, and not passing the tests. Also, printing the unknown arch on failure is probably helpful. Signed-off-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-25find dynamic stack allocations in checkstack.plEric Sandeen
Currently, checkstack.pl only looks for fixed subtractions from the stack pointer. However, things like this: void function(int size) { char stackbuster[size << 2]; ... are certainly worth pointing out, I think. This could perhaps be done more cleanly, and the following patch only adds "dynamic" REs for x86 and x86_64, but it works: 0x00b0 crypto_cbc_decrypt_inplace [cbc]: Dynamic (%rax) 0x00ad crypto_pcbc_decrypt_inplace [pcbc]: Dynamic (%rax) 0x02f6 crypto_pcbc_encrypt_inplace [pcbc]: Dynamic (%rax) 0x036c _crypto_xcbc_digest_setkey [xcbc]: Dynamic (%rax) ... (Inspired by Keith Owens' old stack-check script) Signed-off-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: version 0.21Andy Whitcroft
Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: types cannot start mid word for pointer testsAndy Whitcroft
When checking spacing for pointer checks the type cannot start in the middle of a word, ie. this is not 'int * bar': x = fooint * bar; Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: complex macros need to ignore commentsAndy Whitcroft
Ensure we ignore comments in complex macro detection else we incorrectly report this: #define PFM_GROUP_PERM_ANY -1 /* any user/group */ Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: variants -- move the main unary/binary operators to use variantsAndy Whitcroft
Now that we have a variants system, move to using that to carry the unary/binary designation for +, -, &, and *. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: add checks for question mark and colon spacingAndy Whitcroft
Add checks for the question mark colon operator spacing, and also check the other uses of colon. Colon means a number of things: - it introduces the else part of the ?: operator, - it terminates a goto label, - it terminates the case value, - it separates the identifier from the bit size on bit fields, and - it is used to introduce option types in asm(). Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: possible modifiers -- handle multiple modifiers and trailingAndy Whitcroft
Add support for multiple modifiers such as: int __one __two foo; Also handle trailing known modifiers when defecting modifiers: int __one foo __read_mostly; Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: possible types -- known modifiers cannot be typesAndy Whitcroft
Ensure we do not inadvertantly load known modifiers up as possible types. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: handle return types of pointers to functionsAndy Whitcroft
Make sure we correctly mark the return type of the pointer to a function declaration. const void *(*sb_tag)(struct sysfs_tag_info *info); Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: macro complexity checks are meaningless in linker scriptsAndy Whitcroft
Exclude vmlinux.lds.h from the macro complexity checks. They will never apply sanely here. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: possible modifiers are not being correctly matchedAndy Whitcroft
Although we are finding the added modifier in the declaration below we are not correctly matching it as a type. Fix the declaration. static void __ref *vmem_alloc_pages(unsigned int order) { } Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: improve type matcher debugAndy Whitcroft
Improve type matcher debug so we can see what it does match. As part of this move us to to using the common debug framework. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: allow for type modifiers on multiple declarationsAndy Whitcroft
Allow for type modifiers mid declaration on multiple declarations: struct mxser_mstatus ms, __user *msu = argp; Reported by Jiri Slaby. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: correct spelling in kfree checksWolfram Sang
Correct spelling in the kfree reports. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: usb_free_urb() can take NULLGreg Kroah-Hartman
usb_free_urb() can take a NULL, so let's check and warn about that. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: condition/loop indent checksAndy Whitcroft
Check to see if the block/statement which a condition or loop introduces is indented correctly. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: toughen trailing if statement checks and extend them to while ↵Andy Whitcroft
and for Extend the trailing statement checks to report a trailing semi-colon ';' as we really want it on the next line and indented so it is really really obvious. Also extend the tests to include while and for. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: check spacing for square bracketsAndy Whitcroft
Check on the spacing before square brackets. We should only allow spaces there if this is part of a type definition or an initialialiser. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: switch -- report trailing statements on case and defaultAndy Whitcroft
Report trailing statements on case and default lines. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: allow printk strings to exceed 80 characters to maintain their ↵Andy Whitcroft
searchability Allow printk strings to break the 80 character width limits, thus keeping them complete and searchable. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: trailing statement indent: fix end of statement locationAndy Whitcroft
Fix end of statement location. Where the last line of the statement is replaced we are miss reporting the newly added replacement an incorrectly indented trailing statement for the negative context. We are also incorrectly reporting negative statements generally. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: macros: fix statement counting block end detectionAndy Whitcroft
We are incorrectly counting the lines in a block while accumulating the trailing lines in a macro statement, leading to false positives. Fix end of block handling and general counting for negative context lines. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: types: unary -- goto introduces unary contextAndy Whitcroft
When we see a goto we enter unary context. For example: goto *h; Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: comment detection: ignore macro continuation when detecting ↵Andy Whitcroft
associated comments When looking for an associated comment they may be suffixed by a macro continuation. Ignore this. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: possible types: __asm__ is never a typeAndy Whitcroft
We are false matching __asm__ as a type, and then tripping the external function checks. Squash. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: add a checkpatch warning for new uses of __initcall().Michael Ellerman
[apw@shadowen.org: generalise pattern and add tests] Signed-off-by: Michael Ellerman <michael@ellerman.id.au> Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: types: some types may also be identifiersAndy Whitcroft
Some types such as typedefs may overlap real identifiers. Be more targetted about when a type can really exist. Where it cannot let it be an identifier. This prevents false reporting of the minus '-' in unary context in the following: foo[bar->bool - 1]; Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: return is not a function -- parentheses for casts are ok tooAndy Whitcroft
Casts require parentheses so it is possible to have something like this: return (int)(*a); This miss trips the complexity function. Ensure that the two separate parenthesised sections are not coelesced. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24checkpatch: Version: 0.20Andy Whitcroft
Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24remove the v850 portAdrian Bunk
Trying to compile the v850 port brings many compile errors, one of them exists since at least kernel 2.6.19. There also seems to be noone willing to bring this port back into a usable state. This patch therefore removes the v850 port. If anyone ever decides to revive the v850 port the code will still be available from older kernels, and it wouldn't be impossible for the port to reenter the kernel if it would become actively maintained again. Signed-off-by: Adrian Bunk <bunk@kernel.org> Acked-by: Greg Ungerer <gerg@uclinux.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-22Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6Linus Torvalds
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (79 commits) arm: bus_id -> dev_name() and dev_set_name() conversions sparc64: fix up bus_id changes in sparc core code 3c59x: handle pci_name() being const MTD: handle pci_name() being const HP iLO driver sysdev: Convert the x86 mce tolerant sysdev attribute to generic attribute sysdev: Add utility functions for simple int/ulong variable sysdev attributes sysdev: Pass the attribute to the low level sysdev show/store function driver core: Suppress sysfs warnings for device_rename(). kobject: Transmit return value of call_usermodehelper() to caller sysfs-rules.txt: reword API stability statement debugfs: Implement debugfs_remove_recursive() HOWTO: change email addresses of James in HOWTO always enable FW_LOADER unless EMBEDDED=y uio-howto.tmpl: use unique output names uio-howto.tmpl: use standard copyright/legal markings sysfs: don't call notify_change sysdev: fix debugging statements in registration code. kobject: should use kobject_put() in kset-example kobject: reorder kobject to save space on 64 bit builds ...