Skip to content

ISA string parser cleanups

Conor Dooley linux-devicetree linux-riscv 3 versions – Applied

Status from this message: Applied, thanks!

Get series with b4
b4 am 20230607-audacity-overhaul-82bb867a825f@spud

Versions newest first · linked by author and title

  1. v3 Latest7 patches 6 repliesApplied 7/7
  2. v28 patches 0 repliesSuperseded
  3. v17 patches 10 repliesSuperseded

Changes in v3 from the cover letter

- Rebase on top of ACPI support & drop a patch that landed in that series

Patches in v3 All 7 applied

#Subject and filesSizeRepliesApplied
1/7RISC-V: simplify register width check in ISA string parsingarch/riscv/kernel/cpufeature.c+7 -81 replyApplied
2/7RISC-V: split early & late of_node to hartid mappingarch/riscv/include/asm/processor.h arch/riscv/kernel/cpu.c arch/riscv/kernel/smpboot.c+23 -21 replyApplied
3/7RISC-V: validate riscv,isa at boot, not during ISA string parsingarch/riscv/kernel/cpu.c arch/riscv/kernel/cpufeature.c+11 -91 replyApplied
4/7RISC-V: rework comments in ISA string parserarch/riscv/kernel/cpufeature.c+59 -110 repliesApplied
5/7RISC-V: remove decrement/increment dance in ISA string parserarch/riscv/kernel/cpufeature.c+6 -81 replyApplied
6/7dt-bindings: riscv: explicitly mention assumption of Zicntr & Zihpm supportDocumentation/devicetree/bindings/riscv/cpus.yaml+2 -21 replyApplied
7/7RISC-V: always report presence of extensions formerly part of the base ISAarch/riscv/include/asm/hwcap.h arch/riscv/kernel/cpu.c arch/riscv/kernel/cpufeature.c+25 -00 repliesApplied

Reviews trailers per patch

6 of 7 patches have a Reviewed-by or Acked-by.

PatchAndrew JonesSunil V LRob Herring
1/7R-b R-b
2/7R-b R-b
3/7R-b R-b
4/7R-b
5/7R-b R-b
6/7A-b
7/7

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v3 thread

Cover letter [PATCH v3 0/7] ISA string parser cleanups

From: Conor Dooley <[email protected]>

With that out of the way, here are some cleanups for our riscv,isa handling.

Here are some bits that were discussed with Drew on the "should we allow caps" threads that I have now created patches for:
- splitting of riscv_of_processor_hartid() into two distinct functions, one for use purely during early boot, prior to the establishment of the possible-cpus mask & another to fit the other current use-cases
- that then allows us to then completely skip some validation of the hartid in the parser
- the biggest diff in the series is a rework of the comments in the parser, as I have mostly found the existing (sparse) ones to not be all that helpful whenever I have to go back and look at it
- from writing the comments, I found a conditional doing a bit of a dance that I found counter-intuitive, so I've had a go at making that match what I would expect a little better
- i implies 4 other extensions, so add them as extensions and set them for the craic. Sure why not like...

There's a trivial numbering conflict with Evan's Zb* additions. The other thing to consider is whether some of the extensions I am explicitly enabling make sense in the context of ACPI. I've made sure not to enable them where I am not sure.

Cheers,
Conor.

Changes in v3:
- Rebase on top of ACPI support & drop a patch that landed in that series

Changes in v2:
- Pick up tags on most patches
- Drop some dt specifics from a parser comment
- Add Zicntr and Zihpm to the "always report" patch
- Note the Zicntr and Zihpm bits in the binding in a new patch.

CC Paul Walmsley <[email protected]>
CC Palmer Dabbelt <[email protected]>
CC Conor Dooley <[email protected]>
CC Andrew Jones <[email protected]>
CC Sunil V L <[email protected]>
CC Yangyu Chen <[email protected]>
CC Rob Herring <[email protected]>
CC Krzysztof Kozlowski <[email protected]>

Conor Dooley (7):
RISC-V: simplify register width check in ISA string parsing
RISC-V: split early & late of_node to hartid mapping
RISC-V: validate riscv,isa at boot, not during ISA string parsing
RISC-V: rework comments in ISA string parser
RISC-V: remove decrement/increment dance in ISA string parser
dt-bindings: riscv: explicitly mention assumption of Zicntr & Zihpm
support
RISC-V: always report presence of extensions formerly part of the base
ISA

 .../devicetree/bindings/riscv/cpus.yaml       |   4 +-
 arch/riscv/include/asm/hwcap.h                |   4 +
 arch/riscv/include/asm/processor.h            |   1 +
 arch/riscv/kernel/cpu.c                       |  34 +++++-
 arch/riscv/kernel/cpufeature.c                | 108 ++++++++++++++----
 arch/riscv/kernel/smpboot.c                   |   2 +-
 6 files changed, 123 insertions(+), 30 deletions(-)

base-commit: 748462b59f901557377b2c33ea9808ff2000e141

Signature · 7 lines
2.39.2


_______________________________________________
linux-riscv mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-riscv