Skip to content
Snippets Groups Projects
Select Git revision
0 results

util.c

Blame
    • Kumar Gala's avatar
      e7563aff
      fsl-ddr: Fix handling of >4G of memory when !CONFIG_PHYS_64BIT · e7563aff
      Kumar Gala authored
      
      The ddr code computes most things as 64-bit quantities and had some places
      in the middle that it was using phy_addr_t and phys_size_t.
      
      Instead we use unsigned long long through out and only at the last stage of
      setting the LAWs and reporting the amount of memory to the board code do we
      truncate down to what we can cover via phys_size_t.
      
      This has the added benefit that the DDR controller itself is always setup
      the same way regardless of how much memory we have.  Its only the LAW
      setup that limits what is visible to the system.
      
      Signed-off-by: default avatarKumar Gala <galak@kernel.crashing.org>
      e7563aff
      History
      fsl-ddr: Fix handling of >4G of memory when !CONFIG_PHYS_64BIT
      Kumar Gala authored
      
      The ddr code computes most things as 64-bit quantities and had some places
      in the middle that it was using phy_addr_t and phys_size_t.
      
      Instead we use unsigned long long through out and only at the last stage of
      setting the LAWs and reporting the amount of memory to the board code do we
      truncate down to what we can cover via phys_size_t.
      
      This has the added benefit that the DDR controller itself is always setup
      the same way regardless of how much memory we have.  Its only the LAW
      setup that limits what is visible to the system.
      
      Signed-off-by: default avatarKumar Gala <galak@kernel.crashing.org>