scsi: cxlflash: Hide FC internals behind common access routine

As staging to support FC-related updates to the SISlite specification,
introduce helper routines to obtain references to FC resources that exist
within the global map. This will allow changes to the underlying global map
structure without impacting existing code paths.

Signed-off-by: Matthew R. Ochs <mrochs@linux.vnet.ibm.com>
Signed-off-by: Uma Krishnan <ukrishn@linux.vnet.ibm.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
Matthew R. Ochs
2017-04-12 14:14:17 -05:00
committed by Martin K. Petersen
부모 8fa4f1770d
커밋 0aa14887c6
3개의 변경된 파일61개의 추가작업 그리고 41개의 파일을 삭제

파일 보기

@@ -240,6 +240,20 @@ static inline u64 lun_to_lunid(u64 lun)
return be64_to_cpu(lun_id);
}
static inline __be64 __iomem *get_fc_port_regs(struct cxlflash_cfg *cfg, int i)
{
struct afu *afu = cfg->afu;
return &afu->afu_map->global.fc_regs[i][0];
}
static inline __be64 __iomem *get_fc_port_luns(struct cxlflash_cfg *cfg, int i)
{
struct afu *afu = cfg->afu;
return &afu->afu_map->global.fc_port[i][0];
}
int cxlflash_afu_sync(struct afu *, ctx_hndl_t, res_hndl_t, u8);
void cxlflash_list_init(void);
void cxlflash_term_global_luns(void);