aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/firmware/iscsi_ibft_find.c
diff options
context:
space:
mode:
authorJan Beulich <JBeulich@novell.com>2009-10-02 11:12:39 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-10-05 15:05:40 -0400
commited3c661448a1b4b0b07c0a0d3c6e8a19c7d0ffd7 (patch)
treeddf42bb3a23d51a836f5faf6ffd88f0a4f7508e5 /drivers/firmware/iscsi_ibft_find.c
parent41cb6654eb2cf01476223a3742946b9f65bd1bbd (diff)
iSCSI/iBFT: use proper address translation
In virtual environments (namely, Xen Dom0) virt <-> phys and virt <-> isa-bus translations cannot be freely interchanged (and even outside such environments it is not really correct to do so). When looking at memory below 1M, the latter translations should always be used. iscsi_ibft_find.c part from: Martin Wilck <martin.wilck@ts.fujitsu.com>. Signed-off-by: Jan Beulich <jbeulich@novell.com> Signed-off-by: Peter Jones <pjones@redhat.com> Signed-off-by: Konrad Rzeszutek Wilk <ketuzsezs@darnok.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/firmware/iscsi_ibft_find.c')
-rw-r--r--drivers/firmware/iscsi_ibft_find.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/firmware/iscsi_ibft_find.c b/drivers/firmware/iscsi_ibft_find.c
index d53fbbfefa3e..dfb15c06c88f 100644
--- a/drivers/firmware/iscsi_ibft_find.c
+++ b/drivers/firmware/iscsi_ibft_find.c
@@ -65,10 +65,10 @@ void __init reserve_ibft_region(void)
65 * so skip that area */ 65 * so skip that area */
66 if (pos == VGA_MEM) 66 if (pos == VGA_MEM)
67 pos += VGA_SIZE; 67 pos += VGA_SIZE;
68 virt = phys_to_virt(pos); 68 virt = isa_bus_to_virt(pos);
69 if (memcmp(virt, IBFT_SIGN, IBFT_SIGN_LEN) == 0) { 69 if (memcmp(virt, IBFT_SIGN, IBFT_SIGN_LEN) == 0) {
70 unsigned long *addr = 70 unsigned long *addr =
71 (unsigned long *)phys_to_virt(pos + 4); 71 (unsigned long *)isa_bus_to_virt(pos + 4);
72 len = *addr; 72 len = *addr;
73 /* if the length of the table extends past 1M, 73 /* if the length of the table extends past 1M,
74 * the table cannot be valid. */ 74 * the table cannot be valid. */