Skip to contentSkip to conversation

Fix bug in io64 target (introduced by commit aba27ac)

PATCH New Vasili Galka 3 participants 4 messages Jun 16, 2014 – Jun 18, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix bug in io64 target (introduced by commit aba27ac)

#1 lore raw

PATCH 1/1 Fix bug in io64 target (introduced by commit aba27ac)

Heh. Good catch. thanks!
But now I'm curious: how did you find this?

Acked-by dirk.eibach at gdsys.cc

Cheers
Dirk

#2 lore raw

PATCH 1/1 Fix bug in io64 target (introduced by commit aba27ac)

Hi Dirk,

Quoted 7 lines · Dirk Eibach

Heh. Good catch. thanks!
But now I'm curious: how did you find this?

Acked-by dirk.eibach at gdsys.cc

Cheers
Dirk

I had the following compiler warning (and I actually don't understand why it was generated here):

In file included from /home/lab/dev/uboot/board/gdsys/405ex/io64.c:25:0:
/home/lab/dev/uboot/board/gdsys/405ex/io64.c: In function 'last_stage_init':
/home/lab/dev/uboot/include/gdsys_fpga.h:35:17: warning: iteration 2u invokes undefined behavior [-Waggressive-loop-optimizations]

        &fpga_ptr[ix]->fld, \
                 ^
/home/lab/dev/uboot/board/gdsys/405ex/io64.c:307:4: note: in expansion
of macro 'FPGA_GET_REG'
    FPGA_GET_REG(k, hicb_ch[k].status_int, &status);
    ^

/home/lab/dev/uboot/board/gdsys/405ex/io64.c:305:3: note: containing loop
for (k = 0; k < 32; ++k) {
^

So I had to look on the code...

Best,
Vasili

#3 lore raw

PATCH 1/1 Fix bug in io64 target (introduced by commit aba27ac)

In reply to Vasili Galka
Quoted 7 lines · Vasili Galka

From comparison of current logic and the logic that was prior to commit aba27ac, we see that first parameter of FPGA_GET_REG() shall be the FPGA index and not channel number. The re-factoring in commit aba27ac accidentally changed that.

Cc Dirk Eibach <[email protected]>, Stefan Roese <[email protected]>

Applied to u-boot/master (and updated commit message to have an acked-by from Dirk), thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140618/9bfa750e/attachment.pgp>