]>
git.ipfire.org Git - people/ms/u-boot.git/blob - board/renesas/rsk7269/rsk7269.c
2 * Copyright (C) 2012 Renesas Electronics Europe Ltd.
3 * Copyright (C) 2012 Phil Edworthy
4 * Copyright (C) 2008 Renesas Solutions Corp.
5 * Copyright (C) 2008 Nobuhiro Iwamatsu
7 * Based on u-boot/board/rsk7264/rsk7264.c
9 * SPDX-License-Identifier: GPL-2.0+
16 #include <asm/processor.h>
20 puts("BOARD: Renesas RSK7269\n");
29 void led_set_state(unsigned short value
)
34 * The RSK board has the SMSC89218 wired up 'incorrectly'.
35 * Byte-swapping is necessary, and so poor performance is inevitable.
36 * This problem cannot evade by the swap function of CHIP, this can
37 * evade by software Byte-swapping.
38 * And this has problem by FIFO access only. pkt_data_pull/pkt_data_push
39 * functions necessary to solve this problem.
41 u32
pkt_data_pull(struct eth_device
*dev
, u32 addr
)
43 volatile u16
*addr_16
= (u16
*)(dev
->iobase
+ addr
);
44 return (u32
)((swab16(*addr_16
) << 16) & 0xFFFF0000)\
45 | swab16(*(addr_16
+ 1));
48 void pkt_data_push(struct eth_device
*dev
, u32 addr
, u32 val
)
51 *(volatile u16
*)(addr
+ 2) = swab16((u16
)val
);
52 *(volatile u16
*)(addr
) = swab16((u16
)(val
>> 16));
55 int board_eth_init(bd_t
*bis
)
59 rc
= smc911x_initialize(0, CONFIG_SMC911X_BASE
);