1 // SPDX-License-Identifier: GPL-2.0-only 2 /* 3 * Intel Merrifield FLIS platform device initialization file 4 * 5 * Copyright (C) 2016, Intel Corporation 6 * 7 * Author: Andy Shevchenko <andriy.shevchenko@linux.intel.com> 8 */ 9 10 #include <linux/init.h> 11 #include <linux/ioport.h> 12 #include <linux/platform_device.h> 13 14 #include <asm/intel-mid.h> 15 16 #define FLIS_BASE_ADDR 0xff0c0000 17 #define FLIS_LENGTH 0x8000 18 19 static struct resource mrfld_pinctrl_mmio_resource = { 20 .start = FLIS_BASE_ADDR, 21 .end = FLIS_BASE_ADDR + FLIS_LENGTH - 1, 22 .flags = IORESOURCE_MEM, 23 }; 24 25 static struct platform_device mrfld_pinctrl_device = { 26 .name = "pinctrl-merrifield", 27 .id = PLATFORM_DEVID_NONE, 28 .resource = &mrfld_pinctrl_mmio_resource, 29 .num_resources = 1, 30 }; 31 mrfld_pinctrl_init(void)32static int __init mrfld_pinctrl_init(void) 33 { 34 if (intel_mid_identify_cpu() == INTEL_MID_CPU_CHIP_TANGIER) 35 return platform_device_register(&mrfld_pinctrl_device); 36 37 return -ENODEV; 38 } 39 arch_initcall(mrfld_pinctrl_init); 40