* [PATCH] Exporting reserved APIs in GPMC library.
@ 2006-11-27 16:15 Syed Mohammed, Khasim
2006-11-30 22:43 ` tony
0 siblings, 1 reply; 2+ messages in thread
From: Syed Mohammed, Khasim @ 2006-11-27 16:15 UTC (permalink / raw)
To: linux-omap-open-source
[-- Attachment #1: Type: text/plain, Size: 474 bytes --]
Hi,
The attached patch is to export two APIs (gpmc_cs_set_reserved and
gpmc_cs_reserved) of GPMC library.
This allows other libraries and drivers to access these APIs with out
doing a gpmc_request.
Reason: If I have already configured a GPMC CS in boot loader I might
not be interested in doing the same again in Kernel. However I might
want to reserve this particular CS so that it doesn't show as free when
others do a gpmc_request.
Regards,
Khasim
[-- Attachment #2: gpmc_exportedapi.patch --]
[-- Type: application/octet-stream, Size: 942 bytes --]
This patch exports two reserved APIs gpmc_cs_set_reserved and gpmc_cs_reserved.
Signed-off-by: Syed Mohammed Khasim <x0khasim@ti.com>
Files Changed:
gpmc.c | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
=============================================================================
--- linux-omap/arch/arm/mach-omap2/gpmc.c 2006-11-20 21:54:01.000000000 -0600
+++ my_linux_devpt/arch/arm/mach-omap2/gpmc.c 2006-11-27 09:33:21.000000000 -0600
@@ -264,14 +264,20 @@ static int gpmc_cs_mem_enabled(int cs)
return l & (1 << 6);
}
-static void gpmc_cs_set_reserved(int cs, int reserved)
+void gpmc_cs_set_reserved(int cs, int reserved)
{
+ if (cs > GPMC_CS_NUM)
+ return -ENODEV;
+
gpmc_cs_map &= ~(1 << cs);
gpmc_cs_map |= (reserved ? 1 : 0) << cs;
}
-static int gpmc_cs_reserved(int cs)
+int gpmc_cs_reserved(int cs)
{
+ if (cs > GPMC_CS_NUM)
+ return -ENODEV;
+
return gpmc_cs_map & (1 << cs);
}
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Exporting reserved APIs in GPMC library.
2006-11-27 16:15 [PATCH] Exporting reserved APIs in GPMC library Syed Mohammed, Khasim
@ 2006-11-30 22:43 ` tony
0 siblings, 0 replies; 2+ messages in thread
From: tony @ 2006-11-30 22:43 UTC (permalink / raw)
To: Syed Mohammed, Khasim; +Cc: linux-omap-open-source
* Syed Mohammed, Khasim <x0khasim@ti.com> [061127 08:16]:
> Hi,
>
> The attached patch is to export two APIs (gpmc_cs_set_reserved and
> gpmc_cs_reserved) of GPMC library.
>
> This allows other libraries and drivers to access these APIs with out
> doing a gpmc_request.
>
> Reason: If I have already configured a GPMC CS in boot loader I might
> not be interested in doing the same again in Kernel. However I might
> want to reserve this particular CS so that it doesn't show as free when
> others do a gpmc_request.
Pushing your two patches today as a single patch. Left out the HISTORY
part to cut down on clutter as it already shows up in git.
Regards,
Tony
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2006-11-30 22:43 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-27 16:15 [PATCH] Exporting reserved APIs in GPMC library Syed Mohammed, Khasim
2006-11-30 22:43 ` tony
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox