Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Software for White Rabbit PTP Core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
32
Issues
32
List
Board
Labels
Milestones
Merge Requests
6
Merge Requests
6
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Software for White Rabbit PTP Core
Commits
1e2001f1
Commit
1e2001f1
authored
Apr 03, 2023
by
Tomasz Wlostowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixes to get wrc to boot with silabs/riscv on spec150t, wip
parent
32f4771f
Pipeline
#4404
failed with stage
in 44 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
33 additions
and
21 deletions
+33
-21
Makefile
Makefile
+1
-1
board.h
boards/spec_silabs/board.h
+31
-19
endpoint.c
dev/endpoint.c
+1
-1
No files found.
Makefile
View file @
1e2001f1
...
...
@@ -103,7 +103,7 @@ ldflags-$(CONFIG_ARCH_LM32) = -mmultiply-enabled -mbarrel-shift-enabled \
-nostdlib
-T
$(LDS-y)
ldflags-$(CONFIG_ARCH_RISCV)
=
-march
=
rv32im
$
(
USE-COMP-INSTR-y
)
-mabi
=
ilp32
\
-nostdlib
-T
$
(
LDS-y
)
asflags-$(CONFIG_ARCH_RISCV)
+=
-march
=
rv32im
$
(
USE-COMP-INSTR-y
)
-mabi
=
ilp32
asflags-$(CONFIG_ARCH_RISCV)
+=
-march
=
rv32im
$
(
USE-COMP-INSTR-y
)
_zicsr
-mabi
=
ilp32
arch-files-$(CONFIG_ARCH_LM32)
=
$(OUTPUT).bram
$(OUTPUT).vhd
$(OUTPUT).mif
arch-files-$(CONFIG_ARCH_RISCV)
=
$(OUTPUT).bram
$(OUTPUT).vhd
$(OUTPUT).mif
...
...
boards/spec_silabs/board.h
View file @
1e2001f1
...
...
@@ -3,25 +3,34 @@
*
* Released according to the GNU GPL, version 2 or any later version.
*/
#include <netconsole.h>
#ifndef __BOARD_WRC_H
#define __BOARD_WRC_H
/*
* This is meant to be automatically included by the Makefile,
* when wrpc-sw is build for wrc (node) -- as opposed to wrs (switch)
*/
#ifdef CONFIG_ARCH_RISCV
#define DEV_BASE 0x100000
#elif defined CONFIG_ARCH_LM32
#define DEV_BASE 0x40000
#else
#error (Wrong Arch!)
#endif
/* Fixed base addresses */
#define BASE_MINIC 0x20000
#define BASE_EP 0x20100
#define BASE_SOFTPLL 0x20200
#define BASE_PPS_GEN 0x20300
#define BASE_SYSCON 0x20400
#define BASE_UART 0x20500
#define BASE_ONEWIRE 0x20600
#define BASE_SI57X_INTERFACE 0x28000
#define BASE_WDIAGS_PRIV 0x20900
#define BOARD_USE_EVENTS 0
#define BASE_MINIC (DEV_BASE + 0x000)
#define BASE_EP (DEV_BASE + 0x100)
#define BASE_SOFTPLL (DEV_BASE + 0x200)
#define BASE_PPS_GEN (DEV_BASE + 0x300)
#define BASE_SYSCON (DEV_BASE + 0x400)
#define BASE_UART (DEV_BASE + 0x500)
#define BASE_ONEWIRE (DEV_BASE + 0x600)
#define BASE_WDIAGS_PRIV (DEV_BASE + 0x900)
#define BASE_SI57X_INTERFACE (DEV_BASE + 0x8000)
/* Board-specific parameters */
#define TICS_PER_SECOND 1000
...
...
@@ -29,13 +38,16 @@
/* WR Core system/CPU clock frequency in Hz */
#define CPU_CLOCK 62500000ULL
/* WR Reference clock period (picoseconds) and frequency (Hz) */
#ifdef CONFIG_TARGET_GENERIC_PHY_16BIT
# define NS_PER_CLOCK 16
# define REF_CLOCK_PERIOD_PS 16000
# define REF_CLOCK_FREQ_HZ 62500000
#else
# define NS_PER_CLOCK 8
# define REF_CLOCK_PERIOD_PS 8000
# define REF_CLOCK_FREQ_HZ 125000000
/* Baud rate of the builtin UART (does not apply to the VUART) */
#define UART_BAUDRATE 115200ULL
#endif
/* Maximum number of simultaneously created sockets */
#define NET_MAX_SOCKETS 12
...
...
@@ -56,13 +68,13 @@
#define BOARD_MAX_CHAN_AUX 2
#define BOARD_MAX_PTRACKERS 1
#
define
CONFIG_DISALLOW_LONG_DIVISION
#
undef
CONFIG_DISALLOW_LONG_DIVISION
#define BOARD_
MAX_CONSOLE_DEVICES 1
#define BOARD_
USE_EVENTS 0
#define
CONSOLE_UART_BAUDRATE 115200
#define
BOARD_MAX_CONSOLE_DEVICES (1 + HAS_NETCONSOLE + HAS_PUTS_SYSLOG)
#define
SDB_ADDRESS 0x300
00
#define
CONSOLE_UART_BAUDRATE 1152
00
#define FMC_EEPROM_ADR 0x50
...
...
dev/endpoint.c
View file @
1e2001f1
...
...
@@ -101,7 +101,7 @@ void ep_reset_phy(struct wr_endpoint_device* dev)
ep_pcs_write
(
dev
,
MDIO_REG_MCR
,
MDIO_MCR_PDOWN
);
/* reset the PHY */
pp_printf
(
"Running long PHY reset...
\n
"
);
timer_delay_ms
(
100
00
);
timer_delay_ms
(
3
00
);
pp_printf
(
"PHY reset complete
\n
"
);
ep_pcs_write
(
dev
,
MDIO_REG_MCR
,
MDIO_MCR_RESET
);
/* reset the PHY */
ep_pcs_write
(
dev
,
MDIO_REG_MCR
,
0
);
/* reset the PHY */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment