mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-07 16:11:43 +00:00
The port 62/66 ACPI commands were implemented in chip/lm4/lpc.c. They should be handled in common instead of being tied to a particular EC. BUG=chrome-os-partner:23774 BRANCH=none TEST=manual read EC_ACPI_MEM_VERSION # iotools io_write8 0x66 0x80; iotools io_write8 0x62 0; iotools io_read8 0x62 0x01 write & read EC_ACPI_MEM_TEST # iotools io_write8 0x66 0x81; iotools io_write8 0x62 1; iotools io_write8 0x62 0xa5 # iotools io_write8 0x66 0x80; iotools io_write8 0x62 1; iotools io_read8 0x62 0xa5 # iotools io_write8 0x66 0x80; iotools io_write8 0x62 2; iotools io_read8 0x62 0x5a # iotools io_write8 0x66 0x81; iotools io_write8 0x62 1; iotools io_write8 0x62 0xbb # iotools io_write8 0x66 0x80; iotools io_write8 0x62 1; iotools io_read8 0x62 0xbb # iotools io_write8 0x66 0x80; iotools io_write8 0x62 2; iotools io_read8 0x62 0x44 read & write EC_ACPI_MEM_KEYBOARD_BACKLIGHT # iotools io_write8 0x66 0x81; iotools io_write8 0x62 3; iotools io_write8 0x62 100 (keyboard lights up) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 3; iotools io_read8 0x62 0x64 # iotools io_write8 0x66 0x81; iotools io_write8 0x62 3; iotools io_write8 0x62 50 (keyboard dimmer) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 3; iotools io_read8 0x62 0x32 # iotools io_write8 0x66 0x81; iotools io_write8 0x62 3; iotools io_write8 0x62 0 (keyboard goes dark) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 3; iotools io_read8 0x62 0x00 read & write EC_ACPI_MEM_FAN_DUTY # iotools io_write8 0x66 0x81; iotools io_write8 0x62 4; iotools io_write8 0x62 100 (fan on full) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 4; iotools io_read8 0x62 0x64 # iotools io_write8 0x66 0x81; iotools io_write8 0x62 4; iotools io_write8 0x62 50 (fan on half speed) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 4; iotools io_read8 0x62 0x32 # iotools io_write8 0x66 0x81; iotools io_write8 0x62 4; iotools io_write8 0x62 0 (fan off) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 4; iotools io_read8 0x62 0x00 # iotools io_write8 0x66 0x81; iotools io_write8 0x62 4; iotools io_write8 0x62 0xff (fan back to EC control) # iotools io_write8 0x66 0x80; iotools io_write8 0x62 4; iotools io_read8 0x62 0xff test EC_CMD_ACPI_QUERY_EVENT # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x00 On EC console: > hostevent set 0x0f000000 # ectool eventget Current host events: 0x0f000000 # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x19 # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x1a # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x1b # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x1c # iotools io_write8 0x66 0x84; iotools io_read8 0x62 0x00 # ectool eventget Current host events: 0x00000000 Change-Id: I011a5a2051171ec1d37e55ce03e1ce74b93a7e14 Signed-off-by: Bill Richardson <wfrichar@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/179692
63 lines
2.6 KiB
Makefile
63 lines
2.6 KiB
Makefile
# -*- makefile -*-
|
|
# Copyright (c) 2013 The Chromium OS Authors. All rights reserved.
|
|
# Use of this source code is governed by a BSD-style license that can be
|
|
# found in the LICENSE file.
|
|
#
|
|
# Common files build
|
|
#
|
|
|
|
common-y=main.o util.o console_output.o uart_buffering.o
|
|
common-y+=memory_commands.o shared_mem.o system.o hooks.o
|
|
common-y+=gpio.o version.o printf.o queue.o
|
|
|
|
common-$(CONFIG_ALS)+=als.o
|
|
common-$(CONFIG_BACKLIGHT_LID)+=backlight_lid.o
|
|
# TODO(crosbug.com/p/23821): Why do these include battery_common but
|
|
# the other batteries don't? Perhaps should use CONFIG_CMD_BATTERY
|
|
# instead, since all that's in battery.c is the battery console
|
|
# command?
|
|
common-$(CONFIG_BATTERY_BQ27541)+=battery.o
|
|
common-$(CONFIG_BATTERY_SMART)+=battery.o
|
|
common-$(CONFIG_CHARGER)+=charge_state.o charger.o
|
|
# TODO(crosbug.com/p/23815): This is really the charge state machine
|
|
# for ARM, not the charger driver for the tps65090. Rename.
|
|
common-$(CONFIG_CHARGER_TPS65090)+=pmu_tps65090_charger.o
|
|
common-$(CONFIG_COMMON_PANIC_OUTPUT)+=panic_output.o
|
|
common-$(CONFIG_COMMON_TIMER)+=timer.o
|
|
common-$(CONFIG_PMU_POWERINFO)+=pmu_tps65090_powerinfo.o
|
|
common-$(CONFIG_PMU_TPS65090)+=pmu_tps65090.o
|
|
common-$(CONFIG_EOPTION)+=eoption.o
|
|
common-$(CONFIG_EXTPOWER_FALCO)+=extpower_falco.o
|
|
common-$(CONFIG_EXTPOWER_GPIO)+=extpower_gpio.o
|
|
common-$(CONFIG_EXTPOWER_SNOW)+=extpower_snow.o
|
|
common-$(CONFIG_EXTPOWER_SPRING)+=extpower_spring.o
|
|
common-$(CONFIG_FANS)+=fan.o
|
|
common-$(CONFIG_FLASH)+=flash.o
|
|
common-$(CONFIG_FMAP)+=fmap.o
|
|
common-$(CONFIG_I2C)+=i2c.o
|
|
common-$(CONFIG_I2C_ARBITRATION)+=i2c_arbitration.o
|
|
common-$(CONFIG_KEYBOARD_PROTOCOL_8042)+=keyboard_8042.o
|
|
common-$(CONFIG_KEYBOARD_PROTOCOL_MKBP)+=keyboard_mkbp.o
|
|
common-$(CONFIG_KEYBOARD_TEST)+=keyboard_test.o
|
|
common-$(CONFIG_LED_COMMON)+=led_common.o
|
|
common-$(CONFIG_LID_SWITCH)+=lid_switch.o
|
|
common-$(CONFIG_LPC)+=port80.o
|
|
common-$(CONFIG_ONEWIRE)+=onewire.o
|
|
common-$(CONFIG_POWER_BUTTON)+=power_button.o
|
|
common-$(CONFIG_POWER_BUTTON_X86)+=power_button_x86.o
|
|
common-$(CONFIG_PSTORE)+=pstore_commands.o
|
|
common-$(CONFIG_PWM)+=pwm.o
|
|
common-$(CONFIG_PWM_KBLIGHT)+=pwm_kblight.o
|
|
common-$(CONFIG_SWITCH)+=switch.o
|
|
common-$(CONFIG_TEMP_SENSOR)+=temp_sensor.o thermal.o
|
|
common-$(CONFIG_USB_PORT_POWER_DUMB)+=usb_port_power_dumb.o
|
|
common-$(CONFIG_USB_PORT_POWER_SMART)+=usb_port_power_smart.o
|
|
common-$(CONFIG_WIRELESS)+=wireless.o
|
|
common-$(HAS_TASK_CHIPSET)+=chipset.o throttle_ap.o
|
|
common-$(HAS_TASK_CONSOLE)+=console.o
|
|
common-$(HAS_TASK_HOSTCMD)+=acpi.o host_command.o host_event_commands.o
|
|
common-$(HAS_TASK_KEYSCAN)+=keyboard_scan.o
|
|
common-$(HAS_TASK_LIGHTBAR)+=lightbar.o
|
|
common-$(HAS_TASK_VBOOTHASH)+=sha256.o vboot_hash.o
|
|
common-$(TEST_BUILD)+=test_util.o
|