| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227 |
- {
- "$schema": "https://json-schema.org/draft/2020-12/schema",
- "$id": "prod2u-p4-evidence-v2",
- "title": "Prod2U P4 offline evidence v2",
- "type": "object",
- "required": ["schema", "evidence_id", "campaign_id", "campaign_identity", "round", "identity", "bmc", "layers", "fan", "windows", "raw_samples", "correlation", "rpm", "ptc", "evidence_binding"],
- "properties": {
- "schema": {"const": "prod2u-p4-evidence-v2"},
- "evidence_id": {"type": "string", "minLength": 1},
- "campaign_id": {"type": "string", "minLength": 1},
- "campaign_identity": {"$ref": "#/$defs/identity"},
- "round": {"type": "integer", "minimum": 1, "maximum": 10},
- "identity": {"$ref": "#/$defs/identity"},
- "bmc": {"$ref": "#/$defs/bmc"},
- "layers": {"$ref": "#/$defs/layers"},
- "fan": {"$ref": "#/$defs/fan"},
- "windows": {"$ref": "#/$defs/windows"},
- "raw_samples": {"$ref": "#/$defs/rawSamples"},
- "correlation": {"$ref": "#/$defs/correlation"},
- "rpm": {"$ref": "#/$defs/rpm"},
- "ptc": {"$ref": "#/$defs/ptc"},
- "evidence_binding": {"$ref": "#/$defs/evidenceBinding"}
- },
- "additionalProperties": true,
- "$defs": {
- "identity": {
- "type": "object",
- "required": ["dut_id", "build_id", "bitstream_sha256", "profile"],
- "properties": {
- "dut_id": {"type": "string", "minLength": 1},
- "build_id": {"type": "string", "minLength": 1},
- "bitstream_sha256": {"type": "string", "pattern": "^[0-9a-fA-F]{64}$"},
- "variant": {"enum": ["trace", "normal"]},
- "profile": {"type": "string", "minLength": 1},
- "source_manifest_sha256": {"type": "string", "pattern": "^[0-9a-fA-F]{64}$"},
- "planned_rounds": {"const": 10}
- },
- "additionalProperties": true
- },
- "bmc": {
- "type": "object",
- "required": ["status", "reason"],
- "properties": {
- "status": {"const": "out_of_scope"},
- "reason": {"type": "string", "minLength": 1}
- },
- "additionalProperties": true
- },
- "layerStatus": {"enum": ["pass", "fail", "blocked", "not_run"]},
- "layers": {
- "type": "object",
- "required": ["required", "optional"],
- "properties": {
- "required": {
- "type": "object",
- "required": ["program_sram", "fresh_ready", "host_ack", "pwm_state", "fan3_tach_trend", "timeout_fallback", "disable", "ptc_command_path"],
- "properties": {
- "program_sram": {"$ref": "#/$defs/layerStatus"},
- "fresh_ready": {"$ref": "#/$defs/layerStatus"},
- "host_ack": {"$ref": "#/$defs/layerStatus"},
- "pwm_state": {"$ref": "#/$defs/layerStatus"},
- "fan3_tach_trend": {"$ref": "#/$defs/layerStatus"},
- "timeout_fallback": {"$ref": "#/$defs/layerStatus"},
- "disable": {"$ref": "#/$defs/layerStatus"},
- "ptc_command_path": {"$ref": "#/$defs/layerStatus"}
- },
- "additionalProperties": {"$ref": "#/$defs/layerStatus"}
- },
- "optional": {
- "type": "object",
- "additionalProperties": {"$ref": "#/$defs/layerStatus"}
- }
- },
- "additionalProperties": true
- },
- "fanStatus": {"enum": ["detected", "absent", "intermittent"]},
- "fan": {
- "type": "object",
- "required": ["FAN3"],
- "properties": {
- "FAN3": {
- "type": "object",
- "required": ["FG5", "FG6"],
- "properties": {
- "FG5": {"$ref": "#/$defs/fanStatus"},
- "FG6": {"$ref": "#/$defs/fanStatus"}
- },
- "anyOf": [
- {"properties": {"FG5": {"const": "detected"}}, "required": ["FG5"]},
- {"properties": {"FG6": {"const": "detected"}}, "required": ["FG6"]}
- ],
- "additionalProperties": true
- }
- },
- "additionalProperties": true
- },
- "window": {
- "type": "object",
- "required": ["index", "start_s", "end_s", "continuous", "snapshot_seq", "overflow_mask"],
- "properties": {
- "index": {"type": "integer", "minimum": 0},
- "start_s": {"type": "number"},
- "end_s": {"type": "number"},
- "continuous": {"const": true},
- "snapshot_seq": {"type": "integer", "minimum": 0, "maximum": 4294967295},
- "overflow_mask": {"type": "integer", "minimum": 0, "maximum": 255}
- },
- "additionalProperties": true
- },
- "windows": {"type": "array", "minItems": 42, "maxItems": 42, "items": {"$ref": "#/$defs/window"}},
- "fanSample": {
- "type": "object",
- "required": ["window_edges", "rpm"],
- "properties": {
- "window_edges": {"type": "integer", "minimum": 0},
- "rpm": {"type": "number", "minimum": 0}
- },
- "additionalProperties": true
- },
- "rawSample": {
- "type": "object",
- "required": ["fan_setting_percent", "snapshot_seq", "overflow_mask", "FG5", "FG6"],
- "properties": {
- "fan_setting_percent": {"enum": [0, 20, 40, 60, 80, 100]},
- "snapshot_seq": {"type": "integer", "minimum": 0, "maximum": 4294967295},
- "overflow_mask": {"type": "integer", "minimum": 0, "maximum": 255},
- "FG5": {"$ref": "#/$defs/fanSample"},
- "FG6": {"$ref": "#/$defs/fanSample"}
- },
- "additionalProperties": true
- },
- "rawSamples": {
- "type": "array",
- "minItems": 30,
- "maxItems": 30,
- "items": {"$ref": "#/$defs/rawSample"}
- },
- "correlation": {
- "type": "object",
- "required": ["spearman_rho", "low_mean_rpm", "high_mean_rpm", "high_significantly_higher", "samples"],
- "properties": {
- "spearman_rho": {"type": "number", "minimum": -1, "maximum": 1},
- "low_mean_rpm": {"type": "number", "minimum": 0},
- "high_mean_rpm": {"type": "number", "minimum": 0},
- "high_significantly_higher": {"const": true},
- "samples": {
- "type": "array",
- "minItems": 6,
- "maxItems": 6,
- "items": {
- "type": "object",
- "required": ["fan_setting_percent", "rpm"],
- "properties": {
- "fan_setting_percent": {"type": "number"},
- "rpm": {"type": "number", "minimum": 0}
- },
- "additionalProperties": true
- }
- }
- },
- "additionalProperties": true
- },
- "rpm": {
- "type": "object",
- "required": ["status", "reason"],
- "properties": {
- "status": {"const": "not_qualified"},
- "reason": {"type": "string", "minLength": 1}
- },
- "additionalProperties": true
- },
- "ptc": {
- "type": "object",
- "required": ["actuation", "measurement"],
- "properties": {
- "actuation": {"const": true},
- "measurement": {"const": "not_run"}
- },
- "additionalProperties": true
- },
- "artifactBinding": {
- "type": "object",
- "required": ["path", "sha256"],
- "properties": {
- "path": {"type": "string", "minLength": 1},
- "sha256": {"type": "string", "pattern": "^[0-9a-fA-F]{64}$"},
- "status": {"type": "string"}
- },
- "additionalProperties": true
- },
- "receiptBinding": {
- "allOf": [
- {"$ref": "#/$defs/artifactBinding"},
- {"required": ["status"], "properties": {"status": {"const": "pass"}}}
- ]
- },
- "bindingIdentity": {
- "type": "object",
- "required": ["dut_id", "build_id", "bitstream_sha256", "variant", "profile", "source_manifest_sha256"],
- "properties": {
- "dut_id": {"type": "string", "minLength": 1},
- "build_id": {"type": "string", "minLength": 1},
- "bitstream_sha256": {"type": "string", "pattern": "^[0-9a-fA-F]{64}$"},
- "variant": {"enum": ["trace", "normal"]},
- "profile": {"type": "string", "minLength": 1},
- "source_manifest_sha256": {"type": "string", "pattern": "^[0-9a-fA-F]{64}$"}
- },
- "additionalProperties": true
- },
- "evidenceBinding": {
- "type": "object",
- "required": ["programmer_receipt", "pre_program_raw", "combined_rx_raw", "raw_transcript", "td_receipt", "source_manifest", "package_manifest", "package_inventory", "identity"],
- "properties": {
- "programmer_receipt": {"$ref": "#/$defs/receiptBinding"},
- "pre_program_raw": {"$ref": "#/$defs/artifactBinding"},
- "combined_rx_raw": {"$ref": "#/$defs/artifactBinding"},
- "raw_transcript": {"$ref": "#/$defs/artifactBinding"},
- "td_receipt": {"$ref": "#/$defs/artifactBinding"},
- "source_manifest": {"$ref": "#/$defs/artifactBinding"},
- "package_manifest": {"$ref": "#/$defs/artifactBinding"},
- "package_inventory": {"$ref": "#/$defs/artifactBinding"},
- "identity": {"$ref": "#/$defs/bindingIdentity"}
- },
- "additionalProperties": true
- }
- }
- }
|