lkml.org 
[lkml]   [2012]   [May]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH EDAC v26 36/66] i5400_edac: improve debug messages to better represent the filled memory
    Date
    Improves the debug output message, in order to better represent the
    memory controller hierarchy, when outputing the debug messages.

    No functional changes when debug is disabled.

    Reviewed-by: Aristeu Rozanski <arozansk@redhat.com>
    Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
    ---
    drivers/edac/i5400_edac.c | 15 ++++++++++++++-
    1 files changed, 14 insertions(+), 1 deletions(-)

    diff --git a/drivers/edac/i5400_edac.c b/drivers/edac/i5400_edac.c
    index ff7bf80..6640c29 100644
    --- a/drivers/edac/i5400_edac.c
    +++ b/drivers/edac/i5400_edac.c
    @@ -963,7 +963,7 @@ static void calculate_dimm_size(struct i5400_pvt *pvt)
    int dimm, max_dimms;
    char *p, *mem_buffer;
    int space, n;
    - int channel;
    + int channel, branch;

    /* ================= Generate some debug output ================= */
    space = PAGE_SIZE;
    @@ -1028,6 +1028,19 @@ static void calculate_dimm_size(struct i5400_pvt *pvt)
    space -= n;
    }

    + space -= n;
    + debugf2("%s\n", mem_buffer);
    + p = mem_buffer;
    + space = PAGE_SIZE;
    +
    + n = snprintf(p, space, " ");
    + p += n;
    + for (branch = 0; branch < MAX_BRANCHES; branch++) {
    + n = snprintf(p, space, " branch %d | ", branch);
    + p += n;
    + space -= n;
    + }
    +
    /* output the last message and free buffer */
    debugf2("%s\n", mem_buffer);
    kfree(mem_buffer);
    --
    1.7.8


    \
     
     \ /
      Last update: 2012-05-18 19:41    [W:4.867 / U:0.000 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site