From: Laurent Pinchart Date: Thu, 2 Mar 2017 19:47:36 +0000 (+0200) Subject: py: db.py: Add command line argument to specify connector X-Git-Url: https://git.ti.com/gitweb?p=android%2Fexternal-libkmsxx.git;a=commitdiff_plain;h=c02a6e019ef4f2a77fcbde67a720221c7f37225e py: db.py: Add command line argument to specify connector When a command line argument is present, its value is used as a connector name that the script will try to use. Signed-off-by: Laurent Pinchart Signed-off-by: Tomi Valkeinen --- diff --git a/py/tests/db.py b/py/tests/db.py index f0a962d..eb31669 100755 --- a/py/tests/db.py +++ b/py/tests/db.py @@ -56,10 +56,14 @@ class FlipHandler(pykms.PageFlipHandlerBase): else: crtc.page_flip(fb, self) +if len(sys.argv) > 1: + conn_name = sys.argv[1] +else: + conn_name = '' card = pykms.Card() res = pykms.ResourceManager(card) -conn = res.reserve_connector() +conn = res.reserve_connector(conn_name) crtc = res.reserve_crtc(conn) mode = conn.get_default_mode()