Skip to contentSkip to conversation

is_xen_swiotlb_buffer() vs CONFIG_HIGHMEM

DISCUSSION Jan Beulich 2 participants 3 messages Dec 14, 2009 – Dec 16, 2009

lore
Share & tools
lore
#0 lore raw

Jeremy,

shouldn't is_xen_swiotlb_buffer() also check against e.g. highstart_pfn to deal with wrap-around potentially leading to aliasing of [xen_io_tlb_start,xen_io_tlb_end)?

Jan

#1 lore raw
Quoted 4 lines · Jan Beulich

shouldn't is_xen_swiotlb_buffer() also check against e.g. highstart_pfn to deal with wrap-around potentially leading to aliasing of [xen_io_tlb_start,xen_io_tlb_end)?

So what you're saying is that if the pfn is for a high page, then "__va(pfn << PAGE_SHIFT);" is simply invalid. The resulting addr is undefined, and may end up erroneously aliasing with the xen tlb buffer.

Do I understand your concern properly?

J

#2 lore raw
Quoted 7 lines
Quoted 1 line
Quoted 1 line

Jeremy Fitzhardinge <[email protected]> 15.12.09 19:34 >>>

Quoted 4 lines · Jan Beulich

shouldn't is_xen_swiotlb_buffer() also check against e.g. highstart_pfn to deal with wrap-around potentially leading to aliasing of [xen_io_tlb_start,xen_io_tlb_end)?

Quoted 5 lines

So what you're saying is that if the pfn is for a high page, then "__va(pfn << PAGE_SHIFT);" is simply invalid. The resulting addr is undefined, and may end up erroneously aliasing with the xen tlb buffer.

Do I understand your concern properly?

Yes.

Jan