1
2
3
7
8
9
10
11
12
13
14
15
18
19
20
21
25
26
27
28
29
30
31
32
33
/* ... */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "jep106.h"
#include "log.h"
static const char * const jep106[][126] = {
#include "jep106.inc"
...};
const char *jep106_table_manufacturer(unsigned int bank, unsigned int id)
{
if (id < 1 || id > 126) {
LOG_DEBUG("BUG: Caller passed out-of-range JEP106 ID!");
return "<invalid>";
}if (id < 1 || id > 126) { ... }
id--;
if (bank >= ARRAY_SIZE(jep106) || !jep106[bank][id])
return "<unknown>";
return jep106[bank][id];
}{ ... }