dracut-ng - the event driven initramfs infrastructure - fix(kernel-modules): add blk_mq_alloc_disk and blk_cleanup_disk to bl… · dracut-ng/dracut-ng@b292ce7
vblk->disk = alloc_disk(1 << PART_BITS); 分配request_queue结构,从属于virtio-blk的gendisk结构下 q = vblk->disk->queue = blk_mq_init_queue(&virtio_mq_reg, vblk); 对request的操作处理函数都在virtio_mq_reg结构的virtio_mq_ops中: static struct blk_mq_ops virtio_mq_ops = { .queue_...
vblk->disk = alloc_disk(1 << PART_BITS); memset(&vblk->tag_set, 0, sizeof(vblk->tag_set)); vblk->tag_set.ops = &virtio_mq_ops; vblk->tag_set.queue_depth = virtblk_queue_depth; vblk->tag_set.numa_node = NUMA_NO_NODE; vblk->tag_set.flags = BLK_MQ_F_SHOULD_MERGE...
disk = alloc_disk(0);if(!disk) {blk_cleanup_queue(pmem->pmem_queue);return-ENOMEM; } disk->major = pmem_major; disk->first_minor =0; disk->fops = &pmem_fops; disk->private_data = pmem; disk->queue= pmem->pmem_queue; disk->flags = GENHD_FL_EXT_DEVT; nvdimm_namespace_disk_...
err_alloc_disk: blk_cleanup_queue(host->queue); host->queue=NULL; err_blk_init_queue: out:returnretval; } 开发者ID:mozgwar,项目名称:GC-Wii-Linux-Kernel-3.12.y,代码行数:51,代码来源:gcn-sd.c 示例7: slave_configure ▲点赞 1▼ ...
static int virtblk_get_id(struct gendisk *disk, char *id_str) { struct virtio_blk *vblk = disk->private_data; struct request_queue *q = vblk->disk->queue; struct request *req; struct virtblk_req *vbr; int err;req = blk_mq_alloc_request(q, REQ_OP_DRV_IN, 0); ...
poolIdDisk domain ID. The value ranges from 0 to n minus one, where n indicates the maximum number of disk domains supported by a product. Views Diagnostic view Usage Guidelines None Example View the waiting alloc block queue information of disk domain 0. ...
poolIdDisk domain ID. The value ranges from 0 to n minus one, where n indicates the maximum number of disk domains supported by a product. Views Diagnostic view Usage Guidelines None Example View the waiting alloc block queue information of disk domain 0. ...
vblk->disk = alloc_disk(1 << PART_BITS); if (!vblk->disk) { err = -ENOMEM; goto out_free_vq; } /* Default queue sizing is to fill the ring. */ if (!virtblk_queue_depth) { virtblk_queue_depth = vblk->vqs[0].vq->num_free; /* ... but without indirect ...
调用blk_alloc_queue_node分配请求队列的内存,分配的内存节点与设备连接的NUMA节点一致,避免远端内存访问问题。 调用blk_mq_init_allocated_queue初始化分配的请求队列(request_queue),blk-mq的request_queue中包含两层队列,即percpu的软件队列(ctx)和与块设备硬件队列一一对应的硬件派发队列(hctx)。这个初始化过程主要...