1 回答

TA貢獻(xiàn)1806條經(jīng)驗(yàn) 獲得超8個(gè)贊
據(jù)此(取自問(wèn)題):
pci_bus 0000:00: root bus resource [mem 0x1000000000-0x10ffffffff] (bus address [0x00000000-0xffffffff])
pci_bus 0000:00: root bus resource [mem 0x1100000000-0x11ffffffff pref] (bus address [0x00000000-0xffffffff])
pci_bus 0000:00: root bus resource [mem 0x2000000000-0x2fffffffff] (bus address [0x00000000-0xfffffffff])
pci_bus 0000:00: root bus resource [mem 0x3000000000-0x3fffffffff pref] (bus address [0x00000000-0xfffffffff])
存儲(chǔ)器地址0x20'0000'0000對(duì)應(yīng)于總線地址0。
因此,如果要使用存儲(chǔ)器地址0x21'0000'0000訪問(wèn)該設(shè)備中的BAR,則需要將其編程為0x1'0000'0000。
同樣,存儲(chǔ)器地址0x10'0000'0000對(duì)應(yīng)于總線地址0。因此,設(shè)備中的BAR被編程為0,可以使用存儲(chǔ)器地址0x10'0000'0000進(jìn)行訪問(wèn)。
添加回答
舉報(bào)