lkml.org 
[lkml]   [2012]   [Aug]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    Date
    SubjectRe: [PATCH v3] printk: add option to print cpu id
    On Fri, Aug 3, 2012 at 3:13 PM, Greg KH <gregkh@linuxfoundation.org> wrote:
    > On Fri, Aug 03, 2012 at 03:07:39PM -0700, Pandita, Vikram wrote:
    >> On Fri, Aug 3, 2012 at 2:59 PM, Greg KH <gregkh@linuxfoundation.org> wrote:
    >> > On Fri, Aug 03, 2012 at 02:24:20PM -0700, Pandita, Vikram wrote:
    >> >> Aaro
    >> >>
    >> >> On Fri, Aug 3, 2012 at 1:08 PM, Aaro Koskinen <aaro.koskinen@iki.fi> wrote:
    >> >> > Hi,
    >> >> >
    >> >> > On Fri, Aug 03, 2012 at 11:25:37AM -0700, Pandita, Vikram wrote:
    >> >> >> > And really: Wasting 1/3 of the 80 character line is too much.
    >> >> >>
    >> >> >> You _WASTE_ 4 chars only if you are interested in this info by
    >> >> >> enabling: CONFIG_PRINTK_CPUID
    >> >> >
    >> >> > I guess you waste 4 + 3 chars? You could optimize the length by checking
    >> >> > CONFIG_NR_CPUS?
    >> >>
    >> >> Good point.
    >> >> Looks there is a variable 'nr_cpu_ids' that could be used as well.
    >> >>
    >> >> If there is general consensus that the patch can help the arm
    >> >> community, and others in general,
    >> >> this optimization should be easy to implement - saving few chars space
    >> >> in each line of console output.
    >> >>
    >> >> For now i will stick to this v3 version of path, unless you think otherwise.
    >> >
    >> > I don't think is is something that anyone needs, and if you do, as
    >> > pointed out, you can use the trace function to make it happen.
    >> >
    >>
    >> This was something that got used internally and helped at times.
    >
    > Could you have used the trace point instead?

    As i understood the trace_prink(), one would need to modify existing
    printk -> trace_printk. Is my understanding correct?

    Most of the times the problem exhibits as a random hang, without having a clue
    which code to modify. That time one generic defconfig global switch is
    your first tool.

    Other issue i found, using this patch, that on multi-core ARM systems,
    almost 99% of times, IRQ's are handled by CPU0,
    even if CPU0 was really busy and other CPU's were free. I am yet to
    understand a good reason why.

    this patch also helped in other areas as mentioned in the thread
    http://marc.info/?l=linux-omap&m=134401269106619&w=2

    Not sure how easy its to use trace_printk for such issues, i found
    having one defconfig option was much easier
    to get going. Correct me if i have not understood trace_printk well enough.


    >
    > greg k-h


    \
     
     \ /
      Last update: 2012-08-04 01:01    [W:0.027 / U:118.516 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site