Re: Extending the number of PMP entries


Mr Tariq Kurd <tariq.kurd@...>
 

yes, fair enough.

Leaving it unrestricted is certainly the most flexible way

 

Tariq

 

From: tech-privileged@... [mailto:tech-privileged@...] On Behalf Of Allen Baum
Sent: 01 June 2020 23:26
To: Andrew Waterman <andrew@...>
Cc: Tariq Kurd <tariq.kurd@...>; tech-privileged@...
Subject: Re: [RISC-V] [tech-privileged] Extending the number of PMP entries

 

The only reason that you might want to enforce some ordering is just so setup code doesn't have to check every single entry to see if it's writable or not. 

That is not a great reason for something that is only executed once at boot time.

 

On Sun, May 31, 2020 at 5:13 PM Andrew Waterman <andrew@...> wrote:

I've merged the pull request, but comments are obviously still welcome.  I recommend adding them on github at https://github.com/riscv/riscv-isa-manual/pull/525 to reduce the likelihood that they get lost.

 

On Fri, May 22, 2020 at 3:31 PM Andrew Waterman <andrew@...> wrote:

I've made a pull request to extend the number of PMP entries, and have attached the compiled PDF for convenience.  Feedback and error detection are appreciated: the fact that there used to be 16 PMP entries manifested in several places in the document.

 

 

On Fri, May 22, 2020 at 12:30 AM Tariq Kurd <tariq.kurd@...> wrote:

Hi Andrew,

 

That’s fine for me. Implementing 0 / 16 / 64 PMP entries is ok

 

Tariq

 

From: Andrew Waterman [mailto:andrew@...]
Sent: 21 May 2020 17:50
To: Tariq Kurd <tariq.kurd@...>
Cc: tech-privileged@...
Subject: Re: [RISC-V] [tech-privileged] Extending the number of PMP entries

 

 

 

On Thu, May 21, 2020 at 8:17 AM Mr Tariq Kurd <tariq.kurd@...> wrote:

Hi everyone,

 

Can we allocate more CSRs so that we can have more PMP entries available? We already have one implementation which requires 20 PMP entries, for example.

Currently the CSR address space can allow up to 64 PMP entries (unless CSRs have been allocated which I don’t know about).

0x3A4 – 0x3AF could become pmpcfg4-15

0x3C0 – 0x3EF could become pmpaddr16-63

 

64 entries would be more than enough (I don’t envisage needing more than 32), but I don’t know about other users.

 

I’m happy to allocate the PMP entries in blocks of 16, for example, and make higher numbered unused entries read-only-zero to save area.

So in our case we would implement the CSRs for 32 entries, but entries 20-31 would be read-only-zero

The other option here is to allocate all 48 at once (and for your example 20-63 would be read-only-zero). This might be slightly easier for software portability and is neutral for HW cost.

 

 

What do people think?

👍

 

Tariq

 

Tariq Kurd

Processor Design I RISC-V Cores, Bristol

Tel: none I Mobile: +447711069063 I E-mail: Tariq.Kurd@...

Company: Huawei I Address: 160 Aztec West, Bristol, UK, BS32 4TU

315px-Huawei    http://www.huawei.com

This e-mail and its attachments contain confidential information from HUAWEI, which is intended only for the person or entity whose address is listed above. Any use of the information contained herein in any way (including, but not limited to, total or partial disclosure,reproduction, or dissemination) by persons other than the intended recipient(s) is prohibited. If you receive this e-mail in error, please notify the sender by phone or email immediately and delete it !

本邮件及其附件含有华为公司的保密信息,仅限于发送给上面 地址中列出的个人或群组。禁止任何其他人以任何形式使用(包括但不限于全部或部分地泄露、复制、或散发)本邮件中的信息。如果您错收了本邮件,请您立即电话或邮件通知发件人并删除本邮件!

 

 

Join tech-privileged@lists.riscv.org to automatically receive all group messages.