Cleanup AtomicReq::commit
authorTomi Valkeinen <tomi.valkeinen@ti.com>
Sun, 22 May 2016 12:42:14 +0000 (15:42 +0300)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Mon, 23 May 2016 06:43:27 +0000 (09:43 +0300)
libkms++/atomicreq.cpp
libkms++/atomicreq.h
py/pykms.cpp
tests/kmscapture.cpp

index f2aa322019552dd1a354b6b811533b1d66aee77c..0e627a84aab03bf6d31e15e8c3d0d06c63d3efba 100644 (file)
@@ -63,13 +63,6 @@ int AtomicReq::test()
        return drmModeAtomicCommit(m_card.fd(), m_req, flags, 0);
 }
 
-int AtomicReq::commit()
-{
-       uint32_t flags = 0;
-
-       return drmModeAtomicCommit(m_card.fd(), m_req, flags, 0);
-}
-
 int AtomicReq::commit(void* data)
 {
        uint32_t flags = DRM_MODE_PAGE_FLIP_EVENT | DRM_MODE_ATOMIC_NONBLOCK;
index 7a8f2a47969856f6de25a9b8e5c01ac78031d028..d9aeb08e8036df481fb01b7b638fd376b21970db 100644 (file)
@@ -23,7 +23,6 @@ public:
        void add(DrmObject *ob, const std::string& prop, uint64_t value);
 
        int test();
-       int commit();
        int commit(void* data);
        int commit_sync();
 
index 7e42e4fe6642b80e4cb255e86a8c4eb170550315..c31d5ce48a797e44f919b6b4fd774182807c2886 100644 (file)
@@ -127,8 +127,7 @@ PYBIND11_PLUGIN(pykms) {
                             py::keep_alive<1, 2>())    // Keep Card alive until this is destructed
                        .def("add", (void (AtomicReq::*)(DrmObject*, const string&, uint64_t)) &AtomicReq::add)
                        .def("test", &AtomicReq::test)
-                       .def("commit", (int (AtomicReq::*)()) &AtomicReq::commit)
-                       .def("commit", (int (AtomicReq::*)(void*)) &AtomicReq::commit)
+                       .def("commit", &AtomicReq::commit)
                        .def("commit_sync", &AtomicReq::commit_sync)
                        ;
 
index ff62678fda407f66dcfd921f319f3131c22420f7..ee700b7970fd1ab8d4cb7e63a4ff9126eb156980 100644 (file)
@@ -427,7 +427,7 @@ int main(int argc, char** argv)
                r = req.test();
                FAIL_IF(r, "Atomic commit failed: %d", r);
 
-               req.commit();
+               req.commit_sync();
        }
 
        for (auto cam : cameras)