6 static struct option longopts[] = {
7 { "open", no_argument, NULL, 'o' },
8 { "close", no_argument, NULL, 'c' },
9 { "dump", no_argument, NULL, 'd' },
16 void usage(int argc, char **argv)
18 printf("Usage: %s [ --dump ] [ --open | --close ]\n",
23 int main(int argc, char **argv)
27 printf("This program must be run as root, dumbass.\n");
34 while ((ch = getopt_long(argc, argv, "ocsd:", longopts, NULL)) != -1)
39 if (op & OP_SET) usage(argc, argv);
44 if (op & OP_SET) usage(argc, argv);
55 if (!op) usage(argc, argv);
64 smram_aseg_set_state(do_open);