{"id":20429041,"url":"https://github.com/pp3345/sysfs-msrs","last_synced_at":"2026-04-20T14:33:53.462Z","repository":{"id":144978107,"uuid":"186150178","full_name":"pp3345/sysfs-msrs","owner":"pp3345","description":"A Linux kernel module that exposes x86 CPU MSRs via sysfs","archived":false,"fork":false,"pushed_at":"2019-05-11T15:54:44.000Z","size":7,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-05T05:32:31.345Z","etag":null,"topics":["linux","msr","x86"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/pp3345.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-11T15:31:43.000Z","updated_at":"2023-03-11T22:30:43.000Z","dependencies_parsed_at":"2024-04-13T22:31:00.256Z","dependency_job_id":null,"html_url":"https://github.com/pp3345/sysfs-msrs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pp3345/sysfs-msrs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pp3345%2Fsysfs-msrs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pp3345%2Fsysfs-msrs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pp3345%2Fsysfs-msrs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pp3345%2Fsysfs-msrs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pp3345","download_url":"https://codeload.github.com/pp3345/sysfs-msrs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pp3345%2Fsysfs-msrs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32050938,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-20T11:35:06.609Z","status":"ssl_error","status_checked_at":"2026-04-20T11:34:48.899Z","response_time":94,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["linux","msr","x86"],"created_at":"2024-11-15T07:32:43.769Z","updated_at":"2026-04-20T14:33:53.426Z","avatar_url":"https://github.com/pp3345.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sysfs-msrs\nA Linux kernel module that allows to read and write x86 CPU MSRs (machine-specific registers) via sysfs. This was created as a \nlearning project and does not necessarily serve a useful purpose. The code is somewhat messy and there are some issues, e.g., \nwrite-only registers are not properly exposed and registers with ambiguous addresses are not correctly handled.\n\nCurrently only \"Architectural MSRs\" as defined by the _Intel® 64 and IA-32 Architectures Software Developer’s Manual_ are \nsupported, though it can be easily extended for microarchitecture-specific MSRs by adding them to `msrs.h`.\n\n## Build\n```bash\n$ git clone https://github.com/pp3345/sysfs-msrs.git\n$ cd sysfs-msrs\n$ make -C /path/to/linux/kernel/source M=$(pwd)\n$ # OR (if building against distribution kernel, might require installing kernel-devel or similar package)\n$ make -C /usr/lib/modules/`uname -r`/build M=$(pwd)\n```\n\n## Installation\n```bash\n$ sudo make -C /path/to/linux/kernel/source M=$(pwd) modules_install\n$ # OR (if building against distribution kernel)\n$ sudo make -C /usr/lib/modules/`uname -r`/build M=$(pwd) modules_install\n```\n\n## Usage\n```bash\n$ sudo modprobe sysfs-msrs\n$ cd /sys/devices/system/cpu/cpuN/msrs # where N is the logical ID of the CPU you're interested in\n$ ls -l\ntotal 0\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_APERF\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_APIC_BASE\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_A_PMC0\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_A_PMC1\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_A_PMC2\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_A_PMC3\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_BIOS_SIGN_ID\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_BNDCFGS\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_CLOCK_MODULATION\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_CPU_DCA_CAP\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_CSTAR\n-rw-rw----. 1 root root 4096 May 11 17:30 IA32_DEBUGCTL\n# ...\n$ sudo cat IA32_FEATURE_CONTROL # read MSR\n$ echo 1 | sudo tee IA32_PEBS_ENABLE # write MSR\n```\n\n**Use with caution.**\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpp3345%2Fsysfs-msrs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpp3345%2Fsysfs-msrs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpp3345%2Fsysfs-msrs/lists"}