2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-29 07:34:06 +08:00
linux-next/include/linux/mfd/rdc321x.h
Axel Lin 1ec93b9b17 mfd: rdc321x: Fix off-by-one for ngpio setting
The valid gpio is GPIO0 ~ GPIO58, so ngpio should be 59.
This patch also renames RDC321X_MAX_GPIO to RDC321X_NUM_GPIO because it
actually means the number of available GPIOs.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
2014-06-03 08:11:17 +01:00

27 lines
552 B
C

#ifndef __RDC321X_MFD_H
#define __RDC321X_MFD_H
#include <linux/types.h>
#include <linux/pci.h>
/* Offsets to be accessed in the southbridge PCI
* device configuration register */
#define RDC321X_WDT_CTRL 0x44
#define RDC321X_GPIO_CTRL_REG1 0x48
#define RDC321X_GPIO_DATA_REG1 0x4c
#define RDC321X_GPIO_CTRL_REG2 0x84
#define RDC321X_GPIO_DATA_REG2 0x88
#define RDC321X_NUM_GPIO 59
struct rdc321x_gpio_pdata {
struct pci_dev *sb_pdev;
unsigned max_gpios;
};
struct rdc321x_wdt_pdata {
struct pci_dev *sb_pdev;
};
#endif /* __RDC321X_MFD_H */