ARM: riscpc: simplify vram_size calculation
Subsystems (3)
PATCH 1/1 ARM: riscpc: simplify vram_size calculation
The code to calculate vram_size in parse_tag_acorn() is unnecessarily complex and inflexible. Replace it with a simple multiplication.
Signed-off-by Ethan Nelson-Moore <[email protected]>
--- arch/arm/mach-rpc/riscpc.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-)
arch/arm/mach-rpc/riscpc.c +1 -10
@@ -43,17 +43,8 @@ static int __init parse_tag_acorn(const struct tag *tag) { memc_ctrl_reg = tag->u.acorn.memc_control_reg; number_mfm_drives = tag->u.acorn.adfsdrives; + vram_size = tag->u.acorn.vram_pages *PAGE_SIZE ; -switch (tag->u.acorn.vram_pages) { -case 512 : - vram_size +=PAGE_SIZE *256 ; - fallthrough;/* ??? */ -case 256 : - vram_size +=PAGE_SIZE *256 ; -break ; -default : -break ; - }#if 0 if (vram_size) { desc->video_start =0x02000000 ;
Signature · 1 line
2.43.0