ref: d1604b5f9ce1d64919a8b8313e1db22ebd8d5213
parent: 96e9f3707cdc0b76e019f444c24869fecc7b5a21
author: cinap_lenrek <cinap_lenrek@felloff.net>
date: Sun Oct 18 13:02:42 EDT 2020
sdnvme: use PCIWADDR() instead of PADDR()
--- a/sys/src/9/pc/sdnvme.c
+++ b/sys/src/9/pc/sdnvme.c
@@ -127,7 +127,7 @@
e[2] = 0;
e[3] = 0;
if(mptr != nil){
- pa = PADDR(mptr);
+ pa = PCIWADDR(mptr);
e[4] = pa;
e[5] = pa>>32;
} else {
@@ -135,7 +135,7 @@
e[5] = 0;
}
if(len > 0){
- pa = PADDR(data);
+ pa = PCIWADDR(data);
e[6] = pa;
e[7] = pa>>32;
if(len > ctlr->mps - (pa & ctlr->mps-1))
@@ -531,11 +531,11 @@
return 0;
}
- pa = PADDR(cqalloc(ctlr, &ctlr->cq[0], ctlr->mpsshift));
+ pa = PCIWADDR(cqalloc(ctlr, &ctlr->cq[0], ctlr->mpsshift));
ctlr->reg[ACQBase0] = pa;
ctlr->reg[ACQBase1] = pa>>32;
- pa = PADDR(sqalloc(ctlr, &ctlr->sq[0], ctlr->mpsshift));
+ pa = PCIWADDR(sqalloc(ctlr, &ctlr->sq[0], ctlr->mpsshift));
ctlr->reg[ASQBase0] = pa;
ctlr->reg[ASQBase1] = pa>>32;