4 Jul 22:36
Re: the printk problem
Matthew Wilcox <matthew <at> wil.cx>
2008-07-04 20:36:21 GMT
2008-07-04 20:36:21 GMT
On Fri, Jul 04, 2008 at 01:02:05PM -0700, Linus Torvalds wrote: > On Fri, 4 Jul 2008, Linus Torvalds wrote: > > > > so I think we could easily just say that we extend %p in various ways: > > > > - %pS - print pointer as a symbol > > > > and leave tons of room for future extensions for different kinds of > > pointers. > > So here's a totally untested example patch of this, which could probably > easily be extended to to other things. > > I actually made it '%pF' and '%pS' for a Function descriptor pointer and > normal Symbolic pointer respectively, because of the stupid things ia64 > and PPC64 do with the pointer indirection through function descriptors. It's also true for parisc, fwiw. Added a cc to them. > That function descriptor indirection is totally untested, and I did it > with a > > pagefault_disable(); > __get_user(..) > pagefault_enable(); > > thing because I thought it would be nice if printk() was always safe, and > passing bogus function pointers to '%pF' should try to work, but quite > frankly, I didn't even check that that part compiles, much less works. >(Continue reading)
RSS Feed