Skip to content

Add patches for 7.1 - #2178

Open
Apiznel wants to merge 8 commits into
linux-surface:masterfrom
Apiznel:7.1
Open

Apiznel wants to merge 8 commits into
linux-surface:masterfrom
Apiznel:7.1

Conversation

@Apiznel

@Apiznel Apiznel commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

Rebased 0005-ipts.patch, 0009-surface-button.patch, and 0013-cameras.patch because of:

Removed 0015-rtc.patch because upstream does something similar:

Cornell Chin added 2 commits June 14, 2026 16:41
Derived from latest 7.0 patches
Based on the current v7.0 config
@cfouche3005

Copy link
Copy Markdown

Surface Laptop Studio 1 : no issue to report, no issue
Surface Book 1 : need this patch

@orthogonaleety

orthogonaleety commented Jun 28, 2026 •

Copy link
Copy Markdown

Rebased 0005-ipts.patch, 0009-surface-button.patch, and 0013-cameras.patch because of:
...
Removed 0015-rtc.patch because upstream does something similar:
...

Hi @Apiznel . These changes are more numerous and varied in their nature as a single PR, and harder to discern one from the other, as compared with your previous similar PRs. Especially considering they are distilled into patch files, which in turn patch multiple files.

Are you rebasing from a clone of surface 'kernel' project somewhere, where these changes are easier to read? For example in my case I'm trying to understand what conflict needed to be addressed for the rebasing this time around, just a change in the offset for where the patched are applied, or something more functional?

@Apiznel

Apiznel commented Jun 28, 2026

Copy link
Copy Markdown
Contributor Author

@orthogonaleety ipts and cameras are just context changes for the aforementioned commits which each correspond to the patch I had to manually rebase. As for surface-button, the function surface_button_check_MSHW0040 now passes acpi_handle handle into the arguments so I just removed the one inside the function. Since dev is now unused in the patch here, I also opted to remove it from arguments (previously, it was used in assigning handle). I haven't made any functional changes from the original patches.

I don't see how these are different from my previous pull requests? If you could elaborate/give examples, that would be appreciated. In regards to reviewing, I don't know how you're approaching it. I do have a local kernel repo (not of the linux-surface one) although that wouldn't be any more readable.

You could diff my patches from 7.0 to 7.1. Do note that I did rebase 7.0 for the same context change as with ipts so it won't show up when diffing.
Here's a diff for your convenience: 7.0-7.1.diff.gz (gzipped because github doesn't allow uploading .diff files)

@orthogonaleety

orthogonaleety commented Jun 28, 2026 •

Copy link
Copy Markdown

...

I don't see how these are different from my previous pull requests? If you could elaborate/give examples, that would be appreciated.
...

You're quite right. I hadn't noticed for example this comment in the past. So I assumed when I saw your comments above that there was more to it this time.
That clears it up then.

(I have used the diff method you mention on the patches patches previously, but that was just when I was anticipating them to be just context/offset changes..)

Many thanks Apiznel

@cfouche3005

Copy link
Copy Markdown

Surface Laptop Studio 1 : no issue to report, no issue Surface Book 1 : need this patch

I have tested with the patch on my Surface Laptop Studio 1, don't see any issue

@orthogonaleety

orthogonaleety commented Jul 12, 2026 •

Copy link
Copy Markdown

Tests good for me for 7.1.3 , Surface Pro 8, (fedora 44)

(for f44 would need this cherry picking among other outstanding PRs, orthogonaleety@a0b81c4)

orthogonaleety and others added 2 commits July 21, 2026 19:21
Correct IPTS_HID_REPORT_DATA_SIZE out by 3 bytes

Investigating an issue linux-surface#2150

change in kernel hid-core torvalds/linux@0a3fe97
"remove the memset() and simply return if the incoming event buffer size is not
large enough"

Causes a problem between incorrect sizing of IPTS_HID_REPORT_DATA_SIZE used with hid_input_report which does not agree with the hid device's authoritative setup with ipts_fallback_descriptor[]

It appears that Report ID (1 byte) and the Scan Time (2 bytes) where missed in the accounting.
fix kernel error for EDS1 type surface devices & update context 0013-cameras.patch
@Fefff

Fefff commented Aug 1, 2026 •

Copy link
Copy Markdown

7.1.5, Surface Laptop Studio 2, Fedora 43 - So far no issues :)

@christophfink

Copy link
Copy Markdown

Tested 7.1.1-7.1.7 on Arch, Surface Pro 9 - all working perfectly

@onefish2

Copy link
Copy Markdown

Surface Pro 8 with 7.1.5 on Arch Linux. Rear camera works well. Had to patch the patch as the rear camera image was upside down by default. Rotated 180 degrees and now it works. Quality isn't that great. Better than nothing.

@Zhuangkh

Copy link
Copy Markdown

Tested 7.1.8 on AnduinOS, SurfaceBook 2, the front camera works fine, though the image quality seems a bit low, the rear camera shows a green screen. All other functions are working normally. ;)

Apiznel pushed a commit to Apiznel/linux-surface that referenced this pull request Aug 18, 2026
@LegendaryFire

Copy link
Copy Markdown
Contributor

Updated the package build for Arch 7.1.8 with updated symlinks, removal of the dirty frag patch set, bumped kernel version, and regenerated package checksums.
Apiznel#2

Tested and working great on my Surface Laptop Studio 2, it appears this kernel also fixed a hibernate issue with the Surface Laptop Studio 2. It could also be the fact the 7.1 the kernel powers off by default on a fatal ACPI error instead of just logging it like previous releases, however regardless it doesn't just ramp up the fans and hang anymore, which required holding the power button to fully shutdown.

Cornell Chin added 2 commits August 19, 2026 13:18
@fildunsky fildunsky mentioned this pull request Sep 1, 2026
@fildunsky

Copy link
Copy Markdown

Data point in case it is useful: this series forward-ports to 7.2.2 almost
unchanged
.

Applied in order with git am --3way against v7.2.2, fourteen of the fifteen
patches land with no conflict at all. The only one that needs anything is
0011-surface-shutdown.patch, and only in context — v7.2 reworded the comment
on the neighbouring non_mappable_bars field in include/linux/pci.h:

The line your patch adds and the code around it are untouched. patch -F3 takes
it as is; updating the context line makes it apply with zero fuzz.

configs/surface-7.1.config needed no changes for 7.2 either.

I built the result as 7.2.2-surface-1 and have been running it on a Surface
Pro 8
for a day: touch (ithc), pen, suspend, battery and all three cameras
work, including the IR one with face authentication through PAM. So the series
is good beyond the version it targets, for at least one machine.

Put it up as #2262 so it is not just sitting in a fork; the work is yours, that
PR only carries it across. Branch, if you would rather cherry-pick than review a
second PR: https://github.com/fildunsky/linux-surface/tree/pro8-7.2

Nothing here needs action from you — mostly it seemed worth saying that a merge
of this PR does not become stale the moment 7.2 lands.

This was referenced Sep 1, 2026
jmacpolin pushed a commit to jmacpolin/linux-cachyos-surface that referenced this pull request Oct 5, 2026
The PKGBUILD tracked the moving tip of Apiznel/linux-surface's 7.1
branch (upstream PR linux-surface/linux-surface#2178) and fetched the
config fragment separately from the patches. Pin both to df5430f, the
commit that was built and tested on a Surface Pro 9, by taking the
fragment from the same git checkout.

- Source linux-surface via #commit= and drop the hard-coded
  "git checkout 7.1", which would have undone any pin, plus the unused
  _surface_ver/_surface_rel/_surface_ref.
- Support local fixes: override-<surface patch> replaces that patch and
  local-*.patch is applied after the surface set, both with -F0.
- Run olddefconfig before "make prepare" so new options take their
  defaults instead of prompting (the tested build answered all 168
  prompts with the default).
- Use the tested kernel's .config as the base config (it was a 6.18.3
  config) and drop the stale 6.19 config files.
- Pad b2sums for conditionally added sources so --skipinteg is no
  longer required; regenerate .SRCINFO; add a .gitignore for makepkg
  outputs; document all of this in the README.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01H55DadM3MRfAT2DdzTd2VN

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants