Skip to content

Commit de2ae88

Browse files
konradybcioGeorgi Djakov
authored andcommitted
interconnect: qcom: sdx65: Retire DEFINE_QBCM
The struct definition macros are hard to read and compare, expand them. Signed-off-by: Konrad Dybcio <[email protected]> Reviewed-by: Bjorn Andersson <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Georgi Djakov <[email protected]>
1 parent 37474b0 commit de2ae88

File tree

1 file changed

+165
-20
lines changed

1 file changed

+165
-20
lines changed

drivers/interconnect/qcom/sdx65.c

Lines changed: 165 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -604,26 +604,171 @@ static struct qcom_icc_node xs_sys_tcu_cfg = {
604604
.buswidth = 8,
605605
};
606606

607-
DEFINE_QBCM(bcm_ce0, "CE0", false, &qxm_crypto);
608-
DEFINE_QBCM(bcm_mc0, "MC0", true, &ebi);
609-
DEFINE_QBCM(bcm_pn0, "PN0", true, &qhm_snoc_cfg, &qhs_aoss, &qhs_apss, &qhs_audio, &qhs_blsp1, &qhs_clk_ctl, &qhs_crypto0_cfg, &qhs_ddrss_cfg, &qhs_ecc_cfg, &qhs_imem_cfg, &qhs_ipa, &qhs_mss_cfg, &qhs_pcie_parf, &qhs_pdm, &qhs_prng, &qhs_qdss_cfg, &qhs_qpic, &qhs_sdc1, &qhs_snoc_cfg, &qhs_spmi_fetcher, &qhs_spmi_vgi_coex, &qhs_tcsr, &qhs_tlmm, &qhs_usb3, &qhs_usb3_phy, &srvc_snoc);
610-
DEFINE_QBCM(bcm_pn1, "PN1", false, &xm_sdc1);
611-
DEFINE_QBCM(bcm_pn2, "PN2", false, &qhm_audio, &qhm_spmi_fetcher1);
612-
DEFINE_QBCM(bcm_pn3, "PN3", false, &qhm_blsp1, &qhm_qpic);
613-
DEFINE_QBCM(bcm_pn4, "PN4", false, &qxm_crypto);
614-
DEFINE_QBCM(bcm_sh0, "SH0", true, &qns_llcc);
615-
DEFINE_QBCM(bcm_sh1, "SH1", false, &qns_memnoc_snoc);
616-
DEFINE_QBCM(bcm_sh3, "SH3", false, &xm_apps_rdwr);
617-
DEFINE_QBCM(bcm_sn0, "SN0", true, &qns_snoc_memnoc);
618-
DEFINE_QBCM(bcm_sn1, "SN1", false, &qxs_imem);
619-
DEFINE_QBCM(bcm_sn2, "SN2", false, &xs_qdss_stm);
620-
DEFINE_QBCM(bcm_sn3, "SN3", false, &xs_sys_tcu_cfg);
621-
DEFINE_QBCM(bcm_sn5, "SN5", false, &xs_pcie);
622-
DEFINE_QBCM(bcm_sn6, "SN6", false, &qhm_qdss_bam, &xm_qdss_etr);
623-
DEFINE_QBCM(bcm_sn7, "SN7", false, &qnm_aggre_noc, &xm_pcie, &xm_usb3, &qns_aggre_noc);
624-
DEFINE_QBCM(bcm_sn8, "SN8", false, &qnm_memnoc);
625-
DEFINE_QBCM(bcm_sn9, "SN9", false, &qnm_memnoc_pcie);
626-
DEFINE_QBCM(bcm_sn10, "SN10", false, &qnm_ipa, &xm_ipa2pcie_slv);
607+
static struct qcom_icc_bcm bcm_ce0 = {
608+
.name = "CE0",
609+
.keepalive = false,
610+
.num_nodes = 1,
611+
.nodes = { &qxm_crypto },
612+
};
613+
614+
static struct qcom_icc_bcm bcm_mc0 = {
615+
.name = "MC0",
616+
.keepalive = true,
617+
.num_nodes = 1,
618+
.nodes = { &ebi },
619+
};
620+
621+
static struct qcom_icc_bcm bcm_pn0 = {
622+
.name = "PN0",
623+
.keepalive = true,
624+
.num_nodes = 26,
625+
.nodes = { &qhm_snoc_cfg,
626+
&qhs_aoss,
627+
&qhs_apss,
628+
&qhs_audio,
629+
&qhs_blsp1,
630+
&qhs_clk_ctl,
631+
&qhs_crypto0_cfg,
632+
&qhs_ddrss_cfg,
633+
&qhs_ecc_cfg,
634+
&qhs_imem_cfg,
635+
&qhs_ipa,
636+
&qhs_mss_cfg,
637+
&qhs_pcie_parf,
638+
&qhs_pdm,
639+
&qhs_prng,
640+
&qhs_qdss_cfg,
641+
&qhs_qpic,
642+
&qhs_sdc1,
643+
&qhs_snoc_cfg,
644+
&qhs_spmi_fetcher,
645+
&qhs_spmi_vgi_coex,
646+
&qhs_tcsr,
647+
&qhs_tlmm,
648+
&qhs_usb3,
649+
&qhs_usb3_phy,
650+
&srvc_snoc
651+
},
652+
};
653+
654+
static struct qcom_icc_bcm bcm_pn1 = {
655+
.name = "PN1",
656+
.keepalive = false,
657+
.num_nodes = 1,
658+
.nodes = { &xm_sdc1 },
659+
};
660+
661+
static struct qcom_icc_bcm bcm_pn2 = {
662+
.name = "PN2",
663+
.keepalive = false,
664+
.num_nodes = 2,
665+
.nodes = { &qhm_audio, &qhm_spmi_fetcher1 },
666+
};
667+
668+
static struct qcom_icc_bcm bcm_pn3 = {
669+
.name = "PN3",
670+
.keepalive = false,
671+
.num_nodes = 2,
672+
.nodes = { &qhm_blsp1, &qhm_qpic },
673+
};
674+
675+
static struct qcom_icc_bcm bcm_pn4 = {
676+
.name = "PN4",
677+
.keepalive = false,
678+
.num_nodes = 1,
679+
.nodes = { &qxm_crypto },
680+
};
681+
682+
static struct qcom_icc_bcm bcm_sh0 = {
683+
.name = "SH0",
684+
.keepalive = true,
685+
.num_nodes = 1,
686+
.nodes = { &qns_llcc },
687+
};
688+
689+
static struct qcom_icc_bcm bcm_sh1 = {
690+
.name = "SH1",
691+
.keepalive = false,
692+
.num_nodes = 1,
693+
.nodes = { &qns_memnoc_snoc },
694+
};
695+
696+
static struct qcom_icc_bcm bcm_sh3 = {
697+
.name = "SH3",
698+
.keepalive = false,
699+
.num_nodes = 1,
700+
.nodes = { &xm_apps_rdwr },
701+
};
702+
703+
static struct qcom_icc_bcm bcm_sn0 = {
704+
.name = "SN0",
705+
.keepalive = true,
706+
.num_nodes = 1,
707+
.nodes = { &qns_snoc_memnoc },
708+
};
709+
710+
static struct qcom_icc_bcm bcm_sn1 = {
711+
.name = "SN1",
712+
.keepalive = false,
713+
.num_nodes = 1,
714+
.nodes = { &qxs_imem },
715+
};
716+
717+
static struct qcom_icc_bcm bcm_sn2 = {
718+
.name = "SN2",
719+
.keepalive = false,
720+
.num_nodes = 1,
721+
.nodes = { &xs_qdss_stm },
722+
};
723+
724+
static struct qcom_icc_bcm bcm_sn3 = {
725+
.name = "SN3",
726+
.keepalive = false,
727+
.num_nodes = 1,
728+
.nodes = { &xs_sys_tcu_cfg },
729+
};
730+
731+
static struct qcom_icc_bcm bcm_sn5 = {
732+
.name = "SN5",
733+
.keepalive = false,
734+
.num_nodes = 1,
735+
.nodes = { &xs_pcie },
736+
};
737+
738+
static struct qcom_icc_bcm bcm_sn6 = {
739+
.name = "SN6",
740+
.keepalive = false,
741+
.num_nodes = 2,
742+
.nodes = { &qhm_qdss_bam, &xm_qdss_etr },
743+
};
744+
745+
static struct qcom_icc_bcm bcm_sn7 = {
746+
.name = "SN7",
747+
.keepalive = false,
748+
.num_nodes = 4,
749+
.nodes = { &qnm_aggre_noc, &xm_pcie, &xm_usb3, &qns_aggre_noc },
750+
};
751+
752+
static struct qcom_icc_bcm bcm_sn8 = {
753+
.name = "SN8",
754+
.keepalive = false,
755+
.num_nodes = 1,
756+
.nodes = { &qnm_memnoc },
757+
};
758+
759+
static struct qcom_icc_bcm bcm_sn9 = {
760+
.name = "SN9",
761+
.keepalive = false,
762+
.num_nodes = 1,
763+
.nodes = { &qnm_memnoc_pcie },
764+
};
765+
766+
static struct qcom_icc_bcm bcm_sn10 = {
767+
.name = "SN10",
768+
.keepalive = false,
769+
.num_nodes = 2,
770+
.nodes = { &qnm_ipa, &xm_ipa2pcie_slv },
771+
};
627772

628773
static struct qcom_icc_bcm * const mc_virt_bcms[] = {
629774
&bcm_mc0,

0 commit comments

Comments
 (0)