projects
/
project
/
bcm63xx
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b69b603
)
x86: ivybridge: Implement PCH_REQ_PMBASE_INFO
author
Simon Glass
<
[email protected]
>
Fri, 26 Apr 2019 03:59:02 +0000
(21:59 -0600)
committer
Bin Meng
<
[email protected]
>
Wed, 8 May 2019 05:02:15 +0000
(13:02 +0800)
Implement this ioctl() to support power off.
Signed-off-by: Simon Glass <
[email protected]
>
Reviewed-by: Bin Meng <
[email protected]
>
arch/x86/cpu/ivybridge/bd82x6x.c
patch
|
blob
|
history
diff --git
a/arch/x86/cpu/ivybridge/bd82x6x.c
b/arch/x86/cpu/ivybridge/bd82x6x.c
index ed9bce641687f812a71c34df997d56e7c17adde0..1cb6cecda9ea0fb1d066b0fe9a2df5421d853bdb 100644
(file)
--- a/
arch/x86/cpu/ivybridge/bd82x6x.c
+++ b/
arch/x86/cpu/ivybridge/bd82x6x.c
@@
-229,6
+229,21
@@
static int bd82x6x_ioctl(struct udevice *dev, enum pch_req_t req, void *data,
return -ENOENT;
return val & RCBA_AUDIO_CONFIG_MASK;
+ case PCH_REQ_PMBASE_INFO: {
+ struct pch_pmbase_info *pm = data;
+ int ret;
+
+ /* Find the base address of the powermanagement registers */
+ ret = dm_pci_read_config16(dev, 0x40, &pm->base);
+ if (ret)
+ return ret;
+ pm->base &= 0xfffe;
+ pm->gpio0_en_ofs = GPE0_EN;
+ pm->pm1_sts_ofs = PM1_STS;
+ pm->pm1_cnt_ofs = PM1_CNT;
+
+ return 0;
+ }
default:
return -ENOSYS;
}