Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit eda9dcfa authored by Rohit Vaswani's avatar Rohit Vaswani Committed by David Brown
Browse files

ARM: msm: Remove gpiomux-v2 and re-organize MSM_GPIOMUX configs



Remove gpiomux-v2 as it's not being used and make way for future improvements.

Signed-off-by: default avatarRohit Vaswani <rvaswani@codeaurora.org>
Signed-off-by: default avatarDavid Brown <davidb@codeaurora.org>
parent 1a56e4b2
Loading
Loading
Loading
Loading
+5 −8
Original line number Original line Diff line number Diff line
@@ -48,9 +48,7 @@ config ARCH_MSM8X60
	select CPU_V7
	select CPU_V7
	select GPIO_MSM_V2
	select GPIO_MSM_V2
	select HAVE_SMP
	select HAVE_SMP
	select MSM_GPIOMUX
	select MSM_SCM if SMP
	select MSM_SCM if SMP
	select MSM_V2_TLMM
	select USE_OF
	select USE_OF


config ARCH_MSM8960
config ARCH_MSM8960
@@ -58,9 +56,8 @@ config ARCH_MSM8960
	select ARM_GIC
	select ARM_GIC
	select CPU_V7
	select CPU_V7
	select HAVE_SMP
	select HAVE_SMP
	select MSM_GPIOMUX
	select GPIO_MSM_V2
	select MSM_SCM if SMP
	select MSM_SCM if SMP
	select MSM_V2_TLMM
	select USE_OF
	select USE_OF


config MSM_HAS_DEBUG_UART_HS
config MSM_HAS_DEBUG_UART_HS
@@ -124,10 +121,10 @@ config MSM_SMD
	bool
	bool


config MSM_GPIOMUX
config MSM_GPIOMUX
	bool
	depends on !(ARCH_MSM8X60 || ARCH_MSM8960)

	bool "MSM V1 TLMM GPIOMUX architecture"
config MSM_V2_TLMM
	help
	bool
	  Support for MSM V1 TLMM GPIOMUX architecture.


config MSM_SCM
config MSM_SCM
	bool
	bool
+2 −4
Original line number Original line Diff line number Diff line
@@ -27,7 +27,5 @@ obj-$(CONFIG_ARCH_MSM7X30) += board-msm7x30.o devices-msm7x30.o
obj-$(CONFIG_ARCH_QSD8X50) += board-qsd8x50.o devices-qsd8x50.o
obj-$(CONFIG_ARCH_QSD8X50) += board-qsd8x50.o devices-qsd8x50.o
obj-$(CONFIG_ARCH_MSM8X60) += board-dt-8660.o
obj-$(CONFIG_ARCH_MSM8X60) += board-dt-8660.o
obj-$(CONFIG_ARCH_MSM8960) += board-dt-8960.o
obj-$(CONFIG_ARCH_MSM8960) += board-dt-8960.o

obj-$(CONFIG_MSM_GPIOMUX) += gpiomux.o
obj-$(CONFIG_ARCH_MSM7X30) += gpiomux-v1.o gpiomux.o
obj-$(CONFIG_ARCH_QSD8X50) += gpiomux-8x50.o
obj-$(CONFIG_ARCH_QSD8X50) += gpiomux-8x50.o gpiomux-v1.o gpiomux.o
obj-$(CONFIG_ARCH_MSM8X60) += gpiomux-8x60.o gpiomux-v2.o gpiomux.o

arch/arm/mach-msm/gpiomux-8x60.c

deleted100644 → 0
+0 −19
Original line number Original line Diff line number Diff line
/* Copyright (c) 2010, Code Aurora Forum. 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 and
 * only 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., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301, USA.
 */
#include "gpiomux.h"

struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {};

arch/arm/mach-msm/gpiomux-v2.c

deleted100644 → 0
+0 −25
Original line number Original line Diff line number Diff line
/* Copyright (c) 2010, Code Aurora Forum. 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 and
 * only 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., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301, USA.
 */
#include <linux/io.h>
#include <mach/msm_iomap.h>
#include "gpiomux.h"

void __msm_gpiomux_write(unsigned gpio, gpiomux_config_t val)
{
	writel(val & ~GPIOMUX_CTL_MASK,
	       MSM_TLMM_BASE + 0x1000 + (0x10 * gpio));
}

arch/arm/mach-msm/gpiomux-v2.h

deleted100644 → 0
+0 −61
Original line number Original line Diff line number Diff line
/* Copyright (c) 2010, Code Aurora Forum. 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 and
 * only 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., 51 Franklin Street, Fifth Floor, Boston, MA
 * 02110-1301, USA.
 */
#ifndef __ARCH_ARM_MACH_MSM_GPIOMUX_V2_H
#define __ARCH_ARM_MACH_MSM_GPIOMUX_V2_H

#define GPIOMUX_NGPIOS 173

typedef u16 gpiomux_config_t;

enum {
	GPIOMUX_DRV_2MA  = 0UL << 6,
	GPIOMUX_DRV_4MA  = 1UL << 6,
	GPIOMUX_DRV_6MA  = 2UL << 6,
	GPIOMUX_DRV_8MA  = 3UL << 6,
	GPIOMUX_DRV_10MA = 4UL << 6,
	GPIOMUX_DRV_12MA = 5UL << 6,
	GPIOMUX_DRV_14MA = 6UL << 6,
	GPIOMUX_DRV_16MA = 7UL << 6,
};

enum {
	GPIOMUX_FUNC_GPIO = 0UL  << 2,
	GPIOMUX_FUNC_1    = 1UL  << 2,
	GPIOMUX_FUNC_2    = 2UL  << 2,
	GPIOMUX_FUNC_3    = 3UL  << 2,
	GPIOMUX_FUNC_4    = 4UL  << 2,
	GPIOMUX_FUNC_5    = 5UL  << 2,
	GPIOMUX_FUNC_6    = 6UL  << 2,
	GPIOMUX_FUNC_7    = 7UL  << 2,
	GPIOMUX_FUNC_8    = 8UL  << 2,
	GPIOMUX_FUNC_9    = 9UL  << 2,
	GPIOMUX_FUNC_A    = 10UL << 2,
	GPIOMUX_FUNC_B    = 11UL << 2,
	GPIOMUX_FUNC_C    = 12UL << 2,
	GPIOMUX_FUNC_D    = 13UL << 2,
	GPIOMUX_FUNC_E    = 14UL << 2,
	GPIOMUX_FUNC_F    = 15UL << 2,
};

enum {
	GPIOMUX_PULL_NONE   = 0UL,
	GPIOMUX_PULL_DOWN   = 1UL,
	GPIOMUX_PULL_KEEPER = 2UL,
	GPIOMUX_PULL_UP     = 3UL,
};

#endif
Loading