drivers/accessibility/speakup/makemapdata.c
Source file repositories/reference/linux-study-clean/drivers/accessibility/speakup/makemapdata.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/accessibility/speakup/makemapdata.c- Extension
.c- Size
- 2783 bytes
- Lines
- 128
- Domain
- Driver Families
- Bucket
- drivers/accessibility
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
stdlib.hstdio.hlibgen.hstring.hctype.hutils.h
Detected Declarations
function get_definefunction main
Annotated Snippet
if (strlen(def_val) > 5) {
//if (def_val[0] == '(')
// def_val++;
cp = strchr(def_val, '+');
if (!cp)
continue;
if (cp[-1] == ' ')
cp[-1] = '\0';
*cp++ = '\0';
this = find_key(def_val);
while (*cp == ' ')
cp++;
if (!this || *cp < '0' || *cp > '9')
continue;
value = this->value+atoi(cp);
} else if (!strncmp(def_val, "0x", 2))
sscanf(def_val+2, "%x", &value);
else if (*def_val >= '0' && *def_val <= '9')
value = atoi(def_val);
else
continue;
add_key(def_name, value, is_spk);
}
printf("struct st_key_init init_key_data[] = {\n");
for (i = 0; i < HASHSIZE; i++) {
this = &key_table[i];
if (!this->name)
continue;
do {
printf("\t{ \"%s\", %d, %d, },\n", this->name, this->value, this->shift);
this = this->next;
} while (this);
}
printf("\t{ \".\", 0, 0 }\n};\n");
exit(0);
}
Annotation
- Immediate include surface: `stdlib.h`, `stdio.h`, `libgen.h`, `string.h`, `ctype.h`, `utils.h`.
- Detected declarations: `function get_define`, `function main`.
- Atlas domain: Driver Families / drivers/accessibility.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.