All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
To: m silverstri <michael.j.silverstri@gmail.com>
Cc: Devin Heitmueller <dheitmueller@kernellabs.com>,
	linux-media <linux-media@vger.kernel.org>
Subject: Re: How can I find out what is the driver for device node '/dev/video11'
Date: Wed, 08 Jan 2014 22:19:01 +0100	[thread overview]
Message-ID: <52CDC0C5.6010109@gmail.com> (raw)
In-Reply-To: <CABMudhTjgXpitX83K2x6_Lyse=Rts0h+t-9LZpUNCAV8yacOJw@mail.gmail.com>

On 01/08/2014 08:15 PM, m silverstri wrote:
> Thanks.
>
> I am studying android source code.
>  From here,  it has code which open("/dev/video11", O_RDWR, 0) as
> decoding device.
>
> http://androidxref.com/4.4.2_r1/xref/hardware/samsung_slsi/exynos5/libhwjpeg/ExynosJpegBase.cpp

What you're looking for might be this proprietary Samsung JPEG codec driver
used in Android.

https://android.googlesource.com/kernel/exynos/+/android-exynos-3.4/drivers/media/video/exynos/jpeg/

If you intend to use mainline kernel you need to consider the s5p-jpeg 
driver,
which exposes to user space standard interface without any proprietary 
additions
incompatible with the V4L2 spec.

> I want to find out which is the corresponding driver code for device
> '/dev/video11'.

I suspect these numbers are fixed in the Android kernel (they are hard
coded in the user space library as you're pointing out above), which is
a pretty bad practice.

It's better to use VIDIOC_QUERYCAP ioctl to find a video device with
specific name, as Devin suggested. You can also find a video device
exposed by a specific driver through sysfs, as is done in
exynos_v4l2_open_devname() function in this a bit less hacky code:

https://android.googlesource.com/platform/hardware/samsung_slsi/exynos5/+/jb-mr1-release/libv4l2/exynos_v4l2.c

Thanks,
Sylwester

  reply	other threads:[~2014-01-08 21:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-08 18:50 How can I find out what is the driver for device node '/dev/video11' m silverstri
2014-01-08 18:56 ` Devin Heitmueller
2014-01-08 19:03   ` m silverstri
2014-01-08 19:08     ` Devin Heitmueller
2014-01-08 19:15       ` m silverstri
2014-01-08 21:19         ` Sylwester Nawrocki [this message]
2014-01-08 21:43           ` m silverstri

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=52CDC0C5.6010109@gmail.com \
    --to=sylvester.nawrocki@gmail.com \
    --cc=dheitmueller@kernellabs.com \
    --cc=linux-media@vger.kernel.org \
    --cc=michael.j.silverstri@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.