/openbmc/linux/drivers/gpu/drm/nouveau/nvkm/subdev/fb/ |
H A D | gddr5.c | 75 ram->mr[0] &= ~0xf7f; in nvkm_gddr5_calc() 80 ram->mr[1] &= ~0x0bf; in nvkm_gddr5_calc() 89 ram->mr1_nuts = ram->mr[1]; in nvkm_gddr5_calc() 91 ram->mr[1] &= ~0x030; in nvkm_gddr5_calc() 95 ram->mr[3] &= ~0x020; in nvkm_gddr5_calc() 98 ram->mr[5] &= ~0x004; in nvkm_gddr5_calc() 103 if (ram->mr[6] & 0x001) in nvkm_gddr5_calc() 105 ram->mr[6] &= ~0xff1; in nvkm_gddr5_calc() 110 ram->mr[7] &= ~0x300; in nvkm_gddr5_calc() 113 ram->mr[7] &= ~0x088; in nvkm_gddr5_calc() [all …]
|
H A D | gddr3.c | 89 DLL = !(ram->mr[1] & 0x1); in nvkm_gddr3_calc() 98 ODT = (ram->mr[1] & 0xc) >> 2; in nvkm_gddr3_calc() 101 hi = ram->mr[2] & 0x1; in nvkm_gddr3_calc() 107 ram->mr[0] &= ~0xf74; in nvkm_gddr3_calc() 108 ram->mr[0] |= (CWL & 0x07) << 9; in nvkm_gddr3_calc() 109 ram->mr[0] |= (CL & 0x07) << 4; in nvkm_gddr3_calc() 110 ram->mr[0] |= (CL & 0x08) >> 1; in nvkm_gddr3_calc() 112 ram->mr[1] &= ~0x3fc; in nvkm_gddr3_calc() 113 ram->mr[1] |= (ODT & 0x03) << 2; in nvkm_gddr3_calc() 114 ram->mr[1] |= (RON & 0x03) << 8; in nvkm_gddr3_calc() [all …]
|
H A D | ramgk104.c | 160 const u32 mcoef = ((--ram->P2 << 28) | (ram->N2 << 8) | ram->M2); in r1373f4_init() 161 const u32 rcoef = (( ram->P1 << 16) | (ram->N1 << 8) | ram->M1); in r1373f4_init() 343 if (ram->from == 2 && ram->mode != 2) { in gk104_ram_calc_gddr5() 354 if (ram->from != 2 && ram->mode != 2) { in gk104_ram_calc_gddr5() 373 if (ram->from != 2 && ram->mode == 2) { in gk104_ram_calc_gddr5() 703 const u32 rcoef = (( ram->P1 << 16) | (ram->N1 << 8) | ram->M1); in gk104_ram_calc_sddr3() 1066 &ram->N1, &ram->fN1, &ram->M1, &ram->P1, in gk104_ram_calc_xits() 1067 &ram->N2, &ram->M2, &ram->P2); in gk104_ram_calc_xits() 1078 &ram->fN1, &ram->M1, &ram->P1); in gk104_ram_calc_xits() 1143 ram->base.next = &ram->base.target; in gk104_ram_calc() [all …]
|
H A D | sddr3.c | 93 (ram->mr[1] & 0x040) >> 5 | in nvkm_sddr3_calc() 106 ram->mr[0] &= ~0xf74; in nvkm_sddr3_calc() 107 ram->mr[0] |= (WR & 0x07) << 9; in nvkm_sddr3_calc() 108 ram->mr[0] |= (CL & 0x0e) << 3; in nvkm_sddr3_calc() 109 ram->mr[0] |= (CL & 0x01) << 2; in nvkm_sddr3_calc() 111 ram->mr[1] &= ~0x245; in nvkm_sddr3_calc() 112 ram->mr[1] |= (ODT & 0x1) << 2; in nvkm_sddr3_calc() 113 ram->mr[1] |= (ODT & 0x2) << 5; in nvkm_sddr3_calc() 114 ram->mr[1] |= (ODT & 0x4) << 7; in nvkm_sddr3_calc() 115 ram->mr[1] |= !DLL; in nvkm_sddr3_calc() [all …]
|
H A D | ramnv50.c | 165 switch (ram->base.type) { in nv50_ram_timing_read() 234 next = &ram->base.target; in nv50_ram_calc() 236 ram->base.next = next; in nv50_ram_calc() 290 switch (ram->base.type) { in nv50_ram_calc() 374 switch (ram->base.type) { in nv50_ram_calc() 574 ram->parts = hweight8(ram->part_mask); in nv50_ram_ctor() 576 nvkm_mm_fini(&ram->vram); in nv50_ram_ctor() 587 struct nv50_ram *ram; in nv50_ram_new() local 590 if (!(ram = kzalloc(sizeof(*ram), GFP_KERNEL))) in nv50_ram_new() 592 *pram = &ram->base; in nv50_ram_new() [all …]
|
H A D | sddr2.c | 61 nvkm_sddr2_calc(struct nvkm_ram *ram) in nvkm_sddr2_calc() argument 67 CL = ram->next->bios.timing_10_CL; in nvkm_sddr2_calc() 82 ODT = (ram->mr[1] & 0x004) >> 2 | in nvkm_sddr2_calc() 83 (ram->mr[1] & 0x040) >> 5; in nvkm_sddr2_calc() 91 ram->mr[0] &= ~0xf70; in nvkm_sddr2_calc() 92 ram->mr[0] |= (WR & 0x07) << 9; in nvkm_sddr2_calc() 93 ram->mr[0] |= (CL & 0x07) << 4; in nvkm_sddr2_calc() 95 ram->mr[1] &= ~0x045; in nvkm_sddr2_calc() 96 ram->mr[1] |= (ODT & 0x1) << 2; in nvkm_sddr2_calc() 97 ram->mr[1] |= (ODT & 0x2) << 5; in nvkm_sddr2_calc() [all …]
|
H A D | ram.c | 125 if (!device->fb || !(ram = device->fb->ram)) in nvkm_ram_get() 127 ram = device->fb->ram; in nvkm_ram_get() 128 mm = &ram->vram; in nvkm_ram_get() 133 vram->ram = ram; in nvkm_ram_get() 162 return ram->func->init(ram); in nvkm_ram_init() 170 if (ram && !WARN_ON(!ram->func)) { in nvkm_ram_del() 172 *pram = ram->func->dtor(ram); in nvkm_ram_del() 204 ram->func = func; in nvkm_ram_ctor() 205 ram->fb = fb; in nvkm_ram_ctor() 206 ram->type = type; in nvkm_ram_ctor() [all …]
|
H A D | ramgf100.c | 109 struct gf100_ram *ram = container_of(fuc, typeof(*ram), fuc); in gf100_ram_train() local 110 struct nvkm_fb *fb = ram->base.fb; in gf100_ram_train() 180 ret = ram_init(fuc, ram->base.fb); in gf100_ram_calc() 215 ret = gt215_pll_calc(subdev, &ram->refpll, ram->mempll.refclk, in gf100_ram_calc() 419 ram_exec(&ram->fuc, false); in gf100_ram_tidy() 441 switch (ram->base.type) { in gf100_ram_init() 492 struct nvkm_ram *ram) in gf100_ram_ctor() argument 530 nvkm_mm_fini(&ram->vram); in gf100_ram_ctor() 572 struct gf100_ram *ram; in gf100_ram_new_() local 575 if (!(ram = kzalloc(sizeof(*ram), GFP_KERNEL))) in gf100_ram_new_() [all …]
|
H A D | ramgt215.c | 194 ret = ram->base.func->calc(&ram->base, (u32) M0205T.freq * 1000); in gt215_link_train() 237 ram->base.func->calc(&ram->base, clk_current); in gt215_link_train() 513 ram->base.next = next; in gt215_ram_calc() 927 return ram; in gt215_ram_dtor() 945 if (!(ram = kzalloc(sizeof(*ram), GFP_KERNEL))) in gt215_ram_new() 947 *pram = &ram->base; in gt215_ram_new() 978 ram->fuc.r_0x100760 = ramfuc_stride(0x100760, 4, ram->base.part_mask); in gt215_ram_new() 979 ram->fuc.r_0x1007a0 = ramfuc_stride(0x1007a0, 4, ram->base.part_mask); in gt215_ram_new() 980 ram->fuc.r_0x1007e0 = ramfuc_stride(0x1007e0, 4, ram->base.part_mask); in gt215_ram_new() 981 ram->fuc.r_0x100da0 = ramfuc_stride(0x100da0, 4, ram->base.part_mask); in gt215_ram_new() [all …]
|
H A D | ramfuc.h | 65 ram->sequence++; in ramfuc_init() 66 ram->fb = fb; in ramfuc_init() 74 if (ram->fb) { in ramfuc_exec() 76 ram->fb = NULL; in ramfuc_exec() 95 reg->sequence = ram->sequence; in ramfuc_wr32() 131 nvkm_memx_nsec(ram->memx, nsec); in ramfuc_nsec() 141 ramfuc_train(struct ramfuc *ram) in ramfuc_train() argument 143 nvkm_memx_train(ram->memx); in ramfuc_train() 153 ramfuc_block(struct ramfuc *ram) in ramfuc_block() argument 155 nvkm_memx_block(ram->memx); in ramfuc_block() [all …]
|
H A D | rammcp77.c | 35 struct mcp77_ram *ram = mcp77_ram(base); in mcp77_ram_init() local 37 u32 dniso = ((ram->base.size - (ram->poller_base + 0x00)) >> 5) - 1; in mcp77_ram_init() 38 u32 hostnb = ((ram->base.size - (ram->poller_base + 0x20)) >> 5) - 1; in mcp77_ram_init() 39 u32 flush = ((ram->base.size - (ram->poller_base + 0x40)) >> 5) - 1; in mcp77_ram_init() 66 struct mcp77_ram *ram; in mcp77_ram_new() local 69 if (!(ram = kzalloc(sizeof(*ram), GFP_KERNEL))) in mcp77_ram_new() 71 *pram = &ram->base; in mcp77_ram_new() 74 size, &ram->base); in mcp77_ram_new() 78 ram->poller_base = size - rsvd_tail; in mcp77_ram_new() 79 ram->base.stolen = base; in mcp77_ram_new() [all …]
|
H A D | ramnv40.c | 36 struct nv40_ram *ram = nv40_ram(base); in nv40_ram_calc() local 53 ram->ctrl = 0x80000000 | (log2P << 16); in nv40_ram_calc() 56 ram->ctrl |= 0x00000100; in nv40_ram_calc() 57 ram->coef = (N1 << 8) | M1; in nv40_ram_calc() 59 ram->ctrl |= 0x40000000; in nv40_ram_calc() 69 struct nv40_ram *ram = nv40_ram(base); in nv40_ram_prog() local 132 nvkm_wr32(device, 0x004048, ram->coef); in nv40_ram_prog() 133 nvkm_wr32(device, 0x004030, ram->coef); in nv40_ram_prog() 194 struct nv40_ram *ram; in nv40_ram_new_() local 195 if (!(ram = kzalloc(sizeof(*ram), GFP_KERNEL))) in nv40_ram_new_() [all …]
|
H A D | ramgp100.c | 31 gp100_ram_init(struct nvkm_ram *ram) in gp100_ram_init() argument 33 struct nvkm_subdev *subdev = &ram->fb->subdev; in gp100_ram_init() 92 struct nvkm_ram *ram; in gp100_ram_new() local 94 if (!(ram = *pram = kzalloc(sizeof(*ram), GFP_KERNEL))) in gp100_ram_new() 97 return gf100_ram_ctor(&gp100_ram, fb, ram); in gp100_ram_new()
|
/openbmc/u-boot/test/lib/ |
H A D | lmb.c | 315 ASSERT_LMB(&lmb, ram, ram_size, 1, ram + ram_size - in test_noreserved() 319 ASSERT_LMB(&lmb, ram, ram_size, 2, ram + ram_size - in test_noreserved() 491 a = lmb_alloc_addr(&lmb, ram, alloc_addr_a - ram); in test_alloc_addr() 493 ASSERT_LMB(&lmb, ram, ram_size, 3, ram, 0x8010000, in test_alloc_addr() 498 ASSERT_LMB(&lmb, ram, ram_size, 2, ram, 0x10010000, in test_alloc_addr() 503 ASSERT_LMB(&lmb, ram, ram_size, 1, ram, 0x18010000, in test_alloc_addr() 508 ASSERT_LMB(&lmb, ram, ram_size, 1, ram, ram_size, in test_alloc_addr() 514 ASSERT_LMB(&lmb, ram, ram_size, 1, ram, ram_size, in test_alloc_addr() 524 ASSERT_LMB(&lmb, ram, ram_size, 2, ram, 0x18010000, in test_alloc_addr() 528 ASSERT_LMB(&lmb, ram, ram_size, 1, ram, 0x18010000, in test_alloc_addr() [all …]
|
/openbmc/linux/drivers/gpu/drm/nouveau/nvkm/subdev/bus/ |
H A D | hwsq.h | 69 ram->sequence++; in hwsq_init() 70 ram->subdev = subdev; in hwsq_init() 75 hwsq_exec(struct hwsq *ram, bool exec) in hwsq_exec() argument 78 if (ram->subdev) { in hwsq_exec() 80 ram->subdev = NULL; in hwsq_exec() 89 if (reg->sequence != ram->sequence) in hwsq_rd32() 99 reg->sequence = ram->sequence; in hwsq_wr32() 119 u32 temp = hwsq_rd32(ram, reg); in hwsq_mask() 138 hwsq_wait_vblank(struct hwsq *ram) in hwsq_wait_vblank() argument 140 nvkm_hwsq_wait_vblank(ram->hwsq); in hwsq_wait_vblank() [all …]
|
/openbmc/qemu/hw/arm/ |
H A D | kzm.c | 87 machine->ram); in kzm_init() 96 } ram[2] = { in kzm_init() local 101 size = MIN(ram_size, ram[i].size); in kzm_init() 105 if (size < ram[i].size) { in kzm_init() 107 machine->ram, in kzm_init() 108 alias_offset, ram[i].size - size); in kzm_init() 110 ram[i].addr + size, &s->ram_alias); in kzm_init() 113 alias_offset += ram[i].size; in kzm_init()
|
H A D | imx25_pdk.c | 87 machine->ram); in imx25_pdk_init() 96 } ram[2] = { in imx25_pdk_init() local 101 size = MIN(ram_size, ram[i].size); in imx25_pdk_init() 105 if (size < ram[i].size) { in imx25_pdk_init() 107 machine->ram, in imx25_pdk_init() 108 alias_offset, ram[i].size - size); in imx25_pdk_init() 110 ram[i].addr + size, &s->ram_alias); in imx25_pdk_init() 113 alias_offset += ram[i].size; in imx25_pdk_init()
|
/openbmc/u-boot/arch/mips/mach-bmips/ |
H A D | dram.c | 15 struct ram_info ram; in dram_init() local 25 err = ram_get_info(dev, &ram); in dram_init() 31 debug("SDRAM base=%zx, size=%x\n", ram.base, ram.size); in dram_init() 33 gd->ram_size = ram.size; in dram_init()
|
/openbmc/u-boot/arch/arm/mach-stm32mp/ |
H A D | dram_init.c | 14 struct ram_info ram; in dram_init() local 23 ret = ram_get_info(dev, &ram); in dram_init() 28 debug("RAM init base=%lx, size=%x\n", ram.base, ram.size); in dram_init() 30 gd->ram_size = ram.size; in dram_init()
|
/openbmc/u-boot/arch/x86/cpu/qemu/ |
H A D | dram.c | 14 u32 ram; in dram_init() local 17 ram = ((u32)inb(CMOS_DATA_PORT)) << 14; in dram_init() 19 ram |= ((u32)inb(CMOS_DATA_PORT)) << 6; in dram_init() 20 ram += 16 * 1024; in dram_init() 22 gd->ram_size = ram * 1024; in dram_init()
|
/openbmc/qemu/tests/tcg/xtensa/ |
H A D | linker.ld.S | 25 ram : ORIGIN = XCHAL_VECBASE_RESET_VADDR, LENGTH = RAM_SIZE 122 } > ram 129 } > ram 138 } > ram 149 } > ram 163 } > ram 166 PROVIDE(_fstack = (ORIGIN(ram) & 0xf0000000) + LENGTH(ram) - 16);
|
/openbmc/linux/tools/testing/selftests/mm/ |
H A D | transhuge-stress.c | 26 size_t ram, len; in main() local 37 ram = sysconf(_SC_PHYS_PAGES); in main() 38 if (ram > SIZE_MAX / psize() / 4) in main() 39 ram = SIZE_MAX / 4; in main() 41 ram *= psize(); in main() 42 len = ram; in main() 64 ram >> (20 + HPAGE_SHIFT - pshift() - 1)); in main() 79 map_len = ram >> (HPAGE_SHIFT - 1); in main()
|
/openbmc/u-boot/arch/sh/cpu/ |
H A D | u-boot.lds | 21 ram : ORIGIN = CONFIG_SYS_SDRAM_BASE, LENGTH = CONFIG_SYS_SDRAM_SIZE 46 } >ram =0xFF 52 } >ram 61 } >ram 69 } >ram 74 } >ram 85 } >ram
|
/openbmc/linux/arch/powerpc/mm/nohash/ |
H A D | e500.c | 138 static unsigned long calc_cam_sz(unsigned long ram, unsigned long virt, in calc_cam_sz() argument 141 unsigned int camsize = __ilog2(ram); in calc_cam_sz() 164 unsigned long ram, int max_cam_idx, in map_mem_in_cams_addr() argument 174 boundary = ram; in map_mem_in_cams_addr() 190 for (ram -= amount_mapped; ram && i < max_cam_idx; i++) { in map_mem_in_cams_addr() 194 cam_sz = calc_cam_sz(ram, virt, phys); in map_mem_in_cams_addr() 198 ram -= cam_sz; in map_mem_in_cams_addr() 229 return map_mem_in_cams_addr(phys, virt, ram, max_cam_idx, dryrun, init); in map_mem_in_cams() 268 unsigned long ram; in adjust_total_lowmem() local 272 ram = min((phys_addr_t)__max_low_memory, (phys_addr_t)total_lowmem); in adjust_total_lowmem() [all …]
|
/openbmc/u-boot/drivers/dfu/ |
H A D | dfu_ram.c | 24 if (offset > dfu->data.ram.size) { in dfu_transfer_medium_ram() 30 memcpy(dfu->data.ram.start + offset, buf, *len); in dfu_transfer_medium_ram() 32 memcpy(buf, dfu->data.ram.start + offset, *len); in dfu_transfer_medium_ram() 45 *size = dfu->data.ram.size; in dfu_get_medium_size_ram() 76 dfu->data.ram.start = (void *)simple_strtoul(argv[1], NULL, 16); in dfu_fill_entity_ram() 77 dfu->data.ram.size = simple_strtoul(argv[2], NULL, 16); in dfu_fill_entity_ram()
|