Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) // SPDX-License-Identifier: GPL-2.0-only
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3)  * linux/drivers/pcmcia/pxa/pxa_cm_x2xx.c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)  * Compulab Ltd., 2003, 2007, 2008
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)  * Mike Rapoport <mike@compulab.co.il>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) #include <linux/module.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) #include <asm/mach-types.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) #include <mach/hardware.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) int cmx255_pcmcia_init(void);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) int cmx270_pcmcia_init(void);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) void cmx255_pcmcia_exit(void);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) void cmx270_pcmcia_exit(void);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) static int __init cmx2xx_pcmcia_init(void)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) 	int ret = -ENODEV;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 	if (machine_is_armcore() && cpu_is_pxa25x())
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 		ret = cmx255_pcmcia_init();
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) 	else if (machine_is_armcore() && cpu_is_pxa27x())
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 		ret = cmx270_pcmcia_init();
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 	return ret;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) static void __exit cmx2xx_pcmcia_exit(void)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) 	if (machine_is_armcore() && cpu_is_pxa25x())
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 		cmx255_pcmcia_exit();
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) 	else if (machine_is_armcore() && cpu_is_pxa27x())
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) 		cmx270_pcmcia_exit();
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) module_init(cmx2xx_pcmcia_init);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) module_exit(cmx2xx_pcmcia_exit);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 42) MODULE_LICENSE("GPL");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 43) MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 44) MODULE_DESCRIPTION("CM-x2xx PCMCIA driver");