board: iocon: Fix fpga index in print_fpga_info()
authorDirk Eibach <dirk.eibach@gdsys.cc>
Thu, 13 Nov 2014 18:21:16 +0000 (19:21 +0100)
committerStefan Roese <sr@denx.de>
Wed, 19 Nov 2014 07:48:41 +0000 (08:48 +0100)
Signed-off-by: Dirk Eibach <dirk.eibach@gdsys.cc>
Signed-off-by: Stefan Roese <sr@denx.de>
board/gdsys/405ep/iocon.c

index 1bac97027d4b9f794bf7455aa01831daa2b74811..fffed7390b427c3d8cbfe99945cf9389fea0a743 100644 (file)
@@ -180,11 +180,11 @@ static void print_fpga_info(unsigned int fpga, bool rgmii2_present)
        unsigned feature_carriers;
        unsigned feature_video_channels;
 
-       int legacy = get_fpga_state(0) & FPGA_STATE_PLATFORM;
+       int legacy = get_fpga_state(fpga) & FPGA_STATE_PLATFORM;
 
-       FPGA_GET_REG(0, versions, &versions);
-       FPGA_GET_REG(0, fpga_version, &fpga_version);
-       FPGA_GET_REG(0, fpga_features, &fpga_features);
+       FPGA_GET_REG(fpga, versions, &versions);
+       FPGA_GET_REG(fpga, fpga_version, &fpga_version);
+       FPGA_GET_REG(fpga, fpga_features, &fpga_features);
 
        unit_type = (versions & 0xf000) >> 12;
        feature_compression = (fpga_features & 0xe000) >> 13;