MIPS: Whitespace cleanup.
[linux-drm-fsl-dcu.git] / arch / mips / cavium-octeon / executive / cvmx-bootmem.c
index fdf5f19bfdb06226b0296ab52ce1d3b453c1ccdd..504ed61a47cd9e4f2a4c6d57b6091c47f3128787 100644 (file)
@@ -155,8 +155,8 @@ int cvmx_bootmem_init(void *mem_desc_ptr)
         *
         * Linux 64 bit: Set XKPHYS bit
         * Linux 32 bit: use mmap to create mapping, use virtual address
-        * CVMX 64 bit:  use physical address directly
-        * CVMX 32 bit:  use physical address directly
+        * CVMX 64 bit:  use physical address directly
+        * CVMX 32 bit:  use physical address directly
         *
         * Note that the CVMX environment assumes the use of 1-1 TLB
         * mappings so that the physical addresses can be used
@@ -398,7 +398,7 @@ error_out:
 int __cvmx_bootmem_phy_free(uint64_t phy_addr, uint64_t size, uint32_t flags)
 {
        uint64_t cur_addr;
-       uint64_t prev_addr = 0; /* zero is invalid */
+       uint64_t prev_addr = 0; /* zero is invalid */
        int retval = 0;
 
 #ifdef DEBUG
@@ -424,7 +424,7 @@ int __cvmx_bootmem_phy_free(uint64_t phy_addr, uint64_t size, uint32_t flags)
        if (cur_addr == 0 || phy_addr < cur_addr) {
                /* add at front of list - special case with changing head ptr */
                if (cur_addr && phy_addr + size > cur_addr)
-                       goto bootmem_free_done; /* error, overlapping section */
+                       goto bootmem_free_done; /* error, overlapping section */
                else if (phy_addr + size == cur_addr) {
                        /* Add to front of existing first block */
                        cvmx_bootmem_phy_set_next(phy_addr,
@@ -611,7 +611,7 @@ int cvmx_bootmem_phy_named_block_free(char *name, uint32_t flags)
        }
 
        cvmx_bootmem_unlock();
-       return named_block_ptr != NULL; /* 0 on failure, 1 on success */
+       return named_block_ptr != NULL; /* 0 on failure, 1 on success */
 }
 
 int64_t cvmx_bootmem_phy_named_block_alloc(uint64_t size, uint64_t min_addr,
@@ -688,3 +688,8 @@ int64_t cvmx_bootmem_phy_named_block_alloc(uint64_t size, uint64_t min_addr,
                cvmx_spinlock_unlock((cvmx_spinlock_t *)&(cvmx_bootmem_desc->lock));
        return addr_allocated;
 }
+
+struct cvmx_bootmem_desc *cvmx_bootmem_get_desc(void)
+{
+       return cvmx_bootmem_desc;
+}