On Thursday 20 September 2007, you wrote:Assuming that we want to go down that road, I think you can do better with more evil macro magic, by using something along the lines of #define KERN_NOTICE "<5>", #define PRINTK_CONTINUED "", #define printk(level, str, ...) \ do { \ if (sizeof(level) == 1) /* continued printk */\ actual_printk(str, __VA_ARGS__); \ else if ((level[1] - '0') < CONFIG_PRINTK_DOICARE) \ actual_printk(level str, __VA_ARGS__); \ } while(0); Then you don't have to change every single printk in the kernel, but only those that don't currently come with a log level. More importantly, you can do the conversion without a flag day, by spreading (an empty) PRINTK_CONTINUED in places that do need a printk without a log level. Arnd <>< -
| 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 |
