Changeset d199a6f in mainline for uspace/srv/bd/hr/raid1.c


Ignore:
Timestamp:
2024-11-15T21:32:20Z (8 months ago)
Author:
Miroslav Cimerman <mc@…>
Children:
7b359f5
Parents:
dfa2313
Message:

hr: DPRINTF, ERR_PRINTF → HR_DEBUG, HR_ERROR

Also add HR_WARN for warning level.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/bd/hr/raid1.c

    rdfa2313 rd199a6f  
    8787
    8888        if (new_volume->dev_no < 2) {
    89                 ERR_PRINTF("RAID 1 array needs at least 2 devices\n");
     89                HR_ERROR("RAID 1 array needs at least 2 devices\n");
    9090                return EINVAL;
    9191        }
     
    127127static errno_t hr_raid1_bd_open(bd_srvs_t *bds, bd_srv_t *bd)
    128128{
    129         DPRINTF("hr_bd_open()\n");
     129        HR_DEBUG("hr_bd_open()\n");
    130130        return EOK;
    131131}
     
    133133static errno_t hr_raid1_bd_close(bd_srv_t *bd)
    134134{
    135         DPRINTF("hr_bd_close()\n");
     135        HR_DEBUG("hr_bd_close()\n");
    136136        return EOK;
    137137}
     
    192192        if (healthy == 0) {
    193193                if (old_state != HR_VOL_FAULTY) {
    194                         ERR_PRINTF("RAID 1 needs at least 1 extent to be"
     194                        HR_WARN("RAID 1 needs at least 1 extent to be"
    195195                            "ONLINE, marking \"%s\" (%lu) volume as FAULTY",
    196196                            vol->devname, vol->svc_id);
     
    200200        } else if (healthy < vol->dev_no) {
    201201                if (old_state != HR_VOL_DEGRADED) {
    202                         ERR_PRINTF("RAID 1 array \"%s\" (%lu) has some "
     202                        HR_WARN("RAID 1 array \"%s\" (%lu) has some "
    203203                            "inactive extent(s), marking volume as DEGRADED",
    204204                            vol->devname, vol->svc_id);
     
    208208        } else {
    209209                if (old_state != HR_VOL_ONLINE) {
    210                         DPRINTF("RAID 1 array \"%s\" (%lu) has all extents "
     210                        HR_WARN("RAID 1 array \"%s\" (%lu) has all extents "
    211211                            "active, marking volume as ONLINE",
    212212                            vol->devname, vol->svc_id);
Note: See TracChangeset for help on using the changeset viewer.