162306a36Sopenharmony_ci/*
262306a36Sopenharmony_ci * drivers/dma/fsl_raid.h
362306a36Sopenharmony_ci *
462306a36Sopenharmony_ci * Freescale RAID Engine device driver
562306a36Sopenharmony_ci *
662306a36Sopenharmony_ci * Author:
762306a36Sopenharmony_ci *	Harninder Rai <harninder.rai@freescale.com>
862306a36Sopenharmony_ci *	Naveen Burmi <naveenburmi@freescale.com>
962306a36Sopenharmony_ci *
1062306a36Sopenharmony_ci * Rewrite:
1162306a36Sopenharmony_ci *	Xuelin Shi <xuelin.shi@freescale.com>
1262306a36Sopenharmony_ci
1362306a36Sopenharmony_ci * Copyright (c) 2010-2012 Freescale Semiconductor, Inc.
1462306a36Sopenharmony_ci *
1562306a36Sopenharmony_ci * Redistribution and use in source and binary forms, with or without
1662306a36Sopenharmony_ci * modification, are permitted provided that the following conditions are met:
1762306a36Sopenharmony_ci *     * Redistributions of source code must retain the above copyright
1862306a36Sopenharmony_ci *       notice, this list of conditions and the following disclaimer.
1962306a36Sopenharmony_ci *     * Redistributions in binary form must reproduce the above copyright
2062306a36Sopenharmony_ci *       notice, this list of conditions and the following disclaimer in the
2162306a36Sopenharmony_ci *       documentation and/or other materials provided with the distribution.
2262306a36Sopenharmony_ci *     * Neither the name of Freescale Semiconductor nor the
2362306a36Sopenharmony_ci *       names of its contributors may be used to endorse or promote products
2462306a36Sopenharmony_ci *       derived from this software without specific prior written permission.
2562306a36Sopenharmony_ci *
2662306a36Sopenharmony_ci * ALTERNATIVELY, this software may be distributed under the terms of the
2762306a36Sopenharmony_ci * GNU General Public License ("GPL") as published by the Free Software
2862306a36Sopenharmony_ci * Foundation, either version 2 of that License or (at your option) any
2962306a36Sopenharmony_ci * later version.
3062306a36Sopenharmony_ci *
3162306a36Sopenharmony_ci * THIS SOFTWARE IS PROVIDED BY Freescale Semiconductor ``AS IS'' AND ANY
3262306a36Sopenharmony_ci * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
3362306a36Sopenharmony_ci * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
3462306a36Sopenharmony_ci * DISCLAIMED. IN NO EVENT SHALL Freescale Semiconductor BE LIABLE FOR ANY
3562306a36Sopenharmony_ci * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
3662306a36Sopenharmony_ci * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
3762306a36Sopenharmony_ci * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
3862306a36Sopenharmony_ci * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
3962306a36Sopenharmony_ci * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
4062306a36Sopenharmony_ci * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
4162306a36Sopenharmony_ci *
4262306a36Sopenharmony_ci */
4362306a36Sopenharmony_ci
4462306a36Sopenharmony_ci#define FSL_RE_MAX_CHANS		4
4562306a36Sopenharmony_ci#define FSL_RE_DPAA_MODE		BIT(30)
4662306a36Sopenharmony_ci#define FSL_RE_NON_DPAA_MODE		BIT(31)
4762306a36Sopenharmony_ci#define FSL_RE_GFM_POLY			0x1d000000
4862306a36Sopenharmony_ci#define FSL_RE_ADD_JOB(x)		((x) << 16)
4962306a36Sopenharmony_ci#define FSL_RE_RMVD_JOB(x)		((x) << 16)
5062306a36Sopenharmony_ci#define FSL_RE_CFG1_CBSI		0x08000000
5162306a36Sopenharmony_ci#define FSL_RE_CFG1_CBS0		0x00080000
5262306a36Sopenharmony_ci#define FSL_RE_SLOT_FULL_SHIFT		8
5362306a36Sopenharmony_ci#define FSL_RE_SLOT_FULL(x)		((x) >> FSL_RE_SLOT_FULL_SHIFT)
5462306a36Sopenharmony_ci#define FSL_RE_SLOT_AVAIL_SHIFT		8
5562306a36Sopenharmony_ci#define FSL_RE_SLOT_AVAIL(x)		((x) >> FSL_RE_SLOT_AVAIL_SHIFT)
5662306a36Sopenharmony_ci#define FSL_RE_PQ_OPCODE		0x1B
5762306a36Sopenharmony_ci#define FSL_RE_XOR_OPCODE		0x1A
5862306a36Sopenharmony_ci#define FSL_RE_MOVE_OPCODE		0x8
5962306a36Sopenharmony_ci#define FSL_RE_FRAME_ALIGN		16
6062306a36Sopenharmony_ci#define FSL_RE_BLOCK_SIZE		0x3 /* 4096 bytes */
6162306a36Sopenharmony_ci#define FSL_RE_CACHEABLE_IO		0x0
6262306a36Sopenharmony_ci#define FSL_RE_BUFFER_OUTPUT		0x0
6362306a36Sopenharmony_ci#define FSL_RE_INTR_ON_ERROR		0x1
6462306a36Sopenharmony_ci#define FSL_RE_DATA_DEP			0x1
6562306a36Sopenharmony_ci#define FSL_RE_ENABLE_DPI		0x0
6662306a36Sopenharmony_ci#define FSL_RE_RING_SIZE		0x400
6762306a36Sopenharmony_ci#define FSL_RE_RING_SIZE_MASK		(FSL_RE_RING_SIZE - 1)
6862306a36Sopenharmony_ci#define FSL_RE_RING_SIZE_SHIFT		8
6962306a36Sopenharmony_ci#define FSL_RE_ADDR_BIT_SHIFT		4
7062306a36Sopenharmony_ci#define FSL_RE_ADDR_BIT_MASK		(BIT(FSL_RE_ADDR_BIT_SHIFT) - 1)
7162306a36Sopenharmony_ci#define FSL_RE_ERROR			0x40000000
7262306a36Sopenharmony_ci#define FSL_RE_INTR			0x80000000
7362306a36Sopenharmony_ci#define FSL_RE_CLR_INTR			0x80000000
7462306a36Sopenharmony_ci#define FSL_RE_PAUSE			0x80000000
7562306a36Sopenharmony_ci#define FSL_RE_ENABLE			0x80000000
7662306a36Sopenharmony_ci#define FSL_RE_REG_LIODN_MASK		0x00000FFF
7762306a36Sopenharmony_ci
7862306a36Sopenharmony_ci#define FSL_RE_CDB_OPCODE_MASK		0xF8000000
7962306a36Sopenharmony_ci#define FSL_RE_CDB_OPCODE_SHIFT		27
8062306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLEN_MASK		0x03000000
8162306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLEN_SHIFT		24
8262306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLQ1_MASK		0x00F00000
8362306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLQ1_SHIFT		20
8462306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLQ2_MASK		0x000F0000
8562306a36Sopenharmony_ci#define FSL_RE_CDB_EXCLQ2_SHIFT		16
8662306a36Sopenharmony_ci#define FSL_RE_CDB_BLKSIZE_MASK		0x0000C000
8762306a36Sopenharmony_ci#define FSL_RE_CDB_BLKSIZE_SHIFT	14
8862306a36Sopenharmony_ci#define FSL_RE_CDB_CACHE_MASK		0x00003000
8962306a36Sopenharmony_ci#define FSL_RE_CDB_CACHE_SHIFT		12
9062306a36Sopenharmony_ci#define FSL_RE_CDB_BUFFER_MASK		0x00000800
9162306a36Sopenharmony_ci#define FSL_RE_CDB_BUFFER_SHIFT		11
9262306a36Sopenharmony_ci#define FSL_RE_CDB_ERROR_MASK		0x00000400
9362306a36Sopenharmony_ci#define FSL_RE_CDB_ERROR_SHIFT		10
9462306a36Sopenharmony_ci#define FSL_RE_CDB_NRCS_MASK		0x0000003C
9562306a36Sopenharmony_ci#define FSL_RE_CDB_NRCS_SHIFT		6
9662306a36Sopenharmony_ci#define FSL_RE_CDB_DEPEND_MASK		0x00000008
9762306a36Sopenharmony_ci#define FSL_RE_CDB_DEPEND_SHIFT		3
9862306a36Sopenharmony_ci#define FSL_RE_CDB_DPI_MASK		0x00000004
9962306a36Sopenharmony_ci#define FSL_RE_CDB_DPI_SHIFT		2
10062306a36Sopenharmony_ci
10162306a36Sopenharmony_ci/*
10262306a36Sopenharmony_ci * the largest cf block is 19*sizeof(struct cmpnd_frame), which is 304 bytes.
10362306a36Sopenharmony_ci * here 19 = 1(cdb)+2(dest)+16(src), align to 64bytes, that is 320 bytes.
10462306a36Sopenharmony_ci * the largest cdb block: struct pq_cdb which is 180 bytes, adding to cf block
10562306a36Sopenharmony_ci * 320+180=500, align to 64bytes, that is 512 bytes.
10662306a36Sopenharmony_ci */
10762306a36Sopenharmony_ci#define FSL_RE_CF_DESC_SIZE		320
10862306a36Sopenharmony_ci#define FSL_RE_CF_CDB_SIZE		512
10962306a36Sopenharmony_ci#define FSL_RE_CF_CDB_ALIGN		64
11062306a36Sopenharmony_ci
11162306a36Sopenharmony_cistruct fsl_re_ctrl {
11262306a36Sopenharmony_ci	/* General Configuration Registers */
11362306a36Sopenharmony_ci	__be32 global_config;	/* Global Configuration Register */
11462306a36Sopenharmony_ci	u8     rsvd1[4];
11562306a36Sopenharmony_ci	__be32 galois_field_config; /* Galois Field Configuration Register */
11662306a36Sopenharmony_ci	u8     rsvd2[4];
11762306a36Sopenharmony_ci	__be32 jq_wrr_config;   /* WRR Configuration register */
11862306a36Sopenharmony_ci	u8     rsvd3[4];
11962306a36Sopenharmony_ci	__be32 crc_config;	/* CRC Configuration register */
12062306a36Sopenharmony_ci	u8     rsvd4[228];
12162306a36Sopenharmony_ci	__be32 system_reset;	/* System Reset Register */
12262306a36Sopenharmony_ci	u8     rsvd5[252];
12362306a36Sopenharmony_ci	__be32 global_status;	/* Global Status Register */
12462306a36Sopenharmony_ci	u8     rsvd6[832];
12562306a36Sopenharmony_ci	__be32 re_liodn_base;	/* LIODN Base Register */
12662306a36Sopenharmony_ci	u8     rsvd7[1712];
12762306a36Sopenharmony_ci	__be32 re_version_id;	/* Version ID register of RE */
12862306a36Sopenharmony_ci	__be32 re_version_id_2; /* Version ID 2 register of RE */
12962306a36Sopenharmony_ci	u8     rsvd8[512];
13062306a36Sopenharmony_ci	__be32 host_config;	/* Host I/F Configuration Register */
13162306a36Sopenharmony_ci};
13262306a36Sopenharmony_ci
13362306a36Sopenharmony_cistruct fsl_re_chan_cfg {
13462306a36Sopenharmony_ci	/* Registers for JR interface */
13562306a36Sopenharmony_ci	__be32 jr_config_0;	/* Job Queue Configuration 0 Register */
13662306a36Sopenharmony_ci	__be32 jr_config_1;	/* Job Queue Configuration 1 Register */
13762306a36Sopenharmony_ci	__be32 jr_interrupt_status; /* Job Queue Interrupt Status Register */
13862306a36Sopenharmony_ci	u8     rsvd1[4];
13962306a36Sopenharmony_ci	__be32 jr_command;	/* Job Queue Command Register */
14062306a36Sopenharmony_ci	u8     rsvd2[4];
14162306a36Sopenharmony_ci	__be32 jr_status;	/* Job Queue Status Register */
14262306a36Sopenharmony_ci	u8     rsvd3[228];
14362306a36Sopenharmony_ci
14462306a36Sopenharmony_ci	/* Input Ring */
14562306a36Sopenharmony_ci	__be32 inbring_base_h;	/* Inbound Ring Base Address Register - High */
14662306a36Sopenharmony_ci	__be32 inbring_base_l;	/* Inbound Ring Base Address Register - Low */
14762306a36Sopenharmony_ci	__be32 inbring_size;	/* Inbound Ring Size Register */
14862306a36Sopenharmony_ci	u8     rsvd4[4];
14962306a36Sopenharmony_ci	__be32 inbring_slot_avail; /* Inbound Ring Slot Available Register */
15062306a36Sopenharmony_ci	u8     rsvd5[4];
15162306a36Sopenharmony_ci	__be32 inbring_add_job;	/* Inbound Ring Add Job Register */
15262306a36Sopenharmony_ci	u8     rsvd6[4];
15362306a36Sopenharmony_ci	__be32 inbring_cnsmr_indx; /* Inbound Ring Consumer Index Register */
15462306a36Sopenharmony_ci	u8     rsvd7[220];
15562306a36Sopenharmony_ci
15662306a36Sopenharmony_ci	/* Output Ring */
15762306a36Sopenharmony_ci	__be32 oubring_base_h;	/* Outbound Ring Base Address Register - High */
15862306a36Sopenharmony_ci	__be32 oubring_base_l;	/* Outbound Ring Base Address Register - Low */
15962306a36Sopenharmony_ci	__be32 oubring_size;	/* Outbound Ring Size Register */
16062306a36Sopenharmony_ci	u8     rsvd8[4];
16162306a36Sopenharmony_ci	__be32 oubring_job_rmvd; /* Outbound Ring Job Removed Register */
16262306a36Sopenharmony_ci	u8     rsvd9[4];
16362306a36Sopenharmony_ci	__be32 oubring_slot_full; /* Outbound Ring Slot Full Register */
16462306a36Sopenharmony_ci	u8     rsvd10[4];
16562306a36Sopenharmony_ci	__be32 oubring_prdcr_indx; /* Outbound Ring Producer Index */
16662306a36Sopenharmony_ci};
16762306a36Sopenharmony_ci
16862306a36Sopenharmony_ci/*
16962306a36Sopenharmony_ci * Command Descriptor Block (CDB) for unicast move command.
17062306a36Sopenharmony_ci * In RAID Engine terms, memcpy is done through move command
17162306a36Sopenharmony_ci */
17262306a36Sopenharmony_cistruct fsl_re_move_cdb {
17362306a36Sopenharmony_ci	__be32 cdb32;
17462306a36Sopenharmony_ci};
17562306a36Sopenharmony_ci
17662306a36Sopenharmony_ci/* Data protection/integrity related fields */
17762306a36Sopenharmony_ci#define FSL_RE_DPI_APPS_MASK		0xC0000000
17862306a36Sopenharmony_ci#define FSL_RE_DPI_APPS_SHIFT		30
17962306a36Sopenharmony_ci#define FSL_RE_DPI_REF_MASK		0x30000000
18062306a36Sopenharmony_ci#define FSL_RE_DPI_REF_SHIFT		28
18162306a36Sopenharmony_ci#define FSL_RE_DPI_GUARD_MASK		0x0C000000
18262306a36Sopenharmony_ci#define FSL_RE_DPI_GUARD_SHIFT		26
18362306a36Sopenharmony_ci#define FSL_RE_DPI_ATTR_MASK		0x03000000
18462306a36Sopenharmony_ci#define FSL_RE_DPI_ATTR_SHIFT		24
18562306a36Sopenharmony_ci#define FSL_RE_DPI_META_MASK		0x0000FFFF
18662306a36Sopenharmony_ci
18762306a36Sopenharmony_cistruct fsl_re_dpi {
18862306a36Sopenharmony_ci	__be32 dpi32;
18962306a36Sopenharmony_ci	__be32 ref;
19062306a36Sopenharmony_ci};
19162306a36Sopenharmony_ci
19262306a36Sopenharmony_ci/*
19362306a36Sopenharmony_ci * CDB for GenQ command. In RAID Engine terminology, XOR is
19462306a36Sopenharmony_ci * done through this command
19562306a36Sopenharmony_ci */
19662306a36Sopenharmony_cistruct fsl_re_xor_cdb {
19762306a36Sopenharmony_ci	__be32 cdb32;
19862306a36Sopenharmony_ci	u8 gfm[16];
19962306a36Sopenharmony_ci	struct fsl_re_dpi dpi_dest_spec;
20062306a36Sopenharmony_ci	struct fsl_re_dpi dpi_src_spec[16];
20162306a36Sopenharmony_ci};
20262306a36Sopenharmony_ci
20362306a36Sopenharmony_ci/* CDB for no-op command */
20462306a36Sopenharmony_cistruct fsl_re_noop_cdb {
20562306a36Sopenharmony_ci	__be32 cdb32;
20662306a36Sopenharmony_ci};
20762306a36Sopenharmony_ci
20862306a36Sopenharmony_ci/*
20962306a36Sopenharmony_ci * CDB for GenQQ command. In RAID Engine terminology, P/Q is
21062306a36Sopenharmony_ci * done through this command
21162306a36Sopenharmony_ci */
21262306a36Sopenharmony_cistruct fsl_re_pq_cdb {
21362306a36Sopenharmony_ci	__be32 cdb32;
21462306a36Sopenharmony_ci	u8 gfm_q1[16];
21562306a36Sopenharmony_ci	u8 gfm_q2[16];
21662306a36Sopenharmony_ci	struct fsl_re_dpi dpi_dest_spec[2];
21762306a36Sopenharmony_ci	struct fsl_re_dpi dpi_src_spec[16];
21862306a36Sopenharmony_ci};
21962306a36Sopenharmony_ci
22062306a36Sopenharmony_ci/* Compound frame */
22162306a36Sopenharmony_ci#define FSL_RE_CF_ADDR_HIGH_MASK	0x000000FF
22262306a36Sopenharmony_ci#define FSL_RE_CF_EXT_MASK		0x80000000
22362306a36Sopenharmony_ci#define FSL_RE_CF_EXT_SHIFT		31
22462306a36Sopenharmony_ci#define FSL_RE_CF_FINAL_MASK		0x40000000
22562306a36Sopenharmony_ci#define FSL_RE_CF_FINAL_SHIFT		30
22662306a36Sopenharmony_ci#define FSL_RE_CF_LENGTH_MASK		0x000FFFFF
22762306a36Sopenharmony_ci#define FSL_RE_CF_BPID_MASK		0x00FF0000
22862306a36Sopenharmony_ci#define FSL_RE_CF_BPID_SHIFT		16
22962306a36Sopenharmony_ci#define FSL_RE_CF_OFFSET_MASK		0x00001FFF
23062306a36Sopenharmony_ci
23162306a36Sopenharmony_cistruct fsl_re_cmpnd_frame {
23262306a36Sopenharmony_ci	__be32 addr_high;
23362306a36Sopenharmony_ci	__be32 addr_low;
23462306a36Sopenharmony_ci	__be32 efrl32;
23562306a36Sopenharmony_ci	__be32 rbro32;
23662306a36Sopenharmony_ci};
23762306a36Sopenharmony_ci
23862306a36Sopenharmony_ci/* Frame descriptor */
23962306a36Sopenharmony_ci#define FSL_RE_HWDESC_LIODN_MASK	0x3F000000
24062306a36Sopenharmony_ci#define FSL_RE_HWDESC_LIODN_SHIFT	24
24162306a36Sopenharmony_ci#define FSL_RE_HWDESC_BPID_MASK		0x00FF0000
24262306a36Sopenharmony_ci#define FSL_RE_HWDESC_BPID_SHIFT	16
24362306a36Sopenharmony_ci#define FSL_RE_HWDESC_ELIODN_MASK	0x0000F000
24462306a36Sopenharmony_ci#define FSL_RE_HWDESC_ELIODN_SHIFT	12
24562306a36Sopenharmony_ci#define FSL_RE_HWDESC_FMT_SHIFT		29
24662306a36Sopenharmony_ci#define FSL_RE_HWDESC_FMT_MASK		(0x3 << FSL_RE_HWDESC_FMT_SHIFT)
24762306a36Sopenharmony_ci
24862306a36Sopenharmony_cistruct fsl_re_hw_desc {
24962306a36Sopenharmony_ci	__be32 lbea32;
25062306a36Sopenharmony_ci	__be32 addr_low;
25162306a36Sopenharmony_ci	__be32 fmt32;
25262306a36Sopenharmony_ci	__be32 status;
25362306a36Sopenharmony_ci};
25462306a36Sopenharmony_ci
25562306a36Sopenharmony_ci/* Raid Engine device private data */
25662306a36Sopenharmony_cistruct fsl_re_drv_private {
25762306a36Sopenharmony_ci	u8 total_chans;
25862306a36Sopenharmony_ci	struct dma_device dma_dev;
25962306a36Sopenharmony_ci	struct fsl_re_ctrl *re_regs;
26062306a36Sopenharmony_ci	struct fsl_re_chan *re_jrs[FSL_RE_MAX_CHANS];
26162306a36Sopenharmony_ci	struct dma_pool *cf_desc_pool;
26262306a36Sopenharmony_ci	struct dma_pool *hw_desc_pool;
26362306a36Sopenharmony_ci};
26462306a36Sopenharmony_ci
26562306a36Sopenharmony_ci/* Per job ring data structure */
26662306a36Sopenharmony_cistruct fsl_re_chan {
26762306a36Sopenharmony_ci	char name[16];
26862306a36Sopenharmony_ci	spinlock_t desc_lock; /* queue lock */
26962306a36Sopenharmony_ci	struct list_head ack_q;  /* wait to acked queue */
27062306a36Sopenharmony_ci	struct list_head active_q; /* already issued on hw, not completed */
27162306a36Sopenharmony_ci	struct list_head submit_q;
27262306a36Sopenharmony_ci	struct list_head free_q; /* alloc available queue */
27362306a36Sopenharmony_ci	struct device *dev;
27462306a36Sopenharmony_ci	struct fsl_re_drv_private *re_dev;
27562306a36Sopenharmony_ci	struct dma_chan chan;
27662306a36Sopenharmony_ci	struct fsl_re_chan_cfg *jrregs;
27762306a36Sopenharmony_ci	int irq;
27862306a36Sopenharmony_ci	struct tasklet_struct irqtask;
27962306a36Sopenharmony_ci	u32 alloc_count;
28062306a36Sopenharmony_ci
28162306a36Sopenharmony_ci	/* hw descriptor ring for inbound queue*/
28262306a36Sopenharmony_ci	dma_addr_t inb_phys_addr;
28362306a36Sopenharmony_ci	struct fsl_re_hw_desc *inb_ring_virt_addr;
28462306a36Sopenharmony_ci	u32 inb_count;
28562306a36Sopenharmony_ci
28662306a36Sopenharmony_ci	/* hw descriptor ring for outbound queue */
28762306a36Sopenharmony_ci	dma_addr_t oub_phys_addr;
28862306a36Sopenharmony_ci	struct fsl_re_hw_desc *oub_ring_virt_addr;
28962306a36Sopenharmony_ci	u32 oub_count;
29062306a36Sopenharmony_ci};
29162306a36Sopenharmony_ci
29262306a36Sopenharmony_ci/* Async transaction descriptor */
29362306a36Sopenharmony_cistruct fsl_re_desc {
29462306a36Sopenharmony_ci	struct dma_async_tx_descriptor async_tx;
29562306a36Sopenharmony_ci	struct list_head node;
29662306a36Sopenharmony_ci	struct fsl_re_hw_desc hwdesc;
29762306a36Sopenharmony_ci	struct fsl_re_chan *re_chan;
29862306a36Sopenharmony_ci
29962306a36Sopenharmony_ci	/* hwdesc will point to cf_addr */
30062306a36Sopenharmony_ci	void *cf_addr;
30162306a36Sopenharmony_ci	dma_addr_t cf_paddr;
30262306a36Sopenharmony_ci
30362306a36Sopenharmony_ci	void *cdb_addr;
30462306a36Sopenharmony_ci	dma_addr_t cdb_paddr;
30562306a36Sopenharmony_ci	int status;
30662306a36Sopenharmony_ci};
307