From patchwork Wed Dec 9 10:12:16 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 65968 X-Patchwork-Delegate: dougsland@redhat.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nB9AAsVI005765 for ; Wed, 9 Dec 2009 10:10:54 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754418AbZLIKKr (ORCPT ); Wed, 9 Dec 2009 05:10:47 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754446AbZLIKKq (ORCPT ); Wed, 9 Dec 2009 05:10:46 -0500 Received: from perceval.irobotique.be ([92.243.18.41]:38389 "EHLO perceval.irobotique.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754418AbZLIKKq (ORCPT ); Wed, 9 Dec 2009 05:10:46 -0500 Received: from ravenclaw.localnet (235.21-245-81.adsl-static.isp.belgacom.be [81.245.21.235]) by perceval.irobotique.be (Postfix) with ESMTPSA id 5A68F35AE9; Wed, 9 Dec 2009 10:10:50 +0000 (UTC) From: Laurent Pinchart To: Mauro Carvalho Chehab Subject: [PATCH] Use dev->bus_id instead of dev_name in pre 2.6.26 kernels Date: Wed, 9 Dec 2009 11:12:16 +0100 User-Agent: KMail/1.12.4 (Linux/2.6.31.6; KDE/4.3.4; x86_64; ; ) Cc: linux-media@vger.kernel.org MIME-Version: 1.0 Message-Id: <200912091112.16352.laurent.pinchart@ideasonboard.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org diff -r 065f9e34e07b linux/include/media/v4l2-dev.h --- a/linux/include/media/v4l2-dev.h Mon Dec 07 10:08:33 2009 -0200 +++ b/linux/include/media/v4l2-dev.h Wed Dec 09 11:04:51 2009 +0100 @@ -156,8 +156,12 @@ #if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 19) return vdev->dev.class_id; #else +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 26) + return vdev->dev.bus_id; +#else return dev_name(&vdev->dev); #endif +#endif } static inline int video_is_registered(struct video_device *vdev)