aboutsummaryrefslogtreecommitdiff
path: root/pa1_syscalls_lkms/csci3753_mult_test.c
blob: 116737a30c2300ff0f28c56bd78edc2cba1eafdf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#define SYS_CALL_NUM 463

int main(int argc, char **argv) {
  if (argc < 3)
    exit(-1);
  int a = atoi(argv[1]), b = atoi(argv[2]);
  long c, res = syscall(SYS_CALL_NUM, a, b, &c);
  printf("%d * %d = %ld\n", a, b, c);
  exit(res);
}