On Thu, 2007-09-20 at 14:58 -0700, Tim Bird wrote:I've converted most all of that treewide. printk(KERN_<level> to pr_<level>( It's pretty automated. $ cat pr_alert.sh #!/bin/sh egrep -r -w --include=*.[ch] -l "printk[[:space:]]*\([[:space:]]*KERN_ALERT" * | \ xargs perl ../cvt_pr.pl KERN_ALERT pr_alert $ cat cvt_pr.pl if ($#ARGV < 3) { print "usage: KERN_<level> pr_<level> files...\n"; exit; } for ($i=2; $i<$#ARGV; $i++) { PrintkSearchReplace($ARGV[$i], $ARGV[0], $ARGV[1]); } sub PrintkSearchReplace{ my($file, $search, $replace) = @_; my $content = ""; local( $/ ); open( my $fh, $file ) or die "File not found '$file'\n"; $content = <$fh>; close(my $fh); my $orig = $content; $content =~ s/\bprintk[[:space:]]*\([[:space:]]*${search}[[:space:]]*([^\"]*)\"([^\\]*)\\n\"/${replace}\(\1 \"\2\"/mgs; $content =~ s/\b${replace}\( /${replace}\(/mgs; if ($orig ne $content) { open(my $fh, ">${file}") or die "Could not open '$file'\n"; print $fh $content; close(my $fh); } } -
| Arnd Bergmann | Re: [PATCH 0/24] make atomic_read() behave consistently across all architectures |
| Andrew Morton | 2.6.23-rc1-mm2 |
| Nick Piggin | [patch 3/6] mm: fix fault vs invalidate race for linear mappings |
| KOSAKI Motohiro | [bug?] tg3: Failed to load firmware "tigon/tg3_tso.bin" |
git: | |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Herbert Xu | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | [GIT]: Networking |
| David Miller | Re: [BUG] New Kernel Bugs |
