Skip to content
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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Feature/l4test enhancement #140

wants to merge 3 commits into from

Conversation

louisom
Copy link
Contributor

@louisom louisom commented Nov 20, 2016

  • Update IPC test cases
  • Add KIP test cases
  • Add mem test cases

int check_kipptr(L4_KernelInterfacePage_t *kip, void * ptr)
{
if (((L4_Word_t)kip + (1 << kip->KipAreaInfo.X.s) >= (L4_Word_t)ptr)
&& (ptr >= (void *) kip))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check coding style.

#include "assert.h"

__USER_TEXT
int check_kipptr(L4_KernelInterfacePage_t *kip, void * ptr)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We prefer void *ptr over void * ptr.

__USER_DATA
kid_list_t kid_list[] =
{
{ 0, 0, "F9", "NCKU" },
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

F9 is an independent project from NCKU.

} kid_list_t;

__USER_DATA
kid_list_t kid_list[] =
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't really want to implement full KernelInformation support. Use dummy array instead.

print_uline(const char *msg, char c)
{
int i, len = strlen(msg);
/*
* TODO: Why can't we use strlen, the string memory was
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment of not intuition.

} else {
if ((L4_ErrorCode() & 0x1) == 0 ||
((L4_ErrorCode() >> 1) & 0x7) != 1) {
printf ("RCV: Incorrect error code: %s %s\n",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use consistent coding style.

@@ -0,0 +1,39 @@
/* Copyright (c) 2002, 2003, 2007, 2010 Karlsruhe University.
Copy link
Member

Choose a reason for hiding this comment

The 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.

#include <l4/types.h>
#include <l4/ipc.h>
#include <l4io.h>
#include <platform/cortex_m.h>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the <platform/cortex_m.h> required?

printf("test: Welcome to memtest!\n");

while (max--) {
// *addr = 0x37ULL;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't leave the dead code.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants