Skip to contentSkip to conversation

ARM: OMAP: Remove IVA IRQ bank

PATCH In review Komal Shah 9 participants 11 messages Aug 28, 2006 – Sep 6, 2006

lore
Share & tools
lore
#1 lore raw

GPIO OF OMAP5912

hi:

i want to do some work about OMAP5912'GPIO.but I am failed to do that.

the following is a simple program:

test.c

-----------------------------------------------------

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>

#define GPIO3_OUT 0xfffbbc40 /* lp1 */

int main()
{
/* Get access to the ports */

/* Set the data signals (D0-7) of the port to all low (0) */ outb(0xffff, GPIO3_OUT);

/* Sleep for a while (100 ms) */
usleep(100000);
}
-----------------------------------------------------
arm-linux-gcc -g test.c -o test.out
----------------------------------------------------
I run the binary file on the omap:./test.out
-----------------------------------------------------
but i get the result:segmentation falt!
---------------------------------------------------
who can provide me with information? if you have done work related with gpio,would you like send me some examplefile?
thanks!

#2 lore raw

AW: GPIO OF OMAP5912

Hello,

I don't know if my idea help you.
Maybe the problem is about the libraries in directory /lib/ on OMAP file systems. It doesn't contain the libraries, which your program need.

Regard,
Thanh

-----Ursprüngliche Nachricht-----
Von: [email protected] [mailto:[email protected]] Im Auftrag von w.b.b
Gesendet: Dienstag, 29. August 2006 08:44
An: [email protected]
Betreff: GPIO OF OMAP5912

hi:

i want to do some work about OMAP5912'GPIO.but I am failed to do that.

the following is a simple program:

test.c

-----------------------------------------------------

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>

#define GPIO3_OUT 0xfffbbc40 /* lp1 */

int main()
{
/* Get access to the ports */

/* Set the data signals (D0-7) of the port to all low (0) */ outb(0xffff, GPIO3_OUT);

/* Sleep for a while (100 ms) */
usleep(100000);
}
-----------------------------------------------------
arm-linux-gcc -g test.c -o test.out
----------------------------------------------------
I run the binary file on the omap:./test.out
-----------------------------------------------------
but i get the result:segmentation falt!
---------------------------------------------------
who can provide me with information? if you have done work related with gpio,would you like send me some examplefile?
thanks!

#3 lore raw

Re: AW: GPIO OF OMAP5912

Don't think you can access physical memory directly in user space. You should use /dev/mem instead.

-kwan

Quoted 56 lines · LIMITED Nguyen Duong Thanh (CR/AEM Praktikant)

Hello,

I don't know if my idea help you.
Maybe the problem is about the libraries in directory /lib/ on OMAP file systems. It doesn't contain the libraries, which your program need.

Regard,
Thanh

-----Ursprüngliche Nachricht-----
Von: [email protected] [mailto:[email protected]] Im Auftrag von w.b.b
Gesendet: Dienstag, 29. August 2006 08:44
An: [email protected]
Betreff: GPIO OF OMAP5912

hi:

i want to do some work about OMAP5912'GPIO.but I am failed to do that.

the following is a simple program:

test.c

-----------------------------------------------------

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>

#define GPIO3_OUT 0xfffbbc40 /* lp1 */

int main()
{
/* Get access to the ports */

/* Set the data signals (D0-7) of the port to all low (0) */ outb(0xffff, GPIO3_OUT);

/* Sleep for a while (100 ms) */
usleep(100000);
}
-----------------------------------------------------
arm-linux-gcc -g test.c -o test.out
----------------------------------------------------
I run the binary file on the omap:./test.out
-----------------------------------------------------
but i get the result:segmentation falt!
---------------------------------------------------
who can provide me with information? if you have done work related with gpio,would you like send me some examplefile?
thanks!
_______________________________________________
Linux-omap-open-source mailing list
[email protected]
http://linux.omap.com/mailman/listinfo/linux-omap-open-source

#4 lore raw

Re: AW: GPIO OF OMAP5912

thanks.
I get information about how to get use of the hardware in linux,but I am still confused about it.
-----------------------------------------------------------
the following steps about it:
1. apply for the resource to linux kernel
2. if you have applied ,then you can do some work about it.
3.if you have finished ,release the resouce.
-------------------------------------------------------------
i can only get the physical memory of the registers from the omap process guide.but I don't know their address in linux.
though it's a very basical question,i have to apply for help.
maybe a simple example can make me understand quickly!

                         thanks
                                    w.b.b

I
----- Original Message -----
From: "Hingkwan Huen" <[email protected]>
To: "LIMITED Nguyen Duong Thanh (CR/AEM Praktikant)" <[email protected]>
Cc: "w.b.b" <[email protected]>; <[email protected]>
Sent: Wednesday, August 30, 2006 12:50 AM
Subject: Re: AW: GPIO OF OMAP5912

Quoted 65 lines

Don't think you can access physical memory directly in user space. You should use /dev/mem instead.

-kwan

Quoted 56 lines · LIMITED Nguyen Duong Thanh (CR/AEM Praktikant)

Hello,

I don't know if my idea help you.
Maybe the problem is about the libraries in directory /lib/ on OMAP file systems. It doesn't contain the libraries, which your program need.

Regard,
Thanh

-----Ursprüngliche Nachricht-----
Von: [email protected] [mailto:[email protected]] Im Auftrag von w.b.b
Gesendet: Dienstag, 29. August 2006 08:44
An: [email protected]
Betreff: GPIO OF OMAP5912

hi:

i want to do some work about OMAP5912'GPIO.but I am failed to do that.

the following is a simple program:

test.c

-----------------------------------------------------

#include <stdio.h>
#include <unistd.h>
#include <asm/io.h>

#define GPIO3_OUT 0xfffbbc40 /* lp1 */

int main()
{
/* Get access to the ports */

/* Set the data signals (D0-7) of the port to all low (0) */ outb(0xffff, GPIO3_OUT);

/* Sleep for a while (100 ms) */
usleep(100000);
}
-----------------------------------------------------
arm-linux-gcc -g test.c -o test.out
----------------------------------------------------
I run the binary file on the omap:./test.out
-----------------------------------------------------
but i get the result:segmentation falt!
---------------------------------------------------
who can provide me with information? if you have done work related with gpio,would you like send me some examplefile?
thanks!
_______________________________________________
Linux-omap-open-source mailing list
[email protected]
http://linux.omap.com/mailman/listinfo/linux-omap-open-source

#5 lore raw

Loading program to OMAP5910

Hi all,

I am trying to look for steps as how to load program to my LDK5910 board which has omap5910.

Now Omap5910 has ARM925T and DSP.

We are able to load program,but not able to execute to ARM core using Code Composer Studio 3.1.We are trying to load boot loader and execute it to program flash through JTAG.

Also we trying to update/load bootloader using serial port. At this moment the default bootloader is not there in the board as we are thinking the flash would have corrupted and serial console output is not showing up in teraterm/hyperterm. All baud setting are fine as per document.

we are using rrloader as bootloader.

Is there any other option through which can load the program & execute in RAM/flash and write to flash.

Please share your input or help reference if any one has work on this board.

Regards
Raja Mallik

#6 lore raw

Re: Loading program to OMAP5910

Quoted 3 lines · Raja Mallik

We are able to load program,but not able to execute to ARM core using Code Composer Studio 3.1.We are trying to load boot loader and execute it to program flash through JTAG.

Check if section 2 of OMAP readme [1] can help you with JTAG and CCS. Maybe the other stuff in HOWTO section of OMAP Wiki [2] can help you as well.

Dirk

[1] http://source.mvista.com/git/gitweb.cgi?p=linux-omap-2.6.git;a=blob_plain;h=f8ffb68e8588c5ad43a72c3534c5f963aa7c91af;f=Documentation/arm/OMAP/README

[2] http://tree.celinuxforum.org/CelfPubWiki/OSK

#7 lore raw

Re: Loading program to OMAP5910

Thank for the input.

Aparently, I am trying to look for steps as how to load program to my LDK5910 board which has omap5910.

Now Omap5910 has ARM925T and DSP.

We are able to load program,but not able to execute to ARM core using Code Composer Studio 3.1. We are trying to load boot loader and execute it to program flash through JTAG.

Also we trying to update/load bootloader using serial port.

At this moment the default bootloader is not there in the board as we are thinking the flash would have corrupted and serial console output is not showing up in teraterm/hyperterm. All baud setting are fine as per document.

we are using rrloader as bootloader.

Is there any other option through which can load the program & execute in RAM/flash and write to flash.

Pl, give your input in this case..

Regards
Raja Mallik

Quoted 15 lines · Dirk Behme
Quoted 3 lines · Raja Mallik

We are able to load program,but not able to execute to ARM core using Code Composer Studio 3.1.We are trying to load boot loader and execute it to program flash through JTAG.

Check if section 2 of OMAP readme [1] can help you with JTAG and CCS. Maybe the other stuff in HOWTO section of OMAP Wiki
[2] can help you as well.

Dirk

[1]
http://source.mvista.com/git/gitweb.cgi?p=linux-omap-2.6.git;a=blob_plain;h=f8ffb68e8588c5ad43a72c3534c5f963aa7c91af;f=Documentation/arm/OMAP/README

[2] http://tree.celinuxforum.org/CelfPubWiki/OSK

#8 lore raw

Random Number Generation

In reply to Dirk Behme

Hello all,

I'm wondering how one would generate a random number on both the DSP and
GPP sides. Does linux come with a tool for generating random numbers? Should I include a standard (and large) math.h library for this purpose? I know the OMAP has hardware support for the generation of random numbers, but I can't seem to find refferences to how to use it in the BSL pdf. Any insight is much appreciated.

Thanks,
Andy

_________________________________________________________________
Windows Live Spaces is here! It�s easy to create your own personal Web site.
http://spaces.live.com/signup.aspx

#9 lore raw

Re: Random Number Generation

Quoted 8 lines · Abot Botbot

Hello all,

I'm wondering how one would generate a random number on both the DSP
and GPP sides. Does linux come with a tool for generating random numbers? Should I include a standard (and large) math.h library for this purpose? I know the OMAP has hardware support for the generation of random numbers, but I can't seem to find refferences to how to use it in the BSL pdf. Any insight is much appreciated.

I have not tried my self, but have you seen the random generator driver in
drivers\char\omap-rng.c?