From patchwork Fri Mar 26 07:06:42 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Guennadi Liakhovetski X-Patchwork-Id: 88434 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2Q76iY7027940 for ; Fri, 26 Mar 2010 07:06:44 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751362Ab0CZHGn (ORCPT ); Fri, 26 Mar 2010 03:06:43 -0400 Received: from mail.gmx.net ([213.165.64.20]:51337 "HELO mail.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1751171Ab0CZHGm (ORCPT ); Fri, 26 Mar 2010 03:06:42 -0400 Received: (qmail invoked by alias); 26 Mar 2010 07:06:40 -0000 Received: from p57BD1E91.dip0.t-ipconnect.de (EHLO axis700.grange) [87.189.30.145] by mail.gmx.net (mp036) with SMTP; 26 Mar 2010 08:06:40 +0100 X-Authenticated: #20450766 X-Provags-ID: V01U2FsdGVkX18tAZ4r3+gtJeqVNE+ksqXhuDSqQB3wFNGgcrd+b5 v+DdZOXyRzT2G6 Received: from lyakh (helo=localhost) by axis700.grange with local-esmtp (Exim 4.63) (envelope-from ) id 1Nv3cw-0001FP-9F for linux-media@vger.kernel.org; Fri, 26 Mar 2010 08:06:42 +0100 Date: Fri, 26 Mar 2010 08:06:42 +0100 (CET) From: Guennadi Liakhovetski To: Linux Media Mailing List Subject: [PATCH] V4L: fix ENUMSTD ioctl to report all supported standards Message-ID: MIME-Version: 1.0 X-Y-GMX-Trusted: 0 X-FuHaFi: 0.53000000000000003 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Fri, 26 Mar 2010 07:06:44 +0000 (UTC) diff --git a/drivers/media/video/v4l2-ioctl.c b/drivers/media/video/v4l2-ioctl.c index 4b11257..2389df0 100644 --- a/drivers/media/video/v4l2-ioctl.c +++ b/drivers/media/video/v4l2-ioctl.c @@ -1065,9 +1065,7 @@ static long __video_do_ioctl(struct file *file, j++; if (curr_id == 0) break; - if (curr_id != V4L2_STD_PAL && - curr_id != V4L2_STD_SECAM && - curr_id != V4L2_STD_NTSC) + if (is_power_of_2(curr_id)) id &= ~curr_id; } if (i <= index)