How to downgrade hybrid (prime) nvidia driver?

Problem started with an automatic update which upgraded Nvidia driver from 510.XX to 515.XX.

Firstly I have tried several times downgrading to older driver through saved pacman cache but there was some weird bug with GreenWithEnvy which couldn’t detect NvidiaXCntrl?.

Secondly I tried my luck with GNOME Fedora. In the end it worked but I couldn’t fully utilise my nvidia GPU. And I returned back to KDE Manjaro with previously used image. I reinstalled Manjaro and tried manually installing driver following this tutorial linuxconfig.org-how-to-install-the-nvidia-drivers-on-manjaro-linux. I got stuck when I tried to install prime because of two packages (?-wayland and nvidia-utils-515) which couldn’t be installed since there was nvidia-utils-510 installed from manual install.

Lastly I installed latest full KDE Manjaro image (21.3.1-220624-linux515), installed video-hybrid-amd-nvidia-prime with mhwd (via GUI) and downgrading driver with a command sudo downgrade --ala-only nvidia but without success.

TL; DR
I would like to downgrade video-hybrid-amd-nvidia-prime Nvidia driver from 515.XX to 510.XX.

Any help is appreciated :slight_smile:

.
This is mine inxi -Fazy :

System:
  Kernel: 5.15.49-1-MANJARO arch: x86_64 bits: 64 compiler: gcc v: 12.1.0
    parameters: BOOT_IMAGE=/boot/vmlinuz-5.15-x86_64
    root=UUID=ace8c6a0-a070-40bf-9cc2-ca19a5997b15 rw quiet apparmor=1
    security=apparmor udev.log_priority=3
  Desktop: KDE Plasma v: 5.24.5 tk: Qt v: 5.15.5 wm: kwin_x11 vt: 1 dm: SDDM
    Distro: Manjaro Linux base: Arch Linux
Machine:
  Type: Desktop Mobo: Gigabyte model: B550 AORUS PRO AC
    serial: <superuser required> UEFI: American Megatrends LLC. v: F13
    date: 07/08/2021
CPU:
  Info: model: AMD Ryzen 7 PRO 4750G with Radeon Graphics bits: 64
    type: MT MCP arch: Zen 2 gen: 3 built: 2020-22 process: TSMC n7 (7nm)
    family: 0x17 (23) model-id: 0x60 (96) stepping: 1 microcode: 0x8600106
  Topology: cpus: 1x cores: 8 tpc: 2 threads: 16 smt: enabled cache:
    L1: 512 KiB desc: d-8x32 KiB; i-8x32 KiB L2: 4 MiB desc: 8x512 KiB L3: 8 MiB
    desc: 2x4 MiB
  Speed (MHz): avg: 1864 high: 3823 min/max: 1400/4454 boost: enabled
    scaling: driver: acpi-cpufreq governor: schedutil cores: 1: 3823 2: 1821
    3: 1407 4: 2992 5: 1331 6: 1408 7: 1387 8: 1653 9: 2785 10: 1332 11: 1375
    12: 1531 13: 1331 14: 2994 15: 1331 16: 1330 bogomips: 115033
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  Vulnerabilities:
  Type: itlb_multihit status: Not affected
  Type: l1tf status: Not affected
  Type: mds status: Not affected
  Type: meltdown status: Not affected
  Type: mmio_stale_data status: Not affected
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl and seccomp
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: Retpolines, IBPB: conditional, IBRS_FW,
    STIBP: conditional, RSB filling
  Type: srbds status: Not affected
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: NVIDIA GA104 [GeForce RTX 3070 Ti] vendor: Palit Microsystems
    driver: nvidia v: 515.48.07 alternate: nouveau,nvidia_drm non-free: 515.xx+
    status: current (as of 2022-06) arch: Ampere process: TSMC n7 (7nm)
    built: 2020-22 pcie: gen: 3 speed: 8 GT/s lanes: 16 link-max: gen: 4
    speed: 16 GT/s bus-ID: 01:00.0 chip-ID: 10de:2482 class-ID: 0300
  Device-2: AMD Renoir vendor: Gigabyte driver: amdgpu v: kernel
    arch: GCN 5.1 process: TSMC n7 (7nm) built: 2018-21 pcie: gen: 3
    speed: 8 GT/s lanes: 16 link-max: gen: 4 speed: 16 GT/s ports:
    active: HDMI-A-1 empty: none bus-ID: 07:00.0 chip-ID: 1002:1636
    class-ID: 0300
  Display: x11 server: X.Org v: 21.1.3 compositor: kwin_x11 driver: X:
    loaded: amdgpu,nvidia unloaded: modesetting,nouveau alternate: fbdev,nv,vesa
    gpu: amdgpu display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 507x285mm (19.96x11.22")
    s-diag: 582mm (22.9")
  Monitor-1: HDMI-A-1 mapped: HDMI-A-0 model: Sony TV 00 serial: <filter>
    built: 2018 res: 1920x1080 dpi: 40 gamma: 1.2
    size: 1218x685mm (47.95x26.97") diag: 1397mm (55") ratio: 16:9 modes:
    max: 3840x2160 min: 640x480
  OpenGL: renderer: AMD RENOIR (LLVM 13.0.1 DRM 3.42 5.15.49-1-MANJARO)
    v: 4.6 Mesa 22.1.2 direct render: Yes
Audio:
  Device-1: NVIDIA GA104 High Definition Audio vendor: Palit Microsystems
    driver: snd_hda_intel v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16
    link-max: gen: 4 speed: 16 GT/s bus-ID: 01:00.1 chip-ID: 10de:228b
    class-ID: 0403
  Device-2: AMD Renoir Radeon High Definition Audio driver: snd_hda_intel
    v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16 link-max: gen: 4
    speed: 16 GT/s bus-ID: 07:00.1 chip-ID: 1002:1637 class-ID: 0403
  Device-3: AMD Family 17h/19h HD Audio vendor: Gigabyte
    driver: snd_hda_intel v: kernel pcie: gen: 3 speed: 8 GT/s lanes: 16
    link-max: gen: 4 speed: 16 GT/s bus-ID: 07:00.6 chip-ID: 1022:15e3
    class-ID: 0403
  Sound Server-1: ALSA v: k5.15.49-1-MANJARO running: yes
  Sound Server-2: JACK v: 1.9.21 running: no
  Sound Server-3: PulseAudio v: 16.1 running: yes
  Sound Server-4: PipeWire v: 0.3.52 running: yes
Network:
  Device-1: Realtek RTL8125 2.5GbE vendor: Gigabyte driver: r8169 v: kernel
    pcie: gen: 2 speed: 5 GT/s lanes: 1 port: e000 bus-ID: 04:00.0
    chip-ID: 10ec:8125 class-ID: 0200
  IF: eno1 state: down mac: <filter>
  Device-2: Intel Dual Band Wireless-AC 3168NGW [Stone Peak] driver: iwlwifi
    v: kernel pcie: gen: 1 speed: 2.5 GT/s lanes: 1 bus-ID: 05:00.0
    chip-ID: 8086:24fb class-ID: 0280
  IF: wlp5s0 state: up mac: <filter>
Bluetooth:
  Device-1: Intel Wireless-AC 3168 Bluetooth type: USB driver: btusb v: 0.8
    bus-ID: 1-5:3 chip-ID: 8087:0aa7 class-ID: e001
  Report: rfkill ID: hci0 rfk-id: 1 state: down bt-service: enabled,running
    rfk-block: hardware: no software: yes address: see --recommends
Drives:
  Local Storage: total: 11.46 TiB used: 10.4 GiB (0.1%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: Samsung
    model: MZVL22T0HBLB-00B00 size: 1.86 TiB block-size: physical: 512 B
    logical: 512 B speed: 63.2 Gb/s lanes: 4 type: SSD serial: <filter>
    rev: GXB7301Q temp: 32.9 C scheme: GPT
  ID-2: /dev/sda maj-min: 8:0 vendor: Seagate model: ST10000NE0008-2PL103
    size: 9.1 TiB block-size: physical: 4096 B logical: 512 B speed: 6.0 Gb/s
    type: HDD rpm: 7200 serial: <filter> rev: EN02 scheme: GPT
  ID-3: /dev/sdb maj-min: 8:16 vendor: Seagate
    model: IronWolf ZA500NM10002-2ZG101 size: 465.76 GiB block-size:
    physical: 512 B logical: 512 B speed: 6.0 Gb/s type: SSD serial: <filter>
    rev: C013 scheme: GPT
  ID-4: /dev/sdc maj-min: 8:32 type: USB vendor: Verbatim model: STORE N GO
    size: 14.88 GiB block-size: physical: 512 B logical: 512 B type: N/A
    serial: <filter> rev: 8.07 scheme: MBR
  SMART Message: Unknown USB bridge. Flash drive/Unsupported enclosure?
  ID-5: /dev/sdd maj-min: 8:48 type: USB vendor: Intenso
    model: Business Line size: 29.88 GiB block-size: physical: 512 B
    logical: 512 B type: N/A serial: <filter> scheme: MBR
  SMART Message: Unknown USB bridge. Flash drive/Unsupported enclosure?
Partition:
  ID-1: / raw-size: 465.46 GiB size: 457.09 GiB (98.20%) used: 10.4 GiB (2.3%)
    fs: ext4 dev: /dev/sdb2 maj-min: 8:18
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 312 KiB (0.1%) fs: vfat dev: /dev/sdb1 maj-min: 8:17
Swap:
  Alert: No swap data was found.
Sensors:
  System Temperatures: cpu: N/A mobo: N/A gpu: amdgpu temp: 30.0 C
  Fan Speeds (RPM): N/A
Info:
  Processes: 369 Uptime: 3m wakeups: 0 Memory: 30.75 GiB used: 2.06 GiB (6.7%)
  Init: systemd v: 251 default: graphical tool: systemctl Compilers:
  gcc: 12.1.0 clang: 13.0.1 Packages: pacman: 1228 lib: 335 flatpak: 0
  Shell: Zsh v: 5.9 default: Bash v: 5.1.16 running-in: konsole inxi: 3.3.19

and mhwd -l && mhwd -li :

0000:01:00.0 (0300:10de:2482) Display controller nVidia Corporation:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
video-hybrid-amd-nvidia-prime            2021.12.18               false            PCI
video-hybrid-amd-nvidia-470xx-prime            2021.12.18               false            PCI
          video-nvidia            2021.12.18               false            PCI
    video-nvidia-470xx            2021.12.18               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI
0000:07:00.0 (0300:1002:1636) Display controller ATI Technologies Inc:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
video-hybrid-amd-nvidia-prime            2021.12.18               false            PCI
video-hybrid-amd-nvidia-470xx-prime            2021.12.18               false            PCI
           video-linux            2018.05.04                true            PCI
     video-modesetting            2020.01.13                true            PCI
            video-vesa            2017.03.12                true            PCI


Installed PCI configs:
--------------------------------------------------------------------------------
                  NAME               VERSION          FREEDRIVER           TYPE
--------------------------------------------------------------------------------
           video-linux            2018.05.04                true            PCI
video-hybrid-amd-nvidia-prime            2021.12.18               false            PCI


Warning: No installed USB configs!