
Dear dirk.eibach@gdsys.cc,
In message 1367847325-21463-7-git-send-email-dirk.eibach@gdsys.cc you wrote:
From: Dirk Eibach eibach@gdsys.de
Signed-off-by: Dirk Eibach dirk.eibach@gdsys.cc
Changes in v2: None
board/gdsys/405ep/dlvision-10g.c | 20 ++++++++++++++------ board/gdsys/405ep/io.c | 20 ++++++++++++++------ board/gdsys/405ep/neo.c | 17 +++++++++++++---- board/gdsys/405ex/405ex.c | 14 ++++++-------- board/gdsys/405ex/io64.c | 38 ++++++++++++++++++++++---------------- 5 files changed, 69 insertions(+), 40 deletions(-)
diff --git a/board/gdsys/405ep/dlvision-10g.c b/board/gdsys/405ep/dlvision-10g.c index 644493b..4d1a02e 100644 --- a/board/gdsys/405ep/dlvision-10g.c +++ b/board/gdsys/405ep/dlvision-10g.c @@ -71,6 +71,16 @@ enum { RAM_DDR2_64 = 2, };
+void fpga_set_reg(unsigned int fpga, u16 reg, u16 data) +{
- out_le16((u16 *)CONFIG_SYS_FPGA_BASE(fpga) + reg / sizeof(u16), data);
+}
+u16 fpga_get_reg(unsigned int fpga, u16 reg) +{
- return in_le16((u16 *)CONFIG_SYS_FPGA_BASE(fpga) + reg / sizeof(u16));
+}
We strictly discourage using a notation of base address plus offset, and require to use proper C structs instead, especially because this allows type checking by the compiler.
You had the this, and now attempt to throw it away. This makes no sense.
NAK.
Best regards,
Wolfgang Denk