[Skiboot] [PATCH 7/7] platform: add zaius
Oliver O'Halloran
oohall at gmail.com
Fri Jan 13 17:56:22 AEDT 2017
WMWWMMMMMMWWMWMWMMMMMMMMMWWWMWMMMWMMWWWMWWWWWMWWWWWWWWWWMMWW
WWKKWWWMMW0kXWWWMMMMMMMMMK wWWK ONW xW WW WWWN WW
WWl xWWWl KWMMMMMMMMMXkkx .WWX k kWX lWW WN WWN KWW
MWl x XMWl O OMMMMMMMMMMMMk OMWK oWk kMX lWW WN WW xWWW
MWl NK WWl XK WWWMMMMMMWWW WWWK oWk kMX lWW WN WW 0MMM
WWl NW NWl XN WWWMMWMMWWW0 .WWWK oWk xMX lWW WN WWX WWM
WWl NN NMl Ko kWWWWWNNNNNN KNNN0 lNx xWX lWW WN WWW dWW
WWl K xNNc L xXXXXXXXXXXO XXXXO lNo dX0 cXX XX NNWW WW
XXc xXXXc kO KXXXXXXXXX OXXXXO l0o dX0 :XX KK XXXX KN
XXo:kKXXXXl 0K KXXXXXXXX0 KXO oXx xX XXd dXXx oXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXxxXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXNNWWWWNNNXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXNNXK00NNWWNNWWWNXXXXXXXXXXXXXXXXXXXXXXX0o
XXXXXXXXXXXXXXXXXNNXOOO0XNXNNNXNWWWNXXXXXXXXXXXXXXXXXXXXKdcc
XXXXXXXXXXXXXXXXNNKOOOk00XkxXNWWNKNWNXXXXXXXXXXXXXXXXX0dcccc
XXXXXXXXXXXKXXXNWX00OOOO0OdloodKK0KWWNXXXXXXXXXXXXXXkocccccc
XXXXXXXXXXXk0XNNKOOOdollokxlokkOOxOXWNXXXXXXXXXXXXKocccccccc
KXXXXXXXXXXdkNX00O0ko:. ,ccc,..cKK0NNNXXXXXXXXXXOlccccccccc
0kOXXXXXXXKlON00O00Oo, ,lo; 'x0KWNNXXXXXXXXXkccccccccccc
XKxox0XXXX0OWKOOO000Oxllodxxkdlldk0XWNNNXXXXXXKdcccccccccccc
XXX0dcdkxdkWWK0OO00K0xlooooxkOkk0O0XWNNNXXXXXKoccccccccccccc
KXXXXkccccdKNNX0KKK00dlllllllokKWXKNWWWNXXXX0occcccccccccccc
dOKXKl:::::ONKKKXdO000xoooooodOKWNXWWWWNOO0klccccccccccccccc
cccll::::::cl;cKk :OKNXkxxxkk0KKNWNWWWWNxoollcldlccccccccccc
:::::::c:::;;;;:x oXWN0XWWWWXXNWWWWNWNKkdxllllxOxooooooollc
::;:doooooc;;;' ' .0WWXNWWWWKNKKWWNdkkdddddcllokOkxxxxxdxxx
::;ldlllod:;:;. ,doOWNWWNXX.cW0dcclddddxoccloOOxdxxdxxkk
;;;cdooodl;::, . .,:d0O;, ;:.ccc:cddddxl:clxOkxxxxkkkx
;;;oxlolo;;::. .ccc:ldxdddccllOkxxkxxkkx
;;;oooddl,::;. .l:c:oxdddlc::oxoxkxoc::
;;;ooddd:;::' .l:c;odxdd:;;cxxko;;;;;
;,;ollol;:;:. ;l;;:xoool;;;xxd:,,,,,
Signed-off-by: Oliver O'Halloran <oohall at gmail.com>
---
platforms/astbmc/Makefile.inc | 2 +-
platforms/astbmc/zaius.c | 53 +++++++++++++++++++++++++++++++++++++++++++
2 files changed, 54 insertions(+), 1 deletion(-)
create mode 100644 platforms/astbmc/zaius.c
diff --git a/platforms/astbmc/Makefile.inc b/platforms/astbmc/Makefile.inc
index 0830b3eba7e3..9affb5dedec6 100644
--- a/platforms/astbmc/Makefile.inc
+++ b/platforms/astbmc/Makefile.inc
@@ -1,6 +1,6 @@
SUBDIRS += $(PLATDIR)/astbmc
-ASTBMC_OBJS = palmetto.o habanero.o firestone.o p8dtu.o garrison.o barreleye.o pnor.o common.o slots.o
+ASTBMC_OBJS = palmetto.o habanero.o firestone.o p8dtu.o garrison.o barreleye.o pnor.o common.o slots.o zaius.o
ASTBMC = $(PLATDIR)/astbmc/built-in.o
$(ASTBMC): $(ASTBMC_OBJS:%=$(PLATDIR)/astbmc/%)
diff --git a/platforms/astbmc/zaius.c b/platforms/astbmc/zaius.c
new file mode 100644
index 000000000000..7770d07525b2
--- /dev/null
+++ b/platforms/astbmc/zaius.c
@@ -0,0 +1,53 @@
+/* Copyright 2017 IBM Corp.
+ *
+ * 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.
+ */
+
+#include <skiboot.h>
+#include <device.h>
+#include <console.h>
+#include <chip.h>
+#include <ipmi.h>
+#include <psi.h>
+#include <npu-regs.h>
+
+#include "astbmc.h"
+
+static bool zaius_probe(void)
+{
+ if (!dt_node_is_compatible(dt_root, "ingrasys,zaius"))
+ return false;
+
+ /* Lot of common early inits here */
+ astbmc_early_init();
+ psi_set_external_irq_policy(EXTERNAL_IRQ_POLICY_LINUX);
+
+ return true;
+}
+
+DECLARE_PLATFORM(zaius_platform) = {
+ .name = "Zaius",
+ .probe = zaius_probe,
+ .init = astbmc_init,
+ .start_preload_resource = flash_start_preload_resource,
+ .resource_loaded = flash_resource_loaded,
+ .bmc = NULL, /* FIXME: Add openBMC */
+ .pci_get_slot_info = slot_table_get_slot_info,
+ .pci_probe_complete = check_all_slot_table,
+ .cec_power_down = astbmc_ipmi_power_down,
+ .cec_reboot = astbmc_ipmi_reboot,
+ .elog_commit = ipmi_elog_commit,
+ .exit = ipmi_wdt_final_reset,
+ .terminate = ipmi_terminate,
+};
--
2.7.4
More information about the Skiboot
mailing list