xref: /OK3568_Linux_fs/kernel/include/linux/soc/cirrus/ep93xx.h (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593Smuzhiyun /* SPDX-License-Identifier: GPL-2.0 */
2*4882a593Smuzhiyun #ifndef _SOC_EP93XX_H
3*4882a593Smuzhiyun #define _SOC_EP93XX_H
4*4882a593Smuzhiyun 
5*4882a593Smuzhiyun struct platform_device;
6*4882a593Smuzhiyun 
7*4882a593Smuzhiyun #define EP93XX_CHIP_REV_D0	3
8*4882a593Smuzhiyun #define EP93XX_CHIP_REV_D1	4
9*4882a593Smuzhiyun #define EP93XX_CHIP_REV_E0	5
10*4882a593Smuzhiyun #define EP93XX_CHIP_REV_E1	6
11*4882a593Smuzhiyun #define EP93XX_CHIP_REV_E2	7
12*4882a593Smuzhiyun 
13*4882a593Smuzhiyun #ifdef CONFIG_ARCH_EP93XX
14*4882a593Smuzhiyun int ep93xx_pwm_acquire_gpio(struct platform_device *pdev);
15*4882a593Smuzhiyun void ep93xx_pwm_release_gpio(struct platform_device *pdev);
16*4882a593Smuzhiyun int ep93xx_ide_acquire_gpio(struct platform_device *pdev);
17*4882a593Smuzhiyun void ep93xx_ide_release_gpio(struct platform_device *pdev);
18*4882a593Smuzhiyun int ep93xx_keypad_acquire_gpio(struct platform_device *pdev);
19*4882a593Smuzhiyun void ep93xx_keypad_release_gpio(struct platform_device *pdev);
20*4882a593Smuzhiyun int ep93xx_i2s_acquire(void);
21*4882a593Smuzhiyun void ep93xx_i2s_release(void);
22*4882a593Smuzhiyun unsigned int ep93xx_chip_revision(void);
23*4882a593Smuzhiyun 
24*4882a593Smuzhiyun #else
ep93xx_pwm_acquire_gpio(struct platform_device * pdev)25*4882a593Smuzhiyun static inline int ep93xx_pwm_acquire_gpio(struct platform_device *pdev) { return 0; }
ep93xx_pwm_release_gpio(struct platform_device * pdev)26*4882a593Smuzhiyun static inline void ep93xx_pwm_release_gpio(struct platform_device *pdev) {}
ep93xx_ide_acquire_gpio(struct platform_device * pdev)27*4882a593Smuzhiyun static inline int ep93xx_ide_acquire_gpio(struct platform_device *pdev) { return 0; }
ep93xx_ide_release_gpio(struct platform_device * pdev)28*4882a593Smuzhiyun static inline void ep93xx_ide_release_gpio(struct platform_device *pdev) {}
ep93xx_keypad_acquire_gpio(struct platform_device * pdev)29*4882a593Smuzhiyun static inline int ep93xx_keypad_acquire_gpio(struct platform_device *pdev) { return 0; }
ep93xx_keypad_release_gpio(struct platform_device * pdev)30*4882a593Smuzhiyun static inline void ep93xx_keypad_release_gpio(struct platform_device *pdev) {}
ep93xx_i2s_acquire(void)31*4882a593Smuzhiyun static inline int ep93xx_i2s_acquire(void) { return 0; }
ep93xx_i2s_release(void)32*4882a593Smuzhiyun static inline void ep93xx_i2s_release(void) {}
ep93xx_chip_revision(void)33*4882a593Smuzhiyun static inline unsigned int ep93xx_chip_revision(void) { return 0; }
34*4882a593Smuzhiyun 
35*4882a593Smuzhiyun #endif
36*4882a593Smuzhiyun 
37*4882a593Smuzhiyun #endif
38