Lines Matching refs:disk

52 static int drbd_open(struct gendisk *disk, blk_mode_t mode);
149 io_allowed = (device->state.disk >= mins);
290 * tl_abort_disk_io() - Abort disk I/O for all requests for a certain device in the TL
849 uuid_flags |= device->new_state_tmp.disk == D_INCONSISTENT ? 4 : 0;
891 D_ASSERT(device, device->state.disk == D_UP_TO_DATE);
1280 drbd_err(device, "Failed to write bitmap to disk!\n");
1889 static int drbd_open(struct gendisk *disk, blk_mode_t mode)
1891 struct drbd_device *device = disk->private_data;
1945 .disk = D_DISKLESS,
2689 struct gendisk *disk;
2719 disk = blk_alloc_disk(&lim, NUMA_NO_NODE);
2720 if (IS_ERR(disk)) {
2721 err = PTR_ERR(disk);
2725 device->vdisk = disk;
2726 device->rq_queue = disk->queue;
2728 set_disk_ro(disk, true);
2730 disk->major = DRBD_MAJOR;
2731 disk->first_minor = minor;
2732 disk->minors = 1;
2733 disk->fops = &drbd_ops;
2734 disk->flags |= GENHD_FL_NO_PART;
2735 sprintf(disk->disk_name, "drbd%d", minor);
2736 disk->private_data = device;
2738 blk_queue_flag_set(QUEUE_FLAG_STABLE_WRITES, disk->queue);
2739 blk_queue_write_cache(disk->queue, true, true);
2793 err = add_disk(disk);
2830 put_disk(disk);
3057 * metadata even if we detach due to a disk failure! */
3128 /* The on-disk size of the activity log, calculated from offsets, and
3132 * fits in the available on-disk activity log size.
3135 * of possible unused padding space in the on disk layout. */
3170 /* should fit (for now: exactly) into the available on-disk space;
3218 if (device->state.disk != D_DISKLESS)
3237 called BEFORE disk is attached */