Release 4.10 arch/s390/mm/mem_detect.c
/*
* Copyright IBM Corp. 2008, 2009
*
* Author(s): Heiko Carstens <heiko.carstens@de.ibm.com>
*/
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/memblock.h>
#include <linux/init.h>
#include <linux/debugfs.h>
#include <linux/seq_file.h>
#include <asm/ipl.h>
#include <asm/sclp.h>
#include <asm/setup.h>
#define CHUNK_READ_WRITE 0
#define CHUNK_READ_ONLY 1
static inline void memblock_physmem_add(phys_addr_t start, phys_addr_t size)
{
memblock_add_range(&memblock.memory, start, size, 0, 0);
memblock_add_range(&memblock.physmem, start, size, 0, 0);
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
philipp hachtmann | philipp hachtmann | 41 | 91.11% | 1 | 33.33% |
heiko carstens | heiko carstens | 4 | 8.89% | 2 | 66.67% |
| Total | 45 | 100.00% | 3 | 100.00% |
void __init detect_memory_memblock(void)
{
unsigned long memsize, rnmax, rzm, addr, size;
int type;
rzm = sclp.rzm;
rnmax = sclp.rnmax;
memsize = rzm * rnmax;
if (!rzm)
rzm = 1UL << 17;
max_physmem_end = memsize;
addr = 0;
/* keep memblock lists close to the kernel */
memblock_set_bottom_up(true);
do {
size = 0;
type = tprot(addr);
do {
size += rzm;
if (max_physmem_end && addr + size >= max_physmem_end)
break;
} while (type == tprot(addr + size));
if (type == CHUNK_READ_WRITE || type == CHUNK_READ_ONLY) {
if (max_physmem_end && (addr + size > max_physmem_end))
size = max_physmem_end - addr;
memblock_physmem_add(addr, size);
}
addr += size;
} while (addr < max_physmem_end);
memblock_set_bottom_up(false);
if (!max_physmem_end)
max_physmem_end = memblock_end_of_DRAM();
}
Contributors
| Person | Tokens | Prop | Commits | CommitProp |
heiko carstens | heiko carstens | 134 | 77.46% | 6 | 66.67% |
philipp hachtmann | philipp hachtmann | 31 | 17.92% | 1 | 11.11% |
david hildenbrand | david hildenbrand | 6 | 3.47% | 1 | 11.11% |
michael holzheu | michael holzheu | 2 | 1.16% | 1 | 11.11% |
| Total | 173 | 100.00% | 9 | 100.00% |
Overall Contributors
| Person | Tokens | Prop | Commits | CommitProp |
heiko carstens | heiko carstens | 153 | 60.24% | 6 | 60.00% |
philipp hachtmann | philipp hachtmann | 92 | 36.22% | 1 | 10.00% |
david hildenbrand | david hildenbrand | 6 | 2.36% | 1 | 10.00% |
michael holzheu | michael holzheu | 2 | 0.79% | 1 | 10.00% |
hans-joachim picht | hans-joachim picht | 1 | 0.39% | 1 | 10.00% |
| Total | 254 | 100.00% | 10 | 100.00% |
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.