[vserver] patching linux 4.1.11 with linux-vserver patch

From: Corey Wright <undefined_at_pobox.com>
Date: Fri 23 Oct 2015 - 18:00:44 BST
Message-Id: <20151023120044.c2411044063f171807296590@pobox.com>

patch-4.1.3-vs2.3.8.2_donotuse.diff fails to apply to linux 4.1.11 in two
places (besides Makefile which will fail on anything other than 4.1.3).

patching file Makefile
Hunk #1 FAILED at 1.
1 out of 1 hunk FAILED -- saving rejects to file Makefile.rej
...
patching file fs/namei.c
Hunk #4 FAILED at 1551.
Hunk #5 succeeded at 1610 (offset 29 lines).
Hunk #6 succeeded at 2605 (offset 29 lines).
Hunk #7 succeeded at 2687 (offset 29 lines).
Hunk #8 succeeded at 2741 (offset 29 lines).
Hunk #9 succeeded at 3244 (offset 29 lines).
Hunk #10 succeeded at 3382 (offset 29 lines).
Hunk #11 succeeded at 3419 (offset 29 lines).
Hunk #12 succeeded at 3545 (offset 29 lines).
Hunk #13 succeeded at 4119 (offset 29 lines).
Hunk #14 succeeded at 4624 (offset 29 lines).
1 out of 14 hunks FAILED -- saving rejects to file fs/namei.c.rej
...
patching file kernel/printk/printk.c
Hunk #2 FAILED at 488.
Hunk #3 succeeded at 1265 with fuzz 2 (offset -3 lines).
Hunk #4 succeeded at 1278 (offset -3 lines).
Hunk #5 succeeded at 1300 (offset -3 lines).
1 out of 5 hunks FAILED -- saving rejects to file kernel/printk/printk.c.rej

upstream changed some code involving CAP_SYSLOG which doesn't directly affect
the linux-vserver patch, but changed the patch's context (adjacent source
code) and confused patch as to where to apply the associated patch hunk. the
upstream change was
http://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/kernel/printk/printk.c?h=linux-4.1.y&id=ae41bfc68161ea5d280091ccb9593e9f68d5db44

upstream changed some code involving dentry checking which broke the
linux-vserver patch context. i'm not too sure about my "fix" as the only
thing affected was a "FIXME" comment which doesn't provide much context and
is hard to test for correctness. ;) the upstream change was
http://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/fs/namei.c?h=linux-4.1.y&id=2058efbcb0eb148db2086266cfb048da42fd0a93

step-by-step process:
0. get linux-4.1.11
1. apply patch-4.1.3-vs2.3.8.2_donotuse.diff [1]
2. apply delta-cow-fix30.diff [2]
2. apply attached patch-4.1.3-11-vs2.3.8.2_donotuse.diff

[1] http://vserver.13thfloor.at/Experimental/patch-4.1.3-vs2.3.8.2_donotuse.diff
[2] http://people.linux-vserver.org/~dhozac/p/k/delta-cow-fix30.diff

resulting kernel tested with debian wheezy on virtualbox, passing testme.sh
and testfs.sh, and successfully starting, entering, exiting, and stopping a
guest using util-vserver 0.30.216-pre3117 (with cleanupMount removed).

thanks to herbert for the 4.1.3 patch and daniel for the cow patch.

corey

--
undefined@pobox.com

Received on Fri Oct 23 17:58:58 2015
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Fri 23 Oct 2015 - 17:58:58 BST by hypermail 2.1.8