[U-Boot-Users] [patch]fixes for cmd_fpga.c

The attached patch:
1) fixes a bug with the 'fpga loadb' command
The bug is in calculating the config data size - 4 bytes of length info were being read as signed chars, casted to long, shifted and added. The cast to long was doing sign extension and causing an incorrect result if a byte was greater than 0x80. For me this caused the fpga load to end early and time out waiting for the hardware completion.
2) removes compilation warnings about using __FUNCTION__ concatenated with strings
3) changes the fpga loadb to always print the file header info during a load.
I realize this patch is a mishmash - hopefully it's helpful to someone.

In message c166aa9f050111215735ec493f@mail.gmail.com you wrote:
The attached patch:
- fixes a bug with the 'fpga loadb' command
...
- removes compilation warnings about using __FUNCTION__ concatenated with
strings
- changes the fpga loadb to always print the file header info during a load.
Added, thanks.
Next time please don't forget to include a CHANGELOG entry!
Best regards,
Wolfgang Denk
participants (2)
-
Andrew Dyer
-
Wolfgang Denk