Skip to content
This repository has been archived by the owner on Oct 5, 2018. It is now read-only.

Commit

Permalink
Merge pull request #106 from Leo-Yan/hikey_enable_mcu_lpm_4.0_0805
Browse files Browse the repository at this point in the history
Hikey: Upgrade new mcu and lpm for 4.1rc4 (0805)
  • Loading branch information
ldts committed Aug 17, 2015
2 parents 13b2999 + 0c2d92e commit c8a160c
Show file tree
Hide file tree
Showing 65 changed files with 2,114 additions and 1,428 deletions.
6 changes: 6 additions & 0 deletions Documentation/devicetree/bindings/arm/psci.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ Main node required properties:
support, but are permitted to be present for compatibility with
existing software when "arm,psci" is later in the compatible list.

* "arm,psci-1.0" : for implementations complying to PSCI 1.0. PSCI 1.0 is
backward compatible with PSCI 0.2 with minor specification updates,
as defined in the PSCI specification[2].

- method : The method of calling the PSCI firmware. Permitted
values are:

Expand Down Expand Up @@ -100,3 +104,5 @@ Case 3: PSCI v0.2 and PSCI v0.1.

[1] Kernel documentation - ARM idle states bindings
Documentation/devicetree/bindings/arm/idle-states.txt
[2] Power State Coordination Interface (PSCI) specification
http://infocenter.arm.com/help/topic/com.arm.doc.den0022c/DEN0022C_Power_State_Coordination_Interface.pdf
57 changes: 57 additions & 0 deletions Documentation/devicetree/bindings/mailbox/hisi-mailbox.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
Hisilicon Mailbox Driver
========================

The Hisilicon mailbox supports up to 32 channels. Each channel
is unidirectional with a maximum message size of 8 words. I/O is
performed using register access (there is no DMA) and the cell
raises an interrupt when messages are received.

Mailbox Device Node:
====================

Required properties:
--------------------
- compatible: Shall be "hisilicon,hi6220-mbox"
- reg: Contains the mailbox register address range (base
address and length); the first item is for IPC
registers, the second item is shared buffer for
slots.
- #mbox-cells Common mailbox binding property to identify the number
of cells required for the mailbox specifier. Should be 1.
- interrupts: Contains the interrupt information for the mailbox
device. The format is dependent on which interrupt
controller the SoCs use.

Example:
--------

mailbox: mailbox@F7510000 {
#mbox-cells = <1>;
compatible = "hisilicon,hi6220-mbox";
reg = <0x0 0xF7510000 0x0 0x1000>, /* IPC_S */
<0x0 0x06DFF800 0x0 0x0800>; /* Mailbox */
interrupt-parent = <&gic>;
interrupts = <0 94 4>;
};


Mailbox client
===============

"mboxes" and the optional "mbox-names" (please see
Documentation/devicetree/bindings/mailbox/mailbox.txt for details). Each value
of the mboxes property should contain a phandle to the mailbox controller
device node and second argument is the channel index. It must be 0 (hardware
support only one channel). The equivalent "mbox-names" property value can be
used to give a name to the communication channel to be used by the client user.

Example:
--------

stub_clock: stub_clock {
compatible = "hisilicon,hi6220-stub-clk";
hisilicon,hi6220-clk-sram = <&sram>;
#clock-cells = <1>;
mbox-names = "mbox-tx";
mboxes = <&mailbox 1>;
};
9 changes: 9 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -7789,6 +7789,15 @@ S: Maintained
F: include/linux/power_supply.h
F: drivers/power/

POWER STATE COORDINATION INTERFACE (PSCI)
M: Mark Rutland <[email protected]>
M: Lorenzo Pieralisi <[email protected]>
L: [email protected]
S: Maintained
F: drivers/firmware/psci.c
F: include/linux/psci.h
F: include/uapi/linux/psci.h

PNP SUPPORT
M: Rafael J. Wysocki <[email protected]>
S: Maintained
Expand Down
6 changes: 1 addition & 5 deletions arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -975,11 +975,6 @@ config PLAT_PXA
config PLAT_VERSATILE
bool

config ARM_TIMER_SP804
bool
select CLKSRC_MMIO
select CLKSRC_OF if OF

source "arch/arm/firmware/Kconfig"

source arch/arm/mm/Kconfig
Expand Down Expand Up @@ -1465,6 +1460,7 @@ config HOTPLUG_CPU
config ARM_PSCI
bool "Support for the ARM Power State Coordination Interface (PSCI)"
depends on CPU_V7
select ARM_PSCI_FW
help
Say Y here if you want Linux to communicate with system firmware
implementing the PSCI specification for CPU-centric power
Expand Down
1 change: 0 additions & 1 deletion arch/arm/common/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ obj-$(CONFIG_SHARP_LOCOMO) += locomo.o
obj-$(CONFIG_SHARP_PARAM) += sharpsl_param.o
obj-$(CONFIG_SHARP_SCOOP) += scoop.o
obj-$(CONFIG_PCI_HOST_ITE8152) += it8152.o
obj-$(CONFIG_ARM_TIMER_SP804) += timer-sp.o
obj-$(CONFIG_MCPM) += mcpm_head.o mcpm_entry.o mcpm_platsmp.o vlock.o
CFLAGS_REMOVE_mcpm_entry.o = -pg
AFLAGS_mcpm_head.o := -march=armv7-a
Expand Down
23 changes: 0 additions & 23 deletions arch/arm/include/asm/psci.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,34 +14,11 @@
#ifndef __ASM_ARM_PSCI_H
#define __ASM_ARM_PSCI_H

#define PSCI_POWER_STATE_TYPE_STANDBY 0
#define PSCI_POWER_STATE_TYPE_POWER_DOWN 1

struct psci_power_state {
u16 id;
u8 type;
u8 affinity_level;
};

struct psci_operations {
int (*cpu_suspend)(struct psci_power_state state,
unsigned long entry_point);
int (*cpu_off)(struct psci_power_state state);
int (*cpu_on)(unsigned long cpuid, unsigned long entry_point);
int (*migrate)(unsigned long cpuid);
int (*affinity_info)(unsigned long target_affinity,
unsigned long lowest_affinity_level);
int (*migrate_info_type)(void);
};

extern struct psci_operations psci_ops;
extern struct smp_operations psci_smp_ops;

#ifdef CONFIG_ARM_PSCI
int psci_init(void);
bool psci_smp_available(void);
#else
static inline int psci_init(void) { return 0; }
static inline bool psci_smp_available(void) { return false; }
#endif

Expand Down
2 changes: 1 addition & 1 deletion arch/arm/kernel/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ obj-$(CONFIG_EARLY_PRINTK) += early_printk.o

obj-$(CONFIG_ARM_VIRT_EXT) += hyp-stub.o
ifeq ($(CONFIG_ARM_PSCI),y)
obj-y += psci.o psci-call.o
obj-y += psci-call.o
obj-$(CONFIG_SMP) += psci_smp.o
endif

Expand Down
Loading

0 comments on commit c8a160c

Please sign in to comment.