linux-openrisc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/3] openrisc: Add cacheinfo support and introduce new utility functions
@ 2025-03-23 19:55 Sahil Siddiq
  2025-03-23 19:55 ` [PATCH v3 1/3] openrisc: Refactor struct cpuinfo_or1k to reduce duplication Sahil Siddiq
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Sahil Siddiq @ 2025-03-23 19:55 UTC (permalink / raw)
  To: jonas, stefan.kristiansson, shorne; +Cc: sahilcdq, linux-openrisc, linux-kernel

Hi,

This patch series is substantially different from the previous two
versions. I have split the previous versions into 3 patches as follows:
1. Refactor struct cpuinfo_or1k.
2. Introduce new utility functions and check existence of cache
   components.
3. Add cacheinfo support.

The main purpose of this series is to expose CPU cache attributes for
OpenRISC in sysfs using the cacheinfo API. The core implementation
to achieve this is in patch #3. Patch #1 and #2 add certain enhancements
to simplify the implementation of cacheinfo support.

Patch #1 removes duplication of cache-related data members in struct
cpuinfo_or1k.

Patch #2 introduces several utility functions. One set of functions is
used to check if the cache components and SPRs exist before attempting
to use them. The other set provides a convenient interface to flush or
invalidate a range of cache blocks.

Thanks,
Sahil

Sahil Siddiq (3):
  openrisc: Refactor struct cpuinfo_or1k to reduce duplication
  openrisc: Introduce new utility functions to flush and invalidate
    caches
  openrisc: Add cacheinfo support

 arch/openrisc/include/asm/cacheflush.h |  17 ++++
 arch/openrisc/include/asm/cpuinfo.h    |  58 ++++++++++++--
 arch/openrisc/kernel/Makefile          |   2 +-
 arch/openrisc/kernel/cacheinfo.c       | 104 +++++++++++++++++++++++++
 arch/openrisc/kernel/dma.c             |  18 +----
 arch/openrisc/kernel/setup.c           |  39 ----------
 arch/openrisc/mm/cache.c               |  52 +++++++++++--
 arch/openrisc/mm/init.c                |   5 +-
 8 files changed, 224 insertions(+), 71 deletions(-)
 create mode 100644 arch/openrisc/kernel/cacheinfo.c


base-commit: ea1413e5b53a8dd4fa7675edb23cdf828bbdce1e
-- 
2.48.1


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2025-03-28 19:40 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-23 19:55 [PATCH v3 0/3] openrisc: Add cacheinfo support and introduce new utility functions Sahil Siddiq
2025-03-23 19:55 ` [PATCH v3 1/3] openrisc: Refactor struct cpuinfo_or1k to reduce duplication Sahil Siddiq
2025-03-26 16:50   ` Stafford Horne
2025-03-23 19:55 ` [PATCH v3 2/3] openrisc: Introduce new utility functions to flush and invalidate caches Sahil Siddiq
2025-03-26 17:11   ` Stafford Horne
2025-03-28 19:40     ` Sahil Siddiq
2025-03-23 19:55 ` [PATCH v3 3/3] openrisc: Add cacheinfo support Sahil Siddiq
2025-03-23 22:52   ` kernel test robot
2025-03-26 17:13   ` Stafford Horne

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).