diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/nvme.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/include/linux/nvme.h b/include/linux/nvme.h index f1974cab60cf..aa575033dbe7 100644 --- a/include/linux/nvme.h +++ b/include/linux/nvme.h | |||
| @@ -546,6 +546,8 @@ struct nvme_ns { | |||
| 546 | 546 | ||
| 547 | int ns_id; | 547 | int ns_id; |
| 548 | int lba_shift; | 548 | int lba_shift; |
| 549 | u64 mode_select_num_blocks; | ||
| 550 | u32 mode_select_block_len; | ||
| 549 | }; | 551 | }; |
| 550 | 552 | ||
| 551 | /* | 553 | /* |
| @@ -563,6 +565,39 @@ struct nvme_iod { | |||
| 563 | dma_addr_t first_dma; | 565 | dma_addr_t first_dma; |
| 564 | struct scatterlist sg[0]; | 566 | struct scatterlist sg[0]; |
| 565 | }; | 567 | }; |
| 568 | |||
| 569 | /** | ||
| 570 | * nvme_free_iod - frees an nvme_iod | ||
| 571 | * @dev: The device that the I/O was submitted to | ||
| 572 | * @iod: The memory to free | ||
| 573 | */ | ||
| 574 | void nvme_free_iod(struct nvme_dev *dev, struct nvme_iod *iod); | ||
| 575 | |||
| 576 | int nvme_setup_prps(struct nvme_dev *dev, struct nvme_common_command *cmd, | ||
| 577 | struct nvme_iod *iod, int total_len, gfp_t gfp); | ||
| 578 | struct nvme_iod *nvme_map_user_pages(struct nvme_dev *dev, int write, | ||
| 579 | unsigned long addr, unsigned length); | ||
| 580 | void nvme_unmap_user_pages(struct nvme_dev *dev, int write, | ||
| 581 | struct nvme_iod *iod); | ||
| 582 | struct nvme_queue *get_nvmeq(struct nvme_dev *dev); | ||
| 583 | void put_nvmeq(struct nvme_queue *nvmeq); | ||
| 584 | int nvme_submit_sync_cmd(struct nvme_queue *nvmeq, struct nvme_command *cmd, | ||
| 585 | u32 *result, unsigned timeout); | ||
| 586 | int nvme_submit_flush_data(struct nvme_queue *nvmeq, struct nvme_ns *ns); | ||
| 587 | int nvme_submit_admin_cmd(struct nvme_dev *, struct nvme_command *, | ||
| 588 | u32 *result); | ||
| 589 | int nvme_identify(struct nvme_dev *, unsigned nsid, unsigned cns, | ||
| 590 | dma_addr_t dma_addr); | ||
| 591 | int nvme_get_features(struct nvme_dev *dev, unsigned fid, unsigned nsid, | ||
| 592 | dma_addr_t dma_addr, u32 *result); | ||
| 593 | int nvme_set_features(struct nvme_dev *dev, unsigned fid, unsigned dword11, | ||
| 594 | dma_addr_t dma_addr, u32 *result); | ||
| 595 | |||
| 596 | struct sg_io_hdr; | ||
| 597 | |||
| 598 | int nvme_sg_io(struct nvme_ns *ns, struct sg_io_hdr __user *u_hdr); | ||
| 599 | int nvme_sg_get_version_num(int __user *ip); | ||
| 600 | |||
| 566 | #endif | 601 | #endif |
| 567 | 602 | ||
| 568 | #endif /* _LINUX_NVME_H */ | 603 | #endif /* _LINUX_NVME_H */ |
