MCPcopy Create free account
hub / github.com/coreboot/coreboot / mei_dump

Function mei_dump

util/intelmetool/src/me.c:34–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32static uint8_t* mei_mmap;
33
34static void mei_dump(void *ptr, int dword, int offset, const char *type)
35{
36 /* struct mei_csr *csr; */
37
38
39 switch (offset) {
40 case MEI_H_CSR:
41 case MEI_ME_CSR_HA:
42/*
43 csr = ptr;
44 if (!csr) {
45 printf("%-9s[%02x] : ", type, offset);
46 printf("ERROR: 0x%08x\n", dword);
47 break;
48 }
49 printf("%-9s[%02x] : ", type, offset);
50 printf("depth=%u read=%02u write=%02u ready=%u "
51 "reset=%u intgen=%u intstatus=%u intenable=%u\n",
52 csr->buffer_depth, csr->buffer_read_ptr,
53 csr->buffer_write_ptr, csr->ready, csr->reset,
54 csr->interrupt_generate, csr->interrupt_status,
55 csr->interrupt_enable);
56*/
57 break;
58 case MEI_ME_CB_RW:
59 case MEI_H_CB_WW:
60 printf("%-9s[%02x] : ", type, offset);
61 printf("CB: 0x%08x\n", dword);
62 break;
63 default:
64 printf("%-9s[%02x] : ", type, offset);
65 printf("0x%08x\n", offset);
66 break;
67 }
68}
69
70/*
71 * ME/MEI access helpers using memcpy to avoid aliasing.

Callers 5

mei_read_dword_ptrFunction · 0.70
mei_write_dword_ptrFunction · 0.70
pci_read_dword_ptrFunction · 0.70
write_cbFunction · 0.70
read_cbFunction · 0.70

Calls 1

printfFunction · 0.85

Tested by

no test coverage detected