summaryrefslogtreecommitdiffstats
path: root/meta-quanta/meta-q71l
diff options
context:
space:
mode:
authorDave Cobbley <david.j.cobbley@linux.intel.com>2018-08-22 21:40:54 -0400
committerBrad Bishop <bradleyb@fuzziesquirrel.com>2018-08-23 12:39:42 -0400
commit194ff4f1f5d44b12e9cb06ddafa6adb20174a13c (patch)
tree823835cd29daf8901a31ac14c7e6534abf199be3 /meta-quanta/meta-q71l
parent4feb727cd6b77a68bdaca63e121b378d814f5eaf (diff)
downloadtalos-openbmc-194ff4f1f5d44b12e9cb06ddafa6adb20174a13c.tar.gz
talos-openbmc-194ff4f1f5d44b12e9cb06ddafa6adb20174a13c.zip
[Subtree] Bring openbmc machines to top level
The new subtree model brings the subtrees up from the openbmc-machines layer. Change-Id: I58a03ae1be374bc79ae1438e65e888375d12d0c0 Signed-off-by: Dave Cobbley <david.j.cobbley@linux.intel.com> Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'meta-quanta/meta-q71l')
-rw-r--r--meta-quanta/meta-q71l/README.md6
-rw-r--r--meta-quanta/meta-q71l/conf/bblayers.conf.sample35
-rw-r--r--meta-quanta/meta-q71l/conf/conf-notes.txt2
-rw-r--r--meta-quanta/meta-q71l/conf/layer.conf9
-rw-r--r--meta-quanta/meta-q71l/conf/local.conf.sample21
-rw-r--r--meta-quanta/meta-q71l/conf/machine/quanta-q71l.conf38
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/images/obmc-phosphor-image.bbappend3
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%.bbappend20
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/bmc2
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/fp2
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/motherboard2
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/pdb2
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config-native.bb18
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config/channel.yaml5
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-fru-merge-config-native.bb14
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map-native.bb19
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map/config.yaml202
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map-native.bb18
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map/config.yaml523
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-gpio.service9
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweroff.service14
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweron.service14
-rwxr-xr-xmeta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/init_once.sh32
-rwxr-xr-xmeta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweroff.sh10
-rwxr-xr-xmeta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweron.sh10
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/quanta-powerctrl.bb27
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%.bbappend17
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4c.conf1
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4e.conf1
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4f.conf1
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/iio-hwmon.conf19
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/pwm-tacho-controller@1e786000.conf9
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/spictrl/files/spimaster.py148
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/spictrl/spictrl.bb19
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config.bb37
-rw-r--r--meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config/Quanta-q71l.py48
36 files changed, 1357 insertions, 0 deletions
diff --git a/meta-quanta/meta-q71l/README.md b/meta-quanta/meta-q71l/README.md
new file mode 100644
index 000000000..01315ae1b
--- /dev/null
+++ b/meta-quanta/meta-q71l/README.md
@@ -0,0 +1,6 @@
+Quanta-Q71l
+================
+
+This is the Quanta-Q71l machine layer.
+
+This platform is currently supported, although often behind.
diff --git a/meta-quanta/meta-q71l/conf/bblayers.conf.sample b/meta-quanta/meta-q71l/conf/bblayers.conf.sample
new file mode 100644
index 000000000..4797c565b
--- /dev/null
+++ b/meta-quanta/meta-q71l/conf/bblayers.conf.sample
@@ -0,0 +1,35 @@
+# LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf
+# changes incompatibly
+LCONF_VERSION = "8"
+
+BBPATH = "${TOPDIR}"
+BBFILES ?= ""
+
+BBLAYERS ?= " \
+ ##OEROOT##/meta \
+ ##OEROOT##/meta-poky \
+ ##OEROOT##/meta-openembedded/meta-oe \
+ ##OEROOT##/meta-openembedded/meta-networking \
+ ##OEROOT##/meta-openembedded/meta-perl \
+ ##OEROOT##/meta-openembedded/meta-python \
+ ##OEROOT##/meta-openembedded/meta-webserver \
+ ##OEROOT##/meta-phosphor \
+ ##OEROOT##/meta-aspeed \
+ ##OEROOT##/meta-x86 \
+ ##OEROOT##/meta-quanta \
+ ##OEROOT##/meta-quanta/meta-q71l \
+ "
+BBLAYERS_NON_REMOVABLE ?= " \
+ ##OEROOT##/meta \
+ ##OEROOT##/meta-poky \
+ ##OEROOT##/meta-openembedded/meta-oe \
+ ##OEROOT##/meta-openembedded/meta-networking \
+ ##OEROOT##/meta-openembedded/meta-perl \
+ ##OEROOT##/meta-openembedded/meta-python \
+ ##OEROOT##/meta-openembedded/meta-webserver \
+ ##OEROOT##/meta-phosphor \
+ ##OEROOT##/meta-aspeed \
+ ##OEROOT##/meta-x86 \
+ ##OEROOT##/meta-quanta \
+ ##OEROOT##/meta-quanta/meta-q71l \
+ "
diff --git a/meta-quanta/meta-q71l/conf/conf-notes.txt b/meta-quanta/meta-q71l/conf/conf-notes.txt
new file mode 100644
index 000000000..9b3c01a55
--- /dev/null
+++ b/meta-quanta/meta-q71l/conf/conf-notes.txt
@@ -0,0 +1,2 @@
+Common targets are:
+ obmc-phosphor-image
diff --git a/meta-quanta/meta-q71l/conf/layer.conf b/meta-quanta/meta-q71l/conf/layer.conf
new file mode 100644
index 000000000..80bae52e9
--- /dev/null
+++ b/meta-quanta/meta-q71l/conf/layer.conf
@@ -0,0 +1,9 @@
+# We have a conf and classes directory, add to BBPATH
+BBPATH .= ":${LAYERDIR}"
+
+# We have recipes-* directories, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
+ ${LAYERDIR}/recipes-*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "q71l"
+BBFILE_PATTERN_q71l = ""
diff --git a/meta-quanta/meta-q71l/conf/local.conf.sample b/meta-quanta/meta-q71l/conf/local.conf.sample
new file mode 100644
index 000000000..8862b5c68
--- /dev/null
+++ b/meta-quanta/meta-q71l/conf/local.conf.sample
@@ -0,0 +1,21 @@
+MACHINE ??= "quanta-q71l"
+DISTRO ?= "openbmc-phosphor"
+PACKAGE_CLASSES ?= "package_rpm"
+SANITY_TESTED_DISTROS_append ?= " RedHatEnterpriseWorkstation-6.*"
+EXTRA_IMAGE_FEATURES = "debug-tweaks"
+USER_CLASSES ?= "buildstats image-mklibs image-prelink"
+PATCHRESOLVE = "noop"
+BB_DISKMON_DIRS = "\
+ STOPTASKS,${TMPDIR},1G,100K \
+ STOPTASKS,${DL_DIR},1G,100K \
+ STOPTASKS,${SSTATE_DIR},1G,100K \
+ STOPTASKS,/tmp,100M,100K \
+ ABORT,${TMPDIR},100M,1K \
+ ABORT,${DL_DIR},100M,1K \
+ ABORT,${SSTATE_DIR},100M,1K \
+ ABORT,/tmp,10M,1K"
+CONF_VERSION = "1"
+INHERIT += "extrausers"
+EXTRA_USERS_PARAMS = " \
+ usermod -p '\$1\$UGMqyqdG\$FZiylVFmRRfl9Z0Ue8G7e/' root; \
+ "
diff --git a/meta-quanta/meta-q71l/conf/machine/quanta-q71l.conf b/meta-quanta/meta-q71l/conf/machine/quanta-q71l.conf
new file mode 100644
index 000000000..b36a09821
--- /dev/null
+++ b/meta-quanta/meta-q71l/conf/machine/quanta-q71l.conf
@@ -0,0 +1,38 @@
+KMACHINE = "aspeed"
+KERNEL_DEVICETREE = "${KMACHINE}-bmc-${MACHINE}.dtb"
+
+require conf/machine/include/ast2400.inc
+require conf/machine/include/obmc-bsp-common.inc
+
+UBOOT_MACHINE_palmetto = "ast_g4_ncsi_config"
+UBOOT_ENTRYPOINT = "0x40008000"
+UBOOT_LOADADDRESS = "0x40008000"
+
+FLASH_SIZE = "32768"
+
+# If we included the openpower.inc we'd get these from that.
+#OBMC_MACHINE_FEATURES += "\
+# obmc-phosphor-fan-mgmt \
+# obmc-phosphor-chassis-mgmt \
+# obmc-phosphor-flash-mgmt \
+# obmc-host-ipmi \
+# obmc-host-ctl \
+# obmc-host-state-mgmt \
+# obmc-chassis-state-mgmt \
+# obmc-bmc-state-mgmt \
+# "
+# But we don't, and it's ok :D We're pulling in specific packages in an image recipe.
+
+# This sets up our own Quanta-q71l.py inclusion based on the Zaius.py in the skeleton repo.
+# As something temporarily required.
+VIRTUAL-RUNTIME_skeleton_workbook = "${MACHINE}-config"
+PREFERRED_PROVIDER_virtual/obmc-inventory-data ?= "${VIRTUAL-RUNTIME_skeleton_workbook}"
+
+# These are meant to include the inventory config.yaml and so on.
+PREFERRED_PROVIDER_virtual/phosphor-ipmi-fru-inventory = "q71l-ipmi-inventory-map-native"
+PREFERRED_PROVIDER_virtual/phosphor-ipmi-sensor-inventory = "q71l-ipmi-sensor-map-native"
+PREFERRED_PROVIDER_virtual/phosphor-ipmi-channel-config = "q71l-ipmi-channel-config-native"
+PREFERRED_PROVIDER_virtual/phosphor-ipmi-fru-merge-config = "q71l-ipmi-fru-merge-config-native"
+
+
+PREFERRED_PROVIDER_virtual/obmc-host-ipmi-hw = "phosphor-ipmi-bt"
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/images/obmc-phosphor-image.bbappend b/meta-quanta/meta-q71l/recipes-phosphor/images/obmc-phosphor-image.bbappend
new file mode 100644
index 000000000..6124ab018
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/images/obmc-phosphor-image.bbappend
@@ -0,0 +1,3 @@
+OBMC_IMAGE_EXTRA_INSTALL_append_quanta-q71l = " spictrl"
+OBMC_IMAGE_EXTRA_INSTALL_append_quanta-q71l = " quanta-powerctrl"
+
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%.bbappend b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%.bbappend
new file mode 100644
index 000000000..f50949720
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%.bbappend
@@ -0,0 +1,20 @@
+inherit obmc-phosphor-systemd
+
+FILESEXTRAPATHS_prepend_quanta-q71l := "${THISDIR}/${PN}:"
+
+EEPROM_NAMES = "motherboard pdb fp bmc"
+
+EEPROMFMT = "system/chassis/{0}"
+EEPROM_ESCAPEDFMT = "system-chassis-{0}"
+EEPROMS = "${@compose_list(d, 'EEPROMFMT', 'EEPROM_NAMES')}"
+EEPROMS_ESCAPED = "${@compose_list(d, 'EEPROM_ESCAPEDFMT', 'EEPROM_NAMES')}"
+
+ENVFMT = "obmc/eeproms/{0}"
+SYSTEMD_ENVIRONMENT_FILE_${PN}_append_quanta-q71l := " ${@compose_list(d, 'ENVFMT', 'EEPROMS')}"
+
+TMPL = "obmc-read-eeprom@.service"
+TGT = "${SYSTEMD_DEFAULT_TARGET}"
+INSTFMT = "obmc-read-eeprom@{0}.service"
+FMT = "../${TMPL}:${TGT}.wants/${INSTFMT}"
+
+SYSTEMD_LINK_${PN}_append_quanta-q71l := " ${@compose_list(d, 'FMT', 'EEPROMS_ESCAPED')}"
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/bmc b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/bmc
new file mode 100644
index 000000000..04040806b
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/bmc
@@ -0,0 +1,2 @@
+SYSFS_PATH=/sys/bus/i2c/devices/8-0050/eeprom
+FRUID=50
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/fp b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/fp
new file mode 100644
index 000000000..32e3ef7b8
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/fp
@@ -0,0 +1,2 @@
+SYSFS_PATH=/sys/bus/i2c/devices/1-0057/eeprom
+FRUID=57
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/motherboard b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/motherboard
new file mode 100644
index 000000000..b01390ae9
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/motherboard
@@ -0,0 +1,2 @@
+SYSFS_PATH=/sys/bus/i2c/devices/1-0054/eeprom
+FRUID=56
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/pdb b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/pdb
new file mode 100644
index 000000000..a08392130
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/phosphor-ipmi-fru%/obmc/eeproms/system/chassis/pdb
@@ -0,0 +1,2 @@
+SYSFS_PATH=/sys/bus/i2c/devices/7-0052/eeprom
+FRUID=52
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config-native.bb b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config-native.bb
new file mode 100644
index 000000000..6eae84570
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config-native.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Quanta Q71l IPMI Channel to if_name mapping."
+PR = "r1"
+
+inherit native
+inherit phosphor-ipmi-host
+inherit obmc-phosphor-license
+
+PROVIDES += "virtual/phosphor-ipmi-channel-config"
+
+SRC_URI += "file://channel.yaml"
+
+S = "${WORKDIR}"
+
+do_install() {
+ DEST=${D}${sensor_datadir}
+ install -d ${DEST}
+ install channel.yaml ${DEST}/channel.yaml
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config/channel.yaml b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config/channel.yaml
new file mode 100644
index 000000000..3cc2cd242
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-channel-config/channel.yaml
@@ -0,0 +1,5 @@
+1:
+ ifName: eth0
+2:
+ ifName: eth1
+
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-fru-merge-config-native.bb b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-fru-merge-config-native.bb
new file mode 100644
index 000000000..330cda177
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-fru-merge-config-native.bb
@@ -0,0 +1,14 @@
+inherit native
+inherit obmc-phosphor-license
+
+DEPENDS += "virtual/phosphor-ipmi-fru-inventory"
+PROVIDES += "virtual/phosphor-ipmi-fru-merge-config"
+
+# Put the fru_config in the right place with the right name.
+# Pull the IPMI FRU YAML config to use it in the IPMI HOST YAML.
+do_install_append() {
+ IPMI_FRU_SRC=${datadir}/phosphor-ipmi-fru/config
+ IPMI_HOST_DEST=${D}${datadir}/phosphor-ipmi-host/config
+ install -d ${IPMI_HOST_DEST}
+ cat ${IPMI_FRU_SRC}/config.yaml > ${IPMI_HOST_DEST}/fru_config.yaml
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map-native.bb b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map-native.bb
new file mode 100644
index 000000000..93706f3e3
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map-native.bb
@@ -0,0 +1,19 @@
+SUMMARY = "Quanta-Q71l IPMI to DBus Inventory mapping."
+PR = "r1"
+
+inherit native
+inherit obmc-phosphor-license
+inherit phosphor-ipmi-fru
+
+SRC_URI += "file://config.yaml"
+
+PROVIDES += "virtual/phosphor-ipmi-fru-inventory"
+
+S = "${WORKDIR}"
+
+do_install() {
+ DEST=${D}${config_datadir}
+
+ install -d ${DEST}
+ install config.yaml ${DEST}
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map/config.yaml b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map/config.yaml
new file mode 100644
index 000000000..87295213b
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-inventory-map/config.yaml
@@ -0,0 +1,202 @@
+0x56:
+ /system/chassis/motherboard:
+ entityID: 7
+ entityInstance: 1
+ interfaces:
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ BuildDate:
+ IPMIFruProperty: Mfg Date
+ IPMIFruSection: Board
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Board
+ Manufacturer:
+ IPMIFruProperty: Manufacturer
+ IPMIFruSection: Board
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Item:
+ PrettyName:
+ IPMIFruProperty: Name
+ IPMIFruSection: Board
+ /system:
+ entityID: 23
+ entityInstance: 1
+ interfaces:
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Chassis
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Chassis
+ Model:
+ IPMIFruProperty: Type
+ IPMIFruSection: Chassis
+
+0x50:
+ /system/chassis/motherboard/bmc:
+ entityID: 6
+ entityInstance: 1
+ interfaces:
+ xyz.openbmc_project.Inventory.Item:
+ PrettyName:
+ IPMIFruProperty: Name
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ BuildDate:
+ IPMIFruProperty: Mfg Date
+ IPMIFruSection: Board
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Board
+ Manufacturer:
+ IPMIFruProperty: Manufacturer
+ IPMIFruSection: Board
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Revision:
+ Version:
+ IPMIFruProperty: FRU File ID
+ IPMIFruSection: Board
+
+0x52:
+ /system/chassis/pdb:
+ entityID: 21
+ entityInstance: 1
+ interfaces:
+ xyz.openbmc_project.Inventory.Item:
+ PrettyName:
+ IPMIFruProperty: Name
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Board
+ Manufacturer:
+ IPMIFruProperty: Manufacturer
+ IPMIFruSection: Board
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Board
+ BuildDate:
+ IPMIFruProperty: Mfg Date
+ IPMIFruSection: Board
+ Model:
+ IPMIFruProperty: Model Number
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Revision:
+ Version:
+ IPMIFruProperty: FRU File ID
+ IPMIFruSection: Board
+
+0x57:
+ /system/chassis/fp:
+ entityID: 2
+ entityInstance: 1
+ interfaces:
+ xyz.openbmc_project.Inventory.Item:
+ PrettyName:
+ IPMIFruProperty: Name
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Board
+ Manufacturer:
+ IPMIFruProperty: Manufacturer
+ IPMIFruSection: Board
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Board
+ BuildDate:
+ IPMIFruProperty: Mfg Date
+ IPMIFruSection: Board
+ Model:
+ IPMIFruProperty: Model Number
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Revision:
+ Version:
+ IPMIFruProperty: FRU File ID
+ IPMIFruSection: Board
+
+0x20:
+ /system/chassis/motherboard/mezzanine8/memory_riser:
+ entityID: 8
+ entityInstance: 1
+ interfaces: &riser
+ xyz.openbmc_project.Inventory.Item:
+ PrettyName:
+ IPMIFruProperty: Name
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Asset:
+ SerialNumber:
+ IPMIFruProperty: Serial Number
+ IPMIFruSection: Board
+ Manufacturer:
+ IPMIFruProperty: Manufacturer
+ IPMIFruSection: Board
+ PartNumber:
+ IPMIFruProperty: Part Number
+ IPMIFruSection: Board
+ BuildDate:
+ IPMIFruProperty: Mfg Date
+ IPMIFruSection: Board
+ Model:
+ IPMIFruProperty: Model Number
+ IPMIFruSection: Board
+ xyz.openbmc_project.Inventory.Decorator.Revision:
+ Version:
+ IPMIFruProperty: FRU File ID
+ IPMIFruSection: Board
+
+0x21:
+ /system/chassis/motherboard/mezzanine7/memory_riser:
+ entityID: 8
+ entityInstance: 2
+ interfaces:
+ <<: *riser
+
+0x22:
+ /system/chassis/motherboard/mezzanine6/memory_riser:
+ entityID: 8
+ entityInstance: 3
+ interfaces:
+ <<: *riser
+
+0x23:
+ /system/chassis/motherboard/mezzanine5/memory_riser:
+ entityID: 8
+ entityInstance: 4
+ interfaces:
+ <<: *riser
+
+0x24:
+ /system/chassis/motherboard/mezzanine4/memory_riser:
+ entityID: 8
+ entityInstance: 5
+ interfaces:
+ <<: *riser
+
+0x25:
+ /system/chassis/motherboard/mezzanine3/memory_riser:
+ entityID: 8
+ entityInstance: 6
+ interfaces:
+ <<: *riser
+
+0x26:
+ /system/chassis/motherboard/mezzanine2/memory_riser:
+ entityID: 8
+ entityInstance: 7
+ interfaces:
+ <<: *riser
+
+0x27:
+ /system/chassis/motherboard/mezzanine1/memory_riser:
+ entityID: 8
+ entityInstance: 8
+ interfaces:
+ <<: *riser
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map-native.bb b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map-native.bb
new file mode 100644
index 000000000..951a55fb7
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map-native.bb
@@ -0,0 +1,18 @@
+SUMMARY = "Quanta Q71l IPMI to DBus Sensor mapping."
+PR = "r1"
+
+inherit native
+inherit phosphor-ipmi-host
+inherit obmc-phosphor-license
+
+PROVIDES += "virtual/phosphor-ipmi-sensor-inventory"
+
+SRC_URI += "file://config.yaml"
+
+S = "${WORKDIR}"
+
+do_install() {
+ DEST=${D}${sensor_datadir}
+ install -d ${DEST}
+ install config.yaml ${DEST}/sensor.yaml
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map/config.yaml b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map/config.yaml
new file mode 100644
index 000000000..fb0ccfcbc
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/ipmi/q71l-ipmi-sensor-map/config.yaml
@@ -0,0 +1,523 @@
+0xD0:
+ sensorType: 0x01
+ path: /xyz/openbmc_project/extsensors/margin/fleeting0
+ sensorReadingType: 0x01
+ multiplierM: 511
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.DegreesC
+ scale: -3
+ mutability: Mutability::Write|Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0xFF:
+ type: int64_t
+
+0xF0:
+ sensorType: 0x01
+ path: /xyz/openbmc_project/sensors/temperature/temp2_inlet
+ sensorReadingType: 0x01
+ multiplierM: 511
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.DegreesC
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xF1:
+ sensorType: 0x01
+ path: /xyz/openbmc_project/sensors/temperature/temp1
+ sensorReadingType: 0x01
+ multiplierM: 511
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.DegreesC
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xF2:
+ sensorType: 0x01
+ path: /xyz/openbmc_project/sensors/temperature/temp3
+ sensorReadingType: 0x01
+ multiplierM: 511
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.DegreesC
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xB0:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan1
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xC0:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan1
+ sensorReadingType: 0x01
+ multiplierM: 1
+ offsetB: 0
+ bExp: 0
+ mutability: Mutability::Write
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Control.FanPwm:
+ Target:
+ Offsets:
+ 0xFF:
+ type: uint64_t
+
+0xB1:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan2
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xC1:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan2
+ sensorReadingType: 0x01
+ multiplierM: 1
+ offsetB: 0
+ bExp: 0
+ mutability: Mutability::Write
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Control.FanPwm:
+ Target:
+ Offsets:
+ 0xFF:
+ type: uint64_t
+
+0xB2:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan3
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xC2:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan3
+ sensorReadingType: 0x01
+ multiplierM: 1
+ offsetB: 0
+ bExp: 0
+ mutability: Mutability::Write
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Control.FanPwm:
+ Target:
+ Offsets:
+ 0xFF:
+ type: uint64_t
+
+0xB3:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan4
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xC3:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan4
+ sensorReadingType: 0x01
+ multiplierM: 1
+ offsetB: 0
+ bExp: 0
+ mutability: Mutability::Write
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Control.FanPwm:
+ Target:
+ Offsets:
+ 0xFF:
+ type: uint64_t
+
+0xB4:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan5
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xB5:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan6
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xB6:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan7
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xB7:
+ sensorType: 0x04
+ path: /xyz/openbmc_project/sensors/fan_tach/fan8
+ sensorReadingType: 0x01
+ multiplierM: 100
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.RPMS
+ scale: 0
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE0:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p3v3_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE1:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p5v_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE2:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p12v_aux_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE3:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p1v1_ssb
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE4:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/pvcc_cpu0
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE5:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/pvcc_cpu1
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE6:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p3v3_aux_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE7:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p5v_aux_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE8:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/pvcc_cpu2
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xE9:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/pvcc_cpu3
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xEA:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p12v_scaled
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
+
+0xEB:
+ sensorType: 0x02
+ path: /xyz/openbmc_project/sensors/voltage/p3v_vbat
+ sensorReadingType: 0x01
+ multiplierM: 64
+ offsetB: 0
+ bExp: 0
+ unit: xyz.openbmc_project.Sensor.Value.Unit.Volts
+ scale: -3
+ mutability: Mutability::Read
+ serviceInterface: org.freedesktop.DBus.Properties
+ readingType: readingData
+ interfaces:
+ xyz.openbmc_project.Sensor.Value:
+ Value:
+ Offsets:
+ 0x0:
+ type: int64_t
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-gpio.service b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-gpio.service
new file mode 100644
index 000000000..159b3cca6
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-gpio.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=Configure GPIOs for Host Power Control
+
+[Service]
+Restart=no
+RemainAfterExit=true
+Type=oneshot
+ExecStart=/usr/bin/env init_once.sh
+SyslogIdentifier=init_once.sh
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweroff.service b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweroff.service
new file mode 100644
index 000000000..9b96ce7ca
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweroff.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Stop Host
+Requires=host-gpio.service
+After=host-gpio.service
+Conflicts=obmc-chassis-power-on@0.target
+
+[Service]
+RemainAfterExit=yes
+Type=oneshot
+ExecStart=/usr/bin/env poweroff.sh
+SyslogIdentifier=poweroff.sh
+
+[Install]
+WantedBy=obmc-chassis-power-off@0.target
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweron.service b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweron.service
new file mode 100644
index 000000000..69720c9aa
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/host-poweron.service
@@ -0,0 +1,14 @@
+[Unit]
+Description=Start Host
+Requires=host-gpio.service
+After=host-gpio.service
+Conflicts=obmc-chassis-poweroff@0.target
+
+[Service]
+RemainAfterExit=yes
+Type=oneshot
+ExecStart=/usr/bin/env poweron.sh
+SyslogIdentifier=poweron.sh
+
+[Install]
+WantedBy=obmc-chassis-poweron@0.target
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/init_once.sh b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/init_once.sh
new file mode 100755
index 000000000..205ecaff0
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/init_once.sh
@@ -0,0 +1,32 @@
+#!/bin/bash
+
+# Set all output GPIOs as such and drive them with reasonable values.
+function set_gpio_active_low() {
+ if [ $# -ne 2 ]; then
+ echo "set_gpio_active_low: need both GPIO# and initial level";
+ return;
+ fi
+
+ echo $1 > /sys/class/gpio/export
+ echo 1 > /sys/class/gpio/gpio$1/active_low
+ echo $2 > /sys/class/gpio/gpio$1/direction
+}
+
+GPIO_BASE=$(cat /sys/devices/platform/ahb/ahb:apb/1e780000.gpio/gpio/*/base)
+
+# FM_BMC_READY_N, GPIO Q4, active low
+set_gpio_active_low $((${GPIO_BASE} + 128 + 4)) high
+
+# FM_BMC_SSB_SMI_LPC_N, GPIO Q6, active low
+set_gpio_active_low $((${GPIO_BASE} + 128 + 6)) high
+
+# FM_BMC_SYS_THROTTLE_N, GPIO A3, active low
+set_gpio_active_low $((${GPIO_BASE} + 0 + 3)) high
+
+# FM_BMC_SSB_SCI_LPC_N, GPIO E4, active low
+set_gpio_active_low $((${GPIO_BASE} + 32 + 4)) high
+
+# FP_PWR_BTN_PASS_R_N, GPIO D3, active low
+set_gpio_active_low $((${GPIO_BASE} + 24 + 3)) high
+
+exit 0;
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweroff.sh b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweroff.sh
new file mode 100755
index 000000000..8e0dae38c
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweroff.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+GPIO_BASE=$(cat /sys/devices/platform/ahb/ahb:apb/1e780000.gpio/gpio/*/base)
+GPIO_NUM=$(($GPIO_BASE + 24 + 3))
+
+echo 1 > /sys/class/gpio/gpio${GPIO_NUM}/value
+sleep 5
+echo 0 > /sys/class/gpio/gpio${GPIO_NUM}/value
+
+exit 0;
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweron.sh b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweron.sh
new file mode 100755
index 000000000..f925a33a8
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/files/poweron.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+GPIO_BASE=$(cat /sys/devices/platform/ahb/ahb:apb/1e780000.gpio/gpio/*/base)
+GPIO_NUM=$(($GPIO_BASE + 24 + 3))
+
+echo 1 > /sys/class/gpio/gpio${GPIO_NUM}/value
+sleep 1
+echo 0 > /sys/class/gpio/gpio${GPIO_NUM}/value
+
+exit 0;
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/quanta-powerctrl.bb b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/quanta-powerctrl.bb
new file mode 100644
index 000000000..fd02327f1
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/quanta-powerctrl/quanta-powerctrl.bb
@@ -0,0 +1,27 @@
+FILESEXTRAPATHS_append := "${THISDIR}/files:"
+
+inherit systemd
+inherit obmc-phosphor-license
+inherit obmc-phosphor-systemd
+
+S = "${WORKDIR}/"
+
+SRC_URI = "file://init_once.sh \
+ file://poweroff.sh \
+ file://poweron.sh \
+ file://host-gpio.service \
+ file://host-poweroff.service \
+ file://host-poweron.service"
+
+DEPENDS = "systemd"
+RDEPENDS_${PN} = "bash"
+
+SYSTEMD_PACKAGES = "${PN}"
+SYSTEMD_SERVICE_${PN} = "host-gpio.service host-poweron.service host-poweroff.service"
+
+do_install() {
+ install -d ${D}/usr/sbin
+ install -m 0755 ${S}init_once.sh ${D}/${sbindir}/
+ install -m 0755 ${S}poweroff.sh ${D}/${sbindir}/
+ install -m 0755 ${S}poweron.sh ${D}/${sbindir}/
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%.bbappend b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%.bbappend
new file mode 100644
index 000000000..19365c2fc
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%.bbappend
@@ -0,0 +1,17 @@
+inherit obmc-phosphor-utils
+
+FILESEXTRAPATHS_prepend_quanta-q71l := "${THISDIR}/${PN}:"
+
+# More conf files can be added as sensors are added.
+
+ITEMS = "pwm-tacho-controller@1e786000.conf"
+
+TEMPS = "tmp75@4c tmp75@4e tmp75@4f"
+TEMPBASE = "ahb/apb/i2c@1e78a000/i2c-bus@80/{0}.conf"
+ITEMS += "${@compose_list(d, 'TEMPBASE', 'TEMPS')}"
+ITEMS += "iio-hwmon.conf"
+
+ENVS = "obmc/hwmon/{0}"
+SYSTEMD_ENVIRONMENT_FILE_${PN}_append_quanta-q71l := " ${@compose_list(d, 'ENVS', 'ITEMS')}"
+
+EXTRA_OECONF_append_quanta-q71l = " --enable-negative-errno-on-fail"
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4c.conf b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4c.conf
new file mode 100644
index 000000000..4ac0ebfc9
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4c.conf
@@ -0,0 +1 @@
+LABEL_temp1=temp2_inlet
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4e.conf b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4e.conf
new file mode 100644
index 000000000..504e4cfeb
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4e.conf
@@ -0,0 +1 @@
+LABEL_temp1=temp3
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4f.conf b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4f.conf
new file mode 100644
index 000000000..10ec2653b
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/ahb/apb/i2c@1e78a000/i2c-bus@80/tmp75@4f.conf
@@ -0,0 +1 @@
+LABEL_temp1=temp1
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/iio-hwmon.conf b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/iio-hwmon.conf
new file mode 100644
index 000000000..cb8d54e18
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/iio-hwmon.conf
@@ -0,0 +1,19 @@
+LABEL_in1=p3v3_scaled
+GAIN_in1=1.62
+LABEL_in2=p5v_scaled
+GAIN_in2=2.47
+LABEL_in3=p12v_aux_scaled
+GAIN_in3=6.01
+LABEL_in4=p1v1_ssb
+LABEL_in5=pvcc_cpu0
+LABEL_in6=pvcc_cpu1
+LABEL_in7=p3v3_aux_scaled
+GAIN_in7=1.62
+LABEL_in8=p5v_aux_scaled
+GAIN_in8=2.47
+LABEL_in9=pvcc_cpu2
+LABEL_in10=pvcc_cpu3
+LABEL_in11=p12v_scaled
+GAIN_in11=6.01
+LABEL_in12=p3v_vbat
+GAIN_in12=1.4992504
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/pwm-tacho-controller@1e786000.conf b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/pwm-tacho-controller@1e786000.conf
new file mode 100644
index 000000000..dfdecb40d
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/sensors/phosphor-hwmon%/obmc/hwmon/pwm-tacho-controller@1e786000.conf
@@ -0,0 +1,9 @@
+LABEL_fan1=fan1
+LABEL_fan2=fan2
+LABEL_fan3=fan3
+LABEL_fan4=fan4
+LABEL_fan5=fan5
+LABEL_fan6=fan6
+LABEL_fan7=fan7
+LABEL_fan8=fan8
+
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/spictrl/files/spimaster.py b/meta-quanta/meta-q71l/recipes-phosphor/spictrl/files/spimaster.py
new file mode 100644
index 000000000..dd08372b7
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/spictrl/files/spimaster.py
@@ -0,0 +1,148 @@
+# Copyright (C) 2017 Google Inc.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+#!/usr/bin/env python
+"""Basic utility for reading and writing registers on an ASPEED BMC.
+
+The values hardcoded are for the ASPEED AST2400.
+"""
+
+import subprocess
+import sys
+
+IO_TOOL = 'devmem'
+PROTECTION_KEY = '0x1E6E2000'
+HWTRAP = '0x1E6E2070'
+# The AST2400 SCU Password (as int for write_register)
+SCU_PASSWORD = 0x1688A8A8
+
+# Bits 13:12
+SPI_MASK = 0xffffcfff
+# Enable SPI Master
+SPI_MASTER = 0x1000
+# Enable SPI Master and SPI Slave to AHB Bridge
+SPI_MASTER_SLAVE = 0x2000
+# Enable SPI Pass-through
+SPI_BYPASS = 0x3000
+
+
+def read_register(address):
+ """Run a tool to read a register value.
+
+ This will convert it to an integer.
+ """
+
+ output = subprocess.check_output([IO_TOOL, address]).replace('\n', '')
+ value = int(output, 16)
+ return value
+
+
+def write_register(address, value):
+ """Run a tool to write the 32-bit register value."""
+
+ subprocess.check_output([IO_TOOL, address, '32', '0x%x' % value])
+ return
+
+
+def set_master(value):
+ """Set Hardware Strapping to SPI Master."""
+
+ print 'Setting to "SPI Master"'
+
+ masked = value & SPI_MASK
+ masked |= SPI_MASTER
+
+ print 'setting: 0x%x' % masked
+ write_register(HWTRAP, masked)
+
+
+def set_ahb_bridge(value):
+ """Set hardware strapping to spi master and spi-slave to ahb."""
+
+ print 'Setting to "SPI Master and SPI Slave to AHB Bridge"'
+ masked = value & SPI_MASK
+ masked |= SPI_MASTER_SLAVE
+
+ print 'setting: 0x%x' % masked
+ write_register(HWTRAP, masked)
+
+
+def set_bypass(value):
+ """Set hardware strappign to spi bypass."""
+
+ print 'Setting to "Enable SPI Pass-through"'
+ masked = value & SPI_MASK
+ masked |= SPI_BYPASS
+
+ print 'setting: 0x%x' % masked
+ write_register(HWTRAP, masked)
+
+
+def usage():
+ """Print usage string."""
+
+ print 'usage: %s master|bridge|bypass' % sys.argv[0]
+ print 'master sets the BMC SPI to Master.'
+ print ('bridge sets the BMC SPI to Master-Slave bridge to AHB (for BIOS ' +
+ 'Update).')
+ print 'bypass sets the BMC SPI to Bypass (default).'
+
+
+def main():
+ """Main entry point for execution."""
+
+ if len(sys.argv) != 2:
+ usage()
+ sys.exit(-1)
+
+ ctrl = sys.argv[1].lower()
+ if ctrl not in ('master', 'bridge', 'bypass'):
+ usage()
+ sys.exit(-1)
+
+ locked = False
+ # Check if locked
+ value = read_register(PROTECTION_KEY)
+ if value == 1:
+ print 'Presently unlocked'
+ else:
+ print 'Presently locked'
+ locked = True
+
+ # if Locked we need to unlock it.
+ if locked:
+ write_register(PROTECTION_KEY, SCU_PASSWORD)
+
+ # Read the value.
+ value = read_register(HWTRAP)
+ if value & SPI_BYPASS == SPI_BYPASS:
+ print 'Presently set to bypass'
+ elif value & SPI_MASTER == SPI_MASTER:
+ print 'Presently set to master'
+ elif value & SPI_MASTER_SLAVE == SPI_MASTER_SLAVE:
+ print 'Presently set to master-slave'
+
+ if ctrl == 'master':
+ set_master(value)
+ elif ctrl == 'bridge':
+ set_ahb_bridge(value)
+ elif ctrl == 'bypass':
+ set_bypass(value)
+
+ # We leave it unlocked in case it was locked.
+ # we could lock it.
+ # TODO(venture): lock it by writing any non-password value.
+
+if __name__ == '__main__':
+ main()
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/spictrl/spictrl.bb b/meta-quanta/meta-q71l/recipes-phosphor/spictrl/spictrl.bb
new file mode 100644
index 000000000..5b2fcf26c
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/spictrl/spictrl.bb
@@ -0,0 +1,19 @@
+# Should RDEPENDS on python at the very least.
+FILESEXTRAPATHS_append := "${THISDIR}/files:"
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://spimaster.py;beginline=1;endline=13;md5=b86c59990b35609be34a0ec322a3cfff"
+
+S = "${WORKDIR}/"
+
+SRC_URI = "file://spimaster.py"
+
+DEPENDS = "python"
+
+FILES_${PN} += "*"
+
+do_install() {
+ install -d ${D}/home
+ install -d ${D}/home/root
+ install -m 0755 ${S}/spimaster.py ${D}/home/root/.
+}
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config.bb b/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config.bb
new file mode 100644
index 000000000..647633f61
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config.bb
@@ -0,0 +1,37 @@
+SUMMARY = "Quanta Q71l board wiring"
+DESCRIPTION = "Board wiring information for the Quanta Q71l system."
+PR = "r1"
+
+inherit allarch
+inherit setuptools
+inherit pythonnative
+inherit obmc-phosphor-license
+
+PROVIDES += "virtual/obmc-inventory-data"
+RPROVIDES_${PN} += "virtual-obmc-inventory-data"
+
+DEPENDS += "python"
+
+S = "${WORKDIR}"
+SRC_URI += "file://Quanta-q71l.py"
+
+# the following is unnecessary.
+python() {
+ machine = d.getVar('MACHINE', True).capitalize() + '.py'
+ d.setVar('_config_in_skeleton', machine)
+}
+
+do_make_setup() {
+ cp ${S}/${_config_in_skeleton} \
+ ${S}/obmc_system_config.py
+ cat <<EOF > ${S}/setup.py
+from distutils.core import setup
+
+setup(name='${BPN}',
+ version='${PR}',
+ py_modules=['obmc_system_config'],
+ )
+EOF
+}
+
+addtask make_setup after do_patch before do_configure
diff --git a/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config/Quanta-q71l.py b/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config/Quanta-q71l.py
new file mode 100644
index 000000000..ca7cb2098
--- /dev/null
+++ b/meta-quanta/meta-q71l/recipes-phosphor/workbook/quanta-q71l-config/Quanta-q71l.py
@@ -0,0 +1,48 @@
+## System states
+## state can change to next state in 2 ways:
+## - a process emits a GotoSystemState signal with state name to goto
+## - objects specified in EXIT_STATE_DEPEND have started
+SYSTEM_STATES = [
+ 'BASE_APPS',
+ 'BMC_STARTING',
+ 'BMC_READY',
+ 'HOST_POWERING_ON',
+ 'HOST_POWERED_ON',
+ 'HOST_BOOTING',
+ 'HOST_BOOTED',
+ 'HOST_POWERED_OFF',
+]
+
+EXIT_STATE_DEPEND = {
+ 'BASE_APPS' : {
+ '/xyz/openbmc_poroject/sensors': 0,
+ },
+ 'BMC_STARTING' : {
+ '/xyz/openbmc_project/control/chassis0': 0,
+ },
+}
+
+FRU_INSTANCES = {}
+
+# I believe these numbers need to match the yaml file used to create the c++ ipmi map.
+# the devices have types, but I don't believe that factors in here, I think these are
+# just unique IDs.
+ID_LOOKUP = {
+ 'FRU' : {},
+ # The number at the end needs to match the FRU ID.
+ # https://github.com/openbmc/skeleton/blob/master/pysystemmgr/system_manager.py#L143
+ # The parameter for it is of type 'y' (unsigned 8-bit integer) presumably decimal?
+ 'FRU_STR' : {},
+ 'SENSOR' : {},
+ 'GPIO_PRESENT' : {}
+}
+
+GPIO_CONFIG = {}
+HWMON_CONFIG = {}
+GPIO_CONFIGS = {}
+
+# Miscellaneous non-poll sensor with system specific properties.
+# The sensor id is the same as those defined in ID_LOOKUP['SENSOR'].
+MISC_SENSORS = {}
+
+# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4
OpenPOWER on IntegriCloud