-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/l4test enhancement #140
base: master
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,5 +6,6 @@ user-apps-l4test-y = \ | |
string.o \ | ||
ipc.o \ | ||
kip.o \ | ||
mem.o \ | ||
assert.o \ | ||
main.o \ |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
/* Copyright (c) 2002, 2003, 2007, 2010 Karlsruhe University. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You should replace the copyright notice with F9 Microkernel project since it is ARM Cortex-M specific. |
||
* All rights reserved. | ||
* Use of this source code is governed by a BSD-style license that can be | ||
* found in the LICENSE file. | ||
*/ | ||
|
||
#include <l4/types.h> | ||
#include <l4/ipc.h> | ||
#include <l4io.h> | ||
#include <platform/cortex_m.h> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is the |
||
|
||
#include "arch.h" | ||
#include "config.h" | ||
#include "l4test.h" | ||
#include "assert.h" | ||
|
||
__USER_TEXT | ||
static void page_touch(void) | ||
{ | ||
volatile L4_Word_t *addr = (L4_Word_t *) get_new_page(); | ||
int n = 0; | ||
int max = 1000; | ||
|
||
printf("test: Welcome to memtest!\n"); | ||
|
||
while (max--) { | ||
// *addr = 0x37ULL; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Don't leave the dead code. |
||
addr += (PAGE_SIZE / sizeof(*addr)); | ||
n++; | ||
} | ||
|
||
print_result("Page touch", true); | ||
} | ||
|
||
__USER_TEXT | ||
void all_mem_tests(void) | ||
{ | ||
page_touch(); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use consistent coding style.