Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset e11c527 in mainline for uspace/srv/bd/vbd/types/vbd.h


Ignore:
Timestamp:
2016-02-18T14:31:00Z (5 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
master
Children:
53e3950
Parents:
8e670dd
Message:

When disk disappears, VBD should be able to force removal of partitions, even if they are open.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/bd/vbd/types/vbd.h

    r8e670dd re11c527  
    11/*
    2  * Copyright (c) 2015 Jiri Svoboda
     2 * Copyright (c) 2016 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    3939
    4040#include <adt/list.h>
     41#include <atomic.h>
    4142#include <bd_srv.h>
    4243#include <label.h>
     
    4849typedef sysarg_t vbds_part_id_t;
    4950
     51typedef enum {
     52        /** No flags */
     53        vrf_none = 0,
     54        /** Force removal */
     55        vrf_force = 0x1
     56} vbds_rem_flag_t;
     57
    5058/** Partition */
    5159typedef struct {
     60        /** Reader held during I/O */
     61        fibril_rwlock_t lock;
    5262        /** Disk this partition belongs to */
    5363        struct vbds_disk *disk;
     
    7282        /** Number of blocks */
    7383        aoff64_t nblocks;
     84        /** Reference count */
     85        atomic_t refcnt;
    7486} vbds_part_t;
    7587
Note: See TracChangeset for help on using the changeset viewer.