linux/drivers/gpio/gpio-ftgpio010.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Faraday Technolog FTGPIO010 gpiochip and interrupt routines
 * Copyright (C) 2017 Linus Walleij <[email protected]>
 *
 * Based on arch/arm/mach-gemini/gpio.c:
 * Copyright (C) 2008-2009 Paulius Zaleckas <[email protected]>
 *
 * Based on plat-mxc/gpio.c:
 * MXC GPIO support. (c) 2008 Daniel Mack <[email protected]>
 * Copyright 2008 Juergen Beisert, [email protected]
 */
#include <linux/gpio/driver.h>
#include <linux/io.h>
#include <linux/interrupt.h>
#include <linux/platform_device.h>
#include <linux/bitops.h>
#include <linux/clk.h>

/* GPIO registers definition */
#define GPIO_DATA_OUT
#define GPIO_DATA_IN
#define GPIO_DIR
#define GPIO_BYPASS_IN
#define GPIO_DATA_SET
#define GPIO_DATA_CLR
#define GPIO_PULL_EN
#define GPIO_PULL_TYPE
#define GPIO_INT_EN
#define GPIO_INT_STAT_RAW
#define GPIO_INT_STAT_MASKED
#define GPIO_INT_MASK
#define GPIO_INT_CLR
#define GPIO_INT_TYPE
#define GPIO_INT_BOTH_EDGE
#define GPIO_INT_LEVEL
#define GPIO_DEBOUNCE_EN
#define GPIO_DEBOUNCE_PRESCALE

/**
 * struct ftgpio_gpio - Gemini GPIO state container
 * @dev: containing device for this instance
 * @gc: gpiochip for this instance
 * @base: remapped I/O-memory base
 * @clk: silicon clock
 */
struct ftgpio_gpio {};

static void ftgpio_gpio_ack_irq(struct irq_data *d)
{}

static void ftgpio_gpio_mask_irq(struct irq_data *d)
{}

static void ftgpio_gpio_unmask_irq(struct irq_data *d)
{}

static int ftgpio_gpio_set_irq_type(struct irq_data *d, unsigned int type)
{}

static void ftgpio_gpio_irq_handler(struct irq_desc *desc)
{}

static int ftgpio_gpio_set_config(struct gpio_chip *gc, unsigned int offset,
				  unsigned long config)
{}

static const struct irq_chip ftgpio_irq_chip =;

static int ftgpio_gpio_probe(struct platform_device *pdev)
{}

static void ftgpio_gpio_remove(struct platform_device *pdev)
{}

static const struct of_device_id ftgpio_gpio_of_match[] =;

static struct platform_driver ftgpio_gpio_driver =;
builtin_platform_driver();