<feed xmlns='http://www.w3.org/2005/Atom'>
<title>opensbi.git/lib/utils/irqchip, branch v1.5</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://cgit.235523.xyz/opensbi.git/atom/lib/utils/irqchip?h=v1.5</id>
<link rel='self' href='http://cgit.235523.xyz/opensbi.git/atom/lib/utils/irqchip?h=v1.5'/>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/'/>
<updated>2024-06-13T13:03:52Z</updated>
<entry>
<title>lib: utils/irqchip: Skip initialize irqchip when dt is not enabled</title>
<updated>2024-06-13T13:03:52Z</updated>
<author>
<name>Xiang W</name>
<email>wxjstz@126.com</email>
</author>
<published>2024-06-11T11:19:30Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=b1c7c750f75dc027602688e4cb192d7b883c71d3'/>
<id>urn:sha1:b1c7c750f75dc027602688e4cb192d7b883c71d3</id>
<content type='text'>
When the dt node has a status property and the value is not ok or
okay, skip initializing irqchip.

Signed-off-by: Xiang W &lt;wxjstz@126.com&gt;
Reviewed-by: Anup Patel &lt;anup@brainfault.org&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Add sanity checks in imsic_get_data() and imsic_get_target_file()</title>
<updated>2024-05-23T05:21:29Z</updated>
<author>
<name>Cyan Yang</name>
<email>cyan.yang@sifive.com</email>
</author>
<published>2024-05-16T08:32:43Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=858754a54470ad0dbbced7838b17054ccd3b96de'/>
<id>urn:sha1:858754a54470ad0dbbced7838b17054ccd3b96de</id>
<content type='text'>
Add extra sanity checks to prevent the caller getting the invalid result from
imsic_get_data() or imsic_get_target_file() when imsic is not initialized
correctly.

Signed-off-by: Cyan Yang &lt;cyan.yang@sifive.com&gt;
Reviewed-by: Anup Patel &lt;anup@brainfault.org&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Check before initializing imsic</title>
<updated>2024-05-16T04:51:16Z</updated>
<author>
<name>Cheng Yang</name>
<email>yangcheng.work@foxmail.com</email>
</author>
<published>2024-05-15T06:15:14Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=e3a30a2c918aae79d4cc403d474c3d2872a9063c'/>
<id>urn:sha1:e3a30a2c918aae79d4cc403d474c3d2872a9063c</id>
<content type='text'>
The current mlevel imsic check is only for the platform, which
may cause hart without imsic in the platform to trigger an
illegal instruction exception when initializing imsic. For
example, the platform contains a management hart that only
supports wired interrupts.

This patch will check if each hart supports Smaia extension
before doing imsic initialization to avoid triggering illegal
instruction exceptions.

Signed-off-by: Cheng Yang &lt;yangcheng.work@foxmail.com&gt;
Reviewed-by: Anup Patel &lt;anup@brainfault.org&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Remove regs paramter of sbi_irqchip_process()</title>
<updated>2024-03-19T06:01:33Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2024-03-11T12:23:41Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=d84e7eb7f0848225e10131ca4b9e1571d78cdabd'/>
<id>urn:sha1:d84e7eb7f0848225e10131ca4b9e1571d78cdabd</id>
<content type='text'>
The irqchip handlers will typically not need pointer to trap registers
so remove regs parameter of sbi_irqchip_process().

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
Reviewed-by: Samuel Holland &lt;samuel.holland@sifive.com&gt;
Tested-by: Samuel Holland &lt;samuel.holland@sifive.com&gt;
Reviewed-by: Clément Léger &lt;cleger@rivosinc.com&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Add shared MMIO region for PLIC in root domain</title>
<updated>2023-12-19T10:26:37Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-12-11T08:37:56Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=cdebae2cc9539e2e0553b9c68eab22997c734cbb'/>
<id>urn:sha1:cdebae2cc9539e2e0553b9c68eab22997c734cbb</id>
<content type='text'>
On platforms with Smepmp, the MMIO regions accessed by M-mode need
to be explicitly marked with M-mode only read/write or shared (both
(M-mode and S-mode) read/write permission.

If the above is not done then runtime PLIC access from M-mode on
platforms with Smepmp will result in access fault when further
results in CPU hotplug not working.

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Allow relaxed MMIO writes in device ipi_send() callback</title>
<updated>2023-11-26T13:15:06Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-11-21T09:19:42Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=f520256d03da84e7ff8bddd084ef873192f46304'/>
<id>urn:sha1:f520256d03da84e7ff8bddd084ef873192f46304</id>
<content type='text'>
Currently, we have a smp_wmb() between atomic_raw_set_bit() and
ipi_send() device callback whereas the MMIO writes done by the
device ipi_send() callback will also include a barrier.

We can avoid unnecessary/redundant barriers described above by
allowing relaxed MMIO writes in device ipi_send() callback. To
achieve this, we simply use  wmb() instead of smp_wmb() before
calling device ipi_send().

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
Reported-by: Bo Gan &lt;ganboing@gmail.com&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Avoid redundant writes to APLIC CLRIE register</title>
<updated>2023-11-24T07:18:41Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-11-21T06:04:14Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=791704cd09c019decf438f6e4f56423cc95cb66a'/>
<id>urn:sha1:791704cd09c019decf438f6e4f56423cc95cb66a</id>
<content type='text'>
Each APLIC CLRIE register allows disabling 32 interrupt sources at
a time by writing -1 so no need to write CLRIE register separately
for each interrupt source.

Fixes: 99792653de29 ("lib: utils/irqchip: Add APLIC initialization library")
Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
Reviewed-by: Atish Patra &lt;atishp@rivosinc.com&gt;
</content>
</entry>
<entry>
<title>lib: sbi: Prefer hartindex over hartid in IPI framework</title>
<updated>2023-09-24T06:09:38Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-09-01T12:11:07Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=78c667b6fc07d2ea783fbd18f43a3f8191de6164'/>
<id>urn:sha1:78c667b6fc07d2ea783fbd18f43a3f8191de6164</id>
<content type='text'>
Let us prefer hartindex over hartid in IPI framework which in-turn
forces IPI users to also prefer hartindex.

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Use scratch space to save per-HART IMSIC pointer</title>
<updated>2023-06-06T10:31:14Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-04-20T04:48:08Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=355796c5bc1906d749850e4215e0f7f53802ba5b'/>
<id>urn:sha1:355796c5bc1906d749850e4215e0f7f53802ba5b</id>
<content type='text'>
Instead of using a global array indexed by hartid, we should use
scratch space to save per-HART IMSIC pointer and IMSIC file number.

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
Reviewed-by: Andrew Jones &lt;ajones@ventanamicro.com&gt;
</content>
</entry>
<entry>
<title>lib: utils/irqchip: Don't check hartid in imsic_update_hartid_table()</title>
<updated>2023-06-05T11:21:07Z</updated>
<author>
<name>Anup Patel</name>
<email>apatel@ventanamicro.com</email>
</author>
<published>2023-04-20T04:44:43Z</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/opensbi.git/commit/?id=1df52fa7e8db2c23a921014404bd472d20ca42e8'/>
<id>urn:sha1:1df52fa7e8db2c23a921014404bd472d20ca42e8</id>
<content type='text'>
The imsic_map_hartid_to_data() already checks hartid before using
so we don't need to check in imsic_update_hartid_table().

Signed-off-by: Anup Patel &lt;apatel@ventanamicro.com&gt;
Reviewed-by: Andrew Jones &lt;ajones@ventanamicro.com&gt;
</content>
</entry>
</feed>
