Yauhen Kharuzhy | c29cfa6 | 2010-12-17 14:42:09 +0900 | [diff] [blame] | 1 | /* linux/arch/arm/plat-s3c2416/setup-sdhci-gpio.c |
| 2 | * |
| 3 | * Copyright 2010 Promwad Innovation Company |
| 4 | * Yauhen Kharuzhy <yauhen.kharuzhy@promwad.com> |
| 5 | * |
| 6 | * S3C2416 - Helper functions for setting up SDHCI device(s) GPIO (HSMMC) |
| 7 | * |
| 8 | * Based on mach-s3c64xx/setup-sdhci-gpio.c |
| 9 | * |
| 10 | * This program is free software; you can redistribute it and/or modify |
| 11 | * it under the terms of the GNU General Public License version 2 as |
| 12 | * published by the Free Software Foundation. |
| 13 | */ |
| 14 | |
| 15 | #include <linux/kernel.h> |
| 16 | #include <linux/types.h> |
| 17 | #include <linux/interrupt.h> |
| 18 | #include <linux/platform_device.h> |
| 19 | #include <linux/io.h> |
| 20 | #include <linux/gpio.h> |
Yauhen Kharuzhy | c29cfa6 | 2010-12-17 14:42:09 +0900 | [diff] [blame] | 21 | |
| 22 | #include <mach/regs-gpio.h> |
Linus Walleij | b0161ca | 2014-01-14 14:24:24 +0100 | [diff] [blame] | 23 | #include <mach/gpio-samsung.h> |
Yauhen Kharuzhy | c29cfa6 | 2010-12-17 14:42:09 +0900 | [diff] [blame] | 24 | #include <plat/gpio-cfg.h> |
| 25 | |
| 26 | void s3c2416_setup_sdhci0_cfg_gpio(struct platform_device *dev, int width) |
| 27 | { |
| 28 | s3c_gpio_cfgrange_nopull(S3C2410_GPE(5), 2 + width, S3C_GPIO_SFN(2)); |
| 29 | } |
| 30 | |
| 31 | void s3c2416_setup_sdhci1_cfg_gpio(struct platform_device *dev, int width) |
| 32 | { |
| 33 | s3c_gpio_cfgrange_nopull(S3C2410_GPL(0), width, S3C_GPIO_SFN(2)); |
| 34 | s3c_gpio_cfgrange_nopull(S3C2410_GPL(8), 2, S3C_GPIO_SFN(2)); |
| 35 | } |