Lines Matching refs:dr_cell

68 	struct of_drconf_cell_v1 *dr_cell;  in drmem_update_dt_v1()  local
79 dr_cell = (struct of_drconf_cell_v1 *)p; in drmem_update_dt_v1()
82 dr_cell->base_addr = cpu_to_be64(lmb->base_addr); in drmem_update_dt_v1()
83 dr_cell->drc_index = cpu_to_be32(lmb->drc_index); in drmem_update_dt_v1()
84 dr_cell->aa_index = cpu_to_be32(lmb->aa_index); in drmem_update_dt_v1()
85 dr_cell->flags = cpu_to_be32(drmem_lmb_flags(lmb)); in drmem_update_dt_v1()
87 dr_cell++; in drmem_update_dt_v1()
94 static void init_drconf_v2_cell(struct of_drconf_cell_v2 *dr_cell, in init_drconf_v2_cell() argument
97 dr_cell->base_addr = cpu_to_be64(lmb->base_addr); in init_drconf_v2_cell()
98 dr_cell->drc_index = cpu_to_be32(lmb->drc_index); in init_drconf_v2_cell()
99 dr_cell->aa_index = cpu_to_be32(lmb->aa_index); in init_drconf_v2_cell()
100 dr_cell->flags = cpu_to_be32(drmem_lmb_flags(lmb)); in init_drconf_v2_cell()
107 struct of_drconf_cell_v2 *dr_cell; in drmem_update_dt_v2() local
129 prop_sz = lmb_sets * sizeof(*dr_cell) + sizeof(__be32); in drmem_update_dt_v2()
137 dr_cell = (struct of_drconf_cell_v2 *)p; in drmem_update_dt_v2()
146 init_drconf_v2_cell(dr_cell, lmb); in drmem_update_dt_v2()
154 dr_cell->seq_lmbs = cpu_to_be32(seq_lmbs); in drmem_update_dt_v2()
155 dr_cell++; in drmem_update_dt_v2()
157 init_drconf_v2_cell(dr_cell, lmb); in drmem_update_dt_v2()
167 dr_cell->seq_lmbs = cpu_to_be32(seq_lmbs); in drmem_update_dt_v2()
237 static void read_drconf_v2_cell(struct of_drconf_cell_v2 *dr_cell, in read_drconf_v2_cell() argument
242 dr_cell->seq_lmbs = of_read_number(p++, 1); in read_drconf_v2_cell()
243 dr_cell->base_addr = of_read_number(p, n_root_addr_cells); in read_drconf_v2_cell()
245 dr_cell->drc_index = of_read_number(p++, 1); in read_drconf_v2_cell()
246 dr_cell->aa_index = of_read_number(p++, 1); in read_drconf_v2_cell()
247 dr_cell->flags = of_read_number(p++, 1); in read_drconf_v2_cell()
256 struct of_drconf_cell_v2 dr_cell; in __walk_drmem_v2_lmbs() local
263 read_drconf_v2_cell(&dr_cell, &prop); in __walk_drmem_v2_lmbs()
265 for (j = 0; j < dr_cell.seq_lmbs; j++) { in __walk_drmem_v2_lmbs()
266 lmb.base_addr = dr_cell.base_addr; in __walk_drmem_v2_lmbs()
267 dr_cell.base_addr += drmem_lmb_size(); in __walk_drmem_v2_lmbs()
269 lmb.drc_index = dr_cell.drc_index; in __walk_drmem_v2_lmbs()
270 dr_cell.drc_index++; in __walk_drmem_v2_lmbs()
272 lmb.aa_index = dr_cell.aa_index; in __walk_drmem_v2_lmbs()
273 lmb.flags = dr_cell.flags; in __walk_drmem_v2_lmbs()
445 struct of_drconf_cell_v2 dr_cell; in init_drmem_v2_lmbs() local
457 read_drconf_v2_cell(&dr_cell, &p); in init_drmem_v2_lmbs()
458 drmem_info->n_lmbs += dr_cell.seq_lmbs; in init_drmem_v2_lmbs()
471 read_drconf_v2_cell(&dr_cell, &p); in init_drmem_v2_lmbs()
473 for (j = 0; j < dr_cell.seq_lmbs; j++) { in init_drmem_v2_lmbs()
476 lmb->base_addr = dr_cell.base_addr; in init_drmem_v2_lmbs()
477 dr_cell.base_addr += drmem_info->lmb_size; in init_drmem_v2_lmbs()
479 lmb->drc_index = dr_cell.drc_index; in init_drmem_v2_lmbs()
480 dr_cell.drc_index++; in init_drmem_v2_lmbs()
482 lmb->aa_index = dr_cell.aa_index; in init_drmem_v2_lmbs()
483 lmb->flags = dr_cell.flags; in init_drmem_v2_lmbs()