lsgpu(1)

πŸ’– lsgpu β€” the manual page, bestie edition πŸ’–

okay so you opened lsgpu(1) and you want the tea? say less. this is the whole page, every flag, every path, every vibe. no cap. 🫢


✨ NAME ✨

lsgpu β€” list and inspect GPUs by scanning the PCI bus, DRM, and sysfs

literally what it says on the tin, and honestly? iconic.


🌸 SYNOPSIS 🌸

lsgpu [OPTIONS]

that's it. that's the whole thing. one command, all the options. she's low maintenance. πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

so lsgpu is part of the igt-gpu-tools suite, and she was literally designed to help with GPU enumeration and debugging. think of her as your group chat's most organized friend who knows exactly which GPU is which and will not let you forget it. πŸ”₯

we're talking a command-line tool for listing and inspecting the GPUs hanging out on your system. she scans the PCI bus, the DRM subsystem, and sysfs to gather up all the info about detected GPU devices and their properties. all three. the whole scavenger hunt. ✨

by default, lsgpu shows you a list of GPUs with the basic details. but bestie, that's just the appetizer. the tool also supports extra options to:

  • print detailed properties and sysfs attributes
  • apply filters so you can pick out specific devices
  • verify access permissions to GPU nodes

filtering happens with the -d or --device option, and it lets you match GPUs based on vendor, PCI attributes, or other criteria. πŸŽ€ heads up though: when you apply a filter, only the first matching device is displayed. so don't come for her when you only see one result β€” that's the assignment.

on top of all that, lsgpu will try to open the matching DRM device nodes β€” /dev/dri/cardX and /dev/dri/renderDX β€” to check whether you actually have access permissions. nosy? maybe. useful? absolutely. 😌

she follows the IGT variable search order for picking the target device:

  1. The --device option, if provided
  2. The IGT_DEVICE environment variable, if set
  3. The .igtrc configuration file (Common::Device setting), if neither of the above is specified

it's giving ✨priority list energy✨ and honestly? respect.


πŸ’… OPTIONS πŸ’…

  • -h, --help β€” Show help text.
  • -n, --numeric β€” Print vendor/device as hex
  • -c, --codename β€” Print codename instead pretty device name
  • -s, --print-simple β€” Print simple (legacy) device details
  • -p, --print-details β€” Print devices with details
  • -P, --pci-scan β€” Print PCI GPU devices
  • -v, --list-vendors β€” List recognized vendors
  • -l, --list-filter-types β€” List registered device filters types
  • -d,--device <filter> β€” Apply a device filter (e.g. 'pci:vendor=Intel,device=discrete,card=0'). Can be used multiple times.
  • -V, --version β€” Print version information and exit
okay real talk: -d / --device can be used multiple times, so stack them filters like stickers on a laptop. 🫢 and copy that example filter exactly if you're using it, bestie β€” character for character. no improvising.

🌈 Default print mode options 🌈

these ones? only valid when you're using the default printout mode. don't try to sneak them in anywhere else, she will not play. πŸ™ˆ

  • --drm β€” Default: Print DRM filters for each device
  • --sysfs β€” Print sysfs filters for each device
  • --pci β€” Print PCI filters for each device

😭 REPORTING BUGS 😭

found a bug? spill. report bugs on fd.o GitLab:

https://gitlab.freedesktop.org/drm/igt-gpu-tools/-/issues
girl help, a bug πŸ’€ β€” but like, a reported one, which is the correct way to handle it.

πŸ‘‘ AUTHOR πŸ‘‘

IGT Developers <igt-dev@lists.freedesktop.org>


2009,2011,2012,2016,2018,2019,2020,2023,2024,2025 Intel Corporation


and that's the whole manual, bestie. this was lsgpu, served fresh from igt-gpu-tools 2.5, dated 2025-03-27. she ate, no crumbs, periodt. πŸ’–βœ¨πŸ¦‹πŸŒΈπŸ’…πŸ«Ά

πŸ“¦ where this page comes from