CC35xxDriverLibrary
hw_sdio_card_fn1.h
Go to the documentation of this file.
1 /******************************************************************************
2 * Filename: hw_sdio_card_fn1.h
3 *
4 * Description: Defines and prototypes for the SDIO_CARD_FN1 peripheral.
5 *
6 * Copyright (c) 2023, Texas Instruments Incorporated
7 * All rights reserved.
8 *
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions are met:
11 *
12 * 1) Redistributions of source code must retain the above copyright notice,
13 * this list of conditions and the following disclaimer.
14 *
15 * 2) Redistributions in binary form must reproduce the above copyright notice,
16 * this list of conditions and the following disclaimer in the documentation
17 * and/or other materials provided with the distribution.
18 *
19 * 3) Neither the name of the ORGANIZATION nor the names of its contributors may
20 * be used to endorse or promote products derived from this software without
21 * specific prior written permission.
22 *
23  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
24 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
25 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
26 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
27 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
28 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
29 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
30 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
31 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
32 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
33 * POSSIBILITY OF SUCH DAMAGE.
34 *
35 ******************************************************************************/
36 #ifndef __HW_SDIO_CARD_FN1_H__
37 #define __HW_SDIO_CARD_FN1_H__
38 /*-------------------------------------------------------------------------------
39 
40 This section defines the register offsets of the SDIO_CARD_FN1 component
41 
42 --------------------------------------------------------------------------------- */
43 
44 //A write only register
45 #define SDIO_CARD_FN1_O_FLUSHCMD 0x00000000U
46 
47 //A R/W register that stores one of the RX buffer thresholds
48 #define SDIO_CARD_FN1_O_RXTHR 0x00000004U
49 
50 //TX IRQ TRIG THR:
51 #define SDIO_CARD_FN1_O_TXIRQTHR 0x0000000CU
52 
53 //A R/W register setting the BLOCK SIZE for the RX and TX DMA flow control
54 #define SDIO_CARD_FN1_O_DMABLKTHR 0x00000010U
55 
56 //A RO register
57 #define SDIO_CARD_FN1_O_IRQSTA 0x00000014U
58 
59 //A R/W register
60 #define SDIO_CARD_FN1_O_IRQMASK 0x00000018U
61 
62 //A R/W register to control SDIO operation
63 #define SDIO_CARD_FN1_O_CTRL 0x0000001CU
64 
65 //RX SDIO PACKET SIZE:
66 #define SDIO_CARD_FN1_O_RXPACS 0x00000020U
67 
68 //RX BYTES IN BUFF:
69 #define SDIO_CARD_FN1_O_RXBBUF 0x00000024U
70 
71 //RX BYTES LEFT:
72 #define SDIO_CARD_FN1_O_RXBLFT 0x00000028U
73 
74 //A read/write register
75 #define SDIO_CARD_FN1_O_RETCTL 0x0000002CU
76 
77 //IRQ2Host Message 16b
78 #define SDIO_CARD_FN1_O_C2HMSG 0x00000030U
79 
80 //IRQ from Host to card Message 16b
81 #define SDIO_CARD_FN1_O_H2CMSG 0x00000034U
82 
83 //Clock gating control
84 #define SDIO_CARD_FN1_O_CLKEN 0x00000038U
85 
86 //A read/write 8-bit register that serves for future debug only
87 #define SDIO_CARD_FN1_O_SPAREREG 0x0000003CU
88 
89 //A write-only register
90 #define SDIO_CARD_FN1_O_IRQCLR 0x00000040U
91 
92 //reset sdio IP due to a SDIO Card Reset command:
93 #define SDIO_CARD_FN1_O_RSTREQ 0x00000044U
94 
95 //Common shadow register to access SDIO-Card RX-Fifo or TX-Fifo
96 #define SDIO_CARD_FN1_O_DATAFIFO 0x00001000U
97 
98 
99 
100 /*-----------------------------------REGISTER------------------------------------
101  Register name: FLUSHCMD
102  Offset name: SDIO_CARD_FN1_O_FLUSHCMD
103  Relative address: 0x0
104  Description: A write only register. Flush command of the RX / TX buffers
105  Default Value: 0x00000000
106 
107  Field: RXBUF
108  From..to bits: 0...0
109  DefaultValue: 0x0
110  Access type: write-only
111  Description: RX BUFFER FLUSH:
112  Writing to this address triggers the flush command of the RX buffer (data value is irrelevant).
113 
114 */
115 #define SDIO_CARD_FN1_FLUSHCMD_RXBUF 0x00000001U
116 #define SDIO_CARD_FN1_FLUSHCMD_RXBUF_M 0x00000001U
117 #define SDIO_CARD_FN1_FLUSHCMD_RXBUF_S 0U
118 /*
119 
120  Field: TXBUF
121  From..to bits: 1...1
122  DefaultValue: 0x0
123  Access type: write-only
124  Description: TX BUFFER FLUSH:
125  Writing to this address triggers the flush command of the TX buffer (data value is irrelevant).
126 
127 */
128 #define SDIO_CARD_FN1_FLUSHCMD_TXBUF 0x00000002U
129 #define SDIO_CARD_FN1_FLUSHCMD_TXBUF_M 0x00000002U
130 #define SDIO_CARD_FN1_FLUSHCMD_TXBUF_S 1U
131 
132 
133 /*-----------------------------------REGISTER------------------------------------
134  Register name: RXTHR
135  Offset name: SDIO_CARD_FN1_O_RXTHR
136  Relative address: 0x4
137  Description: A R/W register that stores one of the RX buffer thresholds.
138  Default Value: 0x00000004
139 
140  Field: VAL
141  From..to bits: 2...7
142  DefaultValue: 0x1
143  Access type: read-write
144  Description: Buffer almost full threshold - When passing threshold an interrupt is generated (used by the software to indicate packets in buffer)
145  The threshold is configured to allow receiving a completer packet header including packet length.
146  Typical packet header could be 1 - 128 Bytes however the threshold must be 32bits aligned since SDIO FIFO supports 32bits aligned read only.
147 
148 */
149 #define SDIO_CARD_FN1_RXTHR_VAL_W 6U
150 #define SDIO_CARD_FN1_RXTHR_VAL_M 0x000000FCU
151 #define SDIO_CARD_FN1_RXTHR_VAL_S 2U
152 
153 
154 /*-----------------------------------REGISTER------------------------------------
155  Register name: TXIRQTHR
156  Offset name: SDIO_CARD_FN1_O_TXIRQTHR
157  Relative address: 0xC
158  Description: TX IRQ TRIG THR:
159  A R/W register that stores the Threshold in bytes to raise host irq.
160  Default Value: 0x00000080
161 
162  Field: VAL
163  From..to bits: 0...7
164  DefaultValue: 0x80
165  Access type: read-write
166  Description: 8-bit value describing the number of bytes needed to trigger host irq
167  1. If HCI packet length > SDIO block (128-bytes) trigger is set to 128 Byte (entire block)
168  2. If HCI packet length < SDIO block, FW sets packet length in bytes as the trigger value
169 
170 */
171 #define SDIO_CARD_FN1_TXIRQTHR_VAL_W 8U
172 #define SDIO_CARD_FN1_TXIRQTHR_VAL_M 0x000000FFU
173 #define SDIO_CARD_FN1_TXIRQTHR_VAL_S 0U
174 
175 
176 /*-----------------------------------REGISTER------------------------------------
177  Register name: DMABLKTHR
178  Offset name: SDIO_CARD_FN1_O_DMABLKTHR
179  Relative address: 0x10
180  Description: A R/W register setting the BLOCK SIZE for the RX and TX DMA flow control
181  Default Value: 0x00020002
182 
183  Field: RXDMABLK
184  From..to bits: 0...2
185  DefaultValue: 0x2
186  Access type: read-write
187  Description: RX DMA BLOCK SIZE SEL:
188  HOST Writes to FIFO
189  Determine when to assert flow control to DMA.
190  The flow should be asserted when num of bytes in FIFO > Threshold.
191  The threshold is determined according to the DMA block size
192  0 - 4 Bytes
193  1 - 8 Bytes
194  2 - 16 Bytes (Default)
195  3 - 32 Bytes
196  4 - 64 Bytes
197  5 - 128 Bytes
198  6,7 - Reserved HOST Writes to FIFO
199  Determine when to assert flow control to DMA.
200  The flow should be asserted when num of bytes in FIFO > Threshold.
201  The threshold is determined according to the DMA block size
202  0 - 4 Bytes
203  1 - 8 Bytes
204  2 - 16 Bytes (Default)
205  3 - 32 Bytes
206  4 - 64 Bytes
207  5 - 128 Bytes
208  6,7 - Reserved
209 
210 */
211 #define SDIO_CARD_FN1_DMABLKTHR_RXDMABLK_W 3U
212 #define SDIO_CARD_FN1_DMABLKTHR_RXDMABLK_M 0x00000007U
213 #define SDIO_CARD_FN1_DMABLKTHR_RXDMABLK_S 0U
214 /*
215 
216  Field: TXDMABLK
217  From..to bits: 16...18
218  DefaultValue: 0x2
219  Access type: read-write
220  Description: TX DMA BLOCK SIZE SEL:
221  HOST reads from FIFO
222  Determine when to assert flow control to DMA.
223  The flow should be asserted when FIFO has enough free buffer >= Threshold.
224  The threshold is determined according to the DMA block size
225  0 - 4 Bytes
226  1 - 8 Bytes
227  2 - 16 Bytes (Default)
228  3 - 32 Bytes
229  4 - 64 Bytes
230  5 - 128 Bytes
231  6,7 - Reserved
232 
233 */
234 #define SDIO_CARD_FN1_DMABLKTHR_TXDMABLK_W 3U
235 #define SDIO_CARD_FN1_DMABLKTHR_TXDMABLK_M 0x00070000U
236 #define SDIO_CARD_FN1_DMABLKTHR_TXDMABLK_S 16U
237 
238 
239 /*-----------------------------------REGISTER------------------------------------
240  Register name: IRQSTA
241  Offset name: SDIO_CARD_FN1_O_IRQSTA
242  Relative address: 0x14
243  Description: A RO register. Holds the status of the different interrupts of the SDIO.
244  This register is cleared by writing to IRQ_CLEAR register
245  Each interrupt is set when the event is active. In the case of ACKINT the software has to read the ACKNAK bit value to see if an ACK event was received or a read retry is starting.
246  Default Value: 0x00000000
247 
248  Field: RXALMSFULL
249  From..to bits: 0...0
250  DefaultValue: 0x0
251  Access type: read-only
252  Description: RX Buffer almost full interrupt
253 
254 */
255 #define SDIO_CARD_FN1_IRQSTA_RXALMSFULL 0x00000001U
256 #define SDIO_CARD_FN1_IRQSTA_RXALMSFULL_M 0x00000001U
257 #define SDIO_CARD_FN1_IRQSTA_RXALMSFULL_S 0U
258 /*
259 
260  Field: FN1EN
261  From..to bits: 1...1
262  DefaultValue: 0x0
263  Access type: read-only
264  Description: Function #1 enable interrupt
265 
266 */
267 #define SDIO_CARD_FN1_IRQSTA_FN1EN 0x00000002U
268 #define SDIO_CARD_FN1_IRQSTA_FN1EN_M 0x00000002U
269 #define SDIO_CARD_FN1_IRQSTA_FN1EN_S 1U
270 /*
271 
272  Field: RXBUFOVR
273  From..to bits: 2...2
274  DefaultValue: 0x0
275  Access type: read-only
276  Description: RX Buffer overrun interrupt
277 
278 */
279 #define SDIO_CARD_FN1_IRQSTA_RXBUFOVR 0x00000004U
280 #define SDIO_CARD_FN1_IRQSTA_RXBUFOVR_M 0x00000004U
281 #define SDIO_CARD_FN1_IRQSTA_RXBUFOVR_S 2U
282 /*
283 
284  Field: RXBUFUNR
285  From..to bits: 3...3
286  DefaultValue: 0x0
287  Access type: read-only
288  Description: RX Buffer under-run interrupt
289 
290 */
291 #define SDIO_CARD_FN1_IRQSTA_RXBUFUNR 0x00000008U
292 #define SDIO_CARD_FN1_IRQSTA_RXBUFUNR_M 0x00000008U
293 #define SDIO_CARD_FN1_IRQSTA_RXBUFUNR_S 3U
294 /*
295 
296  Field: TXBUFOVR
297  From..to bits: 4...4
298  DefaultValue: 0x0
299  Access type: read-only
300  Description: TX Buffer overrun interrupt
301 
302 */
303 #define SDIO_CARD_FN1_IRQSTA_TXBUFOVR 0x00000010U
304 #define SDIO_CARD_FN1_IRQSTA_TXBUFOVR_M 0x00000010U
305 #define SDIO_CARD_FN1_IRQSTA_TXBUFOVR_S 4U
306 /*
307 
308  Field: TXBUFUNR
309  From..to bits: 5...5
310  DefaultValue: 0x0
311  Access type: read-only
312  Description: TX Buffer under-run interrupt
313 
314 */
315 #define SDIO_CARD_FN1_IRQSTA_TXBUFUNR 0x00000020U
316 #define SDIO_CARD_FN1_IRQSTA_TXBUFUNR_M 0x00000020U
317 #define SDIO_CARD_FN1_IRQSTA_TXBUFUNR_S 5U
318 /*
319 
320  Field: HCIACK
321  From..to bits: 6...6
322  DefaultValue: 0x0
323  Access type: read-only
324  Description: HCI packet ACK interrupt
325 
326 */
327 #define SDIO_CARD_FN1_IRQSTA_HCIACK 0x00000040U
328 #define SDIO_CARD_FN1_IRQSTA_HCIACK_M 0x00000040U
329 #define SDIO_CARD_FN1_IRQSTA_HCIACK_S 6U
330 /*
331 
332  Field: HCINACK
333  From..to bits: 7...7
334  DefaultValue: 0x0
335  Access type: read-only
336  Description: HCI packet NACK interrupt
337 
338 */
339 #define SDIO_CARD_FN1_IRQSTA_HCINACK 0x00000080U
340 #define SDIO_CARD_FN1_IRQSTA_HCINACK_M 0x00000080U
341 #define SDIO_CARD_FN1_IRQSTA_HCINACK_S 7U
342 /*
343 
344  Field: HCIWRRET
345  From..to bits: 8...8
346  DefaultValue: 0x0
347  Access type: read-only
348  Description: HCI packet write retry
349 
350 */
351 #define SDIO_CARD_FN1_IRQSTA_HCIWRRET 0x00000100U
352 #define SDIO_CARD_FN1_IRQSTA_HCIWRRET_M 0x00000100U
353 #define SDIO_CARD_FN1_IRQSTA_HCIWRRET_S 8U
354 /*
355 
356  Field: PHYIFERR
357  From..to bits: 9...9
358  DefaultValue: 0x0
359  Access type: read-only
360  Description: Error in the OCP interface of the SDIO PHY
361 
362 */
363 #define SDIO_CARD_FN1_IRQSTA_PHYIFERR 0x00000200U
364 #define SDIO_CARD_FN1_IRQSTA_PHYIFERR_M 0x00000200U
365 #define SDIO_CARD_FN1_IRQSTA_PHYIFERR_S 9U
366 /*
367 
368  Field: CARDRST
369  From..to bits: 10...10
370  DefaultValue: 0x0
371  Access type: read-only
372  Description: Card Reset interrupt
373 
374 */
375 #define SDIO_CARD_FN1_IRQSTA_CARDRST 0x00000400U
376 #define SDIO_CARD_FN1_IRQSTA_CARDRST_M 0x00000400U
377 #define SDIO_CARD_FN1_IRQSTA_CARDRST_S 10U
378 /*
379 
380  Field: PHYINT
381  From..to bits: 11...11
382  DefaultValue: 0x0
383  Access type: read-only
384  Description: SDIO PHY interrupt
385 
386 */
387 #define SDIO_CARD_FN1_IRQSTA_PHYINT 0x00000800U
388 #define SDIO_CARD_FN1_IRQSTA_PHYINT_M 0x00000800U
389 #define SDIO_CARD_FN1_IRQSTA_PHYINT_S 11U
390 /*
391 
392  Field: CRCERR
393  From..to bits: 12...12
394  DefaultValue: 0x0
395  Access type: read-only
396  Description: '1' = CRC Error was detected for rx flow
397 
398 */
399 #define SDIO_CARD_FN1_IRQSTA_CRCERR 0x00001000U
400 #define SDIO_CARD_FN1_IRQSTA_CRCERR_M 0x00001000U
401 #define SDIO_CARD_FN1_IRQSTA_CRCERR_S 12U
402 /*
403 
404  Field: HOST2CORE
405  From..to bits: 13...13
406  DefaultValue: 0x0
407  Access type: read-only
408  Description: Host to Card 15 bit message ready indication
409 
410 */
411 #define SDIO_CARD_FN1_IRQSTA_HOST2CORE 0x00002000U
412 #define SDIO_CARD_FN1_IRQSTA_HOST2CORE_M 0x00002000U
413 #define SDIO_CARD_FN1_IRQSTA_HOST2CORE_S 13U
414 
415 
416 /*-----------------------------------REGISTER------------------------------------
417  Register name: IRQMASK
418  Offset name: SDIO_CARD_FN1_O_IRQMASK
419  Relative address: 0x18
420  Description: A R/W register. Holds the mask bits of the different interrupts of the SDIO.
421  Default Value: 0x00003FFF
422 
423  Field: RXALMSFULL
424  From..to bits: 0...0
425  DefaultValue: 0x1
426  Access type: read-write
427  Description: RX Buffer almost full interrupt
428 
429 */
430 #define SDIO_CARD_FN1_IRQMASK_RXALMSFULL 0x00000001U
431 #define SDIO_CARD_FN1_IRQMASK_RXALMSFULL_M 0x00000001U
432 #define SDIO_CARD_FN1_IRQMASK_RXALMSFULL_S 0U
433 /*
434 
435  Field: FN1EN
436  From..to bits: 1...1
437  DefaultValue: 0x1
438  Access type: read-write
439  Description: Function #1 enable interrupt
440 
441 */
442 #define SDIO_CARD_FN1_IRQMASK_FN1EN 0x00000002U
443 #define SDIO_CARD_FN1_IRQMASK_FN1EN_M 0x00000002U
444 #define SDIO_CARD_FN1_IRQMASK_FN1EN_S 1U
445 /*
446 
447  Field: RXBUFOVR
448  From..to bits: 2...2
449  DefaultValue: 0x1
450  Access type: read-write
451  Description: RX Buffer overrun interrupt
452 
453 */
454 #define SDIO_CARD_FN1_IRQMASK_RXBUFOVR 0x00000004U
455 #define SDIO_CARD_FN1_IRQMASK_RXBUFOVR_M 0x00000004U
456 #define SDIO_CARD_FN1_IRQMASK_RXBUFOVR_S 2U
457 /*
458 
459  Field: RXBUFUNR
460  From..to bits: 3...3
461  DefaultValue: 0x1
462  Access type: read-write
463  Description: RX Buffer under-run interrupt
464 
465 */
466 #define SDIO_CARD_FN1_IRQMASK_RXBUFUNR 0x00000008U
467 #define SDIO_CARD_FN1_IRQMASK_RXBUFUNR_M 0x00000008U
468 #define SDIO_CARD_FN1_IRQMASK_RXBUFUNR_S 3U
469 /*
470 
471  Field: TXBUFOVR
472  From..to bits: 4...4
473  DefaultValue: 0x1
474  Access type: read-write
475  Description: TX Buffer overrun interrupt
476 
477 */
478 #define SDIO_CARD_FN1_IRQMASK_TXBUFOVR 0x00000010U
479 #define SDIO_CARD_FN1_IRQMASK_TXBUFOVR_M 0x00000010U
480 #define SDIO_CARD_FN1_IRQMASK_TXBUFOVR_S 4U
481 /*
482 
483  Field: TXBUFUNR
484  From..to bits: 5...5
485  DefaultValue: 0x1
486  Access type: read-write
487  Description: TX Buffer under-run interrupt
488 
489 */
490 #define SDIO_CARD_FN1_IRQMASK_TXBUFUNR 0x00000020U
491 #define SDIO_CARD_FN1_IRQMASK_TXBUFUNR_M 0x00000020U
492 #define SDIO_CARD_FN1_IRQMASK_TXBUFUNR_S 5U
493 /*
494 
495  Field: HCIACK
496  From..to bits: 6...6
497  DefaultValue: 0x1
498  Access type: read-write
499  Description: HCI packet ACK interrupt
500 
501 */
502 #define SDIO_CARD_FN1_IRQMASK_HCIACK 0x00000040U
503 #define SDIO_CARD_FN1_IRQMASK_HCIACK_M 0x00000040U
504 #define SDIO_CARD_FN1_IRQMASK_HCIACK_S 6U
505 /*
506 
507  Field: HCINACK
508  From..to bits: 7...7
509  DefaultValue: 0x1
510  Access type: read-write
511  Description: HCI packet NACK interrupt
512 
513 */
514 #define SDIO_CARD_FN1_IRQMASK_HCINACK 0x00000080U
515 #define SDIO_CARD_FN1_IRQMASK_HCINACK_M 0x00000080U
516 #define SDIO_CARD_FN1_IRQMASK_HCINACK_S 7U
517 /*
518 
519  Field: HCIWRRET
520  From..to bits: 8...8
521  DefaultValue: 0x1
522  Access type: read-write
523  Description: HCI packet write retry
524 
525 */
526 #define SDIO_CARD_FN1_IRQMASK_HCIWRRET 0x00000100U
527 #define SDIO_CARD_FN1_IRQMASK_HCIWRRET_M 0x00000100U
528 #define SDIO_CARD_FN1_IRQMASK_HCIWRRET_S 8U
529 /*
530 
531  Field: PHYIFERR
532  From..to bits: 9...9
533  DefaultValue: 0x1
534  Access type: read-write
535  Description: Error in the OCP interface of the SDIO PHY
536 
537 */
538 #define SDIO_CARD_FN1_IRQMASK_PHYIFERR 0x00000200U
539 #define SDIO_CARD_FN1_IRQMASK_PHYIFERR_M 0x00000200U
540 #define SDIO_CARD_FN1_IRQMASK_PHYIFERR_S 9U
541 /*
542 
543  Field: CARDRST
544  From..to bits: 10...10
545  DefaultValue: 0x1
546  Access type: read-write
547  Description: Card Reset interrupt
548 
549 */
550 #define SDIO_CARD_FN1_IRQMASK_CARDRST 0x00000400U
551 #define SDIO_CARD_FN1_IRQMASK_CARDRST_M 0x00000400U
552 #define SDIO_CARD_FN1_IRQMASK_CARDRST_S 10U
553 /*
554 
555  Field: PHYMASK
556  From..to bits: 11...11
557  DefaultValue: 0x1
558  Access type: read-write
559  Description: SDIO PHY interrupt
560 
561 */
562 #define SDIO_CARD_FN1_IRQMASK_PHYMASK 0x00000800U
563 #define SDIO_CARD_FN1_IRQMASK_PHYMASK_M 0x00000800U
564 #define SDIO_CARD_FN1_IRQMASK_PHYMASK_S 11U
565 /*
566 
567  Field: CRCERR
568  From..to bits: 12...12
569  DefaultValue: 0x1
570  Access type: read-write
571  Description: '1' = CRC Error was detected for rx flow
572 
573 */
574 #define SDIO_CARD_FN1_IRQMASK_CRCERR 0x00001000U
575 #define SDIO_CARD_FN1_IRQMASK_CRCERR_M 0x00001000U
576 #define SDIO_CARD_FN1_IRQMASK_CRCERR_S 12U
577 /*
578 
579  Field: HOST2CORE
580  From..to bits: 13...13
581  DefaultValue: 0x1
582  Access type: read-write
583  Description: Host to Card 15 bit message ready indication
584 
585 */
586 #define SDIO_CARD_FN1_IRQMASK_HOST2CORE 0x00002000U
587 #define SDIO_CARD_FN1_IRQMASK_HOST2CORE_M 0x00002000U
588 #define SDIO_CARD_FN1_IRQMASK_HOST2CORE_S 13U
589 
590 
591 /*-----------------------------------REGISTER------------------------------------
592  Register name: CTRL
593  Offset name: SDIO_CARD_FN1_O_CTRL
594  Relative address: 0x1C
595  Description: A R/W register to control SDIO operation.
596  Default Value: 0x00000007
597 
598  Field: SDIOEN
599  From..to bits: 0...0
600  DefaultValue: 0x1
601  Access type: read-write
602  Description: SDIO enable - Enable SDIO after CRC error.
603  Cleared by HW after CRC error; Set by FW to de-assert the busy signal
604 
605 */
606 #define SDIO_CARD_FN1_CTRL_SDIOEN 0x00000001U
607 #define SDIO_CARD_FN1_CTRL_SDIOEN_M 0x00000001U
608 #define SDIO_CARD_FN1_CTRL_SDIOEN_S 0U
609 /*
610 
611  Field: BACE
612  From..to bits: 1...1
613  DefaultValue: 0x1
614  Access type: read-write
615  Description: BUSY AFTER CRC ERROR:
616  Enables the module to activate the busy signal after CRC error on data only if sdio_enable was set
617 
618 */
619 #define SDIO_CARD_FN1_CTRL_BACE 0x00000002U
620 #define SDIO_CARD_FN1_CTRL_BACE_M 0x00000002U
621 #define SDIO_CARD_FN1_CTRL_BACE_S 1U
622 /*
623 
624  Field: TXFLEN
625  From..to bits: 2...2
626  DefaultValue: 0x1
627  Access type: read-write
628  Description: TX BUFFER FLUSH ENABLE:
629  Enables the module to flush the TX buffer after receiving packet-read-retry indication (ACK or NACK). When this bit is '0', FW must flush the buffer manually (by writing to FLUSH_CMD register) upon receiving ACK/NACK interrupt. It is needed for the correct operation of the TX FIFO
630 
631 */
632 #define SDIO_CARD_FN1_CTRL_TXFLEN 0x00000004U
633 #define SDIO_CARD_FN1_CTRL_TXFLEN_M 0x00000004U
634 #define SDIO_CARD_FN1_CTRL_TXFLEN_S 2U
635 /*
636 
637  Field: HIRQSYNC
638  From..to bits: 3...3
639  DefaultValue: 0x0
640  Access type: read-write
641  Description: HOST IRQ SYNCHRONIZATION:
642  This bit controls the synchronization of the host interrupt (interrupt from BT to host through the PHY). '1' - interrupt is synchronized to sdio_clk. '0' - interrupt is not synchronized to sdio_clk (and thus synchronized to ocp_clk)
643 
644 */
645 #define SDIO_CARD_FN1_CTRL_HIRQSYNC 0x00000008U
646 #define SDIO_CARD_FN1_CTRL_HIRQSYNC_M 0x00000008U
647 #define SDIO_CARD_FN1_CTRL_HIRQSYNC_S 3U
648 
649 
650 /*-----------------------------------REGISTER------------------------------------
651  Register name: RXPACS
652  Offset name: SDIO_CARD_FN1_O_RXPACS
653  Relative address: 0x20
654  Description: RX SDIO PACKET SIZE:
655  A read only register. Holds the length of the current received SDIO packet. Updated at the beginning of each SDIO packet.
656  Default Value: 0x00000000
657 
658  Field: VAL
659  From..to bits: 0...9
660  DefaultValue: 0x0
661  Access type: read-only
662  Description: Length of the current received SDIO packet. Updated at the beginning of each SDIO packet
663 
664 */
665 #define SDIO_CARD_FN1_RXPACS_VAL_W 10U
666 #define SDIO_CARD_FN1_RXPACS_VAL_M 0x000003FFU
667 #define SDIO_CARD_FN1_RXPACS_VAL_S 0U
668 
669 
670 /*-----------------------------------REGISTER------------------------------------
671  Register name: RXBBUF
672  Offset name: SDIO_CARD_FN1_O_RXBBUF
673  Relative address: 0x24
674  Description: RX BYTES IN BUFF:
675  A read only status register. Holds the current number of bytes in SDIO RX buffer.
676  Default Value: 0x00000000
677 
678  Field: VAL
679  From..to bits: 0...10
680  DefaultValue: 0x0
681  Access type: read-only
682  Description: Current number of bytes in SDIO RX buffer
683 
684 */
685 #define SDIO_CARD_FN1_RXBBUF_VAL_W 11U
686 #define SDIO_CARD_FN1_RXBBUF_VAL_M 0x000007FFU
687 #define SDIO_CARD_FN1_RXBBUF_VAL_S 0U
688 
689 
690 /*-----------------------------------REGISTER------------------------------------
691  Register name: RXBLFT
692  Offset name: SDIO_CARD_FN1_O_RXBLFT
693  Relative address: 0x28
694  Description: RX BYTES LEFT:
695  A read only status register. A down-count counter. Holds the number of bytes in current SDIO packet that were not transmitted to RX buffer yet. Please notice: Before reading this register, the FW MUST read RX_BYTES_IN_BUFFER register.
696  Default Value: 0x00000000
697 
698  Field: VAL
699  From..to bits: 0...10
700  DefaultValue: 0x0
701  Access type: read-only
702  Description: A counter that is loaded with SDIO packet length and decremented the same as the incrementing of bytes-in-buffer status register
703 
704 */
705 #define SDIO_CARD_FN1_RXBLFT_VAL_W 11U
706 #define SDIO_CARD_FN1_RXBLFT_VAL_M 0x000007FFU
707 #define SDIO_CARD_FN1_RXBLFT_VAL_S 0U
708 /*
709 
710  Field: BLIL
711  From..to bits: 15...15
712  DefaultValue: 0x0
713  Access type: read-only
714  Description: BYTES LEFT IS LOCKED:
715  When '0' - the value that is read from rx_bytes_left is the current number of bytes left to transfer to the end of the block.
716  When '1' - the value that is read from rx_bytes_left is the number of bytes left to transfer to the end of the block that was locked on the last read from RX_BYTES_IN_BUF.
717 
718 */
719 #define SDIO_CARD_FN1_RXBLFT_BLIL 0x00008000U
720 #define SDIO_CARD_FN1_RXBLFT_BLIL_M 0x00008000U
721 #define SDIO_CARD_FN1_RXBLFT_BLIL_S 15U
722 
723 
724 /*-----------------------------------REGISTER------------------------------------
725  Register name: RETCTL
726  Offset name: SDIO_CARD_FN1_O_RETCTL
727  Relative address: 0x2C
728  Description: A read/write register. The value states if the BT-SDIO is working with Retry Control mechanism as specified in SDIO spec.
729  Default Value: 0x00000001
730 
731  Field: VAL
732  From..to bits: 0...0
733  DefaultValue: 0x1
734  Access type: read-write
735  Description: When FW writes '1' to this bit, it states that the BT-SDIO is using retry control mechanism. When FW reads this bit, it actually reads the value of the Function 1's RETRY_CONTROL register (the value that the host configured). Default value is '1' because BT FW MUST have retry control mechanism working
736 
737 */
738 #define SDIO_CARD_FN1_RETCTL_VAL 0x00000001U
739 #define SDIO_CARD_FN1_RETCTL_VAL_M 0x00000001U
740 #define SDIO_CARD_FN1_RETCTL_VAL_S 0U
741 
742 
743 /*-----------------------------------REGISTER------------------------------------
744  Register name: C2HMSG
745  Offset name: SDIO_CARD_FN1_O_C2HMSG
746  Relative address: 0x30
747  Description: IRQ2Host Message 16b
748  Default Value: 0x00000000
749 
750  Field: C2HSTS
751  From..to bits: 0...15
752  DefaultValue: 0x0
753  Access type: read-write
754  Description: CARD TO HOST STS:
755  To Host: 16bits MMR which can be written/read by M33 and read/clear (bit map) by host
756  Cleared by HOST writing to CLINTERD (Interrupt Clear 0x13)
757 
758 */
759 #define SDIO_CARD_FN1_C2HMSG_C2HSTS_W 16U
760 #define SDIO_CARD_FN1_C2HMSG_C2HSTS_M 0x0000FFFFU
761 #define SDIO_CARD_FN1_C2HMSG_C2HSTS_S 0U
762 /*
763 
764  Field: C2HIRQ
765  From..to bits: 16...16
766  DefaultValue: 0x0
767  Access type: write-only
768  Description: CARD TO HOST IRQ:
769  To Host: 16bits MMR which can be written/read by M33 and read/clear (bit map) by host
770 
771 */
772 #define SDIO_CARD_FN1_C2HMSG_C2HIRQ 0x00010000U
773 #define SDIO_CARD_FN1_C2HMSG_C2HIRQ_M 0x00010000U
774 #define SDIO_CARD_FN1_C2HMSG_C2HIRQ_S 16U
775 
776 
777 /*-----------------------------------REGISTER------------------------------------
778  Register name: H2CMSG
779  Offset name: SDIO_CARD_FN1_O_H2CMSG
780  Relative address: 0x34
781  Description: IRQ from Host to card Message 16b
782  Default Value: 0x00000000
783 
784  Field: H2CSTS
785  From..to bits: 0...14
786  DefaultValue: 0x0
787  Access type: read-only
788  Description: HOST TO CARD STS:
789  From Host: 15bits MMR which can be written by host and read/clear (bit map) by M33.
790  (bit 16 is the host_to_card_irq that is generated by the HOST and goes to [IRQ_STATUS.HOST_TO_CARD_INT])
791 
792 */
793 #define SDIO_CARD_FN1_H2CMSG_H2CSTS_W 15U
794 #define SDIO_CARD_FN1_H2CMSG_H2CSTS_M 0x00007FFFU
795 #define SDIO_CARD_FN1_H2CMSG_H2CSTS_S 0U
796 
797 
798 /*-----------------------------------REGISTER------------------------------------
799  Register name: CLKEN
800  Offset name: SDIO_CARD_FN1_O_CLKEN
801  Relative address: 0x38
802  Description: Clock gating control
803  Default Value: 0x00000000
804 
805  Field: VAL
806  From..to bits: 0...0
807  DefaultValue: 0x0
808  Access type: read-write
809  Description: 1'b0 - disable clk
810  1'b1 - enable clk
811 
812 */
813 #define SDIO_CARD_FN1_CLKEN_VAL 0x00000001U
814 #define SDIO_CARD_FN1_CLKEN_VAL_M 0x00000001U
815 #define SDIO_CARD_FN1_CLKEN_VAL_S 0U
816 
817 
818 /*-----------------------------------REGISTER------------------------------------
819  Register name: SPAREREG
820  Offset name: SDIO_CARD_FN1_O_SPAREREG
821  Relative address: 0x3C
822  Description: A read/write 8-bit register that serves for future debug only.
823  Default Value: 0x00000000
824 
825  Field: SPARE
826  From..to bits: 0...7
827  DefaultValue: 0x0
828  Access type: read-write
829  Description: spare
830 
831 */
832 #define SDIO_CARD_FN1_SPAREREG_SPARE_W 8U
833 #define SDIO_CARD_FN1_SPAREREG_SPARE_M 0x000000FFU
834 #define SDIO_CARD_FN1_SPAREREG_SPARE_S 0U
835 
836 
837 /*-----------------------------------REGISTER------------------------------------
838  Register name: IRQCLR
839  Offset name: SDIO_CARD_FN1_O_IRQCLR
840  Relative address: 0x40
841  Description: A write-only register. When written, it clears all SDIO pending interrupts
842  Default Value: 0x00000000
843 
844  Field: RXALMSFULL
845  From..to bits: 0...0
846  DefaultValue: 0x0
847  Access type: write-only
848  Description: RX Buffer almost full interrupt clear
849 
850 */
851 #define SDIO_CARD_FN1_IRQCLR_RXALMSFULL 0x00000001U
852 #define SDIO_CARD_FN1_IRQCLR_RXALMSFULL_M 0x00000001U
853 #define SDIO_CARD_FN1_IRQCLR_RXALMSFULL_S 0U
854 /*
855 
856  Field: FN1EN
857  From..to bits: 1...1
858  DefaultValue: 0x0
859  Access type: write-only
860  Description: Function #1 enable interrupt
861 
862 */
863 #define SDIO_CARD_FN1_IRQCLR_FN1EN 0x00000002U
864 #define SDIO_CARD_FN1_IRQCLR_FN1EN_M 0x00000002U
865 #define SDIO_CARD_FN1_IRQCLR_FN1EN_S 1U
866 /*
867 
868  Field: RXBUFOVR
869  From..to bits: 2...2
870  DefaultValue: 0x0
871  Access type: write-only
872  Description: RX Buffer overrun interrupt clear
873 
874 */
875 #define SDIO_CARD_FN1_IRQCLR_RXBUFOVR 0x00000004U
876 #define SDIO_CARD_FN1_IRQCLR_RXBUFOVR_M 0x00000004U
877 #define SDIO_CARD_FN1_IRQCLR_RXBUFOVR_S 2U
878 /*
879 
880  Field: RXBUFUNR
881  From..to bits: 3...3
882  DefaultValue: 0x0
883  Access type: write-only
884  Description: RX Buffer under-run interrupt clear
885 
886 */
887 #define SDIO_CARD_FN1_IRQCLR_RXBUFUNR 0x00000008U
888 #define SDIO_CARD_FN1_IRQCLR_RXBUFUNR_M 0x00000008U
889 #define SDIO_CARD_FN1_IRQCLR_RXBUFUNR_S 3U
890 /*
891 
892  Field: TXBUFOVR
893  From..to bits: 4...4
894  DefaultValue: 0x0
895  Access type: write-only
896  Description: TX Buffer overrun interrupt clear
897 
898 */
899 #define SDIO_CARD_FN1_IRQCLR_TXBUFOVR 0x00000010U
900 #define SDIO_CARD_FN1_IRQCLR_TXBUFOVR_M 0x00000010U
901 #define SDIO_CARD_FN1_IRQCLR_TXBUFOVR_S 4U
902 /*
903 
904  Field: TXBUFUNR
905  From..to bits: 5...5
906  DefaultValue: 0x0
907  Access type: write-only
908  Description: TX Buffer under-run interrupt clear
909 
910 */
911 #define SDIO_CARD_FN1_IRQCLR_TXBUFUNR 0x00000020U
912 #define SDIO_CARD_FN1_IRQCLR_TXBUFUNR_M 0x00000020U
913 #define SDIO_CARD_FN1_IRQCLR_TXBUFUNR_S 5U
914 /*
915 
916  Field: HCIACK
917  From..to bits: 6...6
918  DefaultValue: 0x0
919  Access type: write-only
920  Description: HCI packet ACK interrupt clear
921 
922 */
923 #define SDIO_CARD_FN1_IRQCLR_HCIACK 0x00000040U
924 #define SDIO_CARD_FN1_IRQCLR_HCIACK_M 0x00000040U
925 #define SDIO_CARD_FN1_IRQCLR_HCIACK_S 6U
926 /*
927 
928  Field: HCINACK
929  From..to bits: 7...7
930  DefaultValue: 0x0
931  Access type: write-only
932  Description: HCI packet NACK interrupt clear
933 
934 */
935 #define SDIO_CARD_FN1_IRQCLR_HCINACK 0x00000080U
936 #define SDIO_CARD_FN1_IRQCLR_HCINACK_M 0x00000080U
937 #define SDIO_CARD_FN1_IRQCLR_HCINACK_S 7U
938 /*
939 
940  Field: HCIWRRET
941  From..to bits: 8...8
942  DefaultValue: 0x0
943  Access type: write-only
944  Description: HCI packet write retry clear
945 
946 */
947 #define SDIO_CARD_FN1_IRQCLR_HCIWRRET 0x00000100U
948 #define SDIO_CARD_FN1_IRQCLR_HCIWRRET_M 0x00000100U
949 #define SDIO_CARD_FN1_IRQCLR_HCIWRRET_S 8U
950 /*
951 
952  Field: PHYIFERR
953  From..to bits: 9...9
954  DefaultValue: 0x0
955  Access type: write-only
956  Description: Error in the OCP interface of the SDIO PHY clear
957 
958 */
959 #define SDIO_CARD_FN1_IRQCLR_PHYIFERR 0x00000200U
960 #define SDIO_CARD_FN1_IRQCLR_PHYIFERR_M 0x00000200U
961 #define SDIO_CARD_FN1_IRQCLR_PHYIFERR_S 9U
962 /*
963 
964  Field: CARDRST
965  From..to bits: 10...10
966  DefaultValue: 0x0
967  Access type: write-only
968  Description: Card Reset interrupt clear
969 
970 */
971 #define SDIO_CARD_FN1_IRQCLR_CARDRST 0x00000400U
972 #define SDIO_CARD_FN1_IRQCLR_CARDRST_M 0x00000400U
973 #define SDIO_CARD_FN1_IRQCLR_CARDRST_S 10U
974 /*
975 
976  Field: PHYCLEAR
977  From..to bits: 11...11
978  DefaultValue: 0x0
979  Access type: write-only
980  Description: SDIO PHY interrupt clear
981 
982 */
983 #define SDIO_CARD_FN1_IRQCLR_PHYCLEAR 0x00000800U
984 #define SDIO_CARD_FN1_IRQCLR_PHYCLEAR_M 0x00000800U
985 #define SDIO_CARD_FN1_IRQCLR_PHYCLEAR_S 11U
986 /*
987 
988  Field: CRCERR
989  From..to bits: 12...12
990  DefaultValue: 0x0
991  Access type: write-only
992  Description: CRC Error clear
993 
994 */
995 #define SDIO_CARD_FN1_IRQCLR_CRCERR 0x00001000U
996 #define SDIO_CARD_FN1_IRQCLR_CRCERR_M 0x00001000U
997 #define SDIO_CARD_FN1_IRQCLR_CRCERR_S 12U
998 /*
999 
1000  Field: HOST2CORE
1001  From..to bits: 13...13
1002  DefaultValue: 0x0
1003  Access type: write-only
1004  Description: Host to Card 15 bit message ready indication
1005 
1006 */
1007 #define SDIO_CARD_FN1_IRQCLR_HOST2CORE 0x00002000U
1008 #define SDIO_CARD_FN1_IRQCLR_HOST2CORE_M 0x00002000U
1009 #define SDIO_CARD_FN1_IRQCLR_HOST2CORE_S 13U
1010 
1011 
1012 /*-----------------------------------REGISTER------------------------------------
1013  Register name: RSTREQ
1014  Offset name: SDIO_CARD_FN1_O_RSTREQ
1015  Relative address: 0x44
1016  Description: reset sdio IP due to a SDIO Card Reset command:
1017 
1018  0 - do not reset / de-assert initiated sdio reset
1019  1 - initiate reset sdio reset (both PHY and SDIO System)
1020  Default Value: 0x00000000
1021 
1022  Field: EN
1023  From..to bits: 0...0
1024  DefaultValue: 0x0
1025  Access type: read-write
1026  Description: Function #1 enable interrupt
1027 
1028 */
1029 #define SDIO_CARD_FN1_RSTREQ_EN 0x00000001U
1030 #define SDIO_CARD_FN1_RSTREQ_EN_M 0x00000001U
1031 #define SDIO_CARD_FN1_RSTREQ_EN_S 0U
1032 
1033 
1034 /*-----------------------------------REGISTER------------------------------------
1035  Register name: DATAFIFO
1036  Offset name: SDIO_CARD_FN1_O_DATAFIFO
1037  Relative address: 0x1000
1038  Description: Common shadow register to access SDIO-Card RX-Fifo or TX-Fifo
1039  Default Value: 0x00000000
1040 
1041  Field: RDRXWRTX
1042  From..to bits: 0...31
1043  DefaultValue: 0x0
1044  Access type: read-write
1045  Description: Common access for either:
1046  1. Reading 'sdio_rxfifo'
1047  2. Writing 'sdio_txfifo'
1048  Can be used either as local ocp rd/wr commands, or transactions through DMA machine.
1049 
1050 */
1051 #define SDIO_CARD_FN1_DATAFIFO_RDRXWRTX_W 32U
1052 #define SDIO_CARD_FN1_DATAFIFO_RDRXWRTX_M 0xFFFFFFFFU
1053 #define SDIO_CARD_FN1_DATAFIFO_RDRXWRTX_S 0U
1054 
1055 #endif /* __HW_SDIO_CARD_FN1_H__*/