Skip to content

jason77-wang/linux-riscv-tracker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

linux-riscv-tracker Skill

A Copilot CLI skill for tracking RISC-V semiconductor news and testing Linux kernel patches from the linux-riscv mailing list.

Table of Contents


Overview

This skill provides two main capabilities:

  1. News Collection — Gather the latest product announcements, press releases, blog posts, and community updates from 25+ RISC-V semiconductor companies and generate reports in JSON, HTML, or PDF format.

  2. Patch Testing — Fetch patches from the linux-riscv mailing list (via lore.kernel.org), apply them to a local kernel tree, cross-compile for RISC-V, and boot-test in QEMU.


Prerequisites

For news collection

  • Python 3
  • reportlab (for PDF output): pip install reportlab
  • Internet access to fetch company websites

For patch testing

  • b4 — patch fetching tool: pip install b4
  • riscv64-linux-gnu-gcc — RISC-V cross-compiler
  • qemu-system-riscv64 — RISC-V QEMU emulator
  • opensbi — firmware for QEMU (/usr/lib/riscv64-linux-gnu/opensbi/generic/fw_dynamic.bin)
  • git — for branch management and patch application

Install on Ubuntu/Debian:

sudo apt install gcc-riscv64-linux-gnu qemu-system-misc opensbi git
pip install b4 reportlab

Collecting Semiconductor News

Get updates for a specific company

Ask the Copilot CLI:

get the latest news from SiFive
collect the latest Tenstorrent news
what are the latest updates from StarFive?

The skill will use the corresponding reference file (e.g., references/sifive-news.md) to know which URLs to scrape and how to parse the results.

Get updates for multiple companies

get the latest news from SiFive, Tenstorrent, and Andes
collect updates from all Chinese RISC-V companies (Alibaba DAMO, Nuclei, SpacemiT, ESWIN)

The skill fetches each company in parallel and consolidates results into a single report.

Get updates for all companies

get the latest news from all RISC-V semiconductors
collect news from all riscv companies and generate a report

This fetches updates from all 25+ supported companies and produces a comprehensive report.

Report formats

The skill can produce reports in three formats:

JSON (raw data)

The collected data is stored as a JSON file with this structure:

{
  "title": "Latest RISC-V Updates",
  "subtitle": "Weekly semiconductor news roundup",
  "report_date": "2026-05-08",
  "groups": [
    {
      "name": "SiFive",
      "items": [
        {
          "date": "2026-05-01",
          "type": "Press Release",
          "title": "SiFive Announces New P870 Core",
          "url": "https://www.sifive.com/press/...",
          "summary": "SiFive launched a new high-performance RISC-V core..."
        }
      ]
    }
  ]
}

HTML (standalone web page)

generate an HTML report for the RISC-V news

Uses assets/riscv_news_report_html_template.py:

python assets/riscv_news_report_html_template.py input.json output.html

Produces a self-contained HTML file with styled cards, vendor sections, and metadata tags.

PDF (printable document)

create a PDF version of the report

Uses assets/riscv_news_report_template.py:

python assets/riscv_news_report_template.py input.json output.pdf

Produces a formatted PDF with title page, grouped sections, and per-item metadata.


Fetching Patches from the Mailing List

List recent patches

list all new patches for riscv within 30 days
show me the latest patches on linux-riscv mailing list

The skill queries the lore.kernel.org archive using date ranges:

https://lore.kernel.org/linux-riscv/?q=d:YYYYMMDD..YYYYMMDD

Search patches by keyword or date

find patches related to vector extensions
list all riscv patches from May 8
search for memory management patches on linux-riscv

The skill uses lore.kernel.org search syntax and b4 to fetch matching series.


Testing Patches

Automatic patch test workflow

The assets/riscv-patch-test-workflow.sh script provides a complete automated pipeline:

./assets/riscv-patch-test-workflow.sh [options]

What it does:

  1. Checks prerequisites (b4, cross-compiler, QEMU, OpenSBI)
  2. Creates a test branch from the specified base
  3. Fetches patches (by Message-ID, keyword, or browsing latest)
  4. Applies patches with git am
  5. Builds the kernel (make ARCH=riscv O=<build-dir> Image)
  6. Boots the kernel in QEMU and checks for BUGs/Oops

Options:

Flag Description Default
-b, --branch BRANCH Base branch to apply patches on current branch
-m, --message-id MSGID Apply a specific patch by Message-ID
-k, --keyword KEYWORD Search patches by keyword
-n, --num-patches N Number of patches to show when browsing 20
-j, --jobs N Parallel build jobs $(nproc)
-o, --build-dir DIR Out-of-tree build directory build-riscv-test
-c, --config CONFIG Kernel config target defconfig
-q, --qemu-timeout SECS QEMU boot timeout 60
-r, --rootfs PATH Path to rootfs image for QEMU
-s, --skip-build Skip kernel build
-S, --skip-qemu Skip QEMU boot test
--no-apply Only list patches, don't apply
--dry-run Show what would be done

Examples:

# Interactive: browse latest patches, pick one, build & test
./assets/riscv-patch-test-workflow.sh

# Test a specific patch series by Message-ID
./assets/riscv-patch-test-workflow.sh -m 20260508120000.12345-1-author@example.com

# Search and test vector-related patches
./assets/riscv-patch-test-workflow.sh -k vector

# Just list latest patches without applying
./assets/riscv-patch-test-workflow.sh --no-apply

# Apply on a specific branch with custom build dir
./assets/riscv-patch-test-workflow.sh -b riscv/next -o /tmp/riscv-build -m <msgid>

# Dry-run to preview actions
./assets/riscv-patch-test-workflow.sh --dry-run -k "memory hotplug"

Test specific patches

Ask the Copilot CLI to test individual patches:

apply patch 20260508-riscv-copy-mc-v1-0-abc123@kernel.org and build and test it
fetch the zsmalloc patch series and test it on riscv-upstream branch

The skill will:

  1. Create a test branch
  2. Use b4 am to fetch the specific patch series
  3. Apply with git am
  4. Build with make ARCH=riscv O=build-riscv-test Image -j$(nproc)
  5. Boot in QEMU and check for errors

Test all patches from a specific date

apply all patches of May 08 and build the kernel and test it

The skill will:

  1. Search lore.kernel.org for all patches on that date
  2. Fetch each series with b4 am
  3. Apply them sequentially (skipping those that fail due to base mismatch)
  4. Build and boot-test the result
  5. Report which patches applied successfully and which failed

Manual step-by-step testing

If you prefer manual control:

# 1. Create a test branch
git checkout -b riscv/test-topic riscv-upstream

# 2. Fetch patches
b4 am -o /tmp/patches <message-id>

# 3. Apply
git am /tmp/patches/*.mbx

# 4. Build
make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- O=build-riscv-test defconfig
make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- O=build-riscv-test Image -j$(nproc)

# 5. Boot test
qemu-system-riscv64 -M virt -nographic -m 2G \
  -bios /usr/lib/riscv64-linux-gnu/opensbi/generic/fw_dynamic.bin \
  -kernel build-riscv-test/arch/riscv/boot/Image \
  -append "earlycon=sbi console=ttyS0"

# 6. Check results — look for BUG/Oops/WARNING in output
# Expected: kernel boots to "VFS: Unable to mount root fs" (normal without rootfs)

Supported Semiconductor Companies

Company Reference File
Ahead Computing references/aheadcomputing-news.md
Akeana references/akeana-news.md
Alibaba DAMO / XuanTie references/alibaba-damo-news.md
Andes Technology references/andes-news.md
BeagleBoard Foundation references/beagleboard-news.md
BOSC / XiangShan references/xiangshan-news.md
DeepComputing references/deepcomputing-news.md
ESWIN references/eswin-news.md
Metastone references/metastone-news.md
Microchip references/microchip-news.md
Milk-V references/milkv-news.md
NextSilicon references/nextsilicon-news.md
Nuclei references/nuclei-news.md
Orange Pi references/orangepi-news.md
Pine64 references/pine64-news.md
Qualcomm references/qualcomm-news.md
Rivos references/rivos-news.md
SiFive references/sifive-news.md
Sipeed references/sipeed-news.md
SpacemiT references/spacemit-news.md
StarFive references/starfive-news.md
Tenstorrent references/tenstorrent-news.md
UltraRISC references/ultrarisc-news.md
Ventana Micro references/ventana-news.md
Zhihe Computing references/zhihecomputing-news.md

Each reference file documents:

  • The company's website URL(s) to scrape
  • Which pages contain news/press releases/blog posts
  • How to parse the page structure
  • Fallback strategies if the primary URL is unreachable

File Structure

linux-riscv-tracker/
├── SKILL.md                          # Skill definition (used by Copilot CLI)
├── README.md                         # This file
├── assets/
│   ├── riscv-patch-test-workflow.sh  # Automated patch test pipeline
│   ├── riscv_news_report_template.py       # PDF report generator
│   ├── riscv_news_report_html_template.py  # HTML report generator
│   └── riscv_news_report_example.json      # Example JSON input
└── references/
    ├── sifive-news.md                # Per-company scraping instructions
    ├── tenstorrent-news.md
    ├── andes-news.md
    └── ... (25 reference files total)

Tips

  • No rootfs needed for basic testing: A kernel that boots to "VFS: Unable to mount root fs" is considered a PASS — it means the kernel initialized successfully.
  • MAINTAINERS conflicts: Some patch series target a different base commit. If git am fails, try git am --3way or skip the series.
  • Parallel news collection: When fetching all companies, the skill launches parallel requests for speed.
  • Date range syntax: lore.kernel.org uses d:YYYYMMDD..YYYYMMDD for date filtering.
  • b4 output: Produces .mbx files ready for git am. Use -o <dir> to control output location.

About

a skill to track the latest riscv news an kernel patches and could apply the patches to the kernel, build it and auto test the kernel with qemu

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors