Home
last modified time | relevance | path

Searched refs:sga (Results 1 – 8 of 8) sorted by relevance

/sys/kern/
Dsga.c12 SGArray_Init(SGArray *sga) in SGArray_Init() argument
14 sga->len = 0; in SGArray_Init()
18 SGArray_Append(SGArray *sga, uint64_t off, uint64_t len) in SGArray_Append() argument
20 ASSERT(sga->len < SGARRAY_MAX_ENTRIES) in SGArray_Append()
22 sga->entries[sga->len].offset = off; in SGArray_Append()
23 sga->entries[sga->len].length = len; in SGArray_Append()
24 sga->len++; in SGArray_Append()
26 return sga->len; in SGArray_Append()
30 SGArray_Dump(SGArray *sga) in SGArray_Dump() argument
35 for (i = 0; i < sga->len; i++) in SGArray_Dump()
[all …]
Ddisk.c44 Disk_Read(Disk *disk, void *buf, SGArray *sga, DiskCB cb, void *arg) in Disk_Read() argument
46 return disk->read(disk, buf, sga, cb, arg); in Disk_Read()
50 Disk_Write(Disk *disk, void *buf, SGArray *sga, DiskCB cb, void *arg) in Disk_Write() argument
52 return disk->write(disk, buf, sga, cb, arg); in Disk_Write()
56 Disk_Flush(Disk *disk, void *buf, SGArray *sga, DiskCB cb, void *arg) in Disk_Flush() argument
58 return disk->flush(disk, buf, sga, cb, arg); in Disk_Flush()
80 SGArray sga; in Debug_DumpDisk() local
93 sga.len = 1; in Debug_DumpDisk()
94 sga.entries[0].offset = sector; in Debug_DumpDisk()
95 sga.entries[0].length = 512; in Debug_DumpDisk()
[all …]
Dbufcache.c233 SGArray sga; in BufCache_Read() local
251 SGArray_Init(&sga); in BufCache_Read()
252 SGArray_Append(&sga, diskOffset, BLOCKSIZE); in BufCache_Read()
258 status = Disk_Read(disk, buf, &sga, NULL, NULL); in BufCache_Read()
276 SGArray sga; in BufCache_Write() local
278 SGArray_Init(&sga); in BufCache_Write()
279 SGArray_Append(&sga, entry->diskOffset, BLOCKSIZE); in BufCache_Write()
281 return Disk_Write(entry->disk, buf, &sga, NULL, NULL); in BufCache_Write()
/sys/include/
Dsga.h19 void SGArray_Init(SGArray *sga);
20 int SGArray_Append(SGArray *sga, uint64_t off, uint64_t len);
21 void SGArray_Dump(SGArray *sga);
Ddisk.h27 int Disk_Read(Disk *disk, void * buf, SGArray *sga, DiskCB cb, void *arg);
28 int Disk_Write(Disk *disk, void * buf, SGArray *sga, DiskCB cb, void *arg);
29 int Disk_Flush(Disk *disk, void * buf, SGArray *sga, DiskCB cb, void *arg);
/sys/dev/x86/
Dide.c76 int IDE_Read(Disk *disk, void *buf, SGArray *sga, DiskCB, void *arg);
77 int IDE_Write(Disk *disk, void *buf, SGArray *sga, DiskCB, void *arg);
78 int IDE_Flush(Disk *disk, void *buf, SGArray *sga, DiskCB, void *arg);
271 IDE_Read(Disk *disk, void *buf, SGArray *sga, DiskCB cb, void *arg) in IDE_Read() argument
279 for (i = 0; i < sga->len; i++) { in IDE_Read()
282 sga->entries[i].offset / 512, in IDE_Read()
283 sga->entries[i].length / 512); in IDE_Read()
284 buf += sga->entries[i].length; in IDE_Read()
293 IDE_Write(Disk *disk, void *buf, SGArray *sga, DiskCB cb, void *arg) in IDE_Write() argument
301 for (i = 0; i < sga->len; i++) { in IDE_Write()
[all …]
/sys/dev/
Dahci.c254 AHCI_IssueCommand(AHCI *ahci, int port, SGArray *sga, void *cfis, int len) in AHCI_IssueCommand() argument
266 for (i = 0; i < sga->len; i++) in AHCI_IssueCommand()
268 ct->prdt[i].dba = sga->entries[i].offset; in AHCI_IssueCommand()
269 ct->prdt[i].descInfo = sga->entries[i].length - 1; in AHCI_IssueCommand()
271 ASSERT(sga->entries[i].length % 2 == 0); in AHCI_IssueCommand()
276 cl->cmds[0].prdtl = sga->len; in AHCI_IssueCommand()
302 SGArray sga; in AHCI_IdentifyPort() local
313 sga.len = 1; in AHCI_IdentifyPort()
315 sga.entries[0].offset = (uintptr_t)&ident; in AHCI_IdentifyPort()
316 sga.entries[0].length = 512; in AHCI_IdentifyPort()
[all …]
/sys/
DSConscript59 "kern/sga.c",