MCPcopy Create free account
hub / github.com/F-Stack/f-stack / aw_sid_read

Function aw_sid_read

freebsd/arm/allwinner/aw_sid.c:343–362  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341}
342
343static int
344aw_sid_read(device_t dev, uint32_t offset, uint32_t size, uint8_t *buffer)
345{
346 struct aw_sid_softc *sc;
347 enum aw_sid_fuse_id fuse_id = 0;
348 int i;
349
350 sc = device_get_softc(dev);
351
352 for (i = 0; i < sc->sid_conf->nfuses; i++)
353 if (offset == sc->sid_conf->efuses[i].offset) {
354 fuse_id = sc->sid_conf->efuses[i].id;
355 break;
356 }
357
358 if (fuse_id == 0)
359 return (ENOENT);
360
361 return (aw_sid_get_fuse(fuse_id, buffer, &size));
362}
363
364static int
365aw_sid_sysctl(SYSCTL_HANDLER_ARGS)

Callers

nothing calls this directly

Calls 2

device_get_softcFunction · 0.85
aw_sid_get_fuseFunction · 0.85

Tested by

no test coverage detected