From 4a027397901662198760fef04ab9b2ee78b5153d Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Tue, 10 Mar 2009 10:23:50 +0000 Subject: mtd: Make the third arg of mtd_concat_create() const The "name" argument of mtd_concat_create() is used to set the concat->mtd.name pointer which is already "const char *". Setting the argument type to "const char *" avoids the warning from drivers passing a "const char *" pointer (like the one returned by dev_name). Signed-off-by: Catalin Marinas Cc: David Woodhouse --- include/linux/mtd/concat.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/linux/mtd/concat.h b/include/linux/mtd/concat.h index c02f3d264ecf..e80c674daeb3 100644 --- a/include/linux/mtd/concat.h +++ b/include/linux/mtd/concat.h @@ -13,7 +13,7 @@ struct mtd_info *mtd_concat_create( struct mtd_info *subdev[], /* subdevices to concatenate */ int num_devs, /* number of subdevices */ - char *name); /* name for the new device */ + const char *name); /* name for the new device */ void mtd_concat_destroy(struct mtd_info *mtd); -- cgit v1.2.3 From 347cdc26720fffb7444f68acbb311df155f80d62 Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Tue, 10 Mar 2009 10:24:10 +0000 Subject: Allow arbitrary allocator zone ordering Some platforms may have DMA-capable memory at higher addresses than normal memory. Until the maskable allocator is merged into the kernel, this patch allows architectures to define arbitrary ordering of the allocator zones. Signed-off-by: Catalin Marinas --- include/linux/mmzone.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'include') diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 35a7b5e19465..13ce4536c161 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -212,22 +212,34 @@ enum zone_type { * i386, x86_64 and multiple other arches * <16M. */ +#ifdef CONFIG_ZONE_DMA_IDX + ZONE_DMA = CONFIG_ZONE_DMA_IDX, +#else ZONE_DMA, #endif +#endif #ifdef CONFIG_ZONE_DMA32 /* * x86_64 needs two ZONE_DMAs because it supports devices that are * only able to do DMA to the lower 16M but also 32 bit devices that * can only do DMA areas below 4G. */ +#ifdef CONFIG_ZONE_DMA32_IDX + ZONE_DMA32 = CONFIG_ZONE_DMA32_IDX, +#else ZONE_DMA32, +#endif #endif /* * Normal addressable memory is in ZONE_NORMAL. DMA operations can be * performed on pages in ZONE_NORMAL if the DMA devices support * transfers to all addressable memory. */ +#ifdef CONFIG_ZONE_NORMAL_IDX + ZONE_NORMAL = CONFIG_ZONE_NORMAL_IDX, +#else ZONE_NORMAL, +#endif #ifdef CONFIG_HIGHMEM /* * A memory area that is only addressable by the kernel through @@ -237,9 +249,17 @@ enum zone_type { * table entries on i386) for each page that the kernel needs to * access. */ +#ifdef CONFIG_ZONE_HIGHMEM_IDX + ZONE_HIGHMEM = CONFIG_ZONE_HIGHMEM_IDX, +#else ZONE_HIGHMEM, #endif +#endif +#ifdef CONFIG_ZONE_MOVABLE_IDX + ZONE_MOVABLE = CONFIG_ZONE_MOVABLE_IDX, +#else ZONE_MOVABLE, +#endif __MAX_NR_ZONES }; -- cgit v1.2.3 From fd745777eec63e2c098b9f4cb60f5c94e0b9b298 Mon Sep 17 00:00:00 2001 From: Robert Walker Date: Tue, 10 Mar 2009 10:24:57 +0000 Subject: Add RealView-ICE DCC ethernet and console driver This patch adds support for console and Ethernet over DCC using RealView-ICE to Linux 2.6.28-arm1. Signed-off-by: Robert Walker Signed-off-by: Catalin Marinas --- include/asm-arm/hardware/rvidcc.h | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 include/asm-arm/hardware/rvidcc.h (limited to 'include') diff --git a/include/asm-arm/hardware/rvidcc.h b/include/asm-arm/hardware/rvidcc.h new file mode 100644 index 000000000000..2aec6bdea1f3 --- /dev/null +++ b/include/asm-arm/hardware/rvidcc.h @@ -0,0 +1,35 @@ +/* + Copyright (C) 2004-2007 ARM Limited. + + This program is free software; you can redistribute it and/or + modify it under the terms of the GNU General Public License version 2 + as published by the Free Software Foundation. + + This program is distributed in the hope that 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, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + As a special exception, if other files instantiate templates or use macros + or inline functions from this file, or you compile this file and link it + with other works to produce a work based on this file, this file does not + by itself cause the resulting work to be covered by the GNU General Public + License. However the source code for this file must still be made available + in accordance with section (3) of the GNU General Public License. + + This exception does not invalidate any other reasons why a work based on + this file might be covered by the GNU General Public License. +*/ + +#ifndef __RVIDCC_H +#define __RVIDCC_H + +/* Ioctl defines */ +#define DCC_SETPOLLPERIOD _IOW('T', 1, int) +#define DCC_GETPOLLPERIOD _IOR('T', 2, int) + +#endif -- cgit v1.2.3 From 8814658377809ac739ed9f6769ad7d33f361b711 Mon Sep 17 00:00:00 2001 From: Steve Glendinning Date: Mon, 30 Mar 2009 10:58:42 +0100 Subject: SMSC LAN911x and LAN921x vendor driver Attached is a driver for SMSC's LAN911x and LAN921x families of embedded ethernet controllers. There is an existing smc911x driver in the tree; this is intended to replace it. Dustin McIntire (the author of the smc911x driver) has expressed his support for switching to this driver. This driver contains workarounds for all known hardware issues, and has been tested on all flavours of the chip on multiple architectures. This driver now uses phylib, so this patch also adds support for the device's internal phy Signed-off-by: Steve Glendinning Signed-off-by: Bahadir Balban Signed-off-by: Dustin Mcintire Signed-off-by: Bill Gatliff Signed-off-by: Jeff Garzik --- include/linux/smsc911x.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 include/linux/smsc911x.h (limited to 'include') diff --git a/include/linux/smsc911x.h b/include/linux/smsc911x.h new file mode 100644 index 000000000000..47c4ffd10dbb --- /dev/null +++ b/include/linux/smsc911x.h @@ -0,0 +1,42 @@ +/*************************************************************************** + * + * Copyright (C) 2004-2008 SMSC + * Copyright (C) 2005-2008 ARM + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that 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, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + ***************************************************************************/ +#ifndef __LINUX_SMSC911X_H__ +#define __LINUX_SMSC911X_H__ + +#include + +/* platform_device configuration data, should be assigned to + * the platform_device's dev.platform_data */ +struct smsc911x_platform_config { + unsigned int irq_polarity; + unsigned int irq_type; + phy_interface_t phy_interface; +}; + +/* Constants for platform_device irq polarity configuration */ +#define SMSC911X_IRQ_POLARITY_ACTIVE_LOW 0 +#define SMSC911X_IRQ_POLARITY_ACTIVE_HIGH 1 + +/* Constants for platform_device irq type configuration */ +#define SMSC911X_IRQ_TYPE_OPEN_DRAIN 0 +#define SMSC911X_IRQ_TYPE_PUSH_PULL 1 + +#endif /* __LINUX_SMSC911X_H__ */ -- cgit v1.2.3 From 8fa7f65c026f675f6eba92fd9e87e3cd4b81b651 Mon Sep 17 00:00:00 2001 From: Steve Glendinning Date: Mon, 30 Mar 2009 10:59:55 +0100 Subject: smsc911x: add dynamic bus configuration Convert the driver to select 16-bit or 32-bit bus access at runtime, at a small performance cost. Signed-off-by: Steve Glendinning Acked-by: Catalin Marinas Signed-off-by: David S. Miller --- include/linux/smsc911x.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include') diff --git a/include/linux/smsc911x.h b/include/linux/smsc911x.h index 47c4ffd10dbb..1cbf0313adde 100644 --- a/include/linux/smsc911x.h +++ b/include/linux/smsc911x.h @@ -28,6 +28,7 @@ struct smsc911x_platform_config { unsigned int irq_polarity; unsigned int irq_type; + unsigned int flags; phy_interface_t phy_interface; }; @@ -39,4 +40,8 @@ struct smsc911x_platform_config { #define SMSC911X_IRQ_TYPE_OPEN_DRAIN 0 #define SMSC911X_IRQ_TYPE_PUSH_PULL 1 +/* Constants for flags */ +#define SMSC911X_USE_16BIT (BIT(0)) +#define SMSC911X_USE_32BIT (BIT(1)) + #endif /* __LINUX_SMSC911X_H__ */ -- cgit v1.2.3 From 471ee426ccc66ab6c8208dd9dd4bc2a5a9ad8be2 Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Tue, 8 Sep 2009 17:58:53 +0100 Subject: RealView: Re-implement the sparsemem support for PBX The sparsemem support for the PBX board now uses 3 blocks and only the first one is used for DMA (no memory zones reordering needed). The commit also adds automatic meminfo setting so that no mem= option needs to be given on the kernel command line. Signed-off-by: Catalin Marinas --- include/linux/mmzone.h | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'include') diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 13ce4536c161..35a7b5e19465 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h @@ -212,34 +212,22 @@ enum zone_type { * i386, x86_64 and multiple other arches * <16M. */ -#ifdef CONFIG_ZONE_DMA_IDX - ZONE_DMA = CONFIG_ZONE_DMA_IDX, -#else ZONE_DMA, #endif -#endif #ifdef CONFIG_ZONE_DMA32 /* * x86_64 needs two ZONE_DMAs because it supports devices that are * only able to do DMA to the lower 16M but also 32 bit devices that * can only do DMA areas below 4G. */ -#ifdef CONFIG_ZONE_DMA32_IDX - ZONE_DMA32 = CONFIG_ZONE_DMA32_IDX, -#else ZONE_DMA32, -#endif #endif /* * Normal addressable memory is in ZONE_NORMAL. DMA operations can be * performed on pages in ZONE_NORMAL if the DMA devices support * transfers to all addressable memory. */ -#ifdef CONFIG_ZONE_NORMAL_IDX - ZONE_NORMAL = CONFIG_ZONE_NORMAL_IDX, -#else ZONE_NORMAL, -#endif #ifdef CONFIG_HIGHMEM /* * A memory area that is only addressable by the kernel through @@ -249,17 +237,9 @@ enum zone_type { * table entries on i386) for each page that the kernel needs to * access. */ -#ifdef CONFIG_ZONE_HIGHMEM_IDX - ZONE_HIGHMEM = CONFIG_ZONE_HIGHMEM_IDX, -#else ZONE_HIGHMEM, #endif -#endif -#ifdef CONFIG_ZONE_MOVABLE_IDX - ZONE_MOVABLE = CONFIG_ZONE_MOVABLE_IDX, -#else ZONE_MOVABLE, -#endif __MAX_NR_ZONES }; -- cgit v1.2.3 From 78b124262dda66b1122f70224d5906fd4f14bdbf Mon Sep 17 00:00:00 2001 From: Catalin Marinas Date: Mon, 20 Jul 2009 16:25:37 +0100 Subject: Cortex-M3: Add NVIC support This patch implements the NVIC (interrupt controller) support for Cortex-M3. Signed-off-by: Catalin Marinas --- include/asm-arm/hardware/nvic.h | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 include/asm-arm/hardware/nvic.h (limited to 'include') diff --git a/include/asm-arm/hardware/nvic.h b/include/asm-arm/hardware/nvic.h new file mode 100644 index 000000000000..b7f80266bafd --- /dev/null +++ b/include/asm-arm/hardware/nvic.h @@ -0,0 +1,34 @@ +/* + * linux/include/asm-arm/hardware/nvic.h + * + * Copyright (C) 2008 ARM Limited, All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ +#ifndef __ASM_ARM_HARDWARE_NVIC_H +#define __ASM_ARM_HARDWARE_NVIC_H + +#include + +#define V7M_SCS 0xe000e000 +#define NVIC_INTR_CTRL (V7M_SCS + 0x004) +#define NVIC_SYSTICK_CTRL (V7M_SCS + 0x010) +#define NVIC_SYSTICK_RELOAD (V7M_SCS + 0x014) +#define NVIC_SYSTICK_CURRENT (V7M_SCS + 0x018) +#define NVIC_SYSTICK_CALIBRATION (V7M_SCS + 0x01c) +#define NVIC_SET_ENABLE (V7M_SCS + 0x100) +#define NVIC_CLEAR_ENABLE (V7M_SCS + 0x180) +#define NVIC_SET_PENDING (V7M_SCS + 0x200) +#define NVIC_CLEAR_PENDING (V7M_SCS + 0x280) +#define NVIC_ACTIVE_BIT (V7M_SCS + 0x300) +#define NVIC_PRIORITY (V7M_SCS + 0x400) +#define NVIC_INTR_CTRL_STATE (V7M_SCS + 0xd04) +#define NVIC_SOFTWARE_INTR (V7M_SCS + 0xf00) + +#ifndef __ASSEMBLY__ +void nvic_init(void); +#endif + +#endif -- cgit v1.2.3