Commit 22be71ea authored by Kukjin Kim's avatar Kukjin Kim
Browse files

Merge branch 'next/topic-gpio-samsung' into next-samsung-devel

parents 59ca37f7 b391f8cf
Loading
Loading
Loading
Loading
+0 −3
Original line number Diff line number Diff line
@@ -724,9 +724,6 @@ config ARCH_S3C64XX
	select SAMSUNG_IRQ_VIC_TIMER
	select SAMSUNG_IRQ_UART
	select S3C_GPIO_TRACK
	select S3C_GPIO_PULL_UPDOWN
	select S3C_GPIO_CFG_S3C24XX
	select S3C_GPIO_CFG_S3C64XX
	select S3C_DEV_NAND
	select USB_ARCH_HAS_OHCI
	select SAMSUNG_GPIOLIB_4BIT
+1 −1
Original line number Diff line number Diff line
@@ -53,7 +53,7 @@ static inline void s3c_pm_restored_gpios(void)
	/* nothing here yet */
}

static inline void s3c_pm_saved_gpios(void)
static inline void samsung_pm_saved_gpios(void)
{
	/* nothing here yet */
}
+0 −7
Original line number Diff line number Diff line
@@ -6,9 +6,7 @@ config CPU_S3C2410
	bool
	depends on ARCH_S3C2410
	select CPU_ARM920T
	select S3C_GPIO_PULL_UP
	select S3C2410_CLOCK
	select S3C2410_GPIO
	select CPU_LLSERIAL_S3C2410
	select S3C2410_PM if PM
	select S3C2410_CPUFREQ if CPU_FREQ_S3C24XX
@@ -28,11 +26,6 @@ config S3C2410_PM
	help
	  Power Management code common to S3C2410 and better

config S3C2410_GPIO
	bool
	help
	  GPIO code for S3C2410 and similar processors

config SIMTEC_NOR
	bool
	help
+0 −1
Original line number Diff line number Diff line
@@ -13,7 +13,6 @@ obj-$(CONFIG_CPU_S3C2410) += s3c2410.o
obj-$(CONFIG_CPU_S3C2410_DMA)	+= dma.o
obj-$(CONFIG_CPU_S3C2410_DMA)	+= dma.o
obj-$(CONFIG_S3C2410_PM)	+= pm.o sleep.o
obj-$(CONFIG_S3C2410_GPIO)	+= gpio.o
obj-$(CONFIG_S3C2410_CPUFREQ)	+= cpu-freq.o
obj-$(CONFIG_S3C2410_PLLTABLE)	+= pll.o

+1 −98
Original line number Diff line number Diff line
/* arch/arm/mach-s3c2410/include/mach/gpio-fns.h
 *
 * Copyright (c) 2003-2009 Simtec Electronics
 *	Ben Dooks <ben@simtec.co.uk>
 *
 * S3C2410 - hardware
 *
 * 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 __MACH_GPIO_FNS_H
#define __MACH_GPIO_FNS_H __FILE__

/* These functions are in the to-be-removed category and it is strongly
 * encouraged not to use these in new code. They will be marked deprecated
 * very soon.
 *
 * Most of the functionality can be either replaced by the gpiocfg calls
 * for the s3c platform or by the generic GPIOlib API.
 *
 * As of 2.6.35-rc, these will be removed, with the few drivers using them
 * either replaced or given a wrapper until the calls can be removed.
*/

#include <plat/gpio-cfg.h>

static inline void s3c2410_gpio_cfgpin(unsigned int pin, unsigned int cfg)
{
	/* 1:1 mapping between cfgpin and setcfg calls at the moment */
	s3c_gpio_cfgpin(pin, cfg);
}

/* external functions for GPIO support
 *
 * These allow various different clients to access the same GPIO
 * registers without conflicting. If your driver only owns the entire
 * GPIO register, then it is safe to ioremap/__raw_{read|write} to it.
*/

extern unsigned int s3c2410_gpio_getcfg(unsigned int pin);

/* s3c2410_gpio_getirq
 *
 * turn the given pin number into the corresponding IRQ number
 *
 * returns:
 *	< 0 = no interrupt for this pin
 *	>=0 = interrupt number for the pin
*/

extern int s3c2410_gpio_getirq(unsigned int pin);

/* s3c2410_gpio_irqfilter
 *
 * set the irq filtering on the given pin
 *
 * on = 0 => disable filtering
 *      1 => enable filtering
 *
 * config = S3C2410_EINTFLT_PCLK or S3C2410_EINTFLT_EXTCLK orred with
 *          width of filter (0 through 63)
 *
 *
*/

extern int s3c2410_gpio_irqfilter(unsigned int pin, unsigned int on,
				  unsigned int config);

/* s3c2410_gpio_pullup
 *
 * This call should be replaced with s3c_gpio_setpull().
 *
 * As a note, there is currently no distinction between pull-up and pull-down
 * in the s3c24xx series devices with only an on/off configuration.
 */

/* s3c2410_gpio_pullup
 *
 * configure the pull-up control on the given pin
 *
 * to = 1 => disable the pull-up
 *      0 => enable the pull-up
 *
 * eg;
 *
 *   s3c2410_gpio_pullup(S3C2410_GPB(0), 0);
 *   s3c2410_gpio_pullup(S3C2410_GPE(8), 0);
*/

extern void s3c2410_gpio_pullup(unsigned int pin, unsigned int to);

extern void s3c2410_gpio_setpin(unsigned int pin, unsigned int to);

extern unsigned int s3c2410_gpio_getpin(unsigned int pin);

#endif /* __MACH_GPIO_FNS_H */
#include <plat/gpio-fns.h>
Loading