Fix bug in io64 target (introduced by commit aba27ac)
From comparison of current logic and the logic that was prior to commitaba27ac, we see that first parameter of FPGA_GET_REG() shall be the FPGA index and not channel number. The re-factoring in commitaba27acaccidentally changed that. Cc: Stefan Roese <sr@denx.de> Acked-by: Dirk Eibach <dirk.eibach@gdsys.cc> Signed-off-by: Vasili Galka <vvv444@gmail.com>
This commit is contained in:
parent
7d2357c199
commit
2e43646782
|
|
@ -287,7 +287,7 @@ int last_stage_init(void)
|
||||||
for (fpga = 0; fpga < 2; ++fpga) {
|
for (fpga = 0; fpga < 2; ++fpga) {
|
||||||
for (k = 0; k < 32; ++k) {
|
for (k = 0; k < 32; ++k) {
|
||||||
u16 status;
|
u16 status;
|
||||||
FPGA_GET_REG(k, ch[k].status_int, &status);
|
FPGA_GET_REG(fpga, ch[k].status_int, &status);
|
||||||
if (!(status & (1 << 4))) {
|
if (!(status & (1 << 4))) {
|
||||||
failed = 1;
|
failed = 1;
|
||||||
printf("fpga %d channel %d: no serdes lock\n",
|
printf("fpga %d channel %d: no serdes lock\n",
|
||||||
|
|
@ -304,7 +304,7 @@ int last_stage_init(void)
|
||||||
for (fpga = 0; fpga < 2; ++fpga) {
|
for (fpga = 0; fpga < 2; ++fpga) {
|
||||||
for (k = 0; k < 32; ++k) {
|
for (k = 0; k < 32; ++k) {
|
||||||
u16 status;
|
u16 status;
|
||||||
FPGA_GET_REG(k, hicb_ch[k].status_int, &status);
|
FPGA_GET_REG(fpga, hicb_ch[k].status_int, &status);
|
||||||
if (status)
|
if (status)
|
||||||
printf("fpga %d hicb %d: hicb status %04x\n",
|
printf("fpga %d hicb %d: hicb status %04x\n",
|
||||||
fpga, k, status);
|
fpga, k, status);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue