linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* SIGBUS caused by mmap and memcpy that doesn't go away after application restart
@ 2010-12-20 23:08 AJ ONeal
  2010-12-21  2:03 ` AJ ONeal
  0 siblings, 1 reply; 2+ messages in thread
From: AJ ONeal @ 2010-12-20 23:08 UTC (permalink / raw)
  To: linux-kernel

After posting to my local LUG I was told to ask about the possibility
of a kernel bug here


I have an application which runs for several hours in the same loop
correctly, but eventually dies with SIGBUS.

If I try to start the application again it immediately exits with
SIGBUS and will not work until rebooted.

gdb reports
Program received signal SIGBUS, Bus error.
0x401bd354 in memcpy () from /lib/libc.so.6
(gdb) bt
#0  0x401bd354 in memcpy () from /lib/libc.so.6
#1  0x0000929c in capture_file_write ()
#2  0x0fefeb0a in ?? ()
#3  0x0fefeb0a in ?? ()

Any ideas on what causes this error?
How do I go about finding what #2 and #3 are?


The system is a ARM OMAP3530 (Gumstix Overo). The kernel is 3.6.36.

This is the application flow:

count = 0
do
    outfile = /dev/shm/output.{#count}.dat
    data = read logged.dat for 512kb
    unlink outfile if exists
    truncate outfile to 512kb
    outfile_p = mmap outfile
    memcpy data outfile_p
    munmap
    count += 1
    if count > MAX; count = 0
    advance or rewind logged.dat
loop

I can post a link to a gist of the source upon request.

AJ ONeal

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: SIGBUS caused by mmap and memcpy that doesn't go away after application restart
  2010-12-20 23:08 SIGBUS caused by mmap and memcpy that doesn't go away after application restart AJ ONeal
@ 2010-12-21  2:03 ` AJ ONeal
  0 siblings, 0 replies; 2+ messages in thread
From: AJ ONeal @ 2010-12-21  2:03 UTC (permalink / raw)
  To: linux-kernel

Perhaps this is the wrong list to be asking.
If so will someone kindly suggest a better place?

AJ ONeal


On Mon, Dec 20, 2010 at 4:08 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> After posting to my local LUG I was told to ask about the possibility
> of a kernel bug here
>
>
> I have an application which runs for several hours in the same loop
> correctly, but eventually dies with SIGBUS.
>
> If I try to start the application again it immediately exits with
> SIGBUS and will not work until rebooted.
>
> gdb reports
> Program received signal SIGBUS, Bus error.
> 0x401bd354 in memcpy () from /lib/libc.so.6
> (gdb) bt
> #0  0x401bd354 in memcpy () from /lib/libc.so.6
> #1  0x0000929c in capture_file_write ()
> #2  0x0fefeb0a in ?? ()
> #3  0x0fefeb0a in ?? ()
>
> Any ideas on what causes this error?
> How do I go about finding what #2 and #3 are?
>
>
> The system is a ARM OMAP3530 (Gumstix Overo). The kernel is 3.6.36.
>
> This is the application flow:
>
> count = 0
> do
>    outfile = /dev/shm/output.{#count}.dat
>    data = read logged.dat for 512kb
>    unlink outfile if exists
>    truncate outfile to 512kb
>    outfile_p = mmap outfile
>    memcpy data outfile_p
>    munmap
>    count += 1
>    if count > MAX; count = 0
>    advance or rewind logged.dat
> loop
>
> I can post a link to a gist of the source upon request.
>
> AJ ONeal
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-12-21  2:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-20 23:08 SIGBUS caused by mmap and memcpy that doesn't go away after application restart AJ ONeal
2010-12-21  2:03 ` AJ ONeal

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).