# Frame.work notebook, 12th gen Intel



## cmoerz (Nov 19, 2022)

For anyone, who's thinking about buying - I'm documenting my experiences/pains...

UEFI boot+install works out of the box w/ 13.1
X11 does not work, unless switching to vesa framebuffer (I'll post later, how I got it running), don't bother installing kmod, because it appears we're SOL with Alder Lake GPUs
Suspend/resume does not work
Power consumption (untweaked) at around 10W (!) - don't expect long working sessions on battery...
I've switched my wireless chip to one that supports iwlwifi out of the box to save myself the pains of wifibox, or whatever that Linux contraption is called
I'll spare you the "wows" and "aahs" about build quality; there's Youtube for that, including a reel of 60minutes of advertisement, but that's a different story.

Feel free to add any recommendations, if you got any. I'll post pciconf et al as a follow up.


----------



## cmoerz (Nov 19, 2022)

Additional things I noticed, while using the device:

Only partial multi touch support on mouse/touch pad - at least out of the box. Scrolling with two fingers works, but if you click and drag to select text, it won't work. Hopefully just some missing settings... I'm dreading I might have to plug in a mouse all the time.
The screen in X11 is a sea of pixels, so if you're running with dwm or other "simple" window managers, you're going to have to adjust font sizes a lot. If you're using something more sophisticated, expect having to adjust screen dpi settings or scaling.
Here's the `pciconf -lvv`:

```
hostb0@pci0:0:0:0:    class=0x060000 rev=0x02 hdr=0x00 vendor=0x8086 device=0x4621 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    class      = bridge
    subclass   = HOST-PCI
vgapci0@pci0:0:2:0:    class=0x030000 rev=0x0c hdr=0x00 vendor=0x8086 device=0x4626 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Integrated Graphics Controller'
    class      = display
    subclass   = VGA
none0@pci0:0:4:0:    class=0x118000 rev=0x02 hdr=0x00 vendor=0x8086 device=0x461d subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake Innovation Platform Framework Processor Participant'
    class      = dasp
pcib1@pci0:0:6:0:    class=0x060400 rev=0x02 hdr=0x01 vendor=0x8086 device=0x464d subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = '12th Gen Core Processor PCI Express x4 Controller'
    class      = bridge
    subclass   = PCI-PCI
pcib2@pci0:0:7:0:    class=0x060400 rev=0x02 hdr=0x01 vendor=0x8086 device=0x466e subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 PCI Express Root Port'
    class      = bridge
    subclass   = PCI-PCI
pcib3@pci0:0:7:1:    class=0x060400 rev=0x02 hdr=0x01 vendor=0x8086 device=0x463f subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 PCI Express Root Port'
    class      = bridge
    subclass   = PCI-PCI
pcib4@pci0:0:7:2:    class=0x060400 rev=0x02 hdr=0x01 vendor=0x8086 device=0x462f subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 PCI Express Root Port'
    class      = bridge
    subclass   = PCI-PCI
pcib5@pci0:0:7:3:    class=0x060400 rev=0x02 hdr=0x01 vendor=0x8086 device=0x461f subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 PCI Express Root Port'
    class      = bridge
    subclass   = PCI-PCI
none1@pci0:0:8:0:    class=0x088000 rev=0x02 hdr=0x00 vendor=0x8086 device=0x464f subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = '12th Gen Core Processor Gaussian & Neural Accelerator'
    class      = base peripheral
none2@pci0:0:10:0:    class=0x118000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x467d subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Platform Monitoring Technology'
    class      = dasp
xhci0@pci0:0:13:0:    class=0x0c0330 rev=0x02 hdr=0x00 vendor=0x8086 device=0x461e subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 USB Controller'
    class      = serial bus
    subclass   = USB
none3@pci0:0:13:2:    class=0x0c0340 rev=0x02 hdr=0x00 vendor=0x8086 device=0x463e subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 NHI'
    class      = serial bus
    subclass   = USB
none4@pci0:0:13:3:    class=0x0c0340 rev=0x02 hdr=0x00 vendor=0x8086 device=0x466d subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P Thunderbolt 4 NHI'
    class      = serial bus
    subclass   = USB
xhci1@pci0:0:20:0:    class=0x0c0330 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51ed subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH USB 3.2 xHCI Host Controller'
    class      = serial bus
    subclass   = USB
none5@pci0:0:20:2:    class=0x050000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51ef subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH Shared SRAM'
    class      = memory
    subclass   = RAM
iwlwifi0@pci0:0:20:3:    class=0x028000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51f0 subvendor=0x8086 subdevice=0x0070
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P PCH CNVi WiFi'
    class      = network
ig4iic0@pci0:0:21:0:    class=0x0c8000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51e8 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH Serial IO I2C Controller'
    class      = serial bus
ig4iic1@pci0:0:21:1:    class=0x0c8000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51e9 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH Serial IO I2C Controller'
    class      = serial bus
ig4iic2@pci0:0:21:3:    class=0x0c8000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51eb subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH Serial IO I2C Controller'
    class      = serial bus
none6@pci0:0:22:0:    class=0x078000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51e0 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH HECI Controller'
    class      = simple comms
none7@pci0:0:22:3:    class=0x070002 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51e3 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    class      = simple comms
    subclass   = UART
isab0@pci0:0:31:0:    class=0x060100 rev=0x01 hdr=0x00 vendor=0x8086 device=0x5182 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH eSPI Controller'
    class      = bridge
    subclass   = PCI-ISA
hdac0@pci0:0:31:3:    class=0x040380 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51c8 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH-P High Definition Audio Controller'
    class      = multimedia
    subclass   = HDA
ichsmb0@pci0:0:31:4:    class=0x0c0500 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51a3 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake PCH-P SMBus Host Controller'
    class      = serial bus
    subclass   = SMBus
none8@pci0:0:31:5:    class=0x0c8000 rev=0x01 hdr=0x00 vendor=0x8086 device=0x51a4 subvendor=0xf111 subdevice=0x0002
    vendor     = 'Intel Corporation'
    device     = 'Alder Lake-P PCH SPI Controller'
    class      = serial bus
nvme0@pci0:1:0:0:    class=0x010802 rev=0x01 hdr=0x00 vendor=0x15b7 device=0x5011 subvendor=0x15b7 subdevice=0x5011
    vendor     = 'Sandisk Corp'
    device     = 'WD PC SN810 / Black SN850 NVMe SSD'
    class      = mass storage
    subclass   = NVM
```


----------



## cmoerz (Nov 19, 2022)

Next observation:

acpi_video is loaded, but no brightness settings to adjust in `sysctl`
`xbacklight` fails with "no outputs have backlight property"
I got natural scrolling working for the touch pad by using `xinput` property 239: `xinput set-prop 14 239 1`


----------



## cmoerz (Nov 19, 2022)

Thanks to this site, I made selecting text with touch pad work - I disabled PS2 mode in BIOS.
In other news, I noticed that xinput appears to vary id-wise; maybe that happened after disabling PS2 mode - my previous `xinput` command now requires id 13 instead of 14.


----------



## cmoerz (Nov 19, 2022)

This backlight issue is driving me nuts. I'm thinking about trying out OpenBSD for comparison. Maybe there's something I can learn how they fixed that there...



			OpenBSD on the Framework Laptop - joshua stein


----------



## cmoerz (Nov 19, 2022)

By the way - I noticed in the BIOS one can set a limit for how full to charge the battery. That used to be a PITA on my Thinkpads, so yay for frame.work! No more fiddling with acpi settings.


----------



## T-Daemon (Nov 19, 2022)

cmoerz said:


> acpi_video is loaded, but no brightness settings to adjust in `sysctl`
> `xbacklight` fails with "no outputs have backlight property"





cmoerz said:


> This backlight issue is driving me nuts. I'm thinking about trying out OpenBSD for comparison. Maybe there's something I can learn how they fixed that there...
> 
> 
> 
> OpenBSD on the Framework Laptop - joshua stein


I have a ThinkPad E15 with AMD 'Lucienne' GPU. If this is similar with amdgpu driver, then backlight is available only when the DRM driver module is loaded.

On my system a backlight device node is created after the module is loaded, which can be configured with backlight(8).

```
% ls -l /dev/backlight/
total 0
lrwxr-xr-x  1 root  wheel     23 Nov 17 19:01 amdgpu_bl00 -> ../backlight/backlight0
crw-rw----  1 root  video  0x18a Nov 17 19:01 backlight0
```


----------



## cmoerz (Nov 19, 2022)

Yes, I suppose because the kmod driver does not yet recognize the 12th gen GPU, there's no backlight options to manipulate either. I patched the 510-kmod driver to attempt running the gpu as rocket lake (by adding its device id to the pci definition). Unfortunately, that ended up with a yellow screen and a crashed/hung system.
Looks like, I'm seriously SOL with this on FreeBSD for the moment. I'm surprised that OpenBSD supposedly has this working...
I'm wondering whether there is any compatibility layer/driver, that might make this work.


----------



## cmoerz (Nov 19, 2022)

Forgot to add this previously. To get X11 working for FreeBSD, add a /usr/local/etc/X11/xorg.conf.d/fb.conf:

```
Section "Device"
    Identifier "card0"
    Driver "scfb"
    BusID "pci0:0:2:0"
EndSection
```
And to clarify: this runs without the graphics/drm-kmod.


----------



## angry_vincent (Nov 19, 2022)

cmoerz said:


> Yes, I suppose because the kmod driver does not yet recognize the 12th gen GPU, there's no backlight options to manipulate either. I patched the 510-kmod driver to attempt running the gpu as rocket lake (by adding its device id to the pci definition). Unfortunately, that ended up with a yellow screen and a crashed/hung system.
> Looks like, I'm seriously SOL with this on FreeBSD for the moment. I'm surprised that OpenBSD supposedly has this working...
> I'm wondering whether there is any compatibility layer/driver, that might make this work.


OpenBSD has much newer DRM code, maybe 5.15.x? ( that is linux drm ). FreeBSD is 5.10


----------



## cmoerz (Nov 19, 2022)

Welp, this sounds like my curiosity will finally drive me into kernel programming. Famous last words come to mind: "it can't be that hard".


----------



## cmoerz (Nov 19, 2022)

Unless anyone got any additional insights or questions about the device (i.e. commands to run or check), I'll be moving on to OpenBSD for the moment - at least with this notebook and at least for the moment until kmod finally catches up.


----------



## vermaden (Nov 19, 2022)

There is also wiki page:
- https://wiki.freebsd.org/Laptops/Framework_Laptop


----------



## cmoerz (Nov 19, 2022)

Unfortunately, there's not much to learn from the wiki page. It probably refers to previous models. I believe Intel 10th and 11th gen seem to work reasonably well. I chose the 12th gen and will have to be patient for the moment.

For anyone interested: OpenBSD ain't much better either. Graphics works, but no screen brightness either, around 13W of power drain and no hibernate/suspend - at least not without kernel panic.


----------



## vermaden (Nov 20, 2022)

Oh ... sorry.

I though it had up-to-date content.


----------



## darmokandjalad (Nov 20, 2022)

Thanks for documenting your experience, cmoerz. I hope to make a Framework my next laptop, so I appreciate your being an early adopter.


----------



## cmoerz (Nov 20, 2022)

Yeah, I totally want to support the model. I loved my Thinkpads but Lenovo is just going down the wrong route IMO. The x270 is going to be my last one.

The good thing in this whole mess: I can still order a 11th gen Intel mainboard and just flip it. It's a shame that this is apparently too new. I love the 12th gen with power and efficiency cores. You got a 16core system and you can even turn off cores in the BIOS and save a few watts in the process.

I really don't want to go with OpenBSD because I don't feel at home - apart from the power consumption; over the past year, I've learned a bunch of tricks on how to conserve power on my x270 and getting my 9-10 hours of battery life. Don't want to loose out on that.

I'll flip back to FreeBSD 14 for *** and giggles to see if maybe suspend works. 

OpenBSD does not seem to be much better for the moment - apart from xrandr supporting the graphics card. With suspend and brightness broken as well, it's missing two key features for now. I'm considering signing up and writing to the OpenBSD mailing list, because I'm a total newb but not holding my breath on that one.


----------



## cmoerz (Nov 20, 2022)

Additional update (maybe offtopic), `xbacklight` works as expected on OpenBSD. Probably, because kmod is way newer, as angry_vincent already pointed out...

Now I'm between a rock and a hard place - have a few features that work but not the OS I like or have no control over screen and power but run FreeBSD. I might be better equipped to fix suspend on OpenBSD than doing the whole GPU driver on FreeBSD however. Tough choice.


----------



## steps (Nov 21, 2022)

Yes, a tough and disheartening choice, I feel your conflict. But as far as I can tell, neither FreeBSD nor OpenBSD are suitable for this particular laptop at the moment. Huge power usage on OpenBSD and unaccelerated graphics on FreeBSD is like having a sharp stone in your shoe but you can't take it off.

If I were in your shoes, I would wait until the CPU is supported by FreeBSD and use a sane linux distro until then, like alpine or void. I was running alpine on my laptop for a few months and it was a very nice experience.

The work on drm-kmod is progressing. The pull requests for version 5.11 and 5.12 seem to be ready, they are just not merged yet. Maybe version 5.15 will be ready for the 14.0-RELEASE, or even the 13.2-RELEASE.


----------



## patmaddox (Dec 15, 2022)

What wireless card are you using, and how did you swap it?


----------



## cmoerz (Dec 17, 2022)

I got an Intel AX201.NGWG after reading somewhere, that it works very well out of the box. I can confirm it's working well with FreeBSD 13.1 and OpenBSD 7.2 alike.

Swapping is really easy. You get a screwdriver with the frame.work laptop. You use it to unscrew the bottom screws, lift the keyboard and then unscrew a single screw, unplug a black and a white cable and basically replace it like a nvme disk. If you manage to plug in a disk, you can do that as well. Just be sure to plug the cables back in the right order/place. Otherwise, the antenna isn't going to work.


----------

