#794043 avrdude: Segfault when reading an xmega16-e5 cpu

Package:
avrdude
Source:
avrdude
Description:
software for programming Atmel AVR microcontrollers
Submitter:
Dima Kogan
Date:
2015-07-30 15:09:16 UTC
Severity:
normal
#794043#5
Date:
2015-07-30 03:23:25 UTC
From:
To:
Hi. Every time I try to read the flash in an xmega16-e5, I see avrdude crash:

    dima@shorty:~/stir/linbusctl$ avrdude -B8 -Pusb -c atmelice_pdi -p x16e5 -U flash:r:read.hex:i

    avrdude: AVR device initialized and ready to accept instructions

    Reading | ################################################## | 100% 0.13s

    avrdude: Device signature = 0x1e9445
    avrdude: NOTE: Programmer supports page erase for Xmega devices.
             Each page will be erased before programming it, but no chip erase is performed.
             To disable page erases, specify the -D option; for a chip-erase, use the -e option.
    avrdude: reading flash memory:

    Reading | ################################################## | 100% 2.80s

    avrdude: writing output file "read.hex"

    avrdude done.  Thank you.

    zsh: segmentation fault (core dumped)  avrdude -B8 -Pusb -c atmelice_pdi -p x16e5 -U flash:r:read.hex:i

This happens after the read completes, so fixing this isn't critically
important, but it's still not right. The core isn't particularly illuminating:

    dima@shorty:~/stir/linbusctl$ gdb /usr/bin/avdude core.avrdude.7491
    GNU gdb (Debian 7.9-1) 7.9
    Copyright (C) 2015 Free Software Foundation, Inc.
    License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    This is free software: you are free to change and redistribute it.
    There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
    and "show warranty" for details.
    This GDB was configured as "x86_64-linux-gnu".
    Type "show configuration" for configuration details.
    For bug reporting instructions, please see:
    <http://www.gnu.org/software/gdb/bugs/>.
    Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.
    For help, type "help".
    Type "apropos word" to search for commands related to "word"...
    /usr/bin/avdude: No such file or directory.
    [New LWP 7491]
    Core was generated by `avrdude -B8 -Pusb -c atmelice_pdi -p x16e5 -U flash:r:read.hex:i'.
    Program terminated with signal SIGSEGV, Segmentation fault.
    #0  0x00007f3663739528 in ?? ()
    (gdb) where
    #0  0x00007f3663739528 in ?? ()
    #1  0x0000000100000000 in ?? ()
    #2  0x0000000100000830 in ?? ()
    #3  0x0000000100000000 in ?? ()
    #4  0x00007f3664e25cd8 in ?? ()
    #5  0x00007ffe1eee0470 in ?? ()
    #6  0x00007f3663a63038 in ?? ()
    #7  0x0000000100000000 in ?? ()
    #8  0x00007ffe1eee0520 in ?? ()
    #9  0x0000000000000000 in ?? ()
    (gdb) info threads
      Id   Target Id         Frame
    * 1    LWP 7491          0x00007f3663739528 in ?? ()

#794043#10
Date:
2015-07-30 15:08:11 UTC
From:
To:
Dima Kogan <dima@secretsauce.net> writes:
 
Recompile the avrdude package with debugging symbols:
https://wiki.debian.org/HowToGetABacktrace#Rebuilding_the_package_you.2BIBk-re_debugging
 
Then reproduce the bug. Also try passing -vvvv to avrdude.