Lines Matching refs:clk_rst_ctl
33 union cvmx_uctlx_clk_rst_ctl clk_rst_ctl; in octeon2_usb_reset() local
39 clk_rst_ctl.u64 = cvmx_read_csr(CVMX_UCTLX_CLK_RST_CTL(0)); in octeon2_usb_reset()
40 if (clk_rst_ctl.s.hrst) { in octeon2_usb_reset()
60 union cvmx_uctlx_clk_rst_ctl clk_rst_ctl; in octeon2_usb_clocks_start() local
120 clk_rst_ctl.u64 = cvmx_read_csr(CVMX_UCTLX_CLK_RST_CTL(0)); in octeon2_usb_clocks_start()
126 if (clk_rst_ctl.s.hrst) in octeon2_usb_clocks_start()
129 clk_rst_ctl.s.p_por = 1; in octeon2_usb_clocks_start()
130 clk_rst_ctl.s.hrst = 0; in octeon2_usb_clocks_start()
131 clk_rst_ctl.s.p_prst = 0; in octeon2_usb_clocks_start()
132 clk_rst_ctl.s.h_clkdiv_rst = 0; in octeon2_usb_clocks_start()
133 clk_rst_ctl.s.o_clkdiv_rst = 0; in octeon2_usb_clocks_start()
134 clk_rst_ctl.s.h_clkdiv_en = 0; in octeon2_usb_clocks_start()
135 clk_rst_ctl.s.o_clkdiv_en = 0; in octeon2_usb_clocks_start()
136 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
139 clk_rst_ctl.s.p_refclk_sel = is_crystal_clock ? 0 : 1; in octeon2_usb_clocks_start()
146 clk_rst_ctl.s.p_refclk_div = 0; in octeon2_usb_clocks_start()
149 clk_rst_ctl.s.p_refclk_div = 1; in octeon2_usb_clocks_start()
152 clk_rst_ctl.s.p_refclk_div = 2; in octeon2_usb_clocks_start()
155 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
186 clk_rst_ctl.s.h_div = div; in octeon2_usb_clocks_start()
187 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
189 clk_rst_ctl.u64 = cvmx_read_csr(CVMX_UCTLX_CLK_RST_CTL(0)); in octeon2_usb_clocks_start()
190 clk_rst_ctl.s.h_clkdiv_en = 1; in octeon2_usb_clocks_start()
191 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
193 clk_rst_ctl.s.h_clkdiv_rst = 1; in octeon2_usb_clocks_start()
194 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
203 clk_rst_ctl.s.p_por = 0; in octeon2_usb_clocks_start()
204 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
213 clk_rst_ctl.s.o_clkdiv_rst = 1; in octeon2_usb_clocks_start()
214 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
217 clk_rst_ctl.s.o_clkdiv_en = 1; in octeon2_usb_clocks_start()
218 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
227 clk_rst_ctl.s.p_prst = 1; in octeon2_usb_clocks_start()
228 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
234 clk_rst_ctl.s.p_prst = 0; in octeon2_usb_clocks_start()
235 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
241 clk_rst_ctl.s.p_prst = 1; in octeon2_usb_clocks_start()
242 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()
248 clk_rst_ctl.s.hrst = 1; in octeon2_usb_clocks_start()
249 cvmx_write_csr(CVMX_UCTLX_CLK_RST_CTL(0), clk_rst_ctl.u64); in octeon2_usb_clocks_start()