lkml.org 
[lkml]   [1998]   [Nov]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: virt_to_bus and >1G of memory (was MAX_DMA_ADDRESS ...)
    Date
    Followup to:  <199811111858.TAA03864@gloin.fi.muni.cz>
    By author: Jan Kasprzak <kas@informatics.muni.cz>
    In newsgroup: linux.dev.kernel
    >
    >
    > In my previous mail I wrote:
    > : And another question related to the virt_to_bus on x86:
    > : This function is defined as (x) & ~PAGE_OFFSET. It works for the current
    > : value of the PAGE_OFFSET, but IMHO it does not work when I change the
    > : PAGE_OFFSET to 0x70000000, as suggested in <asm-i386/page.h> for >1GB RAM
    > : machines. Shouldn't the virt_to_bus be defined as (x)-PAGE_OFFSET ?
    > : The physical memory is mapped 1:1 from the PAGE_OFFSET virtual address, IIRC.
    >
    > Can anybody explain this to me? Is (x)-PAGE_OFFSET at any chance
    > slower or less efficient than (x)&~PAGE_OFFSET?
    >

    They are different if PAGE_OFFSET isn't a power of 2.

    -hpa
    --
    PGP: 2047/2A960705 BA 03 D3 2C 14 A8 A8 BD 1E DF FE 69 EE 35 BD 74
    See http://www.zytor.com/~hpa/ for web page and full PGP public key
    I am Bahá'í -- ask me about it or see http://www.bahai.org/
    "To love another person is to see the face of God." -- Les Misérables

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:45    [W:0.021 / U:60.160 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site