Hi Pragnesh, Thanks for the v2 update. I guess our question/comment on the previous v1 patch was about the addition of bsps/riscv/frdme310arty/ directory at all. That is, you might be able to just use bsps/riscv/riscv already. Are there any significant changes that prevent you from just using "bsps/riscv/riscv"? For example, griscv doesn't have FDT, and has its own way of managing (external) interrupts, so a new gricv bsp is added. On the other hand, it looks to me that frdme310arty has FDT and the same PLIC/CLINT drivers that riscv/riscv already uses, which doesn't really need any special handling or additions. I managed, for example, to get bsps/riscv/riscv running on Piccolo [1] on a Xilinx FPGA (with FDT, PLIC, CLINT and 16550 Xilinx UART IP) without having to do anything (except for just two lines of FDT handling code that I submitted patches for).
[1] https://github.com/bluespec/Piccolo Cheers, Hesham On Tue, 10 Sep 2019 at 07:34, Pragnesh Patel <pragnesh.pa...@sifive.com> wrote: > > This series added a support for RISCV freedom E310 Arty A7 bsp > and add bsps/riscv/shared code for reusability > > Changes in v2: > > bsps/riscv/frdme310arty/btimer/btimer.c > - Remove the read_csr() function from btimer.c > - Remove CONFIG_BTIMER_RISCV_GET_MCYCLES macro to get time in > microseconds > > bsps/riscv/frdme310arty/clock/clockdrv.c > bsps/riscv/riscv/clock/clockdrv.c > - Delete both files and Add bsps/riscv/shared/clock/clockdrv.c > - riscv_clock_get_timebase_frequency(): Get timebase-frequency from > cpus or cpu@0 devicetree node because riscv uses "cpus" node and > frdme310arty uses "cpu@0" node to look for timebase-frequency > - Remove rtems_counter_initialize_converter() and > rtems_timecounter_simple_install() functions > > bsps/riscv/frdme310arty/include/bsp/riscv.h > - Remove unused frdme310arty_l2c_base; > > bsps/riscv/frdme310arty/start/bsp_fatal_halt.c > bsps/riscv/riscv/start/bsp_fatal_halt.c > - Delete this file and Add bsps/riscv/shared/start/bsp_fatal_halt.c > > bsps/riscv/frdme310arty/start/bspstart.c > - Remove unused function riscv_get_node_byname() > > bsps/riscv/frdme310arty/start/linkcmds.in > - Use @RISCV_RAM_REGION_BEGIN@ and @RISCV_RAM_REGION_SIZE@ instead of > hard coded values > > c/src/lib/libbsp/riscv/frdme310arty/Makefile.am > - librtemsbsp_a_SOURCES -> bsps/riscv/shared/start/bsp_fatal_halt.c > - librtemsbsp_a_SOURCES -> bsps/riscv/shared/clock/clockdrv.c > > c/src/lib/libbsp/riscv/frdme310arty/configure.ac > - change RISCV_RAM_REGION_SIZE to default 256MiB > > bsps/riscv/riscv/irq/irq.c > - Delete this irq.c and it will now use bsps/riscv/shared/irq/irq.c > > c/src/lib/libbsp/riscv/riscv/Makefile.am > - librtemsbsp_a_SOURCES -> bsps/riscv/shared/start/bsp_fatal_halt.c > - librtemsbsp_a_SOURCES -> bsps/riscv/shared/clock/clockdrv.c > - librtemsbsp_a_SOURCES -> bsps/riscv/shared/irq/irq.c > > Pragnesh Patel (2): > riscv: add freedom E310 Arty A7 bsp > bsp/riscv: Remove duplicate files > > bsps/include/bsp/fatal.h | 6 +- > bsps/riscv/frdme310arty/btimer/btimer.c | 104 ++++++ > bsps/riscv/frdme310arty/config/frdme310arty.cfg | 11 + > bsps/riscv/frdme310arty/console/console-config.c | 146 ++++++++ > bsps/riscv/frdme310arty/console/uart.c | 100 ++++++ > bsps/riscv/frdme310arty/dts/frdme310arty.dts | 130 +++++++ > .../frdme310arty/dts/frdme310arty_dtb_array.c | 259 ++++++++++++++ > bsps/riscv/frdme310arty/headers.am | 15 + > bsps/riscv/frdme310arty/include/bsp.h | 57 ++++ > bsps/riscv/frdme310arty/include/bsp/fe310_uart.h | 42 +++ > bsps/riscv/frdme310arty/include/bsp/irq.h | 73 ++++ > bsps/riscv/frdme310arty/include/bsp/riscv.h | 59 ++++ > bsps/riscv/frdme310arty/include/tm27.h | 334 ++++++++++++++++++ > bsps/riscv/frdme310arty/start/bsp_specs | 9 + > bsps/riscv/frdme310arty/start/bspstart.c | 204 +++++++++++ > bsps/riscv/frdme310arty/start/linkcmds.in | 49 +++ > bsps/riscv/frdme310arty/start/start.S | 147 ++++++++ > bsps/riscv/riscv/clock/clockdrv.c | 212 ------------ > bsps/riscv/riscv/irq/irq.c | 379 > --------------------- > bsps/riscv/riscv/start/bsp_fatal_halt.c | 53 --- > bsps/riscv/shared/clock/clockdrv.c | 231 +++++++++++++ > bsps/riscv/shared/irq/irq.c | 379 > +++++++++++++++++++++ > bsps/riscv/shared/start/bsp_fatal_halt.c | 53 +++ > c/src/lib/libbsp/riscv/acinclude.m4 | 2 + > c/src/lib/libbsp/riscv/frdme310arty/Makefile.am | 75 ++++ > c/src/lib/libbsp/riscv/frdme310arty/configure.ac | 68 ++++ > c/src/lib/libbsp/riscv/riscv/Makefile.am | 6 +- > 27 files changed, 2555 insertions(+), 648 deletions(-) > create mode 100644 bsps/riscv/frdme310arty/btimer/btimer.c > create mode 100644 bsps/riscv/frdme310arty/config/frdme310arty.cfg > create mode 100644 bsps/riscv/frdme310arty/console/console-config.c > create mode 100644 bsps/riscv/frdme310arty/console/uart.c > create mode 100644 bsps/riscv/frdme310arty/dts/frdme310arty.dts > create mode 100644 bsps/riscv/frdme310arty/dts/frdme310arty_dtb_array.c > create mode 100644 bsps/riscv/frdme310arty/headers.am > create mode 100644 bsps/riscv/frdme310arty/include/bsp.h > create mode 100644 bsps/riscv/frdme310arty/include/bsp/fe310_uart.h > create mode 100644 bsps/riscv/frdme310arty/include/bsp/irq.h > create mode 100644 bsps/riscv/frdme310arty/include/bsp/riscv.h > create mode 100644 bsps/riscv/frdme310arty/include/tm27.h > create mode 100644 bsps/riscv/frdme310arty/start/bsp_specs > create mode 100644 bsps/riscv/frdme310arty/start/bspstart.c > create mode 100644 bsps/riscv/frdme310arty/start/linkcmds.in > create mode 100644 bsps/riscv/frdme310arty/start/start.S > delete mode 100644 bsps/riscv/riscv/clock/clockdrv.c > delete mode 100644 bsps/riscv/riscv/irq/irq.c > delete mode 100644 bsps/riscv/riscv/start/bsp_fatal_halt.c > create mode 100644 bsps/riscv/shared/clock/clockdrv.c > create mode 100644 bsps/riscv/shared/irq/irq.c > create mode 100644 bsps/riscv/shared/start/bsp_fatal_halt.c > create mode 100644 c/src/lib/libbsp/riscv/frdme310arty/Makefile.am > create mode 100644 c/src/lib/libbsp/riscv/frdme310arty/configure.ac > > -- > 2.7.4 > > _______________________________________________ > devel mailing list > devel@rtems.org > http://lists.rtems.org/mailman/listinfo/devel -- Hesham _______________________________________________ devel mailing list devel@rtems.org http://lists.rtems.org/mailman/listinfo/devel