lkml.org 
[lkml]   [2017]   [Jan]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 13/60] staging: lustre: obdclass: health_check to report unhealthy upon LBUG
    Date
    From: Bruno Faccini <bruno.faccini@intel.com>

    When a LBUG has occurred, without panic_on_lbug being set,
    health_check sysfs file must return an unhealthy state.

    Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
    Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-7486
    Reviewed-on: http://review.whamcloud.com/17981
    Reviewed-by: Bobi Jam <bobijam@hotmail.com>
    Reviewed-by: Niu Yawei <yawei.niu@intel.com>
    Reviewed-by: James Simmons <uja.ornl@yahoo.com>
    Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
    Signed-off-by: James Simmons <jsimmons@infradead.org>
    ---
    drivers/staging/lustre/lustre/obdclass/linux/linux-module.c | 6 ++++--
    1 file changed, 4 insertions(+), 2 deletions(-)

    diff --git a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
    index 22e6d1f..ef25db6 100644
    --- a/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
    +++ b/drivers/staging/lustre/lustre/obdclass/linux/linux-module.c
    @@ -224,8 +224,10 @@ static ssize_t pinger_show(struct kobject *kobj, struct attribute *attr,
    int i;
    size_t len = 0;

    - if (libcfs_catastrophe)
    - return sprintf(buf, "LBUG\n");
    + if (libcfs_catastrophe) {
    + len = sprintf(buf, "LBUG\n");
    + healthy = false;
    + }

    read_lock(&obd_dev_lock);
    for (i = 0; i < class_devno_max(); i++) {
    --
    1.8.3.1
    \
     
     \ /
      Last update: 2017-01-29 01:15    [W:4.114 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site