Changeset 5772aa1 in mainline for uspace/srv/bd/vbd/disk.c


Ignore:
Timestamp:
2017-07-14T21:31:44Z (8 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9f64c1e
Parents:
94c05b89
Message:

VBD needs to empty a newly created partition before exposing it to the volume server.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/bd/vbd/disk.c

    r94c05b89 r5772aa1  
    3939#include <errno.h>
    4040#include <io/log.h>
     41#include <label/empty.h>
     42#include <label/label.h>
    4143#include <loc.h>
    4244#include <stdio.h>
     
    842844        if (rc != EOK) {
    843845                log_msg(LOG_DEFAULT, LVL_ERROR, "Error creating partition.");
     846                goto error;
     847        }
     848
     849        rc = label_part_empty(lpart);
     850        if (rc != EOK) {
     851                log_msg(LOG_DEFAULT, LVL_ERROR, "Error emptying partition.");
    844852                goto error;
    845853        }
Note: See TracChangeset for help on using the changeset viewer.