diff mbox

[U-Boot,v4,01/13] board: controlcenterd: Fix pci access

Message ID 1404372506-15314-2-git-send-email-dirk.eibach@gdsys.cc
State Accepted
Delegated to: Tom Rini
Headers show

Commit Message

Dirk Eibach July 3, 2014, 7:28 a.m. UTC
From: Dirk Eibach <dirk.eibach@gdsys.cc>

readl was called with values instead of pointers to these values.
Why this ever did work is a mystery...

Signed-off-by: Dirk Eibach <dirk.eibach@gdsys.cc>
---

Changes in v4: None
Changes in v3: None
Changes in v2: None

 board/gdsys/p1022/controlcenterd.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Tom Rini July 8, 2014, 1:38 a.m. UTC | #1
On Thu, Jul 03, 2014 at 09:28:14AM +0200, Dirk Eibach wrote:

> From: Dirk Eibach <dirk.eibach@gdsys.cc>
> 
> readl was called with values instead of pointers to these values.
> Why this ever did work is a mystery...
> 
> Signed-off-by: Dirk Eibach <dirk.eibach@gdsys.cc>

Applied to u-boot/master, thanks!
diff mbox

Patch

diff --git a/board/gdsys/p1022/controlcenterd.c b/board/gdsys/p1022/controlcenterd.c
index 8ccd9ce..0a3517d 100644
--- a/board/gdsys/p1022/controlcenterd.c
+++ b/board/gdsys/p1022/controlcenterd.c
@@ -386,9 +386,9 @@  static void hydra_initialize(void)
 		fpga = pci_map_bar(devno, PCI_BASE_ADDRESS_0,
 			PCI_REGION_MEM);
 
-		versions = readl(fpga->versions);
-		fpga_version = readl(fpga->fpga_version);
-		fpga_features = readl(fpga->fpga_features);
+		versions = readl(&fpga->versions);
+		fpga_version = readl(&fpga->fpga_version);
+		fpga_features = readl(&fpga->fpga_features);
 
 		hardware_version = versions & 0xf;
 		feature_uart_channels = (fpga_features >> 6) & 0x1f;