From patchwork Thu Jul 19 12:00:20 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans Verkuil X-Patchwork-Id: 1216311 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 578783FC33 for ; Thu, 19 Jul 2012 12:01:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751663Ab2GSMA7 (ORCPT ); Thu, 19 Jul 2012 08:00:59 -0400 Received: from ams-iport-3.cisco.com ([144.254.224.146]:21746 "EHLO ams-iport-3.cisco.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750707Ab2GSMAy (ORCPT ); Thu, 19 Jul 2012 08:00:54 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=hans.verkuil@cisco.com; l=944; q=dns/txt; s=iport; t=1342699254; x=1343908854; h=from:to:cc:subject:date:message-id; bh=IIxRUsDDFjNGOZ18BZxABGdO/gfcwkQeQM4vCncYhi4=; b=Yc0ch7qRcdBtDQraAq0oyeeZxRihdKM+P/0n1h3iXksS7dMYz6d1nvSc Slb4gbiggVEdOesBkJKH5LVOaujQG6qxn6d185s4RqAnV5yGMUmr+424W 9ksRqQLb7eCHrFgeB9iZRyJZQhYIuHrddtv2rJ8baR/EBI5GVg+YkXTrH Y=; X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av0EAF32B1CQ/khN/2dsb2JhbABFuUCBB4IhAQEEEgEUUhBRVxkih2ueO6AGj0CDHAOVRIkphHqBZoJh X-IronPort-AV: E=Sophos;i="4.77,615,1336348800"; d="scan'208";a="6750890" Received: from ams-core-4.cisco.com ([144.254.72.77]) by ams-iport-3.cisco.com with ESMTP; 19 Jul 2012 12:00:51 +0000 Received: from cobaltpc1.cisco.com (dhcp-10-54-92-107.cisco.com [10.54.92.107]) by ams-core-4.cisco.com (8.14.5/8.14.5) with ESMTP id q6JC0pxs030906; Thu, 19 Jul 2012 12:00:51 GMT From: Hans Verkuil To: linux-media@vger.kernel.org Cc: Pawel Osciak , Marek Szyprowski Subject: [RFC PATCH 2/6] mem2mem_testdev: set bus_info and device_caps. Date: Thu, 19 Jul 2012 14:00:20 +0200 Message-Id: <8e6829023ea338cee205b6e27aee75a008e97454.1342699069.git.hans.verkuil@cisco.com> X-Mailer: git-send-email 1.7.10 In-Reply-To: <1342699224-12642-1-git-send-email-hans.verkuil@cisco.com> References: <1342699224-12642-1-git-send-email-hans.verkuil@cisco.com> In-Reply-To: <903c0da0d6e7354d6f884f0ddec783143165e54c.1342699069.git.hans.verkuil@cisco.com> References: <903c0da0d6e7354d6f884f0ddec783143165e54c.1342699069.git.hans.verkuil@cisco.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Signed-off-by: Hans Verkuil --- drivers/media/video/mem2mem_testdev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/media/video/mem2mem_testdev.c b/drivers/media/video/mem2mem_testdev.c index a1d5c15..fe8c565 100644 --- a/drivers/media/video/mem2mem_testdev.c +++ b/drivers/media/video/mem2mem_testdev.c @@ -427,10 +427,10 @@ static int vidioc_querycap(struct file *file, void *priv, { strncpy(cap->driver, MEM2MEM_NAME, sizeof(cap->driver) - 1); strncpy(cap->card, MEM2MEM_NAME, sizeof(cap->card) - 1); - cap->bus_info[0] = 0; - cap->capabilities = V4L2_CAP_VIDEO_CAPTURE | V4L2_CAP_VIDEO_OUTPUT + strlcpy(cap->bus_info, MEM2MEM_NAME, sizeof(cap->bus_info)); + cap->device_caps = V4L2_CAP_VIDEO_CAPTURE | V4L2_CAP_VIDEO_OUTPUT | V4L2_CAP_STREAMING; - + cap->capabilities = cap->device_caps | V4L2_CAP_DEVICE_CAPS; return 0; }