1360275b3SKumar Gala /* 2360275b3SKumar Gala * Copyright 2008-2011 Freescale Semiconductor, Inc. 3360275b3SKumar Gala * 4360275b3SKumar Gala * (C) Copyright 2000 5360275b3SKumar Gala * Wolfgang Denk, DENX Software Engineering, wd@denx.de. 6360275b3SKumar Gala * 7360275b3SKumar Gala * See file CREDITS for list of people who contributed to this 8360275b3SKumar Gala * project. 9360275b3SKumar Gala * 10360275b3SKumar Gala * This program is free software; you can redistribute it and/or 11360275b3SKumar Gala * modify it under the terms of the GNU General Public License as 12360275b3SKumar Gala * published by the Free Software Foundation; either version 2 of 13360275b3SKumar Gala * the License, or (at your option) any later version. 14360275b3SKumar Gala * 15360275b3SKumar Gala * This program is distributed in the hope that it will be useful, 16360275b3SKumar Gala * but WITHOUT ANY WARRANTY; without even the implied warranty of 17360275b3SKumar Gala * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18360275b3SKumar Gala * GNU General Public License for more details. 19360275b3SKumar Gala * 20360275b3SKumar Gala * You should have received a copy of the GNU General Public License 21360275b3SKumar Gala * along with this program; if not, write to the Free Software 22360275b3SKumar Gala * Foundation, Inc., 59 Temple Place, Suite 330, Boston, 23360275b3SKumar Gala * MA 02111-1307 USA 24360275b3SKumar Gala */ 25360275b3SKumar Gala 26360275b3SKumar Gala #include <common.h> 27360275b3SKumar Gala #include <asm/fsl_law.h> 28360275b3SKumar Gala #include <asm/mmu.h> 29360275b3SKumar Gala 30360275b3SKumar Gala struct law_entry law_table[] = { 31360275b3SKumar Gala SET_LAW(CONFIG_SYS_FLASH_BASE_PHYS, LAW_SIZE_256M, LAW_TRGT_IF_LBC), 32360275b3SKumar Gala #ifdef CONFIG_SYS_BMAN_MEM_PHYS 33360275b3SKumar Gala SET_LAW(CONFIG_SYS_BMAN_MEM_PHYS, LAW_SIZE_2M, LAW_TRGT_IF_BMAN), 34360275b3SKumar Gala #endif 35360275b3SKumar Gala #ifdef CONFIG_SYS_QMAN_MEM_PHYS 36360275b3SKumar Gala SET_LAW(CONFIG_SYS_QMAN_MEM_PHYS, LAW_SIZE_2M, LAW_TRGT_IF_QMAN), 37360275b3SKumar Gala #endif 38*f8bc7bb5SKumar Gala #ifdef PIXIS_BASE_PHYS 39360275b3SKumar Gala SET_LAW(PIXIS_BASE_PHYS, LAW_SIZE_4K, LAW_TRGT_IF_LBC), 40*f8bc7bb5SKumar Gala #endif 41*f8bc7bb5SKumar Gala #ifdef CPLD_BASE_PHYS 42*f8bc7bb5SKumar Gala SET_LAW(CPLD_BASE_PHYS, LAW_SIZE_4K, LAW_TRGT_IF_LBC), 43*f8bc7bb5SKumar Gala #endif 44360275b3SKumar Gala #ifdef CONFIG_SYS_DCSRBAR_PHYS 45360275b3SKumar Gala /* Limit DCSR to 32M to access NPC Trace Buffer */ 46360275b3SKumar Gala SET_LAW(CONFIG_SYS_DCSRBAR_PHYS, LAW_SIZE_32M, LAW_TRGT_IF_DCSR), 47360275b3SKumar Gala #endif 48360275b3SKumar Gala #ifdef CONFIG_SYS_NAND_BASE_PHYS 49360275b3SKumar Gala SET_LAW(CONFIG_SYS_NAND_BASE_PHYS, LAW_SIZE_1M, LAW_TRGT_IF_LBC), 50360275b3SKumar Gala #endif 51360275b3SKumar Gala }; 52360275b3SKumar Gala 53360275b3SKumar Gala int num_law_entries = ARRAY_SIZE(law_table); 54