Go to the documentation of this file.
9 #ifndef __ASM_IA64_SN_TIOCE_H__
10 #define __ASM_IA64_SN_TIOCE_H__
13 #define TIOCE_PART_NUM 0xCE00
14 #define TIOCE_SRC_ID 0x01
15 #define TIOCE_REV_A 0x1
18 #define CE_VIRT_PPB_VENDOR_ID 0x10a9
19 #define CE_VIRT_PPB_DEVICE_ID 0x4002
22 #define CE_HOST_BRIDGE_VENDOR_ID 0x10a9
23 #define CE_HOST_BRIDGE_DEVICE_ID 0x4001
26 #define TIOCE_NUM_M40_ATES 4096
27 #define TIOCE_NUM_M3240_ATES 2048
28 #define TIOCE_NUM_PORTS 2
110 #define ce_lsi(link_num) ce_lsi[link_num-1]
257 #define ce_dtl(link_num) ce_dtl_utl[link_num-1]
258 #define ce_utl(link_num) ce_dtl_utl[link_num-1]
467 #define CE_LSI_GB_CFG1_RXL0S_THS_SHFT 0
468 #define CE_LSI_GB_CFG1_RXL0S_THS_MASK (0xffULL << 0)
469 #define CE_LSI_GB_CFG1_RXL0S_SMP_SHFT 8
470 #define CE_LSI_GB_CFG1_RXL0S_SMP_MASK (0xfULL << 8)
471 #define CE_LSI_GB_CFG1_RXL0S_ADJ_SHFT 12
472 #define CE_LSI_GB_CFG1_RXL0S_ADJ_MASK (0x7ULL << 12)
473 #define CE_LSI_GB_CFG1_RXL0S_FLT_SHFT 15
474 #define CE_LSI_GB_CFG1_RXL0S_FLT_MASK (0x1ULL << 15)
475 #define CE_LSI_GB_CFG1_LPBK_SEL_SHFT 16
476 #define CE_LSI_GB_CFG1_LPBK_SEL_MASK (0x3ULL << 16)
477 #define CE_LSI_GB_CFG1_LPBK_EN_SHFT 18
478 #define CE_LSI_GB_CFG1_LPBK_EN_MASK (0x1ULL << 18)
479 #define CE_LSI_GB_CFG1_RVRS_LB_SHFT 19
480 #define CE_LSI_GB_CFG1_RVRS_LB_MASK (0x1ULL << 19)
481 #define CE_LSI_GB_CFG1_RVRS_CLK_SHFT 20
482 #define CE_LSI_GB_CFG1_RVRS_CLK_MASK (0x3ULL << 20)
483 #define CE_LSI_GB_CFG1_SLF_TS_SHFT 24
484 #define CE_LSI_GB_CFG1_SLF_TS_MASK (0xfULL << 24)
487 #define CE_ADM_INT_CE_ERROR_SHFT 0
488 #define CE_ADM_INT_LSI1_IP_ERROR_SHFT 1
489 #define CE_ADM_INT_LSI2_IP_ERROR_SHFT 2
490 #define CE_ADM_INT_PCIE_ERROR_SHFT 3
491 #define CE_ADM_INT_PORT1_HOTPLUG_EVENT_SHFT 4
492 #define CE_ADM_INT_PORT2_HOTPLUG_EVENT_SHFT 5
493 #define CE_ADM_INT_PCIE_PORT1_DEV_A_SHFT 6
494 #define CE_ADM_INT_PCIE_PORT1_DEV_B_SHFT 7
495 #define CE_ADM_INT_PCIE_PORT1_DEV_C_SHFT 8
496 #define CE_ADM_INT_PCIE_PORT1_DEV_D_SHFT 9
497 #define CE_ADM_INT_PCIE_PORT2_DEV_A_SHFT 10
498 #define CE_ADM_INT_PCIE_PORT2_DEV_B_SHFT 11
499 #define CE_ADM_INT_PCIE_PORT2_DEV_C_SHFT 12
500 #define CE_ADM_INT_PCIE_PORT2_DEV_D_SHFT 13
501 #define CE_ADM_INT_PCIE_MSG_SHFT 14
502 #define CE_ADM_INT_PCIE_MSG_SLOT_0_SHFT 14
503 #define CE_ADM_INT_PCIE_MSG_SLOT_1_SHFT 15
504 #define CE_ADM_INT_PCIE_MSG_SLOT_2_SHFT 16
505 #define CE_ADM_INT_PCIE_MSG_SLOT_3_SHFT 17
506 #define CE_ADM_INT_PORT1_PM_PME_MSG_SHFT 22
507 #define CE_ADM_INT_PORT2_PM_PME_MSG_SHFT 23
510 #define CE_ADM_FORCE_INT_PCIE_PORT1_DEV_A_SHFT 0
511 #define CE_ADM_FORCE_INT_PCIE_PORT1_DEV_B_SHFT 1
512 #define CE_ADM_FORCE_INT_PCIE_PORT1_DEV_C_SHFT 2
513 #define CE_ADM_FORCE_INT_PCIE_PORT1_DEV_D_SHFT 3
514 #define CE_ADM_FORCE_INT_PCIE_PORT2_DEV_A_SHFT 4
515 #define CE_ADM_FORCE_INT_PCIE_PORT2_DEV_B_SHFT 5
516 #define CE_ADM_FORCE_INT_PCIE_PORT2_DEV_C_SHFT 6
517 #define CE_ADM_FORCE_INT_PCIE_PORT2_DEV_D_SHFT 7
518 #define CE_ADM_FORCE_INT_ALWAYS_SHFT 8
521 #define INTR_VECTOR_SHFT 56
524 #define CE_ADM_ERR_CRM_SSP_REQ_INVALID (0x1ULL << 0)
525 #define CE_ADM_ERR_SSP_REQ_HEADER (0x1ULL << 1)
526 #define CE_ADM_ERR_SSP_RSP_HEADER (0x1ULL << 2)
527 #define CE_ADM_ERR_SSP_PROTOCOL_ERROR (0x1ULL << 3)
528 #define CE_ADM_ERR_SSP_SBE (0x1ULL << 4)
529 #define CE_ADM_ERR_SSP_MBE (0x1ULL << 5)
530 #define CE_ADM_ERR_CXM_CREDIT_OFLOW (0x1ULL << 6)
531 #define CE_ADM_ERR_DRE_SSP_REQ_INVAL (0x1ULL << 7)
532 #define CE_ADM_ERR_SSP_REQ_LONG (0x1ULL << 8)
533 #define CE_ADM_ERR_SSP_REQ_OFLOW (0x1ULL << 9)
534 #define CE_ADM_ERR_SSP_REQ_SHORT (0x1ULL << 10)
535 #define CE_ADM_ERR_SSP_REQ_SIDEBAND (0x1ULL << 11)
536 #define CE_ADM_ERR_SSP_REQ_ADDR_ERR (0x1ULL << 12)
537 #define CE_ADM_ERR_SSP_REQ_BAD_BE (0x1ULL << 13)
538 #define CE_ADM_ERR_PCIE_COMPL_TIMEOUT (0x1ULL << 14)
539 #define CE_ADM_ERR_PCIE_UNEXP_COMPL (0x1ULL << 15)
540 #define CE_ADM_ERR_PCIE_ERR_COMPL (0x1ULL << 16)
541 #define CE_ADM_ERR_DRE_CREDIT_OFLOW (0x1ULL << 17)
542 #define CE_ADM_ERR_DRE_SRAM_PE (0x1ULL << 18)
543 #define CE_ADM_ERR_SSP_RSP_INVALID (0x1ULL << 19)
544 #define CE_ADM_ERR_SSP_RSP_LONG (0x1ULL << 20)
545 #define CE_ADM_ERR_SSP_RSP_SHORT (0x1ULL << 21)
546 #define CE_ADM_ERR_SSP_RSP_SIDEBAND (0x1ULL << 22)
547 #define CE_ADM_ERR_URE_SSP_RSP_UNEXP (0x1ULL << 23)
548 #define CE_ADM_ERR_URE_SSP_WR_REQ_TIMEOUT (0x1ULL << 24)
549 #define CE_ADM_ERR_URE_SSP_RD_REQ_TIMEOUT (0x1ULL << 25)
550 #define CE_ADM_ERR_URE_ATE3240_PAGE_FAULT (0x1ULL << 26)
551 #define CE_ADM_ERR_URE_ATE40_PAGE_FAULT (0x1ULL << 27)
552 #define CE_ADM_ERR_URE_CREDIT_OFLOW (0x1ULL << 28)
553 #define CE_ADM_ERR_URE_SRAM_PE (0x1ULL << 29)
554 #define CE_ADM_ERR_ADM_SSP_RSP_UNEXP (0x1ULL << 30)
555 #define CE_ADM_ERR_ADM_SSP_REQ_TIMEOUT (0x1ULL << 31)
556 #define CE_ADM_ERR_MMR_ACCESS_ERROR (0x1ULL << 32)
557 #define CE_ADM_ERR_MMR_ADDR_ERROR (0x1ULL << 33)
558 #define CE_ADM_ERR_ADM_CREDIT_OFLOW (0x1ULL << 34)
559 #define CE_ADM_ERR_ADM_SRAM_PE (0x1ULL << 35)
560 #define CE_ADM_ERR_DTL1_MIN_PDATA_CREDIT_ERR (0x1ULL << 36)
561 #define CE_ADM_ERR_DTL1_INF_COMPL_CRED_UPDT_ERR (0x1ULL << 37)
562 #define CE_ADM_ERR_DTL1_INF_POSTED_CRED_UPDT_ERR (0x1ULL << 38)
563 #define CE_ADM_ERR_DTL1_INF_NPOSTED_CRED_UPDT_ERR (0x1ULL << 39)
564 #define CE_ADM_ERR_DTL1_COMP_HD_CRED_MAX_ERR (0x1ULL << 40)
565 #define CE_ADM_ERR_DTL1_COMP_D_CRED_MAX_ERR (0x1ULL << 41)
566 #define CE_ADM_ERR_DTL1_NPOSTED_HD_CRED_MAX_ERR (0x1ULL << 42)
567 #define CE_ADM_ERR_DTL1_NPOSTED_D_CRED_MAX_ERR (0x1ULL << 43)
568 #define CE_ADM_ERR_DTL1_POSTED_HD_CRED_MAX_ERR (0x1ULL << 44)
569 #define CE_ADM_ERR_DTL1_POSTED_D_CRED_MAX_ERR (0x1ULL << 45)
570 #define CE_ADM_ERR_DTL2_MIN_PDATA_CREDIT_ERR (0x1ULL << 46)
571 #define CE_ADM_ERR_DTL2_INF_COMPL_CRED_UPDT_ERR (0x1ULL << 47)
572 #define CE_ADM_ERR_DTL2_INF_POSTED_CRED_UPDT_ERR (0x1ULL << 48)
573 #define CE_ADM_ERR_DTL2_INF_NPOSTED_CRED_UPDT_ERR (0x1ULL << 49)
574 #define CE_ADM_ERR_DTL2_COMP_HD_CRED_MAX_ERR (0x1ULL << 50)
575 #define CE_ADM_ERR_DTL2_COMP_D_CRED_MAX_ERR (0x1ULL << 51)
576 #define CE_ADM_ERR_DTL2_NPOSTED_HD_CRED_MAX_ERR (0x1ULL << 52)
577 #define CE_ADM_ERR_DTL2_NPOSTED_D_CRED_MAX_ERR (0x1ULL << 53)
578 #define CE_ADM_ERR_DTL2_POSTED_HD_CRED_MAX_ERR (0x1ULL << 54)
579 #define CE_ADM_ERR_DTL2_POSTED_D_CRED_MAX_ERR (0x1ULL << 55)
580 #define CE_ADM_ERR_PORT1_PCIE_COR_ERR (0x1ULL << 56)
581 #define CE_ADM_ERR_PORT1_PCIE_NFAT_ERR (0x1ULL << 57)
582 #define CE_ADM_ERR_PORT1_PCIE_FAT_ERR (0x1ULL << 58)
583 #define CE_ADM_ERR_PORT2_PCIE_COR_ERR (0x1ULL << 59)
584 #define CE_ADM_ERR_PORT2_PCIE_NFAT_ERR (0x1ULL << 60)
585 #define CE_ADM_ERR_PORT2_PCIE_FAT_ERR (0x1ULL << 61)
588 #define FLUSH_SEL_PORT1_PIPE0_SHFT 0
589 #define FLUSH_SEL_PORT1_PIPE1_SHFT 4
590 #define FLUSH_SEL_PORT1_PIPE2_SHFT 8
591 #define FLUSH_SEL_PORT1_PIPE3_SHFT 12
592 #define FLUSH_SEL_PORT2_PIPE0_SHFT 16
593 #define FLUSH_SEL_PORT2_PIPE1_SHFT 20
594 #define FLUSH_SEL_PORT2_PIPE2_SHFT 24
595 #define FLUSH_SEL_PORT2_PIPE3_SHFT 28
598 #define CE_DRE_RO_ENABLE (0x1ULL << 0)
599 #define CE_DRE_DYN_RO_ENABLE (0x1ULL << 1)
600 #define CE_DRE_SUP_CONFIG_COMP_ERROR (0x1ULL << 2)
601 #define CE_DRE_SUP_IO_COMP_ERROR (0x1ULL << 3)
602 #define CE_DRE_ADDR_MODE_SHFT 4
605 #define CE_DRE_LAST_CONFIG_COMPLETION (0x7ULL << 0)
606 #define CE_DRE_DOWNSTREAM_CONFIG_ERROR (0x1ULL << 3)
607 #define CE_DRE_CONFIG_COMPLETION_VALID (0x1ULL << 4)
608 #define CE_DRE_CONFIG_REQUEST_ACTIVE (0x1ULL << 5)
611 #define CE_URE_RD_MRG_ENABLE (0x1ULL << 0)
612 #define CE_URE_WRT_MRG_ENABLE1 (0x1ULL << 4)
613 #define CE_URE_WRT_MRG_ENABLE2 (0x1ULL << 5)
614 #define CE_URE_WRT_MRG_TIMER_SHFT 12
615 #define CE_URE_WRT_MRG_TIMER_MASK (0x7FFULL << CE_URE_WRT_MRG_TIMER_SHFT)
616 #define CE_URE_WRT_MRG_TIMER(x) (((u64)(x) << \
617 CE_URE_WRT_MRG_TIMER_SHFT) & \
618 CE_URE_WRT_MRG_TIMER_MASK)
619 #define CE_URE_RSPQ_BYPASS_DISABLE (0x1ULL << 24)
620 #define CE_URE_UPS_DAT1_PAR_DISABLE (0x1ULL << 32)
621 #define CE_URE_UPS_HDR1_PAR_DISABLE (0x1ULL << 33)
622 #define CE_URE_UPS_DAT2_PAR_DISABLE (0x1ULL << 34)
623 #define CE_URE_UPS_HDR2_PAR_DISABLE (0x1ULL << 35)
624 #define CE_URE_ATE_PAR_DISABLE (0x1ULL << 36)
625 #define CE_URE_RCI_PAR_DISABLE (0x1ULL << 37)
626 #define CE_URE_RSPQ_PAR_DISABLE (0x1ULL << 38)
627 #define CE_URE_DNS_DAT_PAR_DISABLE (0x1ULL << 39)
628 #define CE_URE_DNS_HDR_PAR_DISABLE (0x1ULL << 40)
629 #define CE_URE_MALFORM_DISABLE (0x1ULL << 44)
630 #define CE_URE_UNSUP_DISABLE (0x1ULL << 45)
633 #define CE_URE_ATE3240_ENABLE (0x1ULL << 0)
634 #define CE_URE_ATE40_ENABLE (0x1ULL << 1)
635 #define CE_URE_PAGESIZE_SHFT 4
636 #define CE_URE_PAGESIZE_MASK (0x7ULL << CE_URE_PAGESIZE_SHFT)
637 #define CE_URE_4K_PAGESIZE (0x0ULL << CE_URE_PAGESIZE_SHFT)
638 #define CE_URE_16K_PAGESIZE (0x1ULL << CE_URE_PAGESIZE_SHFT)
639 #define CE_URE_64K_PAGESIZE (0x2ULL << CE_URE_PAGESIZE_SHFT)
640 #define CE_URE_128K_PAGESIZE (0x3ULL << CE_URE_PAGESIZE_SHFT)
641 #define CE_URE_256K_PAGESIZE (0x4ULL << CE_URE_PAGESIZE_SHFT)
644 #define PKT_TRAFIC_SHRT 16
645 #define BUS_SRC_ID_SHFT 8
646 #define DEV_SRC_ID_SHFT 3
647 #define FNC_SRC_ID_SHFT 0
648 #define CE_URE_TC_MASK (0x07ULL << PKT_TRAFIC_SHRT)
649 #define CE_URE_BUS_MASK (0xFFULL << BUS_SRC_ID_SHFT)
650 #define CE_URE_DEV_MASK (0x1FULL << DEV_SRC_ID_SHFT)
651 #define CE_URE_FNC_MASK (0x07ULL << FNC_SRC_ID_SHFT)
652 #define CE_URE_PIPE_BUS(b) (((u64)(b) << BUS_SRC_ID_SHFT) & \
654 #define CE_URE_PIPE_DEV(d) (((u64)(d) << DEV_SRC_ID_SHFT) & \
656 #define CE_URE_PIPE_FNC(f) (((u64)(f) << FNC_SRC_ID_SHFT) & \
659 #define CE_URE_SEL1_SHFT 0
660 #define CE_URE_SEL2_SHFT 20
661 #define CE_URE_SEL3_SHFT 40
662 #define CE_URE_SEL1_MASK (0x7FFFFULL << CE_URE_SEL1_SHFT)
663 #define CE_URE_SEL2_MASK (0x7FFFFULL << CE_URE_SEL2_SHFT)
664 #define CE_URE_SEL3_MASK (0x7FFFFULL << CE_URE_SEL3_SHFT)
668 #define CE_URE_MASK1_SHFT 0
669 #define CE_URE_MASK2_SHFT 20
670 #define CE_URE_MASK3_SHFT 40
671 #define CE_URE_MASK1_MASK (0x7FFFFULL << CE_URE_MASK1_SHFT)
672 #define CE_URE_MASK2_MASK (0x7FFFFULL << CE_URE_MASK2_SHFT)
673 #define CE_URE_MASK3_MASK (0x7FFFFULL << CE_URE_MASK3_SHFT)
677 #define CE_URE_SI (0x1ULL << 0)
678 #define CE_URE_ELAL_SHFT 4
679 #define CE_URE_ELAL_MASK (0x7ULL << CE_URE_ELAL_SHFT)
680 #define CE_URE_ELAL_SET(n) (((u64)(n) << CE_URE_ELAL_SHFT) & \
682 #define CE_URE_ELAL1_SHFT 8
683 #define CE_URE_ELAL1_MASK (0x7ULL << CE_URE_ELAL1_SHFT)
684 #define CE_URE_ELAL1_SET(n) (((u64)(n) << CE_URE_ELAL1_SHFT) & \
686 #define CE_URE_SCC (0x1ULL << 12)
687 #define CE_URE_PN1_SHFT 16
688 #define CE_URE_PN1_MASK (0xFFULL << CE_URE_PN1_SHFT)
689 #define CE_URE_PN2_SHFT 24
690 #define CE_URE_PN2_MASK (0xFFULL << CE_URE_PN2_SHFT)
691 #define CE_URE_PN1_SET(n) (((u64)(n) << CE_URE_PN1_SHFT) & \
693 #define CE_URE_PN2_SET(n) (((u64)(n) << CE_URE_PN2_SHFT) & \
697 #define CE_URE_ABP (0x1ULL << 0)
698 #define CE_URE_PCP (0x1ULL << 1)
699 #define CE_URE_MSP (0x1ULL << 2)
700 #define CE_URE_AIP (0x1ULL << 3)
701 #define CE_URE_PIP (0x1ULL << 4)
702 #define CE_URE_HPS (0x1ULL << 5)
703 #define CE_URE_HPC (0x1ULL << 6)
704 #define CE_URE_SPLV_SHFT 7
705 #define CE_URE_SPLV_MASK (0xFFULL << CE_URE_SPLV_SHFT)
706 #define CE_URE_SPLV_SET(n) (((u64)(n) << CE_URE_SPLV_SHFT) & \
708 #define CE_URE_SPLS_SHFT 15
709 #define CE_URE_SPLS_MASK (0x3ULL << CE_URE_SPLS_SHFT)
710 #define CE_URE_SPLS_SET(n) (((u64)(n) << CE_URE_SPLS_SHFT) & \
712 #define CE_URE_PSN1_SHFT 19
713 #define CE_URE_PSN1_MASK (0x1FFFULL << CE_URE_PSN1_SHFT)
714 #define CE_URE_PSN2_SHFT 32
715 #define CE_URE_PSN2_MASK (0x1FFFULL << CE_URE_PSN2_SHFT)
716 #define CE_URE_PSN1_SET(n) (((u64)(n) << CE_URE_PSN1_SHFT) & \
718 #define CE_URE_PSN2_SET(n) (((u64)(n) << CE_URE_PSN2_SHFT) & \
726 #define CE_PIO_MMR 0x00000000
727 #define CE_PIO_MMR_LEN 0x04000000
730 #define CE_PIO_CONFIG_SPACE 0x04000000
731 #define CE_PIO_CONFIG_SPACE_LEN 0x04000000
734 #define CE_PIO_IO_SPACE_ALIAS 0x08000000
735 #define CE_PIO_IO_SPACE_ALIAS_LEN 0x08000000
738 #define CE_PIO_E_CONFIG_SPACE 0x10000000
739 #define CE_PIO_E_CONFIG_SPACE_LEN 0x10000000
742 #define CE_PIO_IO_SPACE 0x100000000
743 #define CE_PIO_IO_SPACE_LEN 0x100000000
746 #define CE_PIO_MEM_SPACE 0x200000000
747 #define CE_PIO_MEM_SPACE_LEN TIO_HWIN_SIZE
753 #define CE_E_CONFIG_BUS_SHFT 20
754 #define CE_E_CONFIG_BUS_MASK (0xFF << CE_E_CONFIG_BUS_SHFT)
755 #define CE_E_CONFIG_DEVICE_SHFT 15
756 #define CE_E_CONFIG_DEVICE_MASK (0x1F << CE_E_CONFIG_DEVICE_SHFT)
757 #define CE_E_CONFIG_FUNC_SHFT 12
758 #define CE_E_CONFIG_FUNC_MASK (0x7 << CE_E_CONFIG_FUNC_SHFT)