2012-12-22 08:09:52 +09:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2010-2012, NVIDIA CORPORATION. All rights reserved.
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify it
|
|
|
|
* under the terms and conditions of the GNU General Public License,
|
|
|
|
* version 2, as published by the Free Software Foundation.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope it will be useful, but WITHOUT
|
|
|
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
|
|
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
|
|
|
* more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __CONFIG_H
|
|
|
|
#define __CONFIG_H
|
|
|
|
|
2014-02-26 22:47:58 +09:00
|
|
|
#include <linux/sizes.h>
|
2012-12-22 08:09:52 +09:00
|
|
|
|
|
|
|
#include "tegra30-common.h"
|
|
|
|
|
ARM: tegra: use a CPU freq that all SKUs can support
U-Boot on Tegra30 currently selects a main CPU frequency that cannot be
supported at all on some SKUs, and needs higher VDD_CPU/VDD_CORE values
on some others. This can result in unreliable operation of the main CPUs.
Resolve this by switching to a CPU frequency that can be supported by any
SKU. According to the following link, the maximum supported CPU frequency
of the slowest Tegra30 SKU is 600MHz:
repo http://nv-tegra.nvidia.com/gitweb/?p=linux-2.6.git;a=summary
branch l4t/l4t-r16-r2
path arch/arm/mach-tegra/tegra3_dvfs.c
table cpu_dvfs_table[]
According to that same table, the minimum VDD_CPU required to operate at
that frequency across all SKUs is 1.007V. Given the adjustment resolution
of the TPS65911 PMIC that's used on all Tegra30-based boards we support,
we'll end up using 1.0125V instead.
At that VDD_CPU, tegra3_get_core_floor_mv() in that same file dictates
that VDD_CORE must be at least 1.2V on all SKUs. According to
tegra_core_speedo_mv() (in tegra3_speedo.c in the same source tree),
that voltage is safe for all SKUs.
An alternative would be to port much of the code from tegra3_dvfs.c and
tegra3_speedo.c in the kernel tree mentioned above. That's more work
than I want to take on right now.
While all the currently supported boards use the same regulator chip for
VDD_CPU, different types of regulators are used for VDD_CORE. Hence, we
add some small conditional code to select how VDD_CORE is programmed. If
this becomes more complex in the future as new boards are added, or we
end up adding code to detect the SoC SKU and dynamically determine the
allowed frequency and required voltages, we should probably make this a
runtime call into a function provided by the board file and/or relevant
PMIC driver.
Cc: Alban Bedel <alban.bedel@avionic-design.de>
Cc: Marcel Ziswiler <marcel@ziswiler.com>
Cc: Bard Liao <bardliao@realtek.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Tom Warren <twarren@nvidia.com>
2014-05-09 00:33:45 +09:00
|
|
|
/* VDD core PMIC */
|
|
|
|
#define CONFIG_TEGRA_VDD_CORE_TPS62361B_SET3
|
|
|
|
|
2012-12-22 08:09:52 +09:00
|
|
|
/* High-level configuration options */
|
|
|
|
#define CONFIG_TEGRA_BOARD_STRING "NVIDIA Cardhu"
|
|
|
|
|
2014-01-24 05:17:01 +09:00
|
|
|
#define BOARD_EXTRA_ENV_SETTINGS \
|
|
|
|
"board_name=cardhu-a04\0" \
|
|
|
|
"fdtfile=tegra30-cardhu-a04.dtb\0"
|
|
|
|
|
2012-12-22 08:09:52 +09:00
|
|
|
/* Board-specific serial config */
|
|
|
|
#define CONFIG_TEGRA_ENABLE_UARTA
|
|
|
|
#define CONFIG_SYS_NS16550_COM1 NV_PA_APB_UARTA_BASE
|
|
|
|
|
|
|
|
#define CONFIG_MACH_TYPE MACH_TYPE_CARDHU
|
|
|
|
|
|
|
|
/* I2C */
|
2012-10-30 16:28:53 +09:00
|
|
|
#define CONFIG_SYS_I2C_TEGRA
|
2012-12-22 08:09:52 +09:00
|
|
|
#define CONFIG_CMD_I2C
|
|
|
|
|
2013-02-27 04:36:22 +09:00
|
|
|
/* SD/MMC */
|
|
|
|
#define CONFIG_MMC
|
|
|
|
#define CONFIG_GENERIC_MMC
|
|
|
|
#define CONFIG_TEGRA_MMC
|
|
|
|
#define CONFIG_CMD_MMC
|
|
|
|
|
|
|
|
/* Environment in eMMC, at the end of 2nd "boot sector" */
|
|
|
|
#define CONFIG_ENV_IS_IN_MMC
|
2013-06-12 06:14:03 +09:00
|
|
|
#define CONFIG_ENV_OFFSET (-CONFIG_ENV_SIZE)
|
2013-02-27 04:36:22 +09:00
|
|
|
#define CONFIG_SYS_MMC_ENV_DEV 0
|
|
|
|
#define CONFIG_SYS_MMC_ENV_PART 2
|
2012-12-22 08:09:52 +09:00
|
|
|
|
2013-01-29 22:51:29 +09:00
|
|
|
/* SPI */
|
|
|
|
#define CONFIG_TEGRA_SLINK_CTRLS 6
|
|
|
|
#define CONFIG_SF_DEFAULT_MODE SPI_MODE_0
|
|
|
|
#define CONFIG_SF_DEFAULT_SPEED 24000000
|
|
|
|
#define CONFIG_CMD_SPI
|
|
|
|
#define CONFIG_CMD_SF
|
|
|
|
#define CONFIG_SPI_FLASH_SIZE (4 << 20)
|
|
|
|
|
2013-06-21 20:05:48 +09:00
|
|
|
/* USB Host support */
|
|
|
|
#define CONFIG_USB_EHCI
|
|
|
|
#define CONFIG_USB_EHCI_TEGRA
|
|
|
|
#define CONFIG_USB_STORAGE
|
|
|
|
#define CONFIG_CMD_USB
|
|
|
|
|
|
|
|
/* USB networking support */
|
|
|
|
#define CONFIG_USB_HOST_ETHER
|
|
|
|
#define CONFIG_USB_ETHER_ASIX
|
|
|
|
|
2014-12-10 14:25:17 +09:00
|
|
|
/* PCI host support */
|
|
|
|
#define CONFIG_PCI
|
|
|
|
#define CONFIG_PCI_TEGRA
|
|
|
|
#define CONFIG_PCI_PNP
|
|
|
|
#define CONFIG_CMD_PCI
|
|
|
|
#define CONFIG_CMD_PCI_ENUM
|
|
|
|
|
|
|
|
/* PCI networking support */
|
|
|
|
#define CONFIG_RTL8169
|
|
|
|
|
2013-06-21 20:05:48 +09:00
|
|
|
/* General networking support */
|
|
|
|
#define CONFIG_CMD_DHCP
|
|
|
|
|
2012-12-22 08:09:52 +09:00
|
|
|
#include "tegra-common-post.h"
|
|
|
|
|
|
|
|
#endif /* __CONFIG_H */
|