Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp2404649imu; Mon, 17 Dec 2018 01:07:16 -0800 (PST) X-Google-Smtp-Source: AFSGD/VhLQRToVNVL7Wa2tt6A3mVAKWXbgvn9H4RLbYJ6OerQ5iFN+O29gYQRca+3J1QwPQ3mI6T X-Received: by 2002:a17:902:e28e:: with SMTP id cf14mr12225054plb.311.1545037636236; Mon, 17 Dec 2018 01:07:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545037636; cv=none; d=google.com; s=arc-20160816; b=FvBXTCAtvvz6/CbEHDmR0lTBuQyUAXLh1NHWZb6PAIWcFriO+kgNa04DJklifg+HNz zYvVm4y+88nGQV5ctAqtfhyXlsedfeXXmDsb6XW+6l37asLJ2sq8/PnOeupCeqzVdKRp KzGqxGK1ppj1oOxu8x16yPRZDACQRY5HTjlDlYxrdxR5VMWYasW7Ks/ilmUS8BYBfGZg DFfzfndpDK2otiUWkIE0G+1dlve2CHBpdWoeubO3MltmNCbYUMHeRQzD9uVA1G6jT2MQ pj5V7FenA/HZTs1bRE/KRgcO9fDz0aM5aC+w+RIn7Wg7AKlVQSzbppKfFy/108/on1IS 8lZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=CMMCAqaIGQ+VvEv/oGAmHHC6KONey+ZFvlJ2qFm3+1I=; b=bdUaJlnaXcjCE6xCQRXWL8+T5hxoLPYVeRoUkdr7G1FBQ1QusLJUZfv1khiBRUqFTH kPir32wQ1ZUHwLKev6U3uVyn/1F4ZNYX3R8ql8D/pyvExBU1K16+f2OqGQoZJDM6OX+K R3CzJweZsTk/Io6gchfi2l0CwJHmWI8YFCApu4XtDt8Dl2tzraUG9MXsaPCBLNdHQGEd 5aRs9WQhQOHrsVmvctbfKO50ShRQdKIK9LG0Ur9apXJPpWuHVi0KAaObSIhZ9jOKyYAz GRS+LgXybygr72uXaWqTY0A/G12zSnUm+tzq//W9z0xwoTY39mUE2nbD1MDBdq3ODqDT CzlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=FQh7lDD0; 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 bj2si10074010plb.27.2018.12.17.01.07.01; Mon, 17 Dec 2018 01:07:16 -0800 (PST) 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=FQh7lDD0; 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 S1731614AbeLQIWS (ORCPT + 99 others); Mon, 17 Dec 2018 03:22:18 -0500 Received: from mail.kernel.org ([198.145.29.99]:56896 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726496AbeLQIWS (ORCPT ); Mon, 17 Dec 2018 03:22:18 -0500 Received: from localhost.localdomain (NE2965lan1.rev.em-net.ne.jp [210.141.244.193]) (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 AB5C720672; Mon, 17 Dec 2018 08:22:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1545034937; bh=q1ieTWvagMn6dWu5JFlMmZaHuRe06eqQjH4kDM/vd7I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FQh7lDD0j7sK2p5hu1eD3CpX7WV0MW+KolliySnMr06h/fPB+AgWaq2GYaztHZX9v FFBmG5s/mx8BWh5p3d6b4DJJXQVcBrLFPd1y7Aufi7Fta391Nmpw5bxX6ZmR39RUEp VOTW/JZgEKDc4kD+B8r30bBSfneUsRd77zAOgU6Q= From: Masami Hiramatsu To: Ingo Molnar , Andrea Righi Cc: "Naveen N . Rao" , Anil S Keshavamurthy , "David S . Miller" , Masami Hiramatsu , Yonghong Song , Andy Lutomirski , Thomas Gleixner , Borislav Petkov , "H . Peter Anvin" , x86@kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 3/3] x86/kprobes: Remove unneeded arch_within_kprobe_blacklist from x86 Date: Mon, 17 Dec 2018 17:21:53 +0900 Message-Id: <154503491354.26176.13903264647254766066.stgit@devbox> X-Mailer: git-send-email 2.13.6 In-Reply-To: <154503482486.26176.6224515860220847638.stgit@devbox> References: <154503482486.26176.6224515860220847638.stgit@devbox> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove x86 specific arch_within_kprobe_blacklist(). Since we have already added all blacklisted symbols to kprobe blacklist by arch_populate_kprobe_blacklist(), we don't need arch_within_kprobe_blacklist() on x86 anymore. Signed-off-by: Masami Hiramatsu --- arch/x86/kernel/kprobes/core.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/arch/x86/kernel/kprobes/core.c b/arch/x86/kernel/kprobes/core.c index 2a291fcb6443..4ba75afba527 100644 --- a/arch/x86/kernel/kprobes/core.c +++ b/arch/x86/kernel/kprobes/core.c @@ -1026,14 +1026,6 @@ int kprobe_fault_handler(struct pt_regs *regs, int trapnr) } NOKPROBE_SYMBOL(kprobe_fault_handler); -bool arch_within_kprobe_blacklist(unsigned long addr) -{ - return (addr >= (unsigned long)__kprobes_text_start && - addr < (unsigned long)__kprobes_text_end) || - (addr >= (unsigned long)__entry_text_start && - addr < (unsigned long)__entry_text_end); -} - int __init arch_populate_kprobe_blacklist(void) { return kprobe_add_area_blacklist((unsigned long)__entry_text_start,