Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp789386ybe; Thu, 5 Sep 2019 06:05:24 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvyUvuYWSsUDm2fMqoUf7/cBtXDMH1kPr0dQIQ+M9uaRvmUjlk8f8Pjofm7UqECBTjg52A X-Received: by 2002:a17:902:fe93:: with SMTP id x19mr3139276plm.337.1567688724293; Thu, 05 Sep 2019 06:05:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567688724; cv=none; d=google.com; s=arc-20160816; b=Gj9m5hYo3QbgmJN4reTxdsDL8K31iXkQgGAlhyqG0krL2fTzmHG0+2kw/DAqJwMYGe wXjCb8aK0sE8Iru67KiVTX6acksXi5zss5JjakJIJg990uGvNT0akBIZ0YbODu+Hwpeo QfxnkhDvg9TRyMZEnh3g5HIcdir8xJCFjNgG4aBRZ+bXeJRqlDiohn5rhFBhvOpTAgyM jTQTCrS6nSW6zSHdrEjk/63Md8VFST/dWETuI/DEfEkXu9lQov903gPRo/j/LNWlM0pX sCI3zYTEIzi33qvX7PnSy2sFOnf8HOZg4+1r9Wi45X0s0beAf3DbqXGbrtf0zu5kvsyM qdpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=m4PJ5BxkhJdabophKnWscbZv3JiyfwMExvBYJbuix0c=; b=gu85me0tb+TAJCWPrTyKpU9Yzc3eN0uSEuJ1Z0azAr1nRsJkUaNuSYqfsPrESbgymz K+WcLOo6/yUSVZzv/V1rX+VpVIEvlqlDTeb2dIXzlrTUR3A07T8W9XgSGyiy3/oq7+0d aCHHsEN48dCXzegrpznPF/YldehKT52g0vWbEsiQuGyW8VE7bzgKlFqG7gn3N6PXiOuw YbeweRiX4f8M6+kln1dqqndZyPGCpMvI38BYtnbp5zHGqG8cRulylhV41KS3wg0ypffW vuCuHvcx3aJROaACUtGUXdWppblF29aJH1JcWAGpSSQVFr8wre8Lu3n8CXuW5YIUZv1N K2/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=OgWjamNn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a18si2069116pfa.177.2019.09.05.06.05.07; Thu, 05 Sep 2019 06:05:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=OgWjamNn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732755AbfIELTZ (ORCPT + 99 others); Thu, 5 Sep 2019 07:19:25 -0400 Received: from mail.kernel.org ([198.145.29.99]:56494 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725921AbfIELTY (ORCPT ); Thu, 5 Sep 2019 07:19:24 -0400 Received: from pobox.suse.cz (prg-ext-pat.suse.com [213.151.95.130]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 648B321883; Thu, 5 Sep 2019 11:19:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1567682363; bh=trWSMNdPAGCrEWjjBN4gvX5GSpUep8UtgXKdzyHMgGI=; h=Date:From:To:cc:Subject:In-Reply-To:References:From; b=OgWjamNnWPljlkWynEYUq06hDNTq6oUnb7qTDfkELOCS8a8E5ovwXwfLwHNjHaflY ePkzdy8A+LqrWYziDMGqUJ7bKYtzU7JHOGYvjtDL58Czo+usqCcSITcLj/uRQQzk/m paBfn8l8NDTZOVM5vRT2eAao5PwOLMiwQGpll8Nk= Date: Thu, 5 Sep 2019 13:19:06 +0200 (CEST) From: Jiri Kosina To: Petr Mladek cc: Josh Poimboeuf , Joe Lawrence , Miroslav Benes , linux-kernel@vger.kernel.org, live-patching@vger.kernel.org Subject: Re: [RFC PATCH 2/2] livepatch: Clear relocation targets on a module removal In-Reply-To: <20190905110955.wl4lwjbnpqybhkcn@pathway.suse.cz> Message-ID: References: <20190814151244.5xoaxib5iya2qjco@treble> <20190816094608.3p2z73oxcoqavnm4@pathway.suse.cz> <20190822223649.ptg6e7qyvosrljqx@treble> <20190823081306.kbkm7b4deqrare2v@pathway.suse.cz> <20190826145449.wyo7avwpqyriem46@treble> <5c649320-a9bf-ae7f-5102-483bc34d219f@redhat.com> <20190904084932.gndrtewubqiaxmzy@pathway.suse.cz> <20190905025055.36loaatxtkhdo4q5@treble> <20190905110955.wl4lwjbnpqybhkcn@pathway.suse.cz> User-Agent: Alpine 2.21 (LSU 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 5 Sep 2019, Petr Mladek wrote: > > I don't have a number, but it's very common to patch a function which > > uses jump labels or alternatives. > > Really? My impression is that both alternatives and jump_labels > are used in hot paths. I would expect them mostly in core code > that is always loaded. > > Alternatives are often used in assembly that we are not able > to livepatch anyway. > > Or are they spread widely via some macros or inlined functions? All the indirect jumps are turned into alternatives when retpolines are in place. -- Jiri Kosina SUSE Labs