Skip to content

Commit 34ff2e9

Browse files
Merge pull request #249 from Telecominfraproject/ocware_alert_host
Host code for alert
2 parents eb22ea8 + a9af083 commit 34ff2e9

18 files changed

Lines changed: 2498 additions & 617 deletions

firmware/ec/platform/oc-sdr/schema/auto_schema.c

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,7 @@ SCHEMA_IMPORT const DriverStruct fact_sdr_fpga_adt7481_cfg;
141141
SCHEMA_IMPORT const DriverStruct fact_sdr_fpga_ps_cfg;
142142
SCHEMA_IMPORT const DriverStruct fact_sync_ts_cfg;
143143

144+
SCHEMA_IMPORT bool alert_log(void *, void *);
144145
SCHEMA_IMPORT bool GPP_ap_Reset(void *, void *);
145146
SCHEMA_IMPORT bool gpp_post_init(void *, void *);
146147
SCHEMA_IMPORT bool gpp_pre_init(void *, void *);
@@ -167,7 +168,6 @@ const Component sys_schema[] = {
167168
.name = "system",
168169
.driver_cfg = &gbc_spi_flash_memory,
169170
.ssHookSet = &(SSHookSet) {
170-
.preInitFxn = NULL,
171171
.postInitFxn = (ssHook_Cb)sys_post_init,
172172
},
173173
.components = (Component[]) {
@@ -206,6 +206,10 @@ const Component sys_schema[] = {
206206
.name = "echo",
207207
.cb_cmd = SYS_cmdEcho,
208208
},
209+
{
210+
.name = "getAlertLogs",
211+
.cb_cmd = alert_log,
212+
},
209213
{}
210214
},
211215
},
@@ -226,6 +230,13 @@ const Component sys_schema[] = {
226230
},
227231
{}
228232
},
233+
.commands = (Command[]) {
234+
{
235+
.name = "getAlertLogs",
236+
.cb_cmd = alert_log,
237+
},
238+
{}
239+
},
229240
},
230241
{
231242
.name = "leadacid_sensor",
@@ -283,6 +294,13 @@ const Component sys_schema[] = {
283294
{
284295
.name = "comp_all",
285296
.postDisabled = POST_DISABLED,
297+
.commands = (Command[]) {
298+
{
299+
.name = "getAlertLogs",
300+
.cb_cmd = alert_log,
301+
},
302+
{}
303+
},
286304
},
287305
{
288306
.name = "ec",
@@ -321,6 +339,13 @@ const Component sys_schema[] = {
321339
{
322340
.name = "comp_all",
323341
.postDisabled = POST_DISABLED,
342+
.commands = (Command[]) {
343+
{
344+
.name = "getAlertLogs",
345+
.cb_cmd = alert_log,
346+
},
347+
{}
348+
},
324349
},
325350
{
326351
.name = "led",
@@ -354,6 +379,13 @@ const Component sys_schema[] = {
354379
{
355380
.name = "comp_all",
356381
.postDisabled = POST_DISABLED,
382+
.commands = (Command[]) {
383+
{
384+
.name = "getAlertLogs",
385+
.cb_cmd = alert_log,
386+
},
387+
{}
388+
},
357389
},
358390
{
359391
.name = "port0",
@@ -409,6 +441,13 @@ const Component sys_schema[] = {
409441
{
410442
.name = "comp_all",
411443
.postDisabled = POST_DISABLED,
444+
.commands = (Command[]) {
445+
{
446+
.name = "getAlertLogs",
447+
.cb_cmd = alert_log,
448+
},
449+
{}
450+
},
412451
},
413452
{
414453
.name = "ap",
@@ -445,6 +484,10 @@ const Component sys_schema[] = {
445484
.name = "reset",
446485
.cb_cmd = GPP_ap_Reset,
447486
},
487+
{
488+
.name = "getAlertLogs",
489+
.cb_cmd = alert_log,
490+
},
448491
{}
449492
},
450493
},
@@ -493,6 +536,10 @@ const Component sys_schema[] = {
493536
.name = "reset",
494537
.cb_cmd = SDR_reset,
495538
},
539+
{
540+
.name = "getAlertLogs",
541+
.cb_cmd = alert_log,
542+
},
496543
{}
497544
},
498545
},
@@ -554,6 +601,10 @@ const Component sys_schema[] = {
554601
.name = "reset",
555602
.cb_cmd = RFFE_reset,
556603
},
604+
{
605+
.name = "getAlertLogs",
606+
.cb_cmd = alert_log,
607+
},
557608
{}
558609
},
559610
},
@@ -708,6 +759,10 @@ const Component sys_schema[] = {
708759
.name = "reset",
709760
.cb_cmd = SYNC_reset,
710761
},
762+
{
763+
.name = "getAlertLogs",
764+
.cb_cmd = alert_log,
765+
},
711766
{}
712767
},
713768
.postDisabled = POST_DISABLED,

0 commit comments

Comments
 (0)