mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-11-24 01:43:08 +02:00
remove mx2-target as it's not part of backfire and was accidently merged into openwrt-xburst
This commit is contained in:
parent
4ecc663fa9
commit
aa55195211
@ -1,24 +0,0 @@
|
||||
#
|
||||
# Copyright (C) 2006-2009 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
ARCH:=arm
|
||||
BOARD:=mx2
|
||||
BOARDNAME:=Freescale MX2
|
||||
FEATURES:=jffs2
|
||||
CFLAGS:=-Os -pipe -march=armv5te -mtune=arm926ej-s -funit-at-a-time
|
||||
|
||||
LINUX_VERSION:=2.6.34-rc3
|
||||
|
||||
DEVICE_TYPE=phone
|
||||
|
||||
define Target/Description
|
||||
endef
|
||||
|
||||
include $(INCLUDE_DIR)/target.mk
|
||||
|
||||
$(eval $(call BuildTarget))
|
@ -1,174 +0,0 @@
|
||||
# CONFIG_AEABI is not set
|
||||
CONFIG_ALIGNMENT_TRAP=y
|
||||
# CONFIG_ARCH_MX1 is not set
|
||||
CONFIG_ARCH_MX2=y
|
||||
# CONFIG_ARCH_MX25 is not set
|
||||
# CONFIG_ARCH_MX3 is not set
|
||||
# CONFIG_ARCH_MX5 is not set
|
||||
CONFIG_ARCH_MXC=y
|
||||
# CONFIG_ARCH_MXC91231 is not set
|
||||
CONFIG_ARCH_MXC_AUDMUX_V1=y
|
||||
# CONFIG_ARCH_NUC93X is not set
|
||||
CONFIG_ARCH_REQUIRE_GPIOLIB=y
|
||||
# CONFIG_ARCH_S5P6440 is not set
|
||||
# CONFIG_ARCH_S5P6442 is not set
|
||||
# CONFIG_ARCH_S5PV210 is not set
|
||||
# CONFIG_ARCH_SELECT_MEMORY_MODEL is not set
|
||||
# CONFIG_ARCH_SHMOBILE is not set
|
||||
# CONFIG_ARCH_SPARSEMEM_DEFAULT is not set
|
||||
# CONFIG_ARCH_SUPPORTS_MSI is not set
|
||||
CONFIG_ARCH_SUSPEND_POSSIBLE=y
|
||||
CONFIG_ARM=y
|
||||
CONFIG_ARM_L1_CACHE_SHIFT=5
|
||||
CONFIG_ARM_THUMB=y
|
||||
CONFIG_BITREVERSE=y
|
||||
# CONFIG_BLK_DEV is not set
|
||||
# CONFIG_BLK_DEV_INITRD is not set
|
||||
CONFIG_BRIDGE_IGMP_SNOOPING=y
|
||||
# CONFIG_BSD_PROCESS_ACCT is not set
|
||||
# CONFIG_CEPH_FS is not set
|
||||
CONFIG_CMDLINE="unused -- bootloader passes ATAG list"
|
||||
CONFIG_COMMON_CLKDEV=y
|
||||
CONFIG_COMPAT_BRK=y
|
||||
CONFIG_CPU_32v5=y
|
||||
CONFIG_CPU_ABRT_EV5TJ=y
|
||||
CONFIG_CPU_ARM926T=y
|
||||
# CONFIG_CPU_CACHE_ROUND_ROBIN is not set
|
||||
CONFIG_CPU_CACHE_VIVT=y
|
||||
CONFIG_CPU_COPY_V4WB=y
|
||||
CONFIG_CPU_CP15=y
|
||||
CONFIG_CPU_CP15_MMU=y
|
||||
# CONFIG_CPU_DCACHE_WRITETHROUGH is not set
|
||||
# CONFIG_CPU_ICACHE_DISABLE is not set
|
||||
CONFIG_CPU_PABRT_LEGACY=y
|
||||
CONFIG_CPU_TLB_V4WBI=y
|
||||
CONFIG_DEBUG_BUGVERBOSE=y
|
||||
# CONFIG_DEBUG_USER is not set
|
||||
CONFIG_DECOMPRESS_LZMA=y
|
||||
# CONFIG_DEFAULT_SECURITY_SELINUX is not set
|
||||
# CONFIG_DEFAULT_SECURITY_SMACK is not set
|
||||
# CONFIG_DEFAULT_SECURITY_TOMOYO is not set
|
||||
CONFIG_DEVTMPFS=y
|
||||
CONFIG_DEVTMPFS_MOUNT=y
|
||||
# CONFIG_FPE_FASTFPE is not set
|
||||
# CONFIG_FPE_NWFPE is not set
|
||||
CONFIG_FRAME_POINTER=y
|
||||
# CONFIG_FSNOTIFY is not set
|
||||
CONFIG_GENERIC_ATOMIC64=y
|
||||
CONFIG_GENERIC_CLOCKEVENTS=y
|
||||
CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
|
||||
CONFIG_GENERIC_FIND_LAST_BIT=y
|
||||
CONFIG_GENERIC_GPIO=y
|
||||
CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y
|
||||
CONFIG_GPIOLIB=y
|
||||
# CONFIG_GPIO_IT8761E is not set
|
||||
CONFIG_GPIO_SYSFS=y
|
||||
CONFIG_HARDIRQS_SW_RESEND=y
|
||||
CONFIG_HAS_DMA=y
|
||||
CONFIG_HAS_IOMEM=y
|
||||
CONFIG_HAS_IOPORT=y
|
||||
CONFIG_HAVE_AOUT=y
|
||||
CONFIG_HAVE_ARCH_KGDB=y
|
||||
CONFIG_HAVE_CLK=y
|
||||
CONFIG_HAVE_FUNCTION_TRACER=y
|
||||
CONFIG_HAVE_GENERIC_DMA_COHERENT=y
|
||||
CONFIG_HAVE_IDE=y
|
||||
CONFIG_HAVE_KERNEL_GZIP=y
|
||||
CONFIG_HAVE_KERNEL_LZMA=y
|
||||
CONFIG_HAVE_KERNEL_LZO=y
|
||||
CONFIG_HAVE_KPROBES=y
|
||||
CONFIG_HAVE_KRETPROBES=y
|
||||
CONFIG_HAVE_LATENCYTOP_SUPPORT=y
|
||||
CONFIG_HAVE_OPROFILE=y
|
||||
CONFIG_HAVE_PERF_EVENTS=y
|
||||
CONFIG_HAVE_PROC_CPU=y
|
||||
# CONFIG_HW_RANDOM is not set
|
||||
CONFIG_IMX_HAVE_IOMUX_V1=y
|
||||
# CONFIG_INLINE_READ_LOCK is not set
|
||||
# CONFIG_INLINE_READ_LOCK_BH is not set
|
||||
# CONFIG_INLINE_READ_LOCK_IRQ is not set
|
||||
# CONFIG_INLINE_READ_LOCK_IRQSAVE is not set
|
||||
# CONFIG_INLINE_READ_TRYLOCK is not set
|
||||
CONFIG_INLINE_READ_UNLOCK=y
|
||||
# CONFIG_INLINE_READ_UNLOCK_BH is not set
|
||||
CONFIG_INLINE_READ_UNLOCK_IRQ=y
|
||||
# CONFIG_INLINE_READ_UNLOCK_IRQRESTORE is not set
|
||||
# CONFIG_INLINE_SPIN_LOCK is not set
|
||||
# CONFIG_INLINE_SPIN_LOCK_BH is not set
|
||||
# CONFIG_INLINE_SPIN_LOCK_IRQ is not set
|
||||
# CONFIG_INLINE_SPIN_LOCK_IRQSAVE is not set
|
||||
# CONFIG_INLINE_SPIN_TRYLOCK is not set
|
||||
# CONFIG_INLINE_SPIN_TRYLOCK_BH is not set
|
||||
CONFIG_INLINE_SPIN_UNLOCK=y
|
||||
# CONFIG_INLINE_SPIN_UNLOCK_BH is not set
|
||||
CONFIG_INLINE_SPIN_UNLOCK_IRQ=y
|
||||
# CONFIG_INLINE_SPIN_UNLOCK_IRQRESTORE is not set
|
||||
# CONFIG_INLINE_WRITE_LOCK is not set
|
||||
# CONFIG_INLINE_WRITE_LOCK_BH is not set
|
||||
# CONFIG_INLINE_WRITE_LOCK_IRQ is not set
|
||||
# CONFIG_INLINE_WRITE_LOCK_IRQSAVE is not set
|
||||
# CONFIG_INLINE_WRITE_TRYLOCK is not set
|
||||
CONFIG_INLINE_WRITE_UNLOCK=y
|
||||
# CONFIG_INLINE_WRITE_UNLOCK_BH is not set
|
||||
CONFIG_INLINE_WRITE_UNLOCK_IRQ=y
|
||||
# CONFIG_INLINE_WRITE_UNLOCK_IRQRESTORE is not set
|
||||
CONFIG_INPUT=y
|
||||
CONFIG_INPUT_EVDEV=y
|
||||
CONFIG_INPUT_KEYBOARD=y
|
||||
# CONFIG_INPUT_MISC is not set
|
||||
# CONFIG_ISDN_CAPI is not set
|
||||
# CONFIG_ISDN_DRV_GIGASET is not set
|
||||
# CONFIG_ISDN_I4L is not set
|
||||
CONFIG_KEYBOARD_ATKBD=y
|
||||
CONFIG_KEYBOARD_GPIO=y
|
||||
CONFIG_KEYBOARD_IMX=y
|
||||
# CONFIG_KEYBOARD_LKKBD is not set
|
||||
# CONFIG_KEYBOARD_MATRIX is not set
|
||||
# CONFIG_KEYBOARD_NEWTON is not set
|
||||
# CONFIG_KEYBOARD_STOWAWAY is not set
|
||||
# CONFIG_KEYBOARD_SUNKBD is not set
|
||||
# CONFIG_KEYBOARD_XTKBD is not set
|
||||
CONFIG_LEDS_GPIO=y
|
||||
# CONFIG_LEDS_TRIGGER_NETDEV is not set
|
||||
# CONFIG_LKDTM is not set
|
||||
# CONFIG_LOGFS is not set
|
||||
CONFIG_MACH_MX21=y
|
||||
# CONFIG_MACH_MX21ADS is not set
|
||||
# CONFIG_MACH_MX27 is not set
|
||||
CONFIG_MACH_VP6500=y
|
||||
# CONFIG_MFD_T7L66XB is not set
|
||||
# CONFIG_MTD_CFI_INTELEXT is not set
|
||||
CONFIG_MTD_CMDLINE_PARTS=y
|
||||
CONFIG_MTD_PHYSMAP=y
|
||||
# CONFIG_MUTEX_SPIN_ON_OWNER is not set
|
||||
# CONFIG_MXC_IRQ_PRIOR is not set
|
||||
# CONFIG_MXC_PWM is not set
|
||||
CONFIG_NEED_DMA_MAP_STATE=y
|
||||
# CONFIG_NETDEV_1000 is not set
|
||||
# CONFIG_NET_ETHERNET is not set
|
||||
CONFIG_PAGEFLAGS_EXTENDED=y
|
||||
CONFIG_PAGE_OFFSET=0xC0000000
|
||||
# CONFIG_PCI_SYSCALL is not set
|
||||
CONFIG_PERF_USE_VMALLOC=y
|
||||
CONFIG_RATIONAL=y
|
||||
# CONFIG_SCSI_DMA is not set
|
||||
CONFIG_SCSI_MOD=y
|
||||
# CONFIG_SERIAL_8250 is not set
|
||||
CONFIG_SERIAL_IMX=y
|
||||
CONFIG_SERIAL_IMX_CONSOLE=y
|
||||
# CONFIG_SERIAL_TIMBERDALE is not set
|
||||
CONFIG_SERIO=y
|
||||
# CONFIG_SERIO_ALTERA_PS2 is not set
|
||||
CONFIG_SERIO_LIBPS2=y
|
||||
# CONFIG_SERIO_RAW is not set
|
||||
CONFIG_SERIO_SERPORT=y
|
||||
CONFIG_SPLIT_PTLOCK_CPUS=999999
|
||||
CONFIG_SYS_SUPPORTS_APM_EMULATION=y
|
||||
# CONFIG_TREE_PREEMPT_RCU is not set
|
||||
# CONFIG_UID16 is not set
|
||||
CONFIG_VECTORS_BASE=0xffff0000
|
||||
# CONFIG_VFP is not set
|
||||
# CONFIG_WATCHDOG is not set
|
||||
CONFIG_ZBOOT_ROM_BSS=0x0
|
||||
CONFIG_ZBOOT_ROM_TEXT=0x0
|
||||
CONFIG_ZONE_DMA_FLAG=0
|
@ -1,255 +0,0 @@
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/mtd/mtd.h>
|
||||
#include <linux/mtd/physmap.h>
|
||||
#include <linux/gpio.h>
|
||||
#include <linux/leds.h>
|
||||
|
||||
#include <mach/common.h>
|
||||
#include <mach/hardware.h>
|
||||
#include <asm/mach-types.h>
|
||||
#include <asm/mach/arch.h>
|
||||
#include <asm/mach/time.h>
|
||||
#include <asm/mach/map.h>
|
||||
#include <mach/imx-uart.h>
|
||||
#include <mach/imxfb.h>
|
||||
#include <mach/iomux-mx21.h>
|
||||
#include <mach/board-vp6500.h>
|
||||
|
||||
#include "devices.h"
|
||||
|
||||
#include <linux/input.h>
|
||||
#include <linux/input/matrix_keypad.h>
|
||||
#include <linux/gpio_keys.h>
|
||||
#include <linux/pwm_backlight.h>
|
||||
|
||||
static unsigned int vp6500_pins[] = {
|
||||
/* UART1 */
|
||||
PE12_PF_UART1_TXD,
|
||||
PE13_PF_UART1_RXD,
|
||||
|
||||
#if 0
|
||||
/* LCDC */
|
||||
PA5_PF_LSCLK,
|
||||
PA6_PF_LD0,
|
||||
PA7_PF_LD1,
|
||||
PA8_PF_LD2,
|
||||
PA9_PF_LD3,
|
||||
PA10_PF_LD4,
|
||||
PA11_PF_LD5,
|
||||
PA12_PF_LD6,
|
||||
PA13_PF_LD7,
|
||||
PA14_PF_LD8,
|
||||
PA15_PF_LD9,
|
||||
PA16_PF_LD10,
|
||||
PA17_PF_LD11,
|
||||
PA18_PF_LD12,
|
||||
PA19_PF_LD13,
|
||||
PA20_PF_LD14,
|
||||
PA21_PF_LD15,
|
||||
PA22_PF_LD16,
|
||||
PA28_PF_HSYNC,
|
||||
PA29_PF_VSYNC,
|
||||
PA30_PF_CONTRAST,
|
||||
PA31_PF_OE_ACD,
|
||||
#endif
|
||||
|
||||
/* LCD Backlight */
|
||||
PE5_PF_PWMO,
|
||||
VP6500_GPIO_BACKLIGHT_EN | GPIO_GPIO | GPIO_OUT,
|
||||
};
|
||||
|
||||
/* Flash */
|
||||
|
||||
static struct physmap_flash_data vp6500_flash_data = {
|
||||
.width = 2,
|
||||
};
|
||||
|
||||
static struct resource vp6500_flash_resource = {
|
||||
.start = MX21_CS0_BASE_ADDR,
|
||||
.end = MX21_CS0_BASE_ADDR + SZ_64M - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
};
|
||||
|
||||
static struct platform_device vp6500_nor_mtd_device = {
|
||||
.name = "physmap-flash",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
.platform_data = &vp6500_flash_data,
|
||||
},
|
||||
.num_resources = 1,
|
||||
.resource = &vp6500_flash_resource,
|
||||
};
|
||||
|
||||
/* LEDs */
|
||||
|
||||
static struct gpio_led vp6500_leds[] = {
|
||||
{
|
||||
.name = "vp6500:orange:keypad",
|
||||
.gpio = VP6500_GPIO_LED_KEYPAD,
|
||||
},
|
||||
{
|
||||
.name = "vp6500:green:",
|
||||
.gpio = VP6500_GPIO_LED_GREEN,
|
||||
.active_low = 1,
|
||||
.default_state = LEDS_GPIO_DEFSTATE_ON,
|
||||
},
|
||||
{
|
||||
.name = "vp6500:red:",
|
||||
.gpio = VP6500_GPIO_LED_RED,
|
||||
},
|
||||
{
|
||||
.name = "vp6500:red:camera",
|
||||
.gpio = VP6500_GPIO_LED_CAMERA,
|
||||
},
|
||||
};
|
||||
|
||||
static struct gpio_led_platform_data vp6500_leds_data = {
|
||||
.leds = vp6500_leds,
|
||||
.num_leds = ARRAY_SIZE(vp6500_leds),
|
||||
};
|
||||
|
||||
static struct platform_device vp6500_leds_device = {
|
||||
.name = "leds-gpio",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
.platform_data = &vp6500_leds_data,
|
||||
},
|
||||
};
|
||||
|
||||
/* Keypad */
|
||||
|
||||
static const uint32_t vp6500_keypad_keys[] = {
|
||||
KEY(0, 3, KEY_F2),
|
||||
KEY(0, 4, KEY_RIGHT),
|
||||
KEY(1, 0, KEY_ZOOM),
|
||||
KEY(1, 1, KEY_NUMERIC_POUND),
|
||||
KEY(1, 2, KEY_0),
|
||||
KEY(1, 3, KEY_ENTER),
|
||||
KEY(1, 4, KEY_8),
|
||||
KEY(2, 0, KEY_5),
|
||||
KEY(2, 1, KEY_2),
|
||||
KEY(2, 2, KEY_DOWN),
|
||||
KEY(2, 3, KEY_OK),
|
||||
KEY(2, 4, KEY_UP),
|
||||
KEY(3, 0, KEY_CAMERA),
|
||||
KEY(3, 1, KEY_NUMERIC_STAR),
|
||||
KEY(3, 2, KEY_9),
|
||||
KEY(3, 3, KEY_LEFT),
|
||||
KEY(3, 4, KEY_6),
|
||||
KEY(4, 0, KEY_7),
|
||||
KEY(4, 1, KEY_4),
|
||||
KEY(4, 2, KEY_1),
|
||||
KEY(4, 3, KEY_3),
|
||||
KEY(4, 4, KEY_F1),
|
||||
};
|
||||
|
||||
static struct matrix_keymap_data vp6500_keypad_data = {
|
||||
.keymap = vp6500_keypad_keys,
|
||||
.keymap_size = ARRAY_SIZE(vp6500_keypad_keys),
|
||||
};
|
||||
|
||||
static struct resource vp6500_keypad_resources[] = {
|
||||
{
|
||||
.start = MX21_KPP_BASE_ADDR,
|
||||
.end = MX21_KPP_BASE_ADDR + 0x10 - 1,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
{
|
||||
.start = MX21_INT_KPP,
|
||||
.flags = IORESOURCE_IRQ,
|
||||
}
|
||||
};
|
||||
|
||||
static struct platform_device vp6500_keypad_device = {
|
||||
.name = "imx-keypad",
|
||||
.id = 0,
|
||||
.dev = {
|
||||
.platform_data = &vp6500_keypad_data,
|
||||
},
|
||||
.resource = vp6500_keypad_resources,
|
||||
.num_resources = ARRAY_SIZE(vp6500_keypad_resources),
|
||||
};
|
||||
|
||||
static struct gpio_keys_button vp6500_keys = {
|
||||
.gpio = VP6500_GPIO_POWER_KEY,
|
||||
.code = KEY_POWER,
|
||||
.desc = "Power button",
|
||||
.active_low = 1,
|
||||
};
|
||||
|
||||
static struct gpio_keys_platform_data vp6500_key_data = {
|
||||
.buttons = &vp6500_keys,
|
||||
.nbuttons = 1,
|
||||
};
|
||||
|
||||
static struct platform_device vp6500_key_device = {
|
||||
.name = "gpio-keys",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
.platform_data = &vp6500_key_data,
|
||||
},
|
||||
};
|
||||
|
||||
/* LCD backlight */
|
||||
|
||||
static int vp6500_backlight_notify(struct device *dev, int brightness)
|
||||
{
|
||||
gpio_set_value(VP6500_GPIO_BACKLIGHT_EN, !!brightness);
|
||||
|
||||
return brightness;
|
||||
}
|
||||
|
||||
static struct platform_pwm_backlight_data vp6500_backlight_data = {
|
||||
.max_brightness = 255,
|
||||
.dft_brightness = 100,
|
||||
.pwm_period_ns = 15000000,
|
||||
.notify = vp6500_backlight_notify,
|
||||
};
|
||||
|
||||
static struct platform_device vp6500_backlight_device = {
|
||||
.name = "pwm-backlight",
|
||||
.id = -1,
|
||||
.dev = {
|
||||
.parent = &mxc_pwm_device.dev,
|
||||
.platform_data = &vp6500_backlight_data,
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
static struct platform_device *platform_devices[] __initdata = {
|
||||
&vp6500_nor_mtd_device,
|
||||
&vp6500_leds_device,
|
||||
&vp6500_keypad_device,
|
||||
&vp6500_key_device,
|
||||
&vp6500_backlight_device,
|
||||
};
|
||||
|
||||
static void __init vp6500_board_init(void)
|
||||
{
|
||||
mxc_gpio_setup_multiple_pins(vp6500_pins, ARRAY_SIZE(vp6500_pins),
|
||||
"vp6500");
|
||||
|
||||
mxc_register_device(&mxc_uart_device0, NULL);
|
||||
mxc_register_device(&mxc_pwm_device, NULL);
|
||||
|
||||
platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices));
|
||||
}
|
||||
|
||||
static void __init vp6500_timer_init(void)
|
||||
{
|
||||
mx21_clocks_init(32768, 26000000);
|
||||
}
|
||||
|
||||
static struct sys_timer vp6500_timer = {
|
||||
.init = vp6500_timer_init,
|
||||
};
|
||||
|
||||
MACHINE_START(VP6500, "Phillips VP6500")
|
||||
.phys_io = MX21_AIPI_BASE_ADDR,
|
||||
.io_pg_offst = ((MX21_AIPI_BASE_ADDR_VIRT) >> 18) & 0xfffc,
|
||||
.boot_params = MX21_PHYS_OFFSET + 0x100,
|
||||
.map_io = mx21_map_io,
|
||||
.init_irq = mx21_init_irq,
|
||||
.init_machine = vp6500_board_init,
|
||||
.timer = &vp6500_timer,
|
||||
MACHINE_END
|
@ -1,17 +0,0 @@
|
||||
|
||||
#ifndef __BOARD_VP6500__
|
||||
#define __BOARD_VP6500__
|
||||
|
||||
#define VP6500_GPIO_POWER_KEY GPIO_PORTB | 5
|
||||
#define VP6500_GPIO_CAMERA_DIRECTION GPIO_PORTB | 13
|
||||
#define VP6500_GPIO_LED_KEYPAD GPIO_PORTC | 18
|
||||
#define VP6500_GPIO_AMP_ENABLE GPIO_PORTC | 25
|
||||
#define VP6500_GPIO_LED_RED GPIO_PORTC | 27
|
||||
#define VP6500_GPIO_LED_GREEN GPIO_PORTC | 28
|
||||
#define VP6500_GPIO_LED_CAMERA GPIO_PORTC | 29
|
||||
#define VP6500_GPIO_BACKLIGHT_EN GPIO_PORTE | 10
|
||||
|
||||
#define VP6500_GPIO_TLV_RESET GPIO_PORTB | 27
|
||||
#define VP6500_GPIO_TLV_ENABLE GPIO_PORTC | 25
|
||||
|
||||
#endif
|
@ -1,28 +0,0 @@
|
||||
#
|
||||
# Copyright (C) 2010 OpenWrt.org
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
include $(TOPDIR)/rules.mk
|
||||
include $(INCLUDE_DIR)/image.mk
|
||||
|
||||
JFFS2_BLOCKSIZE=128k 16k
|
||||
#JFFS2OPTS += -n -s 2048
|
||||
JFFS2OPTS += -n
|
||||
|
||||
define Image/BuildKernel
|
||||
mkdir -p $(BIN_DIR)
|
||||
cp $(KDIR)/vmlinuz $(BIN_DIR)/$(IMG_PREFIX)-zImage
|
||||
endef
|
||||
|
||||
define Image/Prepare
|
||||
cp $(LINUX_DIR)/arch/arm/boot/zImage $(KDIR)/vmlinuz
|
||||
endef
|
||||
|
||||
|
||||
define Image/Build/squashfs
|
||||
$(call prepare_generic_squashfs,$(BIN_DIR)/$(IMG_PREFIX)-root.$(1))
|
||||
endef
|
||||
|
||||
$(eval $(call BuildImage))
|
@ -1,22 +0,0 @@
|
||||
--- a/arch/arm/mach-mx2/Kconfig 2010-04-10 13:56:17.000000000 +0200
|
||||
+++ b/arch/arm/mach-mx2/Kconfig 2010-04-10 13:42:38.000000000 +0200
|
||||
@@ -27,6 +27,12 @@
|
||||
Include support for MX21ADS platform. This includes specific
|
||||
configurations for the board and its peripherals.
|
||||
|
||||
+config MACH_VP6500
|
||||
+ bool "Phillips VP6500 VoIP phone"
|
||||
+ depends on MACH_MX21
|
||||
+ help
|
||||
+ Include support for the Phillips VP6500 VoIP phone.
|
||||
+
|
||||
config MACH_MX27ADS
|
||||
bool "MX27ADS platform"
|
||||
depends on MACH_MX27
|
||||
--- a/arch/arm/mach-mx2/Makefile 2010-04-10 13:56:17.000000000 +0200
|
||||
+++ b/arch/arm/mach-mx2/Makefile 2010-04-10 13:49:32.000000000 +0200
|
||||
@@ -21,3 +21,4 @@
|
||||
obj-$(CONFIG_MACH_EUKREA_MBIMX27_BASEBOARD) += eukrea_mbimx27-baseboard.o
|
||||
obj-$(CONFIG_MACH_PCA100) += mach-pca100.o
|
||||
obj-$(CONFIG_MACH_MXT_TD60) += mach-mxt_td60.o
|
||||
+obj-$(CONFIG_MACH_VP6500) += mach-vp6500.o
|
@ -1,11 +0,0 @@
|
||||
--- a/arch/arm/tools/mach-types 2010-04-10 13:56:20.000000000 +0200
|
||||
+++ b/arch/arm/tools/mach-types 2010-04-10 15:24:46.000000000 +0200
|
||||
@@ -530,7 +530,7 @@
|
||||
dp1000 MACH_DP1000 DP1000 514
|
||||
omap_osk MACH_OMAP_OSK OMAP_OSK 515
|
||||
rg100v3 MACH_RG100V3 RG100V3 516
|
||||
-mx2ads MACH_MX2ADS MX2ADS 517
|
||||
+vp6500 MACH_VP6500 VP6500 517
|
||||
pxa_kilo MACH_PXA_KILO PXA_KILO 518
|
||||
ixp4xx_eagle MACH_IXP4XX_EAGLE IXP4XX_EAGLE 519
|
||||
tosa MACH_TOSA TOSA 520
|
@ -1,22 +0,0 @@
|
||||
--- a/arch/arm/mach-mx2/devices.c 2010-04-10 13:56:17.000000000 +0200
|
||||
+++ b/arch/arm/mach-mx2/devices.c 2010-04-10 15:15:17.000000000 +0200
|
||||
@@ -304,7 +304,7 @@
|
||||
#ifdef CONFIG_MACH_MX27
|
||||
static struct resource otg_resources[] = {
|
||||
{
|
||||
- .start = MX27_USBOTG_BASE_ADDR,
|
||||
+ .start = MX27_usbotg_BASE_ADDR,
|
||||
.end = MX27_USBOTG_BASE_ADDR + 0x1ff,
|
||||
.flags = IORESOURCE_MEM,
|
||||
}, {
|
||||
@@ -483,8 +483,8 @@
|
||||
#ifdef CONFIG_MACH_MX21
|
||||
static struct resource mx21_usbhc_resources[] = {
|
||||
{
|
||||
- .start = MX21_BASE_ADDR,
|
||||
- .end = MX21_BASE_ADDR + 0x1FFF,
|
||||
+ .start = MX21_USBOTG_BASE_ADDR,
|
||||
+ .end = MX21_USBOTG_BASE_ADDR + 0x1FFF,
|
||||
.flags = IORESOURCE_MEM,
|
||||
},
|
||||
{
|
@ -1,73 +0,0 @@
|
||||
This patch allows using a kernel image compressed with LZMA on ARM.
|
||||
Extracting the image is fairly slow, but it might be useful on machines
|
||||
with a very limited amount of storage, as the size benefit is quite
|
||||
significant:
|
||||
Gzip: Data Size: 1586352 Bytes = 1549.17 kB = 1.51 MB
|
||||
LZMA: Data Size: 2135916 Bytes = 2085.86 kB = 2.04 MB
|
||||
|
||||
Signed-off-by: Albin Tonnerre <albin.tonnerre <at> free-electrons.com>
|
||||
Tested-by: Martin Michlmayr <tbm <at> cyrius.com>
|
||||
---
|
||||
v2: Updated to apply on top of 2.6.34-rc1
|
||||
|
||||
arch/arm/Kconfig | 1 +
|
||||
arch/arm/boot/compressed/Makefile | 1 +
|
||||
arch/arm/boot/compressed/decompress.c | 4 ++++
|
||||
arch/arm/boot/compressed/piggy.lzma.S | 6 ++++++
|
||||
4 files changed, 12 insertions(+), 0 deletions(-)
|
||||
create mode 100644 arch/arm/boot/compressed/piggy.lzma.S
|
||||
|
||||
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
|
||||
index 3b18128..3ebc7c3 100644
|
||||
--- a/arch/arm/Kconfig
|
||||
+++ b/arch/arm/Kconfig
|
||||
@@ -21,6 +21,7 @@ config ARM
|
||||
select HAVE_GENERIC_DMA_COHERENT
|
||||
select HAVE_KERNEL_GZIP
|
||||
select HAVE_KERNEL_LZO
|
||||
+ select HAVE_KERNEL_LZMA
|
||||
select HAVE_PERF_EVENTS
|
||||
select PERF_USE_VMALLOC
|
||||
help
|
||||
diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile
|
||||
index 97c89e7..53faa90 100644
|
||||
--- a/arch/arm/boot/compressed/Makefile
|
||||
+++ b/arch/arm/boot/compressed/Makefile
|
||||
@@ -65,6 +65,7 @@ SEDFLAGS = s/TEXT_START/$(ZTEXTADDR)/;s/BSS_START/$(ZBSSADDR)/
|
||||
|
||||
suffix_$(CONFIG_KERNEL_GZIP) = gzip
|
||||
suffix_$(CONFIG_KERNEL_LZO) = lzo
|
||||
+suffix_$(CONFIG_KERNEL_LZMA) = lzma
|
||||
|
||||
targets := vmlinux vmlinux.lds \
|
||||
piggy.$(suffix_y) piggy.$(suffix_y).o \
|
||||
diff --git a/arch/arm/boot/compressed/decompress.c b/arch/arm/boot/compressed/decompress.c
|
||||
index 0da382f..d554df6 100644
|
||||
--- a/arch/arm/boot/compressed/decompress.c
|
||||
+++ b/arch/arm/boot/compressed/decompress.c
|
||||
@@ -39,6 +39,10 @@ extern void error(char *);
|
||||
#include "../../../../lib/decompress_unlzo.c"
|
||||
#endif
|
||||
|
||||
+#ifdef CONFIG_KERNEL_LZMA
|
||||
+#include "../../../../lib/decompress_unlzma.c"
|
||||
+#endif
|
||||
+
|
||||
void do_decompress(u8 *input, int len, u8 *output, void (*error)(char *x))
|
||||
{
|
||||
decompress(input, len, NULL, NULL, output, NULL, error);
|
||||
diff --git a/arch/arm/boot/compressed/piggy.lzma.S b/arch/arm/boot/compressed/piggy.lzma.S
|
||||
new file mode 100644
|
||||
index 0000000..d7e69cf
|
||||
--- /dev/null
|
||||
+++ b/arch/arm/boot/compressed/piggy.lzma.S
|
||||
@@ -0,0 +1,6 @@
|
||||
+ .section .piggydata,#alloc
|
||||
+ .globl input_data
|
||||
+input_data:
|
||||
+ .incbin "arch/arm/boot/compressed/piggy.lzma"
|
||||
+ .globl input_data_end
|
||||
+input_data_end:
|
||||
--
|
||||
1.7.0
|
||||
|
@ -1,137 +0,0 @@
|
||||
diff --git a/arch/arm/plat-mxc/pwm.c b/arch/arm/plat-mxc/pwm.c
|
||||
index c36f263..acc5dc1 100644
|
||||
--- a/arch/arm/plat-mxc/pwm.c
|
||||
+++ b/arch/arm/plat-mxc/pwm.c
|
||||
@@ -25,6 +25,11 @@
|
||||
#define MX1_PWMS 0x04 /* PWM Sample Register */
|
||||
#define MX1_PWMP 0x08 /* PWM Period Register */
|
||||
|
||||
+#define MX1_PWMC_EN (1 << 4)
|
||||
+#define MX1_PWMC_PRESCALER_MASK (0x7f << 8)
|
||||
+#define MX1_PWMC_PRESCALER(x) ((x & 0x7f) << 8)
|
||||
+#define MX1_PWMC_CLKSEL_MASK 0x3
|
||||
+#define MX1_PWMC_CLKSEL(x) ((x & 0x3))
|
||||
|
||||
/* i.MX27, i.MX31, i.MX35 share the same PWM function block: */
|
||||
|
||||
@@ -54,25 +59,32 @@ struct pwm_device {
|
||||
|
||||
int pwm_config(struct pwm_device *pwm, int duty_ns, int period_ns)
|
||||
{
|
||||
+ unsigned long long c;
|
||||
+ unsigned long period_cycles, duty_cycles, prescale;
|
||||
+
|
||||
if (pwm == NULL || period_ns == 0 || duty_ns > period_ns)
|
||||
return -EINVAL;
|
||||
|
||||
- if (cpu_is_mx27() || cpu_is_mx3() || cpu_is_mx25()) {
|
||||
- unsigned long long c;
|
||||
- unsigned long period_cycles, duty_cycles, prescale;
|
||||
- u32 cr;
|
||||
+ c = clk_get_rate(pwm->clk);
|
||||
+
|
||||
+ c = c * period_ns;
|
||||
+
|
||||
+ if (cpu_is_mx1() || cpu_is_mx2())
|
||||
+ c >>= 1;
|
||||
|
||||
- c = clk_get_rate(pwm->clk);
|
||||
- c = c * period_ns;
|
||||
- do_div(c, 1000000000);
|
||||
- period_cycles = c;
|
||||
+ do_div(c, 1000000000);
|
||||
+ period_cycles = c;
|
||||
|
||||
- prescale = period_cycles / 0x10000 + 1;
|
||||
+ prescale = period_cycles / 0x10000 + 1;
|
||||
|
||||
- period_cycles /= prescale;
|
||||
- c = (unsigned long long)period_cycles * duty_ns;
|
||||
- do_div(c, period_ns);
|
||||
- duty_cycles = c;
|
||||
+ period_cycles /= prescale;
|
||||
+ c = (unsigned long long)period_cycles * duty_ns;
|
||||
+ do_div(c, period_ns);
|
||||
+ duty_cycles = c;
|
||||
+
|
||||
+
|
||||
+ if (cpu_is_mx27() || cpu_is_mx3() || cpu_is_mx25()) {
|
||||
+ u32 cr;
|
||||
|
||||
writel(duty_cycles, pwm->mmio_base + MX3_PWMSAR);
|
||||
writel(period_cycles, pwm->mmio_base + MX3_PWMPR);
|
||||
@@ -86,25 +98,28 @@ int pwm_config(struct pwm_device *pwm, int duty_ns, int period_ns)
|
||||
|
||||
writel(cr, pwm->mmio_base + MX3_PWMCR);
|
||||
} else if (cpu_is_mx1() || cpu_is_mx21()) {
|
||||
- /* The PWM subsystem allows for exact frequencies. However,
|
||||
- * I cannot connect a scope on my device to the PWM line and
|
||||
- * thus cannot provide the program the PWM controller
|
||||
- * exactly. Instead, I'm relying on the fact that the
|
||||
- * Bootloader (u-boot or WinCE+haret) has programmed the PWM
|
||||
- * function group already. So I'll just modify the PWM sample
|
||||
- * register to follow the ratio of duty_ns vs. period_ns
|
||||
- * accordingly.
|
||||
- *
|
||||
- * This is good enough for programming the brightness of
|
||||
- * the LCD backlight.
|
||||
- *
|
||||
- * The real implementation would divide PERCLK[0] first by
|
||||
- * both the prescaler (/1 .. /128) and then by CLKSEL
|
||||
- * (/2 .. /16).
|
||||
- */
|
||||
- u32 max = readl(pwm->mmio_base + MX1_PWMP);
|
||||
- u32 p = max * duty_ns / period_ns;
|
||||
- writel(max - p, pwm->mmio_base + MX1_PWMS);
|
||||
+ unsigned long clksel = 0;
|
||||
+ u32 ctrl;
|
||||
+
|
||||
+ while (prescale >= 0x80 && clksel < 4) {
|
||||
+ prescale >>= 1;
|
||||
+ ++clksel;
|
||||
+ }
|
||||
+
|
||||
+ if (clksel > 3)
|
||||
+ return -EINVAL;
|
||||
+
|
||||
+ ctrl = readl(pwm->mmio_base + MX1_PWMC);
|
||||
+ writel(ctrl & ~MX1_PWMC_EN, pwm->mmio_base + MX1_PWMC);
|
||||
+
|
||||
+ writel(duty_cycles, pwm->mmio_base + MX1_PWMS);
|
||||
+ writel(period_cycles, pwm->mmio_base + MX1_PWMP);
|
||||
+
|
||||
+ ctrl &= ~(MX1_PWMC_PRESCALER_MASK | MX1_PWMC_CLKSEL_MASK);
|
||||
+ ctrl |= MX1_PWMC_PRESCALER(prescale);
|
||||
+ ctrl |= MX1_PWMC_CLKSEL(clksel);
|
||||
+ writel(ctrl, pwm->mmio_base + MX1_PWMC);
|
||||
+
|
||||
} else {
|
||||
BUG();
|
||||
}
|
||||
@@ -116,6 +130,11 @@ EXPORT_SYMBOL(pwm_config);
|
||||
int pwm_enable(struct pwm_device *pwm)
|
||||
{
|
||||
int rc = 0;
|
||||
+ if (cpu_is_mx1() || cpu_is_mx2()) {
|
||||
+ u32 ctrl;
|
||||
+ ctrl = readl(pwm->mmio_base + MX1_PWMC);
|
||||
+ writel(ctrl | MX1_PWMC_EN, pwm->mmio_base + MX1_PWMC);
|
||||
+ }
|
||||
|
||||
if (!pwm->clk_enabled) {
|
||||
rc = clk_enable(pwm->clk);
|
||||
@@ -128,7 +147,13 @@ EXPORT_SYMBOL(pwm_enable);
|
||||
|
||||
void pwm_disable(struct pwm_device *pwm)
|
||||
{
|
||||
- writel(0, pwm->mmio_base + MX3_PWMCR);
|
||||
+ if (cpu_is_mx27() || cpu_is_mx3() || cpu_is_mx25()) {
|
||||
+ writel(0, pwm->mmio_base + MX3_PWMCR);
|
||||
+ } else if (cpu_is_mx1() || cpu_is_mx2()) {
|
||||
+ u32 ctrl;
|
||||
+ ctrl = readl(pwm->mmio_base + MX1_PWMC);
|
||||
+ writel(ctrl & ~MX1_PWMC_EN, pwm->mmio_base + MX1_PWMC);
|
||||
+ }
|
||||
|
||||
if (pwm->clk_enabled) {
|
||||
clk_disable(pwm->clk);
|
Loading…
Reference in New Issue
Block a user