Skip to content

Commit

Permalink
lkl: increase the memory size for KASAN test
Browse files Browse the repository at this point in the history
Our kasan tests need more memory otherwise the kernel reports OOM
(out-of-memory) error during the test.  This commit increase the size of
memory for the test.

For the disk-vfio-pci test, we don't increase as it hits another issue
if we increase in the same way (16M=>32M).

Reported-by: Eugene Rodionov <[email protected]>
Reported-by: Octavian Purdila <[email protected]>
Signed-off-by: Hajime Tazaki <[email protected]>
  • Loading branch information
thehajime committed Jun 23, 2023
1 parent e88a85a commit 567eacc
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tools/lkl/tests/boot.c
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ static int lkl_test_kasan(void)
#define KASAN_CMD_LINE
#endif

#define CMD_LINE "mem=16M loglevel=8 " KASAN_CMD_LINE
#define CMD_LINE "mem=32M loglevel=8 " KASAN_CMD_LINE

static int lkl_test_start_kernel(void)
{
Expand Down
2 changes: 1 addition & 1 deletion tools/lkl/tests/disk.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ static int lkl_test_readdir(void)

LKL_TEST_CALL(closedir, lkl_closedir, 0, dir);
LKL_TEST_CALL(chdir_mnt_point, lkl_sys_chdir, 0, mnt_point);
LKL_TEST_CALL(start_kernel, lkl_start_kernel, 0, "mem=16M loglevel=8");
LKL_TEST_CALL(start_kernel, lkl_start_kernel, 0, "mem=32M loglevel=8");
LKL_TEST_CALL(stop_kernel, lkl_sys_halt, 0);

struct lkl_test tests[] = {
Expand Down
2 changes: 1 addition & 1 deletion tools/lkl/tests/net-test.c
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,7 @@ static int lkl_test_nd_remove(void)
}

LKL_TEST_CALL(start_kernel, lkl_start_kernel, 0,
"mem=16M loglevel=8 %s", cla.dhcp ? "ip=dhcp" : "");
"mem=32M loglevel=8 %s", cla.dhcp ? "ip=dhcp" : "");
LKL_TEST_CALL(stop_kernel, lkl_sys_halt, 0);

static int nd_ifindex;
Expand Down

0 comments on commit 567eacc

Please sign in to comment.