// SPDX-License-Identifier: GPL-2.0-only1/*2* Intel CE4100 platform specific setup code3*4* (C) Copyright 2010 Intel Corporation5*/6#include <linux/init.h>7#include <linux/reboot.h>89#include <asm/ce4100.h>10#include <asm/prom.h>11#include <asm/setup.h>12#include <asm/io.h>1314/*15* The CE4100 platform has an internal 8051 Microcontroller which is16* responsible for signaling to the external Power Management Unit the17* intention to reset, reboot or power off the system. This 8051 device has18* its command register mapped at I/O port 0xcf9 and the value 0x4 is used19* to power off the system.20*/21static void ce4100_power_off(void)22{23outb(0x4, 0xcf9);24}2526static void __init sdv_arch_setup(void)27{28sdv_serial_fixup();29}3031static void sdv_pci_init(void)32{33x86_of_pci_init();34}3536/*37* CE4100 specific x86_init function overrides and early setup38* calls.39*/40void __init x86_ce4100_early_setup(void)41{42x86_init.oem.arch_setup = sdv_arch_setup;43x86_init.resources.probe_roms = x86_init_noop;44x86_init.mpparse.find_mptable = x86_init_noop;45x86_init.mpparse.early_parse_smp_cfg = x86_init_noop;46x86_init.pci.init = ce4100_pci_init;47x86_init.pci.init_irq = sdv_pci_init;4849/*50* By default, the reboot method is ACPI which is supported by the51* CE4100 bootloader CEFDK using FADT.ResetReg Address and ResetValue52* the bootloader will however issue a system power off instead of53* reboot. By using BOOT_KBD we ensure proper system reboot as54* expected.55*/56reboot_type = BOOT_KBD;5758pm_power_off = ce4100_power_off;59}606162