aboutsummaryrefslogtreecommitdiffstats
path: root/drmtest.c
diff options
context:
space:
mode:
Diffstat (limited to 'drmtest.c')
-rw-r--r--drmtest.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/drmtest.c b/drmtest.c
index b014ed2..95cb9f1 100644
--- a/drmtest.c
+++ b/drmtest.c
@@ -354,6 +354,7 @@ static void usage(FILE *fp)
" -h print this\n"
" -c <nr> pick card\n"
" -o <name> pick output\n"
+ " -s <secs> set sleep time\n"
" -g openngl mode\n"
#if 0
" -d debug mode (opengl)\n"
@@ -364,18 +365,22 @@ static void usage(FILE *fp)
int main(int argc, char **argv)
{
int card = 0;
+ int secs = 10;
bool gl = false;
char *output = NULL;
int c;
for (;;) {
- c = getopt(argc, argv, "hgdc:o:");
+ c = getopt(argc, argv, "hgdc:s:o:");
if (c == -1)
break;
switch (c) {
case 'c':
card = atoi(optarg);
break;
+ case 's':
+ secs = atoi(optarg);
+ break;
case 'o':
output = optarg;
break;
@@ -408,7 +413,7 @@ int main(int argc, char **argv)
drm_draw_dumb_fb();
}
drm_show_fb();
- sleep(3);
+ sleep(secs);
drm_fini_dev();
return 0;
}