lkml.org 
[lkml]   [2012]   [Apr]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    Subjectehci dynamic debug problem
    Hi,

    I have a quirky device and enabled dynamic debug to
    see the ehci driver debug messages to help me diagnose
    the problem. I see stuff like this:

    [1790542.363321] ehci_hub_control:940: ehci_hcd 0000:00:1a.0: \xffffffd8\xffffff94\xffffff94\xffffffa8\xffffff81\xffffffff\xffffffff\xffffffff\xffffffff}[<\xffffff81\xffffffff\xffffffff\xffffffff\xffffffff\x01
    [1790542.363470] ehci_hub_control:940: ehci_hcd 0000:00:1a.0: \xffffffd8\xffffff94\xffffff94\xffffffa8\xffffff81\xffffffff\xffffffff\xffffffff\xffffffff}[<\xffffff81\xffffffff\xffffffff\xffffffff\xffffffff\x01

    The problem is in ehci-dbg.c:

    #define dbg_port(ehci, label, port, status) { \
    char _buf [80]; \
    dbg_port_buf (_buf, sizeof _buf, label, port, status); \
    ehci_dbg (ehci, "%s\n", _buf); \
    }

    dbg_port_buf() is a no op when DEBUG is not defined, thus
    the ehci_dbg() prints uninitialized memory.


    Does dynamic debug offer an "is the message two lines below enabled" test?
    Simply changing the "#ifdef DEBUG" for dbg_port_buf()
    to "#if defined(DEBUG) || defined(CONFIG_DYNAMIC_DEBUG)"
    is probably not acceptable due to the overhead of dbg_port_buf()?


    Thanks,
    Johannes


    \
     
     \ /
      Last update: 2012-04-13 10:59    [W:2.805 / U:0.008 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site