You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Undefined reference to intel_ipts_connect in ipts_gfx #8
These symbols are an API for IPTS inside of the i915 graphics driver, and them missing sounds like you are building IPTS right into the kernel core (CONFIG_INTEL_IPTS=y) while building i915 as a module (CONFIG_DRM_I915=m). If you want to build one into the kernel core, the other one has to be built into it as well.
You could try to edit the generated .config file manually. But is there any reason why you want both built-in? If they are builtin, you also need have the companion driver for firmware loading built-in (CONFIG_INTEL_IPTS_SURFACE=y) and embed the firmware files themselves.
For example, to build i915 as a built-in driver on Arch Linux:
DRM_I915 depends on HAS_IOMEM [=y] && DRM [=m] && X86 [=y] && PCI [=y] DRM depends on HAS_IOMEM [=y] && (AGP [=m] || AGP [=m]=n) && !EMULATED_CMPXCHG && HAS_DMA [=y]
So, AGP and DRM also need to be built-in (y).
Then, DMC/GuC/HuC firmware need to be specified in CONFIG_EXTRA_FIRMWARE
(if not, loading the firmware will fail early at boot process, maybe because filesystem is not mounted yet).
(There seems to be no need to embed IPTS firmware anymore thanks to the companion driver)
@kitakar5525 I'm building for alpine linux instead of arch... so things are a little more complicated for me.
Anyone happen to have a config with the firmware embedded into the kernel so I can try that? I've never needed to embed firmware into the kernel before so I have no idea what I'm doing.
Neither the battery info nor the touch screen actually works yet, but at least the IPTS shows up in libinput now (without any events from it)
For touch: Do you have the firmware installed (if you have IPTS built as module)?
For battery etc: That depends on SURFACE_ACPI_SAN and thus SURFACE_ACPI_SSH (which depends on a bunch of additional stuff) and SURFACE_ACPI. I've seen you've already found my configs for Arch and Debian, I think you should be able to use those as starting point (I agree that there's room for improvement in managing the configs, I'll probably revisit this in the future). Usually make menuconfig is a pretty good tool to find out if the dependencies are all satisfied (the option just won't show up if they aren't, in which case you'll have to look at the Kconfig files).
Yeah, I pulled your arch config and it worked out of the box for Alpine. Touch, battery, everything but the webcams.
I'm sure I was doing something stupid but make menuconfig had a lot of "bugs" I changed the setting on [something] from module to installed to off, then when I tried to turn it back on, I couldn't install it as a module anymore. So clearly I had a broken config as my starting point.
Yeah, sounds like the config had some options enabled with dependencies that weren't enabled. Ideally, we'd have some list of options that are required for the Surface devices and a tool that enables all of them and their dependencies. The merge_config.sh script could be a base for that, but that doesn't enable dependencies, just prints warnings (which I guess would work too). Also it directly depends on the kernel source, so its a bit difficult to put that into an extra repo.
Activity
StollD commentedon Oct 13, 2019
What is your defconfig?
These symbols are an API for IPTS inside of the i915 graphics driver, and them missing sounds like you are building IPTS right into the kernel core (
CONFIG_INTEL_IPTS=y) while building i915 as a module (CONFIG_DRM_I915=m). If you want to build one into the kernel core, the other one has to be built into it as well.GrayHatter commentedon Oct 13, 2019
That's what I suspected, but make menuconfig wouldn't allow me to specify both as y.
StollD commentedon Oct 13, 2019
You could try to edit the generated
.configfile manually. But is there any reason why you want both built-in? If they are builtin, you also need have the companion driver for firmware loading built-in (CONFIG_INTEL_IPTS_SURFACE=y) and embed the firmware files themselves.GrayHatter commentedon Oct 13, 2019
Only because y seemed easier than m. I'm recompiling now after editing the .config. If y to both doesn't work than I'll try m.
If neither works I'll report back, otherwise hopefully in 2h I'll be able to close this.
Thanks for your help!
kitakar5525 commentedon Oct 13, 2019
For example, to build i915 as a built-in driver on Arch Linux:
DRM_I915depends onHAS_IOMEM [=y] && DRM [=m] && X86 [=y] && PCI [=y]DRMdepends onHAS_IOMEM [=y] && (AGP [=m] || AGP [=m]=n) && !EMULATED_CMPXCHG && HAS_DMA [=y]So, AGP and DRM also need to be built-in (y).
Then, DMC/GuC/HuC firmware need to be specified in
CONFIG_EXTRA_FIRMWARE(if not, loading the firmware will fail early at boot process, maybe because filesystem is not mounted yet).
(There seems to be no need to embed IPTS firmware anymore thanks to the companion driver)
GrayHatter commentedon Oct 13, 2019
@StollD thanks mate, you were correct. I got it compiling.
Neither the battery info nor the touch screen actually works yet, but at least the IPTS shows up in libinput now (without any events from it)
Any help you can offer would be great, but I don't wanna add too much noise to this repo.
GrayHatter commentedon Oct 13, 2019
@kitakar5525 I'm building for alpine linux instead of arch... so things are a little more complicated for me.
Anyone happen to have a config with the firmware embedded into the kernel so I can try that? I've never needed to embed firmware into the kernel before so I have no idea what I'm doing.
kitakar5525 commentedon Oct 13, 2019
I see. Anyway, building IPTS as a module sounds a better idea in order to reload the module because IPTS is not stable yet.
It seems that we need to add the DRM_I915 as a dependency to INTEL_IPTS.
https://github.com/qzed/linux-surface-kernel/blob/37287a3ecd01861432991d4acad0167173cacbde/drivers/misc/ipts/Kconfig#L1-L4
to like this?
qzed commentedon Oct 14, 2019
@kitakar5525 you're correct, we should add it as dependency. Re-opening this issue until that is resolved.
qzed commentedon Oct 14, 2019
@GrayHatter
For touch: Do you have the firmware installed (if you have IPTS built as module)?
For battery etc: That depends on
SURFACE_ACPI_SANand thusSURFACE_ACPI_SSH(which depends on a bunch of additional stuff) andSURFACE_ACPI. I've seen you've already found my configs for Arch and Debian, I think you should be able to use those as starting point (I agree that there's room for improvement in managing the configs, I'll probably revisit this in the future). Usuallymake menuconfigis a pretty good tool to find out if the dependencies are all satisfied (the option just won't show up if they aren't, in which case you'll have to look at the Kconfig files).GrayHatter commentedon Oct 14, 2019
Yeah, I pulled your arch config and it worked out of the box for Alpine. Touch, battery, everything but the webcams.
I'm sure I was doing something stupid but
make menuconfighad a lot of "bugs" I changed the setting on [something] from module to installed to off, then when I tried to turn it back on, I couldn't install it as a module anymore. So clearly I had a broken config as my starting point.qzed commentedon Oct 14, 2019
Yeah, sounds like the config had some options enabled with dependencies that weren't enabled. Ideally, we'd have some list of options that are required for the Surface devices and a tool that enables all of them and their dependencies. The
merge_config.shscript could be a base for that, but that doesn't enable dependencies, just prints warnings (which I guess would work too). Also it directly depends on the kernel source, so its a bit difficult to put that into an extra repo.@StollD and @phunyguy have done some work like this (see e.g. https://github.com/StollD/fedora-linux-surface/blob/19de73504480781f1616d12a58599a7dd0583fa9/config.surface)
270 remaining items
perf machine: Initialize machine->env to address a segfault
net: Handle napi_schedule() calls from non-interrupt
perf test: Fix Hwmon PMU test endianess issue
net: ibmveth: make veth_pool_store stop hanging
perf test: Fix Hwmon PMU test endianess issue
net: ibmveth: make veth_pool_store stop hanging
libbpf: Fix buffer overflow in bpf_object__init_prog
gpiolib: acpi: Add a quirk for Acer Nitro V15
perf cs-etm: Fix decoding for sparse CPU maps
scsi: core: Fix refcount leak for tagset_refcnt
scsi: core: Fix refcount leak for tagset_refcnt
perf annotate: Use jump__delete when freeing LoongArch jumps
ice: fix NULL pointer dereference in ice_reset_all_vfs()
f2fs: fix folio_nr_pages() race after put in large folio invalidate
f2fs: fix folio_nr_pages() race after put in large folio invalidate