Path: blob/master/arch/mips/powertv/asic/prealloc-cronus.c
10818 views
/*1* Memory pre-allocations for Cronus boxes.2*3* Copyright (C) 2005-2009 Scientific-Atlanta, Inc.4*5* This program is free software; you can redistribute it and/or modify6* it under the terms of the GNU General Public License as published by7* the Free Software Foundation; either version 2 of the License, or8* (at your option) any later version.9*10* This program is distributed in the hope that it will be useful,11* but WITHOUT ANY WARRANTY; without even the implied warranty of12* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the13* GNU General Public License for more details.14*15* You should have received a copy of the GNU General Public License16* along with this program; if not, write to the Free Software17* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA18*19* Author: Ken Eppinett20* David Schleef <[email protected]>21*/2223#include <linux/init.h>24#include <linux/ioport.h>25#include <asm/mach-powertv/asic.h>26#include "prealloc.h"2728/*29* DVR_CAPABLE CRONUS RESOURCES30*/31struct resource dvr_cronus_resources[] __initdata =32{33/*34* VIDEO1 / LX135*/36/* Delta-Mu 1 image (2MiB) */37PREALLOC_NORMAL("ST231aImage", 0x24000000, 0x24200000-1,38IORESOURCE_MEM)39/* Delta-Mu 1 monitor (8KiB) */40PREALLOC_NORMAL("ST231aMonitor", 0x24200000, 0x24202000-1,41IORESOURCE_MEM)42/* Delta-Mu 1 RAM (~29.9MiB (32MiB - (2MiB + 8KiB))) */43PREALLOC_NORMAL("MediaMemory1", 0x24202000, 0x26000000-1,44IORESOURCE_MEM)4546/*47* VIDEO2 / LX248*/49/* Delta-Mu 2 image (2MiB) */50PREALLOC_NORMAL("ST231bImage", 0x60000000, 0x60200000-1,51IORESOURCE_MEM)52/* Delta-Mu 2 monitor (8KiB) */53PREALLOC_NORMAL("ST231bMonitor", 0x60200000, 0x60202000-1,54IORESOURCE_MEM)55/* Delta-Mu 2 RAM (~29.9MiB (32MiB - (2MiB + 8KiB))) */56PREALLOC_NORMAL("MediaMemory2", 0x60202000, 0x62000000-1,57IORESOURCE_MEM)5859/*60* Sysaudio Driver61*/62/* DSP code and data images (1MiB) */63PREALLOC_NORMAL("DSP_Image_Buff", 0x00000000, 0x00100000-1,64(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))65/* ADSC CPU PCM buffer (40KiB) */66PREALLOC_NORMAL("ADSC_CPU_PCM_Buff", 0x00000000, 0x0000A000-1,67(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))68/* ADSC AUX buffer (128KiB) */69PREALLOC_NORMAL("ADSC_AUX_Buff", 0x00000000, 0x00020000-1,70(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))71/* ADSC Main buffer (128KiB) */72PREALLOC_NORMAL("ADSC_Main_Buff", 0x00000000, 0x00020000-1,73(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))7475/*76* STAVEM driver/STAPI77*78* This memory area is used for allocating buffers for Video decoding79* purposes. Allocation/De-allocation within this buffer is managed80* by the STAVMEM driver of the STAPI. They could be Decimated81* Picture Buffers, Intermediate Buffers, as deemed necessary for82* video decoding purposes, for any video decoders on Zeus.83*/84/* 12MiB */85PREALLOC_NORMAL("AVMEMPartition0", 0x00000000, 0x00c00000-1,86IORESOURCE_MEM)8788/*89* DOCSIS Subsystem90*/91/* 7MiB */92PREALLOC_DOCSIS("Docsis", 0x67500000, 0x67c00000-1, IORESOURCE_MEM)9394/*95* GHW HAL Driver96*/97/* PowerTV Graphics Heap (14MiB) */98PREALLOC_NORMAL("GraphicsHeap", 0x62700000, 0x63500000-1,99IORESOURCE_MEM)100101/*102* multi com buffer area103*/104/* 128KiB */105PREALLOC_NORMAL("MulticomSHM", 0x26000000, 0x26020000-1,106IORESOURCE_MEM)107108/*109* DMA Ring buffer110*/111PREALLOC_NORMAL("BMM_Buffer", 0x00000000, 0x002EA000-1,112(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))113114/*115* Display bins buffer for unit0116*/117/* 4KiB */118PREALLOC_NORMAL("DisplayBins0", 0x00000000, 0x00001000-1,119(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))120121/*122* Display bins buffer for unit1123*/124/* 4KiB */125PREALLOC_NORMAL("DisplayBins1", 0x00000000, 0x00001000-1,126IORESOURCE_MEM)127128/*129* ITFS130*/131/* 815,104 bytes each for 2 ITFS partitions. */132PREALLOC_NORMAL("ITFS", 0x00000000, 0x0018E000-1, IORESOURCE_MEM)133134/*135* AVFS136*/137/* (945K * 8) = (128K * 3) 5 playbacks / 3 server */138PREALLOC_NORMAL("AvfsDmaMem", 0x00000000, 0x007c2000-1,139IORESOURCE_MEM)140141/* 4KiB */142PREALLOC_NORMAL("AvfsFileSys", 0x00000000, 0x00001000-1,143IORESOURCE_MEM)144145/*146* PMEM147*/148/* Persistent memory for diagnostics (64KiB) */149PREALLOC_PMEM("DiagPersistentMemory", 0x00000000, 0x10000-1,150(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))151152/*153* Smartcard154*/155/* Read and write buffers for Internal/External cards (10KiB) */156PREALLOC_NORMAL("SmartCardInfo", 0x00000000, 0x2800-1,157IORESOURCE_MEM)158159/*160* KAVNET161*/162/* NP Reset Vector - must be of the form xxCxxxxx (4KiB) */163PREALLOC_NORMAL("NP_Reset_Vector", 0x27c00000, 0x27c01000-1,164IORESOURCE_MEM)165/* NP Image - must be video bank 1 (320KiB) */166PREALLOC_NORMAL("NP_Image", 0x27020000, 0x27070000-1, IORESOURCE_MEM)167/* NP IPC - must be video bank 2 (512KiB) */168PREALLOC_NORMAL("NP_IPC", 0x63500000, 0x63580000-1, IORESOURCE_MEM)169170/*171* TFTPBuffer172*173* This buffer is used in some minimal configurations (e.g. two-way174* loader) for storing software images175*/176PREALLOC_TFTP("TFTPBuffer", 0x00000000, MEBIBYTE(80)-1,177(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))178179/*180* Add other resources here181*/182183/*184* End of Resource marker185*/186{187.flags = 0,188},189};190191/*192* NON_DVR_CAPABLE CRONUS RESOURCES193*/194struct resource non_dvr_cronus_resources[] __initdata =195{196/*197* VIDEO1 / LX1198*/199/* Delta-Mu 1 image (2MiB) */200PREALLOC_NORMAL("ST231aImage", 0x24000000, 0x24200000-1,201IORESOURCE_MEM)202/* Delta-Mu 1 monitor (8KiB) */203PREALLOC_NORMAL("ST231aMonitor", 0x24200000, 0x24202000-1,204IORESOURCE_MEM)205/* Delta-Mu 1 RAM (~29.9MiB (32MiB - (2MiB + 8KiB))) */206PREALLOC_NORMAL("MediaMemory1", 0x24202000, 0x26000000-1,207IORESOURCE_MEM)208209/*210* VIDEO2 / LX2211*/212/* Delta-Mu 2 image (2MiB) */213PREALLOC_NORMAL("ST231bImage", 0x60000000, 0x60200000-1,214IORESOURCE_MEM)215/* Delta-Mu 2 monitor (8KiB) */216PREALLOC_NORMAL("ST231bMonitor", 0x60200000, 0x60202000-1,217IORESOURCE_MEM)218/* Delta-Mu 2 RAM (~29.9MiB (32MiB - (2MiB + 8KiB))) */219PREALLOC_NORMAL("MediaMemory2", 0x60202000, 0x62000000-1,220IORESOURCE_MEM)221222/*223* Sysaudio Driver224*/225/* DSP code and data images (1MiB) */226PREALLOC_NORMAL("DSP_Image_Buff", 0x00000000, 0x00100000-1,227(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))228/* ADSC CPU PCM buffer (40KiB) */229PREALLOC_NORMAL("ADSC_CPU_PCM_Buff", 0x00000000, 0x0000A000-1,230(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))231/* ADSC AUX buffer (128KiB) */232PREALLOC_NORMAL("ADSC_AUX_Buff", 0x00000000, 0x00020000-1,233(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))234/* ADSC Main buffer (128KiB) */235PREALLOC_NORMAL("ADSC_Main_Buff", 0x00000000, 0x00020000-1,236(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))237238/*239* STAVEM driver/STAPI240*241* This memory area is used for allocating buffers for Video decoding242* purposes. Allocation/De-allocation within this buffer is managed243* by the STAVMEM driver of the STAPI. They could be Decimated244* Picture Buffers, Intermediate Buffers, as deemed necessary for245* video decoding purposes, for any video decoders on Zeus.246*/247/* 12MiB */248PREALLOC_NORMAL("AVMEMPartition0", 0x00000000, 0x00c00000-1,249IORESOURCE_MEM)250251/*252* DOCSIS Subsystem253*/254/* 7MiB */255PREALLOC_DOCSIS("Docsis", 0x67500000, 0x67c00000-1, IORESOURCE_MEM)256257/*258* GHW HAL Driver259*/260/* PowerTV Graphics Heap (14MiB) */261PREALLOC_NORMAL("GraphicsHeap", 0x62700000, 0x63500000-1,262IORESOURCE_MEM)263264/*265* multi com buffer area266*/267/* 128KiB */268PREALLOC_NORMAL("MulticomSHM", 0x26000000, 0x26020000-1,269IORESOURCE_MEM)270271/*272* DMA Ring buffer (don't need recording buffers)273*/274/* 680KiB */275PREALLOC_NORMAL("BMM_Buffer", 0x00000000, 0x000AA000-1,276(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))277278/*279* Display bins buffer for unit0280*/281/* 4KiB */282PREALLOC_NORMAL("DisplayBins0", 0x00000000, 0x00001000-1,283(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))284285/*286* Display bins buffer for unit1287*/288/* 4KiB */289PREALLOC_NORMAL("DisplayBins1", 0x00000000, 0x00001000-1,290IORESOURCE_MEM)291292/*293* AVFS: player HAL memory294*/295/* 945K * 3 for playback */296PREALLOC_NORMAL("AvfsDmaMem", 0x00000000, 0x002c4c00-1, IORESOURCE_MEM)297298/*299* PMEM300*/301/* Persistent memory for diagnostics (64KiB) */302PREALLOC_PMEM("DiagPersistentMemory", 0x00000000, 0x10000-1,303(IORESOURCE_MEM|IORESOURCE_PTV_RES_LOEXT))304305/*306* Smartcard307*/308/* Read and write buffers for Internal/External cards (10KiB) */309PREALLOC_NORMAL("SmartCardInfo", 0x00000000, 0x2800-1, IORESOURCE_MEM)310311/*312* KAVNET313*/314/* NP Reset Vector - must be of the form xxCxxxxx (4KiB) */315PREALLOC_NORMAL("NP_Reset_Vector", 0x27c00000, 0x27c01000-1,316IORESOURCE_MEM)317/* NP Image - must be video bank 1 (320KiB) */318PREALLOC_NORMAL("NP_Image", 0x27020000, 0x27070000-1, IORESOURCE_MEM)319/* NP IPC - must be video bank 2 (512KiB) */320PREALLOC_NORMAL("NP_IPC", 0x63500000, 0x63580000-1, IORESOURCE_MEM)321322/*323* NAND Flash324*/325/* 10KiB */326PREALLOC_NORMAL("NandFlash", NAND_FLASH_BASE, NAND_FLASH_BASE+0x400-1,327IORESOURCE_MEM)328329/*330* Add other resources here331*/332333/*334* End of Resource marker335*/336{337.flags = 0,338},339};340341342