MCPcopy Create free account
hub / github.com/BlitterStudio/amiberry / gvp_ide_controller_autoconfig_init

Function gvp_ide_controller_autoconfig_init

src/idecontrollers.cpp:2405–2424  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2403}
2404
2405bool gvp_ide_controller_autoconfig_init(struct autoconfig_info *aci)
2406{
2407 ide_add_reset();
2408 if (!aci->doinit) {
2409 aci->autoconfigp = gvp_ide2_controller_autoconfig;
2410 return true;
2411 }
2412 struct ide_board *ide = getide(aci);
2413
2414 init_ide(ide, GVP_IDE, 2, true, false);
2415 ide->configured = 0;
2416 ide->bank = &gvp_ide_controller_bank;
2417 memset(ide->acmemory, 0xff, sizeof ide->acmemory);
2418 for (int i = 0; i < 16; i++) {
2419 uae_u8 b = gvp_ide2_controller_autoconfig[i];
2420 ew(ide, i * 4, b);
2421 }
2422 aci->addrbank = ide->bank;
2423 return true;
2424}
2425
2426void gvp_add_ide_unit(int ch, struct uaedev_config_info *ci, struct romconfig *rc)
2427{

Callers

nothing calls this directly

Calls 4

ide_add_resetFunction · 0.85
getideFunction · 0.85
init_ideFunction · 0.85
ewFunction · 0.70

Tested by

no test coverage detected