All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: linux-omap@vger.kernel.org
Cc: sakari.ailus@maxwell.research.nokia.com
Subject: [RFC/PATCH v3 1/7] v4l: subdev: Generic ioctl support
Date: Thu, 25 Nov 2010 03:54:32 +0100	[thread overview]
Message-ID: <1290653678-15556-2-git-send-email-laurent.pinchart@ideasonboard.com> (raw)
In-Reply-To: <1290653678-15556-1-git-send-email-laurent.pinchart@ideasonboard.com>

Instead of returning an error when receiving an ioctl call with an
unsupported command, forward the call to the subdev core::ioctl handler.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
---
 Documentation/video4linux/v4l2-framework.txt |    5 +++++
 drivers/media/video/v4l2-subdev.c            |    2 +-
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/Documentation/video4linux/v4l2-framework.txt b/Documentation/video4linux/v4l2-framework.txt
index d0fb880..1bb5f22 100644
--- a/Documentation/video4linux/v4l2-framework.txt
+++ b/Documentation/video4linux/v4l2-framework.txt
@@ -407,6 +407,11 @@ VIDIOC_UNSUBSCRIBE_EVENT
 	To properly support events, the poll() file operation is also
 	implemented.
 
+Private ioctls
+
+	All ioctls not in the above list are passed directly to the sub-device
+	driver through the core::ioctl operation.
+
 
 I2C sub-device drivers
 ----------------------
diff --git a/drivers/media/video/v4l2-subdev.c b/drivers/media/video/v4l2-subdev.c
index 438c70f..b57be91 100644
--- a/drivers/media/video/v4l2-subdev.c
+++ b/drivers/media/video/v4l2-subdev.c
@@ -267,7 +267,7 @@ static long subdev_do_ioctl(struct file *file, unsigned int cmd, void *arg)
 	}
 #endif
 	default:
-		return -ENOIOCTLCMD;
+		return v4l2_subdev_call(sd, core, ioctl, cmd, arg);
 	}
 
 	return 0;
-- 
1.7.2.2


  reply	other threads:[~2010-11-25  2:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-25  2:54 [RFC/PATCH v3 0/7] OMAP3 ISP driver Laurent Pinchart
2010-11-25  2:54 ` Laurent Pinchart [this message]
2010-11-25  2:54 ` [RFC/PATCH v3 2/7] v4l: Remove module_name argument to the v4l2_i2c_new_subdev* functions Laurent Pinchart
2010-11-25  2:54 ` [RFC/PATCH v3 3/7] v4l: Add subdev sensor g_skip_frames operation Laurent Pinchart
2010-11-25  2:54 ` [RFC/PATCH v3 4/7] v4l: Include linux/videodev2.h in media/v4l2-ctrls.h Laurent Pinchart
2010-11-25  2:54 ` [RFC/PATCH v3 5/7] ARM: OMAP3: Update Camera ISP definitions for OMAP3630 Laurent Pinchart
2010-12-06 19:30   ` Tony Lindgren
2010-11-25  2:54 ` [RFC/PATCH v3 6/7] omap3: Export omap3isp platform device structure Laurent Pinchart
2010-11-25  7:02   ` Felipe Balbi
2010-11-25 11:17     ` Laurent Pinchart
2010-11-25 11:23       ` Felipe Balbi
2010-12-06 19:32         ` Tony Lindgren
2010-12-10  1:12           ` Laurent Pinchart
2010-11-25  7:03   ` Felipe Balbi

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=1290653678-15556-2-git-send-email-laurent.pinchart@ideasonboard.com \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=sakari.ailus@maxwell.research.nokia.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.