Path: blob/master/arch/arm/mach-mxs/include/mach/gpio.h
10820 views
/*1* Copyright 2007 Freescale Semiconductor, Inc. All Rights Reserved.2* Copyright 2008 Juergen Beisert, [email protected]3*4* This program is free software; you can redistribute it and/or5* modify it under the terms of the GNU General Public License6* as published by the Free Software Foundation; either version 27* of the License, or (at your option) any later version.8* This program is distributed in the hope that it will be useful,9* but WITHOUT ANY WARRANTY; without even the implied warranty of10* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the11* GNU General Public License for more details.12*13* You should have received a copy of the GNU General Public License14* along with this program; if not, write to the Free Software15* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,16* MA 02110-1301, USA.17*/1819#ifndef __MACH_MXS_GPIO_H__20#define __MACH_MXS_GPIO_H__2122#include <asm-generic/gpio.h>2324#define MXS_GPIO_NR(bank, nr) ((bank) * 32 + (nr))2526/* use gpiolib dispatchers */27#define gpio_get_value __gpio_get_value28#define gpio_set_value __gpio_set_value29#define gpio_cansleep __gpio_cansleep30#define gpio_to_irq __gpio_to_irq3132#define irq_to_gpio(irq) ((irq) - MXS_GPIO_IRQ_START)3334#endif /* __MACH_MXS_GPIO_H__ */353637