From patchwork Tue Nov 24 18:41:57 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hilman X-Patchwork-Id: 62548 X-Patchwork-Delegate: paul@pwsan.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 nAOIg6Ev026251 for ; Tue, 24 Nov 2009 18:42:06 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933785AbZKXSl7 (ORCPT ); Tue, 24 Nov 2009 13:41:59 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S933768AbZKXSl7 (ORCPT ); Tue, 24 Nov 2009 13:41:59 -0500 Received: from mail-ew0-f215.google.com ([209.85.219.215]:56834 "EHLO mail-ew0-f215.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932245AbZKXSl6 (ORCPT ); Tue, 24 Nov 2009 13:41:58 -0500 Received: by ewy7 with SMTP id 7so43884ewy.28 for ; Tue, 24 Nov 2009 10:42:03 -0800 (PST) Received: by 10.216.93.14 with SMTP id k14mr2042080wef.152.1259088122478; Tue, 24 Nov 2009 10:42:02 -0800 (PST) Received: from localhost ([216.254.16.51]) by mx.google.com with ESMTPS id i34sm12599298gve.6.2009.11.24.10.42.00 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 24 Nov 2009 10:42:01 -0800 (PST) From: Kevin Hilman To: linux-omap@vger.kernel.org Subject: [PATCH] OMAP: omap_device: add to_omap_device() macro Date: Tue, 24 Nov 2009 10:41:57 -0800 Message-Id: <1259088117-25834-1-git-send-email-khilman@deeprootsystems.com> X-Mailer: git-send-email 1.6.5.1 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/arch/arm/plat-omap/include/plat/omap_device.h b/arch/arm/plat-omap/include/plat/omap_device.h index 11a9773..d939246 100644 --- a/arch/arm/plat-omap/include/plat/omap_device.h +++ b/arch/arm/plat-omap/include/plat/omap_device.h @@ -137,5 +137,7 @@ struct omap_device_pm_latency { }; -#endif +/* Get omap_device pointer from platform_device pointer */ +#define to_omap_device(x) container_of((x), struct omap_device, pdev) +#endif