Lines Matching +full:reg +full:- +full:shift

1 // SPDX-License-Identifier: GPL-2.0-only
24 * some changes (as is the case for the LCD controller on da850-lcdk - the
54 int reg; member
55 int shift; member
61 .reg = DA8XX_MSTPRI0_OFFSET,
62 .shift = 0,
66 .reg = DA8XX_MSTPRI0_OFFSET,
67 .shift = 4,
71 .reg = DA8XX_MSTPRI0_OFFSET,
72 .shift = 16,
76 .reg = DA8XX_MSTPRI0_OFFSET,
77 .shift = 20,
81 .reg = DA8XX_MSTPRI1_OFFSET,
82 .shift = 0,
86 .reg = DA8XX_MSTPRI1_OFFSET,
87 .shift = 4,
91 .reg = DA8XX_MSTPRI1_OFFSET,
92 .shift = 8,
96 .reg = DA8XX_MSTPRI1_OFFSET,
97 .shift = 12,
101 .reg = DA8XX_MSTPRI1_OFFSET,
102 .shift = 16,
106 .reg = DA8XX_MSTPRI1_OFFSET,
107 .shift = 24,
111 .reg = DA8XX_MSTPRI1_OFFSET,
112 .shift = 28,
116 .reg = DA8XX_MSTPRI2_OFFSET,
117 .shift = 0,
121 .reg = DA8XX_MSTPRI2_OFFSET,
122 .shift = 8,
126 .reg = DA8XX_MSTPRI2_OFFSET,
127 .shift = 12,
131 .reg = DA8XX_MSTPRI2_OFFSET,
132 .shift = 20,
136 .reg = DA8XX_MSTPRI2_OFFSET,
137 .shift = 24,
141 .reg = DA8XX_MSTPRI2_OFFSET,
142 .shift = 28,
183 .board = "ti,da850-lcdk",
198 if (of_machine_is_compatible(board_prio->board)) in da8xx_mstpri_get_board_prio()
210 struct device *dev = &pdev->dev; in da8xx_mstpri_probe()
213 u32 reg; in da8xx_mstpri_probe() local
226 return -EINVAL; in da8xx_mstpri_probe()
229 for (i = 0; i < prio_list->numprio; i++) { in da8xx_mstpri_probe()
230 prio = &prio_list->priorities[i]; in da8xx_mstpri_probe()
231 prio_descr = &da8xx_mstpri_priority_list[prio->which]; in da8xx_mstpri_probe()
233 if (prio_descr->reg + sizeof(u32) > resource_size(res)) { in da8xx_mstpri_probe()
238 reg = readl(mstpri + prio_descr->reg); in da8xx_mstpri_probe()
239 reg &= ~prio_descr->mask; in da8xx_mstpri_probe()
240 reg |= prio->val << prio_descr->shift; in da8xx_mstpri_probe()
242 writel(reg, mstpri + prio_descr->reg); in da8xx_mstpri_probe()
249 { .compatible = "ti,da850-mstpri", },
256 .name = "da8xx-mstpri",