From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E48FC3A1D1B for ; Tue, 31 Mar 2026 20:52:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=170.10.133.124 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774990359; cv=none; b=Ec4d0+aBjsoc7tX8hXOLgHDMUySWQbvfkKmMc+UJnH+E1BzPXEq/SuQIA6UsvKq/q7p1voRcWQihpNsqocQYHbbgUX3iSSGrBgRzWWABNCNK379WToNPp3fZvfHJ9lpHL5Em0fp1jHDnujS8hVbumbAnNJRXn2DhuFT0ZBN2mic= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1774990359; c=relaxed/simple; bh=8+UnT8vSH5x3hLrKGpP2WV538rU6FUTW4TA7XgOjUqM=; h=Mime-Version:Content-Type:Date:Message-Id:Cc:Subject:From:To: References:In-Reply-To; b=DAr2MNwHR+cRmNmdlF2k++qE1/9S7fpxYfmmlUWrV5PBG/C2B2R8PcZYBXgTHvjK87BPQfVn4qU4Jq0pIyi/922r6UuEZuu981UU2Wddz4kaeH4kb3ORbpybofb3Mtu4DVWY8BaEzTth3OMhvA8LWIHTpkTcrYIaeg4clI1hhG0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com; spf=pass smtp.mailfrom=redhat.com; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b=T2dVBA7E; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b=rGkkLmvT; arc=none smtp.client-ip=170.10.133.124 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=redhat.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="T2dVBA7E"; dkim=pass (2048-bit key) header.d=redhat.com header.i=@redhat.com header.b="rGkkLmvT" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1774990357; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=jf5SVc6Wh+MV+1Py3i/pwSgvdn+BQX+ZgkhsoC83PmE=; b=T2dVBA7EZ6xJBo7zwgzTn5l7PUFrqKu9T/XRUVo0/rnn1hZl4cGybwa1Zziig/jlCkAxzW XFYyglo0c6DyyW2uqIQoakM2nT6VBfVyG3wQTATXsidkJaLD80HXB3XYig7HikgxvpeKHE 7YtpeOapfKe389tkHJD64ByjPlr3N84= Received: from mail-vk1-f198.google.com (mail-vk1-f198.google.com [209.85.221.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-110-oKpLa4UGPtOpgVIrRUWBoA-1; Tue, 31 Mar 2026 16:52:34 -0400 X-MC-Unique: oKpLa4UGPtOpgVIrRUWBoA-1 X-Mimecast-MFC-AGG-ID: oKpLa4UGPtOpgVIrRUWBoA_1774990354 Received: by mail-vk1-f198.google.com with SMTP id 71dfb90a1353d-56d817b03a8so786043e0c.3 for ; Tue, 31 Mar 2026 13:52:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=google; t=1774990353; x=1775595153; darn=vger.kernel.org; h=in-reply-to:references:to:from:subject:cc:message-id:date :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=jf5SVc6Wh+MV+1Py3i/pwSgvdn+BQX+ZgkhsoC83PmE=; b=rGkkLmvTMp/Zmbgznyoe2IySWvq7FmHlAIDHJGQlhUKWz9qElnWvbWb+OQYHNXjHqR aSB3fPcdDaTHwRWrDSi/RA80SqnCIHHuxQViDEmkIetUMO1soqb8jwLkqAsn0dMv76Oe OxOboiNq67CGN5vXLu/QpVJPNE7YiLWntL81zYOmJT3WfsVbQb79H4TeGiUlegZasHwY fySmvBRH5q1ovzGOSHbUR6iSh/lj5AdJGYGW1+PY602wCUeoknPVgRROvl2HTtnT4cHe N8UKJuzPKuRDVGYgLlAAYMFHgD1/k6t0SmyO879meaBDU2W5Ayaf0QVKsy6xQtNliV30 Yz3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774990353; x=1775595153; h=in-reply-to:references:to:from:subject:cc:message-id:date :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=jf5SVc6Wh+MV+1Py3i/pwSgvdn+BQX+ZgkhsoC83PmE=; b=hWsTxlLojNGcNdBvR5CqOcRjoV49dvVB6zbtGqtB//AiFKmO92jtWuKZiqjLn0ngMX SiYcIpzCtfb/tT9877XI1RXsfeipY1wLtSXDXrdpXXg6ki3Xrwj2VKUiIF97jP333W5R oDFm1o3sVfogGsjYDXXHDmGYs/jIU7ZA8pWJwexwRI7es6eHrgtQQIWFNzTBiMeP1fDX eaNf6h1uf+KTWu4fSlYKdmjigNU86GbwXdUEXOz6rvLQZCs5nH7tznoocWjzah/RG8Q9 qUTjexT6hFg2hQuclKebYDSZ4AzkVoBx9nzAoBNqgs+TxAucyG8BvpTLQ4wHFZiDczz/ 2jyQ== X-Forwarded-Encrypted: i=1; AJvYcCXDu0fzm1w5swzoAnuLygDtVyRdcgowFm+4qtYDTJ3MU3xLdO5PZ2KQLYIM6vI+h+VH9xa3tGUx20jLR2E=@vger.kernel.org X-Gm-Message-State: AOJu0Ywwv91wkkeN/B91j3ooXa1dzVTGieghKLPGKhNQrnWKC9w+b90m HcYYiIsc2rslTXuhBMH7X2rJw0W+IozQ+dK6ZtoqWmSnpndxikSDv95C8ZNjFqXcybUEiXCsq1F lr1HsCCbpy+8SkAbZ1ljl+mz6KlSR5Ob+ygPjpSGyjh570Y0LU5ddSyXXkj9sR2JI/2qA8SbUd3 PG X-Gm-Gg: ATEYQzx2dVwRAbLIpQa+4RQeXm8fY3SzcB8nHR9wk5/bC/PuZ3DY9EHhN3xuVJJtpPr UTi0l5eRyEcESGVlsrKiZmx/VgpS5eO6xoZ/IysxXe5l/wTuhMFV94wTEaCpRpfY6VChpAH6L+l LU026OoiQHiX5F5Sbo+k3oOuNYxVLCR/6nWBjkD5tcQucDbq/2gVPvn0JvXTRrIA3scYW+Veo5o R1DtVC2VtkiuXG7sB01mwqJJgcVmybVMsxC0HCciZ0ghDkyeziXlMr3r0oGsvn9xOw9l3nkIXUb DwNGP2DX92xMhIKMkanIB3MCidB6IOjOc69LSlSx/ozItbhGqeQl6YhppiOC/FzLDRD6dhtPdDH 6wgo0ZP8G59JXaRo= X-Received: by 2002:a05:6122:8c8d:b0:56b:8023:b89e with SMTP id 71dfb90a1353d-56d8a8a5bb0mr521741e0c.6.1774990353568; Tue, 31 Mar 2026 13:52:33 -0700 (PDT) X-Received: by 2002:a05:6122:8c8d:b0:56b:8023:b89e with SMTP id 71dfb90a1353d-56d8a8a5bb0mr521734e0c.6.1774990352988; Tue, 31 Mar 2026 13:52:32 -0700 (PDT) Received: from localhost ([143.54.48.116]) by smtp.gmail.com with ESMTPSA id 71dfb90a1353d-56d588bae4bsm13748228e0c.5.2026.03.31.13.52.29 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 31 Mar 2026 13:52:32 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: multipart/signed; boundary=a749765ff5ddb75338189f0b931545c94d3203d4c9aa1b60eb5b58e37bdb; micalg=pgp-sha512; protocol="application/pgp-signature" Date: Tue, 31 Mar 2026 17:52:27 -0300 Message-Id: Cc: "Pablo Hugen" , , , , , , , Subject: Re: [PATCH] selftests/livepatch: add test for module function patching From: "Pablo Hugen" To: "Miroslav Benes" , "Joe Lawrence" References: <20260320201135.1203992-1-phugen@redhat.com> <177436214729.62466.7977538958560300344.b4-review@b4> <177442832293.70541.15179138173140080388.b4-reply@b4> In-Reply-To: <177442832293.70541.15179138173140080388.b4-reply@b4> --a749765ff5ddb75338189f0b931545c94d3203d4c9aa1b60eb5b58e37bdb Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 > We sort of test the same in test-callbacks.sh. Just using different > means. I think I would not mind having this as well. Ok. The original idea Joe suggested was to check the function output of module targets directly. From what I can tell, test-callbacks.sh covers the callbacks and test-ftrace.sh checks that ftrace can still trace a function after it's been livepatched, neither actually checks that a replacement function in a module target runs. I can be wrong though, still getting familiar with the livepatch tests. > I was *just* in the middle of replying to the patch when yours came in, > so I'll just move over here. I had noticed the same thing re: > test-callbacks.sh despite originally suggested writing this test to > Pablo (and forgot about the callbacks test module). With that, I agree > that it's a nice basic sanity check that's obvious about what it's > testing. Fair point. Altough biased I think it is nice to have this explict sanity c= heck. > A nit but is 'noinline' keyword needed here? proc_create_single() below > takes a function pointer so hopefully test_klp_mod_target_show() stays > even without it? > No strong preference either way. I won't fault a livepatch developer > for being paranoid w/respect to the compiler :D Yeah I think you're right, not strictly needed, just wanted to be sure. After some experience rebasing kpatch integration tests I've been bitten enough times to be paranoid about that :) But since I will work on a follow-up for the other suggestions, I think I'll drop it there. Anyways, thanks for the reviews! Pablo --a749765ff5ddb75338189f0b931545c94d3203d4c9aa1b60eb5b58e37bdb Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQQMP+tqh8XWgfhXItgg/MNYDx+9egUCacw0DwAKCRAg/MNYDx+9 et7mAQCQ3BS4Tzt+l9lrgsw5/AiE6uK+9S9cTY3uaYshOqa7YwD9EDdExC61qsp7 +e6A4kEz6WT7/BhN+jL0JDNSIg8zdQg= =e5bP -----END PGP SIGNATURE----- --a749765ff5ddb75338189f0b931545c94d3203d4c9aa1b60eb5b58e37bdb--