1 // SPDX-License-Identifier: GPL-2.0+ 2 /* 3 * Copyright (C) 2007,2008 4 * Nobuhiro Iwamatsu <iwamatsu@nigauri.org> 5 */ 6 7 #include <common.h> 8 #include <ide.h> 9 #include <netdev.h> 10 #include <asm/processor.h> 11 #include <asm/io.h> 12 #include <asm/pci.h> 13 checkboard(void)14int checkboard(void) 15 { 16 puts("BOARD: Renesas Solutions R2D Plus\n"); 17 return 0; 18 } 19 board_init(void)20int board_init(void) 21 { 22 return 0; 23 } 24 board_late_init(void)25int board_late_init(void) 26 { 27 return 0; 28 } 29 30 #define FPGA_BASE 0xA4000000 31 #define FPGA_CFCTL (FPGA_BASE + 0x04) 32 #define CFCTL_EN (0x432) 33 #define FPGA_CFPOW (FPGA_BASE + 0x06) 34 #define CFPOW_ON (0x02) 35 #define FPGA_CFCDINTCLR (FPGA_BASE + 0x2A) 36 #define CFCDINTCLR_EN (0x01) 37 ide_set_reset(int idereset)38void ide_set_reset(int idereset) 39 { 40 /* if reset = 1 IDE reset will be asserted */ 41 if (idereset) { 42 outw(CFCTL_EN, FPGA_CFCTL); /* CF enable */ 43 outw(inw(FPGA_CFPOW)|CFPOW_ON, FPGA_CFPOW); /* Power OM */ 44 outw(CFCDINTCLR_EN, FPGA_CFCDINTCLR); /* Int clear */ 45 } 46 } 47 48 static struct pci_controller hose; pci_init_board(void)49void pci_init_board(void) 50 { 51 pci_sh7751_init(&hose); 52 } 53 board_eth_init(bd_t * bis)54int board_eth_init(bd_t *bis) 55 { 56 return pci_eth_init(bis); 57 } 58