From patchwork Thu May 13 05:06:40 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: manjugk manjugk X-Patchwork-Id: 99218 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 o4D54e3H025117 for ; Thu, 13 May 2010 05:06:33 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752145Ab0EMFGd (ORCPT ); Thu, 13 May 2010 01:06:33 -0400 Received: from devils.ext.ti.com ([198.47.26.153]:51860 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751879Ab0EMFGc (ORCPT ); Thu, 13 May 2010 01:06:32 -0400 Received: from dbdp31.itg.ti.com ([172.24.170.98]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id o4D56Rv7003392 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 13 May 2010 00:06:30 -0500 Received: from localhost.localdomain (localhost [127.0.0.1]) by dbdp31.itg.ti.com (8.13.8/8.13.8) with ESMTP id o4D56LXp003027; Thu, 13 May 2010 10:36:22 +0530 (IST) From: Manjunatha GK To: linux-omap@vger.kernel.org Cc: Preshit Agarwal , Tony Lindgren , Kevin Hilman , Mike Turquette , Hemanth V Subject: [PATCH v4] OMAP3: Registering sgx device and it's platform data Date: Thu, 13 May 2010 10:36:40 +0530 Message-Id: <1273727200-4811-1-git-send-email-manjugk@ti.com> X-Mailer: git-send-email 1.7.0.4 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@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]); Thu, 13 May 2010 05:06:34 +0000 (UTC) diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c index 2271b9b..6349ee5 100644 --- a/arch/arm/mach-omap2/devices.c +++ b/arch/arm/mach-omap2/devices.c @@ -26,7 +26,7 @@ #include #include #include - +#include #include "mux.h" #if defined(CONFIG_VIDEO_OMAP2) || defined(CONFIG_VIDEO_OMAP2_MODULE) @@ -786,6 +786,23 @@ static inline void omap_hdq_init(void) static inline void omap_hdq_init(void) {} #endif +struct sgx_platform_data omap_sgx_data = { + .set_min_bus_tput = NULL, +}; + +static struct platform_device powervr_device = { + .name = "pvrsrvkm", + .id = -1, + .dev = { + .platform_data = &omap_sgx_data, + } +}; + +static void omap_init_sgx(void) +{ + (void) platform_device_register(&powervr_device); +} + /*-------------------------------------------------------------------------*/ static int __init omap2_init_devices(void) @@ -800,7 +817,7 @@ static int __init omap2_init_devices(void) omap_hdq_init(); omap_init_sti(); omap_init_sha1_md5(); - + omap_init_sgx(); return 0; } arch_initcall(omap2_init_devices); diff --git a/arch/arm/mach-omap2/include/mach/omap_sgxdef.h b/arch/arm/mach-omap2/include/mach/omap_sgxdef.h new file mode 100644 index 0000000..e03ad8b --- /dev/null +++ b/arch/arm/mach-omap2/include/mach/omap_sgxdef.h @@ -0,0 +1,11 @@ +#ifndef OMAP_SGXDEF_H +#define OMAP_SGXDEF_H + +#include + +struct sgx_platform_data { + void (*set_min_bus_tput)(struct device *dev, u8 agent_id, + unsigned long r); +}; + +#endif