From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from lb1-smtp-cloud2.xs4all.net ([194.109.24.21]:35878 "EHLO lb1-smtp-cloud2.xs4all.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751378AbbEHKqK (ORCPT ); Fri, 8 May 2015 06:46:10 -0400 Message-ID: <554C93DE.2010205@xs4all.nl> Date: Fri, 08 May 2015 12:45:50 +0200 From: Hans Verkuil MIME-Version: 1.0 To: Kamil Debski , dri-devel@lists.freedesktop.org, linux-media@vger.kernel.org CC: m.szyprowski@samsung.com, mchehab@osg.samsung.com, kyungmin.park@samsung.com, thomas@tommie-lie.de, sean@mess.org, dmitry.torokhov@gmail.com, linux-input@vger.kernel.org, linux-samsung-soc@vger.kernel.org, lars@opdenkamp.eu, Hans Verkuil Subject: Re: [PATCH v6 07/11] DocBook/media: add CEC documentation References: <1430760785-1169-1-git-send-email-k.debski@samsung.com> <1430760785-1169-8-git-send-email-k.debski@samsung.com> In-Reply-To: <1430760785-1169-8-git-send-email-k.debski@samsung.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-media-owner@vger.kernel.org List-ID: Hi Kamil, A few more comments about the documentation: First of all you should add some documentation about what the passthrough mode actually is. Right now all this says is that you can enable or disable it, but not what it actually does. And next I have a few small comments about the timestamp documentation: > diff --git a/Documentation/DocBook/media/v4l/cec-ioc-g-event.xml b/Documentation/DocBook/media/v4l/cec-ioc-g-event.xml > new file mode 100644 > index 0000000..cbde320 > --- /dev/null > +++ b/Documentation/DocBook/media/v4l/cec-ioc-g-event.xml > @@ -0,0 +1,125 @@ ... > + > + Description > + > + CEC devices can send asynchronous events. These can be retrieved by calling > + the CEC_G_EVENT ioctl. If the file descriptor is in non-blocking > + mode and no event is pending, then it will return -1 and set errno to the &EAGAIN;. > + > + There can be up to 40 events queued up. If more events are added, then the oldest event will be discarded. > + > + > + struct <structname>cec_event</structname> > + > + &cs-str; > + > + > + __u64 > + ts > + Timestamp of the event in ns. "Timestamp of the event in ns. This is based on the monotonic clock. Applications can access this clock using clock_gettime(2) with clock ID CLOCK_MONOTONIC. To turn this into a struct timespec use: struct timespec tmspec; tmspec.tv_sec = ts / 1000000000; tmspec.tv_nsec = ts % 1000000000; " (I hope the docbook syntax for programlisting is correct) > diff --git a/Documentation/DocBook/media/v4l/cec-ioc-receive.xml b/Documentation/DocBook/media/v4l/cec-ioc-receive.xml > new file mode 100644 > index 0000000..dbec20a > --- /dev/null > +++ b/Documentation/DocBook/media/v4l/cec-ioc-receive.xml > @@ -0,0 +1,185 @@ ... > +
> + struct <structname>cec_msg</structname> > + > + &cs-str; > + > + > + __u64 > + ts > + Timestamp of when the message was transmitted in ns in the case > + of CEC_TRANSMIT with reply > + set to 0, or the timestamp of the received message in all other cases. The same timestamp explanation should be given here. Regards, Hans