174 |
{ |
{ |
175 |
l4_fpage_t fpages[MAX_FPAGES]; |
l4_fpage_t fpages[MAX_FPAGES]; |
176 |
unsigned int nr_fpages; |
unsigned int nr_fpages; |
177 |
l4_word_t start = mods[MOD_PHYSMEM].start; |
l4_word_t size = (mods[MOD_PHYSMEM].end - mods[MOD_PHYSMEM].start |
178 |
l4_word_t size = (mods[MOD_PHYSMEM].end - start + min_page_size) |
+ min_page_size - 1) & ~(min_page_size - 1); |
|
& ~(min_page_size - 1); |
|
179 |
|
|
180 |
/* We want to grant all the memory for the physmem binary image |
/* We want to grant all the memory for the physmem binary image |
181 |
with the first page fault, but we might have to send several |
with the first page fault, but we might have to send several |
182 |
fpages. So we first create a list of all fpages we need, then |
fpages. So we first create a list of all fpages we need, then |
183 |
we serve one after another, providing the one containing the |
we serve one after another, providing the one containing the |
184 |
fault address last. */ |
fault address last. */ |
185 |
nr_fpages = make_fpages (start, size, fpages); |
nr_fpages = make_fpages (mods[MOD_PHYSMEM].start, size, |
186 |
|
fpages); |
187 |
|
|
188 |
/* Now serve page requests. */ |
/* Now serve page requests. */ |
189 |
while (nr_fpages) |
while (nr_fpages) |