From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=209.85.221.41 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796137892; b=kjP5cRPOY72mp6NonkjFz66GHylpHoR0ia41v1F28aTkeqxmaTOrRvBrm0dl7fDTtoLf 1mflbz9qi3k4b5ThbqnKmIgAp/jv2jrKCV7VGG6SAlVp3cHbiQj0p18bXqhjP7qSumydy Jt3d6F7w3D0JIp6DDFdYp+mK8SEdHTeSwEG8ruQrJGfW0dD3bLgeOtenBp+IA1BhyyGIp FRcK0yXuYsG+faT44gvMS5CSZiKbIA67xvmj0R4tLyiYeido4s9Q73LV35rP7SDI+Sbwt rMc49PpyXmiKruRoEWuEwH/hu3Jr87cY3xqV8kFBHX8HG1dF61rEmvInatD3rADH0Cw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796137892; h=DMARC-Filter:Received:DKIM-Signature:X-Google-DKIM-Signature: X-Gm-Message-State:X-Gm-Gg:X-Received:Received:From:To:Cc:Subject: Date:Message-ID:X-Mailer:In-Reply-To:References:MIME-Version: Content-Transfer-Encoding; bh=GddvCNAr0OYV8B1hhXJPV9JPhzhxBHjkY2O9qQpVX+c=; b=hUiNkdqD0gRpIPFS6oiLCCRQaMhfLISPEn5vxmpZ6kOzaE5vNHqVyGxf4nLX3a84wK+H ekoV9SVsP02QkV1H0Flp/qH73bufSSPqdnkd7hhjp0Yhx84rCX7KbKvUiEArHCHOSxzpA fvxqX+5NQV50CT+38le6e7/B/kM2c4yqXTVUn0/1XsmW94hG5+axD8S8LCWLZgmtsRY4M 7YgpK4C71oNbpsHVMJB79K6iOYd01wDsrPZsyFTG6jVZEgwHzHHV94IdFvZqRPqjcKv0b Jx/prmke6xQCNqZziXyQSYzKLQK6DHFcRivbqA+3dRlO1T6P1v9HdoR0J02tZVsZbpA== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=Oqnp+kVC; arc=none smtp.remote-ip=209.85.221.41 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id AC42C606A31A for ; Tue, 1 Dec 2026 15:11:31 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org AC42C606A31A Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=Oqnp+kVC Received: by mail-wr1-f41.google.com with SMTP id ffacd0b85a97d-4ac08f4a0b2so8376251f8f.3 for ; Tue, 01 Dec 2026 07:11:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796137890; x=1796742690; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=GddvCNAr0OYV8B1hhXJPV9JPhzhxBHjkY2O9qQpVX+c=; b=Oqnp+kVC5/MyA7rt/NiwWSyp+zoO++1OrMpnRfS5CpVMOMGpfQfPb6R+L46b2mNTl/ V1meP/pPnJWEt0+Qs9FBiyHq2smgu5LeNqAwkONCY0e4caTrPrOoI4St+qZkmrl9vKeb VTz45Ty24lMxzgRl4cjDX9JE14Cc4LjoiT5bPpzD7/knekgI/r4rO9OwqSzpJ763brOa dJvV5C2N9dmOL2g5GbE2yezq7UvF15HTizk1nBaJWbu10SI2l+Wm9wnEnppxX/nBDcbw eN8t1xDnQIGoZAGWaGI3ksUL6qPNyqti/CGLRiLZ+X+D96wphQUyR2/65f7Ty6cvpcml Oqag== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796137890; x=1796742690; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=GddvCNAr0OYV8B1hhXJPV9JPhzhxBHjkY2O9qQpVX+c=; b=oqhQ978qTiiFRVqKU9GIm4fHGAV+oG+UgghFNe1iDd1DhQ5Xj/piRLtlg6oiEOrXfP CtfC8j8ACnh51+RX1cXvizd80fpbLYLABzUCnetAJfTS5/ZZ8KfcyuerLwA7u04h/dPl yGITqOF2n35iz2VRvypcSN8IJezN3pIHZEYotlVB2GOPs4vRji7QifETVCvwoztJsCwE 1/j7rO2IBOCVTeKOxFbBTU01lkkncAt+y973F4wwgKqHApG9Tqmqy59dxrGeD7QNIzjL h71aB35vbWVunDuY34+KqeNwD/ldtJSxOyoCHsse0ytJfyzFXOYH6nWm/CEtyKfdM1hF zU8A== X-Gm-Message-State: APuU4Z8DMc59RgDW+XtdDlKzkZ8pgyUo0/PsglzD7wSdNAdUa1Rbcp+p tRylBLWU+7ltnD04g1Wvu9akcVZncyJS1sc/fXcu6o17KyOXjZbLtSFI X-Gm-Gg: AZFdTZcnWWcAukD8VjSPtO3mNwB0jxRRDdlE36WirHTgkBleNLqS4d+k7FhkexWGGh0 fTPkGJ1DGSRMwrH6XwZnW1OCZn8l+1j5AsiQoqNv3K5T+5xnKGhVWTaC1Y8VxxHV1SK2+La5KPx tFKlap/jhdvcnHu0ly0nlQxNlIv+baIvOvO9TUtuTssapiiJsp3SvLOZ0EvhyNtSf6bmoJzWg59 PaE1+tz3uzRH5LG+wMHydB+DL1KHrU1P0InxP7a/AVjoYDw0Xru/UDpYOfXuhqgxmk82QfwvN33 hHsHsNcyPq0Oo5xk4/jKjuX3GO/BJ20Sl1P1JREMa/olhpykIQIjmSOkRFjP6HvpfKKtMqrEJur C8z7wusE9M6VR2pML8d+wjueYj0zz3gfkd984fHzDl35mKYwRMcX7iHj6nJ5UyUmDLwCGs6g7dK 9MqoVmGNhzLQAsExHclv4guE0tdE9D8ObAmgYD/TMwocY/lJzSri2rEW8HBAGeEcv70ar4NS9eG 9Vjk6UCoxV4qCH+Li4tCcZOWxh84ESnV2E7O5+ktowZ2LwzhQUfWIPjNKNmi658hK5PCwOqHyXl cimIBZikM2RW+KXgZPH4k7RwbnLyF3rGw0VPIVMH12kYUs9aviXrAn3KtNxke1RNz3/3eO5eSen 2qtfxdfezAY1cf0n6oZwS1hx/nqXp0XhGdVCwNvjx9pfWK6/BeLackw== X-Received: by 2002:a5d:6f0d:0:b0:4af:cd40:6fcb with SMTP id ffacd0b85a97d-4afcd40712emr58931644f8f.57.1796137889889; Tue, 01 Dec 2026 07:11:29 -0800 (PST) Received: from Developer ([216.234.217.221]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4ab658e2c8csm72395109f8f.2.2026.12.01.07.11.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 01 Dec 2026 07:11:29 -0800 (PST) From: Seke Kazuru To: joe.lawrence@redhat.com Cc: live-patching@vger.kernel.org, jpoimboe@kernel.org, mbenes@suse.cz, pmladek@suse.com, song@kernel.org, peterz@infradead.org, bpf@vger.kernel.org Subject: Re: objtool/klp: ___bpf_prog_run jumptable is correlated to the original, fix never runs Date: Tue, 1 Dec 2026 17:11:17 +0200 Message-ID: <20261201151117.1659-1-kazuruuni@gmail.com> X-Mailer: git-send-email 2.51.0.windows.1 In-Reply-To: References: X-Mailing-List: live-patching@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Hello Joe, Thank you for the review and the pointers to the test documents. The regression test follows in the next message as a patch. It fails on mainline and passes with either fix, on gcc 11 to 16 and Clang 15 to 19 and 21 to 23, and on arm64 with Josh's klp-build-arm64-latest branch. Writing it showed that since v7.2 the problem has two forms. Since 873a2208ea ("objtool/klp: Calculate object checksums") and 6016dd33a1 ("objtool/klp: Rewrite symbol correlation algorithm"), a patch to ___bpf_prog_run() that moves a label is rejected with "changed data: jumptable.N", so it cannot be built. A patch that leaves every label in place still builds and runs the original handlers. On kernel/bpf/core.o from 7.4-rc5, a change to the ALU_NEG handler is rejected with "changed data: jumptable.14", and a change to the text of the pr_warn() in default_label builds, with ___bpf_prog_run() still pointing at .klp.sym.vmlinux.jumptable.14. The test covers both. I have a version of option 2 that passes the whole suite on the same compilers. I can send it, with a variant of the test whose table has a different name, if that would help. Separately, test-local-to-global-flip fails with Ubuntu's gcc 11 to 14, which default to -fcf-protection=full. I am sending a small patch for the fixture flags in its own thread. The test was written with an AI assistant from klp-write-tests.txt, klp-test-design.txt and the report, as its Assisted-by tag says. I reviewed it and ran the checks described in the changelog. Thank you, Seke Kazuru