From patchwork Wed Jul 18 08:13:23 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Hans Verkuil (hansverk)" X-Patchwork-Id: 1209311 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id B45E9DFFFD for ; Wed, 18 Jul 2012 08:23:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753050Ab2GRIXa (ORCPT ); Wed, 18 Jul 2012 04:23:30 -0400 Received: from ams-iport-2.cisco.com ([144.254.224.141]:22257 "EHLO ams-iport-2.cisco.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751315Ab2GRIX1 (ORCPT ); Wed, 18 Jul 2012 04:23:27 -0400 X-Greylist: delayed 578 seconds by postgrey-1.27 at vger.kernel.org; Wed, 18 Jul 2012 04:23:26 EDT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=hansverk@cisco.com; l=2339; q=dns/txt; s=iport; t=1342599807; x=1343809407; h=from:to:subject:date:cc:mime-version:message-id; bh=V4RXa1euiHb9vwey7ra66RrsMjpxqA53R8EmhqwVQAc=; b=UiRMn9ilGXO7lR2uRZymO8vaqcGbNVj7agBHEDIubWwwcLw7p9xwaeay LgYUdnDaETn/XJmjDmNU/NYyR0ol9zsP7nz0LG4WBTNnrZ0FkAIEDGY80 ExBhHVbMqzs+/jRp7aB4hfoxM7a96btaYBfKBb1RShDfeVX2alSg2AX8p I=; X-Files: 0001-v4l2-dev-forgot-to-add-VIDIOC_DV_TIMINGS_CAP.patch : 1314 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EAL9uBlCQ/khM/2dsb2JhbABFuSiBB4IgAQIWAWYsAwECfg4TIodrnXmgI4tAhk8DiBaGOYZuiSiEeoFmgmE X-IronPort-AV: E=Sophos;i="4.77,608,1336348800"; d="scan'208,223";a="75378082" Received: from ams-core-3.cisco.com ([144.254.72.76]) by ams-iport-2.cisco.com with ESMTP; 18 Jul 2012 08:13:47 +0000 Received: from cobaltpc1.localnet (dhcp-10-54-92-107.cisco.com [10.54.92.107]) by ams-core-3.cisco.com (8.14.5/8.14.5) with ESMTP id q6I8DliU015240; Wed, 18 Jul 2012 08:13:47 GMT From: Hans Verkuil Organization: Cisco Systems Norway To: Linus Torvalds Subject: [PATCH for 3.5] v4l2-dev: forgot to add VIDIOC_DV_TIMINGS_CAP. Date: Wed, 18 Jul 2012 10:13:23 +0200 User-Agent: KMail/1.13.7 (Linux/3.3-0.slh.4-aptosid-amd64; KDE/4.7.4; x86_64; ; ) Cc: "linux-media" , "'Mauro Carvalho Chehab'" MIME-Version: 1.0 X-Length: 3444 X-UID: 566 Message-Id: <201207181013.23597.hansverk@cisco.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Hi Linus, I'm sending the attached one-liner patch directly to you for inclusion in 3.5 as without it the new VIDIOC_DV_TIMINGS_CAP ioctl doesn't work. The cause was that for 3.5 two patch series were merged, one changing V4L2 core ioctl handling and one adding new functionality, and some of the new functionality wasn't handled by the new V4L2 core code. Mauro is still on a well-deserved vacation, so I'm sending it to you directly so it can be merged for 3.5 before it is released. Regards, Hans From 3a9fa27511a2ed13a24ed431879557ddb3ca406b Mon Sep 17 00:00:00 2001 Message-Id: <3a9fa27511a2ed13a24ed431879557ddb3ca406b.1342592537.git.hans.verkuil@cisco.com> From: Hans Verkuil Date: Wed, 11 Jul 2012 14:12:45 +0200 Subject: [PATCH 1/2] v4l2-dev: forgot to add VIDIOC_DV_TIMINGS_CAP. The VIDIOC_DV_TIMINGS_CAP ioctl check wasn't added to determine_valid_ioctls(). This caused this ioctl to always return -ENOTTY. Signed-off-by: Hans Verkuil --- drivers/media/video/v4l2-dev.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/media/video/v4l2-dev.c b/drivers/media/video/v4l2-dev.c index 83dbb2d..0cbada1 100644 --- a/drivers/media/video/v4l2-dev.c +++ b/drivers/media/video/v4l2-dev.c @@ -681,6 +681,7 @@ static void determine_valid_ioctls(struct video_device *vdev) SET_VALID_IOCTL(ops, VIDIOC_G_DV_TIMINGS, vidioc_g_dv_timings); SET_VALID_IOCTL(ops, VIDIOC_ENUM_DV_TIMINGS, vidioc_enum_dv_timings); SET_VALID_IOCTL(ops, VIDIOC_QUERY_DV_TIMINGS, vidioc_query_dv_timings); + SET_VALID_IOCTL(ops, VIDIOC_DV_TIMINGS_CAP, vidioc_dv_timings_cap); /* yes, really vidioc_subscribe_event */ SET_VALID_IOCTL(ops, VIDIOC_DQEVENT, vidioc_subscribe_event); SET_VALID_IOCTL(ops, VIDIOC_SUBSCRIBE_EVENT, vidioc_subscribe_event); -- 1.7.10.4