175
175
enum cmn_model {
176
176
CMN_ANY = -1 ,
177
177
CMN600 = 1 ,
178
+ CI700 = 2 ,
178
179
};
179
180
180
181
/* CMN-600 r0px shouldn't exist in silicon, thankfully */
@@ -186,6 +187,9 @@ enum cmn_revision {
186
187
CMN600_R2P0 ,
187
188
CMN600_R3P0 ,
188
189
CMN600_R3P1 ,
190
+ CI700_R0P0 = 0 ,
191
+ CI700_R1P0 ,
192
+ CI700_R2P0 ,
189
193
};
190
194
191
195
enum cmn_node_type {
@@ -401,8 +405,10 @@ struct arm_cmn_format_attr {
401
405
static bool arm_cmn_is_occup_event (enum cmn_model model ,
402
406
enum cmn_node_type type , unsigned int id )
403
407
{
404
- return (type == CMN_TYPE_DVM && id == 0x05 ) ||
405
- (type == CMN_TYPE_HNF && id == 0x0f );
408
+ if (type == CMN_TYPE_DVM )
409
+ return (model == CMN600 && id == 0x05 ) ||
410
+ (model == CI700 && id == 0x0c );
411
+ return type == CMN_TYPE_HNF && id == 0x0f ;
406
412
}
407
413
408
414
static ssize_t arm_cmn_event_show (struct device * dev ,
@@ -497,14 +503,19 @@ static umode_t arm_cmn_event_attr_is_visible(struct kobject *kobj,
497
503
__CMN_EVENT_XP(n_##_name, (_event) | (2 << 2)), \
498
504
__CMN_EVENT_XP(s_##_name, (_event) | (3 << 2)), \
499
505
__CMN_EVENT_XP(p0_##_name, (_event) | (4 << 2)), \
500
- __CMN_EVENT_XP(p1_##_name, (_event) | (5 << 2))
506
+ __CMN_EVENT_XP(p1_##_name, (_event) | (5 << 2)), \
507
+ __CMN_EVENT_XP(p2_##_name, (_event) | (6 << 2)), \
508
+ __CMN_EVENT_XP(p3_##_name, (_event) | (7 << 2))
501
509
502
510
/* Good thing there are only 3 fundamental XP events... */
503
511
#define CMN_EVENT_XP (_name , _event ) \
504
512
_CMN_EVENT_XP(req_##_name, (_event) | (0 << 5)), \
505
513
_CMN_EVENT_XP(rsp_##_name, (_event) | (1 << 5)), \
506
514
_CMN_EVENT_XP(snp_##_name, (_event) | (2 << 5)), \
507
- _CMN_EVENT_XP(dat_##_name, (_event) | (3 << 5))
515
+ _CMN_EVENT_XP(dat_##_name, (_event) | (3 << 5)), \
516
+ _CMN_EVENT_XP(pub_##_name, (_event) | (4 << 5)), \
517
+ _CMN_EVENT_XP(rsp2_##_name, (_event) | (5 << 5)), \
518
+ _CMN_EVENT_XP(dat2_##_name, (_event) | (6 << 5))
508
519
509
520
510
521
static struct attribute * arm_cmn_event_attrs [] = {
@@ -522,6 +533,20 @@ static struct attribute *arm_cmn_event_attrs[] = {
522
533
_CMN_EVENT_DVM (CMN600 , rxreq_trk_occupancy_all , 0x05 , 0 ),
523
534
_CMN_EVENT_DVM (CMN600 , rxreq_trk_occupancy_dvmop , 0x05 , 1 ),
524
535
_CMN_EVENT_DVM (CMN600 , rxreq_trk_occupancy_dvmsync , 0x05 , 2 ),
536
+ CMN_EVENT_DVM (CI700 , dvmop_tlbi , 0x01 ),
537
+ CMN_EVENT_DVM (CI700 , dvmop_bpi , 0x02 ),
538
+ CMN_EVENT_DVM (CI700 , dvmop_pici , 0x03 ),
539
+ CMN_EVENT_DVM (CI700 , dvmop_vici , 0x04 ),
540
+ CMN_EVENT_DVM (CI700 , dvmsync , 0x05 ),
541
+ CMN_EVENT_DVM (CI700 , vmid_filtered , 0x06 ),
542
+ CMN_EVENT_DVM (CI700 , rndop_filtered , 0x07 ),
543
+ CMN_EVENT_DVM (CI700 , retry , 0x08 ),
544
+ CMN_EVENT_DVM (CI700 , txsnp_flitv , 0x09 ),
545
+ CMN_EVENT_DVM (CI700 , txsnp_stall , 0x0a ),
546
+ CMN_EVENT_DVM (CI700 , trkfull , 0x0b ),
547
+ _CMN_EVENT_DVM (CI700 , trk_occupancy_all , 0x0c , 0 ),
548
+ _CMN_EVENT_DVM (CI700 , trk_occupancy_dvmop , 0x0c , 1 ),
549
+ _CMN_EVENT_DVM (CI700 , trk_occupancy_dvmsync , 0x0c , 2 ),
525
550
526
551
CMN_EVENT_HNF (CMN_ANY , cache_miss , 0x01 ),
527
552
CMN_EVENT_HNF (CMN_ANY , slc_sf_cache_access , 0x02 ),
@@ -558,6 +583,9 @@ static struct attribute *arm_cmn_event_attrs[] = {
558
583
CMN_EVENT_HNF (CMN_ANY , stash_snp_sent , 0x1d ),
559
584
CMN_EVENT_HNF (CMN_ANY , stash_data_pull , 0x1e ),
560
585
CMN_EVENT_HNF (CMN_ANY , snp_fwded , 0x1f ),
586
+ CMN_EVENT_HNF (CI700 , atomic_fwd , 0x20 ),
587
+ CMN_EVENT_HNF (CI700 , mpam_hardlim , 0x21 ),
588
+ CMN_EVENT_HNF (CI700 , mpam_softlim , 0x22 ),
561
589
562
590
CMN_EVENT_HNI (rrt_rd_occ_cnt_ovfl , 0x20 ),
563
591
CMN_EVENT_HNI (rrt_wr_occ_cnt_ovfl , 0x21 ),
@@ -598,6 +626,7 @@ static struct attribute *arm_cmn_event_attrs[] = {
598
626
CMN_EVENT_SBSX (CMN_ANY , wdb_occ_cnt_ovfl , 0x14 ),
599
627
CMN_EVENT_SBSX (CMN_ANY , rd_axi_trkr_occ_cnt_ovfl , 0x15 ),
600
628
CMN_EVENT_SBSX (CMN_ANY , cmo_axi_trkr_occ_cnt_ovfl , 0x16 ),
629
+ CMN_EVENT_SBSX (CI700 , rdb_occ_cnt_ovfl , 0x17 ),
601
630
CMN_EVENT_SBSX (CMN_ANY , arvalid_no_arready , 0x21 ),
602
631
CMN_EVENT_SBSX (CMN_ANY , awvalid_no_awready , 0x22 ),
603
632
CMN_EVENT_SBSX (CMN_ANY , wvalid_no_wready , 0x23 ),
@@ -624,6 +653,25 @@ static struct attribute *arm_cmn_event_attrs[] = {
624
653
CMN_EVENT_RNID (CMN600 , rdb_replay , 0x12 ),
625
654
CMN_EVENT_RNID (CMN600 , rdb_hybrid , 0x13 ),
626
655
CMN_EVENT_RNID (CMN600 , rdb_ord , 0x14 ),
656
+ CMN_EVENT_RNID (CI700 , padb_occ_ovfl , 0x11 ),
657
+ CMN_EVENT_RNID (CI700 , rpdb_occ_ovfl , 0x12 ),
658
+ CMN_EVENT_RNID (CI700 , rrt_occup_ovfl_slice1 , 0x13 ),
659
+ CMN_EVENT_RNID (CI700 , rrt_occup_ovfl_slice2 , 0x14 ),
660
+ CMN_EVENT_RNID (CI700 , rrt_occup_ovfl_slice3 , 0x15 ),
661
+ CMN_EVENT_RNID (CI700 , wrt_throttled , 0x16 ),
662
+
663
+ CMN_EVENT_MTSX (tc_lookup , 0x01 ),
664
+ CMN_EVENT_MTSX (tc_fill , 0x02 ),
665
+ CMN_EVENT_MTSX (tc_miss , 0x03 ),
666
+ CMN_EVENT_MTSX (tdb_forward , 0x04 ),
667
+ CMN_EVENT_MTSX (tcq_hazard , 0x05 ),
668
+ CMN_EVENT_MTSX (tcq_rd_alloc , 0x06 ),
669
+ CMN_EVENT_MTSX (tcq_wr_alloc , 0x07 ),
670
+ CMN_EVENT_MTSX (tcq_cmo_alloc , 0x08 ),
671
+ CMN_EVENT_MTSX (axi_rd_req , 0x09 ),
672
+ CMN_EVENT_MTSX (axi_wr_req , 0x0a ),
673
+ CMN_EVENT_MTSX (tcq_occ_cnt_ovfl , 0x0b ),
674
+ CMN_EVENT_MTSX (tdb_occ_cnt_ovfl , 0x0c ),
627
675
628
676
NULL
629
677
};
@@ -1773,6 +1821,7 @@ static int arm_cmn_remove(struct platform_device *pdev)
1773
1821
#ifdef CONFIG_OF
1774
1822
static const struct of_device_id arm_cmn_of_match [] = {
1775
1823
{ .compatible = "arm,cmn-600" , .data = (void * )CMN600 },
1824
+ { .compatible = "arm,ci-700" , .data = (void * )CI700 },
1776
1825
{}
1777
1826
};
1778
1827
MODULE_DEVICE_TABLE (of , arm_cmn_of_match );
0 commit comments