Comments (13)
@davideschiavone It would be good to ask Shteryana Shopova and Robert Balas about interrupt mapping, since they have more OS experience.
from core-v-mcu.
@bluewww do you have any suggestions? I don't have Shteryana Shopova GitHub ID, nor Greg Martin's one
from core-v-mcu.
@davideschiavone @shteryona is the GitHub ID you need
from core-v-mcu.
An idea for interrupts. but first a clarification comment. We have irqs 3,7, and 11 and 16-31 supported by the cv32e40p, My understanding is irq3 is a software request, Irq7 is Mtime and irq11 is machine interrupt. Is this correct? Does the core-v-mcu support or should we be supporting an MTIMER for IRQ7? This seems to be a good place for an OS periodic timed interrupt. Could that be a rearrangement of the current timer_unit interrupts? or should it be a new timer entity? (currently irq10 and irq11 are TimerL0 and TimerHI). I would propose we connect irq10 to irq7 for MTIME. IRQ11 would seem to be a good match for the event interrupts. The current system routes the udma (and other?) events through an event fifo that seems appropriate for user expandability. That leaves the higher priority interrupts for real time critical applications.
from core-v-mcu.
@gmartin102 . The interrupt mapping should be decided by you, @bluewww and @shteryona .
What you propose looks fine to me, i.e. mapping
PULP IRQ 10 to CV32E4 IRQ 7.
PULP IRQ 26 to CV32E4 IRQ 11 (i.e. event fifo)
And all the rest in the fast interrupts.
We can also attach
PULP IRQ 0 to CV32E4 IRQ 3 (as PULP 0 to 3 are SW interrupts AFAIK)
Please write a proposal and discuss with the SW team ( @bluewww and @shteryona ) as well to have freeRTOS aligned.
Then we can document it, and I will make the changes in the RTL.
does it sound good for you?
and I can integrate that in the RTL
from core-v-mcu.
@davideschiavone
Yes This sounds good, I'll pull a slide together that outlines the basic plan. I'm not completely familiar with all the events -- I count 168 of them and most seem to be place holders? and we seem to have half a dozen or so fast interrupts defined. should have this available in a the next day .. certainly before Friday's discussion
from core-v-mcu.
@davideschiavone I think this is a reasonable mapping.
One thing we have to check yet if the timer that is currently mapped to PULP IRQ 10 can fulfill the properties outlined in the riscv-privileged document with respect to mtime
, mtimecmp
. Shteryana has made some arguments that this might be the case.
from core-v-mcu.
Attached is a proposal for the interrupt mapping.
Core-Interrupt.pdf
from core-v-mcu.
@davideschiavone I think this is a reasonable mapping.
One thing we have to check yet if the timer that is currently mapped to PULP IRQ 10 can fulfill the properties outlined in the riscv-privileged document with respect tomtime
,mtimecmp
. Shteryana has made some arguments that this might be the case.
I think lowRISC's OpenTitat has exactly the TIMER you are looking for:
https://github.com/lowRISC/opentitan/blob/master/hw/top_earlgrey/rtl/autogen/top_earlgrey.sv#L816
Here the RV TIMER is attached directly to the Ibex core
Here the Timer: https://github.com/lowRISC/opentitan/blob/master/hw/ip/rv_timer/rtl/rv_timer.sv
It probably needs some hack to translate the input and output port registers:
input tlul_pkg::tl_h2d_t tl_i,
output tlul_pkg::tl_d2h_t tl_o,
Here the definition of this interface protocol
https://docs.opentitan.org/hw/ip/tlul/doc/index.html
If one can do the TUL2APB and APB2TUL bridges or directly modify their core (which I would not recomend)
that would be perfect
from core-v-mcu.
Just came to my mind that as Ibex speaks OBI, there must be an adapter OBI2TUL, and indeed
https://github.com/lowRISC/opentitan/blob/master/hw/ip/rv_core_ibex/rtl/rv_core_ibex.sv
It's not the best, but one can use this, or starting from that, developing the TUL2APB and viceversa.
from core-v-mcu.
Re: integrating CV32E40P, it appears there is a file reference to ./rtl/include/cv32e40p_fpu_pkg.sv
missing in the cv32e40p/src_files.yml
file.
I added the following to core-v-mcu/ips_list.yml
:
cv32e40p:
commit: master
server: https://github.com
group: openhwgroup
and ran update-ips, and it adds the source files for the core in core-v-mcu/ips
and updates the core-v-mcu build scripts, but when running synthesis there are errors with missing fpu package. When I add cv32e40p_fpu_pkg.sv
to the src_files.yml
file, re-run update-ips, and then proceed to the FPGA flow, everything builds. I guess that should be a issue for cv32e40?
from core-v-mcu.
Hi @hpollittsmith , the cv32e40p integration is on me and it is tracked in this pull request:
MikeOpenHWGroup/pulp_soc#1
once this is done I will issue a PR against the core-v-mcu branch that @zarubaf created that is aligned to PULPissimo.
Please let's not duplicate tasks. I will handle this tasks as I assigned them to me so that we keep aligned and fresh with PULPissimo
from core-v-mcu.
Guys, the module should now be flattened inside the rtl/
directory with the changes applied.
from core-v-mcu.
Related Issues (20)
- [BUG] Problems building the documentation HOT 3
- [TASK] uDMA: peripheral selects HOT 1
- Add programming example for micro-DMA function HOT 5
- Complete the APB Advance Timer chapter of the User Manual HOT 2
- [Clean] PER_ID in udma subsystem is not unique HOT 1
- portmacro.h file error and creating my own app using c compiler HOT 2
- [BUG] <IO control regs offset in apb_soc_ctrl> HOT 3
- Combinatorial loop on `s_block_int`
- [BUG]<build verilator model library> HOT 7
- Using the A2 bootloader to program flash memory HOT 4
- [BUG] Unable to read switch status it always return 1 HOT 10
- cli_test on Genesys2 HOT 3
- How to totally customize UDMA subsystem with pulp_soc_defines header file ? HOT 1
- UART DPI error in Vivado Version 2022.2 HOT 1
- [BUG] SDIO write problem
- [BUG] FlashID is read incorrectly in a2_boot/main.c HOT 4
- Problem when emulating on nexys HOT 3
- [DOCUMENATION] [QUESTION] Purpose of uDMA QSPI Full-Duplex Command HOT 4
- [Help] Enabling Full duplex Transfer mode for SPI HOT 1
- [BUG] docs sphinx_markdown_tables __init__() takes 2 but 3 given HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from core-v-mcu.