blob: f7d751f40244776106a4e7dd7e06004ea560e19a [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Stefano Babicfc05b902012-08-19 21:33:50 +00002/*
3 * Copyright (C) 2011
4 * Stefano Babic, DENX Software Engineering, <sbabic@denx.de>
Stefano Babicfc05b902012-08-19 21:33:50 +00005 */
6
Stefano Babicfc05b902012-08-19 21:33:50 +00007#ifndef __ASM_ARCH_IMX_GPIO_H
8#define __ASM_ARCH_IMX_GPIO_H
9
10#if !(defined(__KERNEL_STRICT_NAMES) || defined(__ASSEMBLY__))
Tom Rinidec7ea02024-05-20 13:35:03 -060011#include <linux/types.h>
12
Stefano Babicfc05b902012-08-19 21:33:50 +000013/* GPIO registers */
14struct gpio_regs {
15 u32 gpio_dr; /* data */
16 u32 gpio_dir; /* direction */
17 u32 gpio_psr; /* pad satus */
18};
19#endif
20
21#define IMX_GPIO_NR(port, index) ((((port)-1)*32)+((index)&31))
22
23#endif