Skip to content

Commit 4586397

Browse files
committed
Add more Linux instructions to finding acpi paths
1 parent f519b77 commit 4586397

File tree

4 files changed

+70
-23
lines changed

4 files changed

+70
-23
lines changed

Laptops/laptop-disable.md

+35-19
Original file line numberDiff line numberDiff line change
@@ -16,28 +16,54 @@ So with laptops, we can hide the dGPU from macOS with the little boot-arg called
1616

1717
Note that this is not needed for install, but recommended for post-install
1818

19-
## Optimus Method
20-
21-
How this works is that we call the `.off` method found on Optimus GPUs, this is the expected way to power off a GPU but some may find their dGPU will power back up later on. Mainly seen in Lenovo's, the Optimus method should work for most users:
22-
23-
To start, grab [SSDT-dGPU-Off.dsl](https://github.com/dortania/Getting-Started-With-ACPI/blob/master/extra-files/decompiled/SSDT-dGPU-Off.dsl.zip)
2419

25-
Next we need to get on Windows, and head to the following:
20+
## Finding the ACPI Path
21+
### Windows
22+
Head to the following:
2623

2724
```
2825
Device Manager -> Display Adapters -> dGPU -> Properties -> Details > BIOS device name
2926
```
3027

3128
* Note some GPUs may be hiding under "BIOS device name"
3229

33-
This should provided you with an ACPI path for your dGPU, most commonly:
30+
This should have provided you with an ACPI path for your dGPU, most commonly:
3431

3532
* Nvidia dGPU: `\_SB.PCI0.PEG0.PEGP`
3633
* AMD dGPU: `\_SB.PCI0.PEGP.DGFX`
3734

3835
![Credit to 1Revenger1 for the image](../images/Desktops/nvidia.png)
3936

40-
Now with that, we'll need to change the ACPI path in the SSDT. Main sections:
37+
### Linux
38+
Use `lcpci` to find the PCI path of your device:
39+
40+
```sh
41+
$ lspci -D | grep VGA
42+
0000:00:02.0 VGA compatible controller: Intel Corporation UHD Graphics (rev 05)
43+
0000:01:00.0 VGA compatible controller: NVIDIA Corporation TU106M [GeForce RTX 2060 Max-Q] (rev a1)
44+
```
45+
46+
Make a note of the PCI path of the dedicated graphics card (`0000:01:00.0` in my case).
47+
48+
Then use `cat` to get the ACPI path (substituting `[PCI path]` with the path obtained above):
49+
50+
```
51+
cat /sys/bus/pci/devices/[PCI path]/firmware_node/path
52+
```
53+
54+
This should have provided you with an ACPI path for your dGPU, most commonly:
55+
56+
* Nvidia dGPU: `\_SB.PCI0.PEG0.PEGP`
57+
* AMD dGPU: `\_SB.PCI0.PEGP.DGFX`
58+
59+
## Optimus Method
60+
61+
How this works is that we call the `.off` method found on Optimus GPUs, this is the expected way to power off a GPU but some may find their dGPU will power back up later on. Mainly seen in Lenovo's, the Optimus method should work for most users:
62+
63+
To start, grab [SSDT-dGPU-Off.dsl](https://github.com/dortania/Getting-Started-With-ACPI/blob/master/extra-files/decompiled/SSDT-dGPU-Off.dsl.zip)
64+
65+
66+
Using the ACPI path you acquired, we'll need to change the ACPI path in the SSDT. Main sections:
4167

4268
```
4369
External(_SB.PCI0.PEG0.PEGP._OFF, MethodObj)
@@ -57,18 +83,8 @@ With some machines, the simple `.off` call won't keep the card off properly, tha
5783

5884
To start, grab [SSDT-NoHybGfx.dsl](https://github.com/dortania/Getting-Started-With-ACPI/blob/master/extra-files/decompiled/SSDT-NoHybGfx.dsl.zip)
5985

60-
Next we need to get on Windows, and head to the following:
61-
62-
```
63-
Device Manager -> Display Adapters -> dGPU -> Properties -> Details > BIOS device name
64-
```
65-
66-
This should provided you with an ACPI path for your dGPU, most commonly:
67-
68-
* Nvidia dGPU: `\_SB.PCI0.PEG0.PEGP`
69-
* AMD dGPU: `\_SB.PCI0.PEGP.DGFX`
7086

71-
Now with that, we'll need to change the ACPI path in the SSDT. Main sections:
87+
Using the ACPI path you acquired, we'll need to change the ACPI path in the SSDT. Main sections:
7288

7389
```
7490
External (_SB_.PCI0.PEG0.PEGP._DSM, MethodObj) // dGPU ACPI Path

Manual/dump.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,11 @@ So to start, we'll need to get a copy of your DSDT from your firmware. The easie
1717
* [SSDTTime](https://github.com/corpnewt/SSDTTime)
1818
* Supports both Windows and Linux for DSDT dumping
1919
* `4. Dump DSDT - Automatically dump the system DSDT`
20-
* Do note that all ACPI patches from clover/OpenCore will be applied to the DSDT with the above method
20+
* sysfs
21+
* Run `sudo cat /sys/firmware/acpi/tables/DSDT > DSDT.aml`
22+
* Fix permissions: `chown "$(whoami):$(id -gn)" DSDT.aml`
23+
24+
* Do note that all ACPI patches from clover/OpenCore will be applied to the DSDT with the above 2 methods
2125

2226
## From Clover
2327

Universal/plug-methods/manual.md

+10-2
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@
99

1010
## Finding the ACPI path
1111

12-
To find the ACPI pathing, you have 2 methods:
12+
To find the ACPI pathing, you have 3 methods:
1313

1414
* [DSDT](#DSDT)
1515
* [DeviceManager](#devicemanager)
16+
* [Linux](#linux)
1617

1718
### DSDT
1819

@@ -36,7 +37,7 @@ If we then search for instances of `CP00` we find that its full ACPI pathing is
3637

3738
Now with the pathing, you can head here: [Edits to the sample SSDT](#edits-to-the-sample-ssdt)
3839

39-
##### DeviceManager
40+
### DeviceManager
4041

4142
If you already have Windows installed on this machine, finding the CPU pathing is fairly easy.
4243

@@ -61,6 +62,13 @@ So with the above X299 example, our CPU pathing would be `SB.SCK0.CP00`
6162

6263
Now with the pathing, you can head here: [Edits to the sample SSDT](#edits-to-the-sample-ssdt)
6364

65+
### Linux
66+
67+
Finding the CPU's ACPI path with Linux is very simple. Simply `cat` the firmware_node path:
68+
```
69+
cat /sys/devices/system/cpu/cpu0/firmware_node/path
70+
```
71+
6472
## Edits to the sample SSDT
6573

6674
Now that we have our ACPI path, lets grab our SSDT and get to work:

Universal/smbus-methods/manual.md

+20-1
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,11 @@
99

1010
## Finding the ACPI path
1111

12-
So to find the ACPI pathing of our SMBus, we've got 2 methods:
12+
So to find the ACPI pathing of our SMBus, we've got 3 methods:
1313

1414
* [Hackintool](#hackintool)
1515
* [DeviceManager](#devicemanager)
16+
* [Linux](#linux)
1617

1718
### Hackintool
1819

@@ -40,6 +41,24 @@ From the above example, we can see the SMBus is located at:
4041
PC00.SMBS
4142
```
4243

44+
45+
### Linux
46+
47+
Use `lcpci` to find the PCI path of the SMBus:
48+
49+
```sh
50+
$ lspci -D | grep SMBus
51+
0000:00:1f.4 SMBus: Intel Corporation Alder Lake-S PCH SMBus Controller (rev 11)
52+
```
53+
54+
Make a note of the PCI path of the SMBus controller (`0000:00:1f.4` in my case).
55+
56+
Then use `cat` to get the ACPI path (substituting `[PCI path]` with the path obtained above):
57+
58+
```
59+
cat /sys/bus/pci/devices/[PCI path]/firmware_node/path
60+
```
61+
4362
With the ACPI pathing, you can now head here: [Edits to the sample SSDT](#edits-to-the-sample-ssdt)
4463

4564
## Edits to the sample SSDT

0 commit comments

Comments
 (0)