[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[microblaze-uclinux] vsnprintf() not working?



I think I've found the origination point of the garbage that's appearing on
my Hyperterminal:

------------- GDB session output begins here.
-------------------------------------

(file: printk.c)
452             printed_len = vsnprintf(printk_buf, sizeof(printk_buf), fmt,
args);
 (gdb) p fmt
$5 = 0xfe10830c "Linux version 2.4.29-uc0 (dbanas@linux) (gcc version
2.95.3-4 Xilinx EDK 6.3 Build EDK_Gmm.11.2) #7 Fri Mar 18 12:18:54 PST
2005\n"
 (gdb) next
459             for (p = printk_buf; *p; p++) {
 (gdb) p printk_buf
$8 = "uuuueeeeoooo....99990000bbbbssssnnnn
ccccrrrrnnnn9999----iiiixxxxKKKK3333iiiiEEEEGGGG1111))))", ' ' <repeats 12
times>, "11118888        5555", '\0' <repeats 895 times>

------------- GDB session output begins here.
-------------------------------------

It looks like the 'vsnprintf' function is being passed the correct Linux
banner in the 'fmt' variable, but is putting garbage into the 'printk_buf'
variable.

Any thoughts?

Thanks, 

David Banas
Field Applications Engineer
Nu Horizons Electronics Corp.
2070 Ringwood Avenue
San Jose, CA 95131
(408)434-0800 - office
(415)846-5837 - cell
http://www.nuhorizons.com

<<attachment: winmail.dat>>