Lines Matching full:disk

14 static int nvme_disk_init(struct disk_info *disk)  in nvme_disk_init()  argument
19 static int nvme_disk_status(struct disk_info *disk) in nvme_disk_status() argument
24 static int nvme_disk_read(struct disk_info *disk, in nvme_disk_read() argument
29 struct nvme_namespace *ns = CONTAINER_OF(disk->name, in nvme_disk_read()
42 nvme_lock(disk->dev); in nvme_disk_read()
63 LOG_WRN("Reading at sector %u (count %d) on disk %s failed", in nvme_disk_read()
69 nvme_unlock(disk->dev); in nvme_disk_read()
73 static int nvme_disk_write(struct disk_info *disk, in nvme_disk_write() argument
78 struct nvme_namespace *ns = CONTAINER_OF(disk->name, in nvme_disk_write()
91 nvme_lock(disk->dev); in nvme_disk_write()
112 LOG_WRN("Writing at sector %u (count %d) on disk %s failed", in nvme_disk_write()
118 nvme_unlock(disk->dev); in nvme_disk_write()
142 LOG_ERR("Flushing disk %s failed", ns->name); in nvme_disk_flush()
150 static int nvme_disk_ioctl(struct disk_info *disk, uint8_t cmd, void *buff) in nvme_disk_ioctl() argument
152 struct nvme_namespace *ns = CONTAINER_OF(disk->name, in nvme_disk_ioctl()
156 nvme_lock(disk->dev); in nvme_disk_ioctl()
193 nvme_unlock(disk->dev); in nvme_disk_ioctl()
206 struct disk_info *disk) in nvme_namespace_disk_setup() argument
208 disk->name = ns->name; in nvme_namespace_disk_setup()
209 disk->ops = &nvme_disk_ops; in nvme_namespace_disk_setup()
210 disk->dev = ns->ctrlr->dev; in nvme_namespace_disk_setup()
212 return disk_access_register(disk); in nvme_namespace_disk_setup()