intel_gtt: Fix PTE offsets

Vincent sent me a patch which I think didn't go far enough.

Honestly, I don't even know what this tool does.

Reported-by: Cheah, Vincent Beng Keat <vincent.beng.keat.cheah@intel.com>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
This commit is contained in:
Ben Widawsky 2013-02-04 17:47:53 -08:00
parent f9c8e365e9
commit f5c3e5811e

View File

@ -70,10 +70,10 @@ int main(int argc, char **argv)
break;
} else {
int offset;
if (IS_G4X(devid) || IS_GEN5(devid))
offset = MB(2);
else
if (IS_GEN4(devid))
offset = KB(512);
else
offset = MB(2);
if (pci_device_map_range(pci_dev,
pci_dev->regions[0].base_addr + offset,
offset,