#! /usr/bin/perl # # checkversion find uses of LINUX_VERSION_CODE or KERNEL_VERSION # without including , or cases of # including that don't need it. # Copyright (C) 2003, Randy Dunlap use strict; $| = 1; my $debugging; foreach my $file (@ARGV) { next if $file =~ "include/linux/version\.h"; # Open this file. open( my $f, '<', $file ) or die "Can't open $file: $!\n"; # Initialize variables. my ($fInComment, $fInString, $fUseVersion); my $iLinuxVersion = 0; while (<$f>) { # Strip comments. $fInComment && (s+^.*?\*/+ +o ? ($fInComment = 0) : next); m+/\*+o && (s+/\*.*?\*/+ +go, (s+/\*.*$+ +o && ($fInComment = 1))); # Pick up definitions. if ( m/^\s*#/o ) { $iLinuxVersion = $. if m/^\s*#\s*include\s*"linux\/version\.h"/o; } # Strip strings. $fInString && (s+^.*?"+ +o ? ($fInString = 0) : next); m+"+o && (s+".*?"+ +go, (s+".*$+ +o && ($fInString = 1))); # Pick up definitions. if ( m/^\s*#/o ) { $iLinuxVersion = $. if m/^\s*#\s*include\s*/o; } # Look for uses: LINUX_VERSION_CODE, KERNEL_VERSION, UTS_RELEASE if (($_ =~ /LINUX_VERSION_CODE/) || ($_ =~ /\WKERNEL_VERSION/)) { $fUseVersion = 1; last if $iLinuxVersion; } } # Report used version IDs without include? if ($fUseVersion && ! $iLinuxVersion) { print "$file: $.: need linux/version.h\n"; } # Report superfluous includes. if ($iLinuxVersion && ! $fUseVersion) { print "$file: $iLinuxVersion linux/version.h not needed.\n"; } # debug: report OK results: if ($debugging) { if ($iLinuxVersion && $fUseVersion) { print "$file: version use is OK ($iLinuxVersion)\n"; } if (! $iLinuxVersion && ! $fUseVersion) { print "$file: version use is OK (none)\n"; } } close($f); } cgit.cgi/linux/net-next.git/tree/drivers/usb/musb?h=nds-private-remove&id=3f67790d2b7e322bcf363ec717085dd78c3ea7cd'>treecommitdiff
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-02-03 13:46:38 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2017-02-03 13:46:38 -0800
commit3f67790d2b7e322bcf363ec717085dd78c3ea7cd (patch)
tree7be20232078a2e801ed93bcdb72f0d955dd9836f /drivers/usb/musb
parentcd44691f7177b2c1e1509d1a17d9b198ebaa34eb (diff)
parent206c4720092d2a24bfefc041b377e889a220ffbf (diff)
Merge tag 'regulator-fix-v4.10-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
Pull regulator fixes from Mark Brown: "Three changes here: two run of the mill driver specific fixes and a change from Mark Rutland which reverts some new device specific ACPI binding code which was added during the merge window as there are concerns about this sending the wrong signal about usage of regulators in ACPI systems" * tag 'regulator-fix-v4.10-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator: regulator: fixed: Revert support for ACPI interface regulator: axp20x: AXP806: Fix dcdcb being set instead of dcdce regulator: twl6030: fix range comparison, allowing vsel = 59
Diffstat (limited to 'drivers/usb/musb')