Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp555196ybz; Wed, 22 Apr 2020 03:36:56 -0700 (PDT) X-Google-Smtp-Source: APiQypKvjivxXk/rfuqdafDICxLh2nGZ8Jq6pJVsH6g5vPE7g6QN8SWZF9WvxcFgt9982FkrLXEO X-Received: by 2002:a05:6402:759:: with SMTP id p25mr5512090edy.102.1587551816394; Wed, 22 Apr 2020 03:36:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587551816; cv=none; d=google.com; s=arc-20160816; b=XLj0a4IE/ur59jzh16/X9hH/6FcLq3rjnPHTY5iQSI9C8aiTYsAmuuIVfeRdnYkox1 pghxQl2Z6U7ylmk07bKCDUcdTiUfHZOOXHZqxlm2qQlasS2LlyDsPE8yius1tOSjypgk 3ebSRKataAP7WG+xExTN0fXDWk3keJVfPdcfcPlTkn7dQWPXlMtsXuSxDluHTVFRrNay iZbiOwJC05iVYnZzrkDOEHNKiGRHLHXxctZYl08HWrBajc22Bh13J0YBApN6x0e3bCgC 1F9hZDPnlXX5fGbM1ijVpBIt0y+XECtjLOcvKCNutx9AQYOkDgdgb9xYKrmI9M7nFtyW Owiw== 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 :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=wFpDohVto6uoX2W5waXoFiYKAl66JhA2t9807XRdebY=; b=0r0hCMMnzDW40MjSl424P755i6Fk/lkj5CrgfkqkIflv0e1smdFiaRpwMptj70uCHZ zFZ/MSY3fy4JSyayIEkFEKrpeHrlK9flUGmIutlQhgW6ac1P2cE+EPd1uzQSXw/9ZbOT VGF+7iMx3JUIpKZraXJBSxTojS8wAFHYjPPIVoCNqqSRsGK2++vEVm3ica+WB0HrbFAW 4rILeRVLPCgTIxnazadSFxx3L9L5k4dPepiiK6K/DWhChxtc/ametArU9MAZ/EW+XKcJ S0TDqwF1gftLihfuSixrUzp+LMdzA2D8p/OcDbdgMNAK/rZ5t9ylaXjOKnIwREAb1VKR rgNg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b="EdbkPJ/O"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id x22si3326186eju.478.2020.04.22.03.36.33; Wed, 22 Apr 2020 03:36:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@gmail.com header.s=20161025 header.b="EdbkPJ/O"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1731137AbgDVKcc (ORCPT + 99 others); Wed, 22 Apr 2020 06:32:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731124AbgDVKc0 (ORCPT ); Wed, 22 Apr 2020 06:32:26 -0400 Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E95F6C03C1A8 for ; Wed, 22 Apr 2020 03:32:25 -0700 (PDT) Received: by mail-wm1-x344.google.com with SMTP id 188so1714010wmc.2 for ; Wed, 22 Apr 2020 03:32:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=wFpDohVto6uoX2W5waXoFiYKAl66JhA2t9807XRdebY=; b=EdbkPJ/O0A0k7r8wauBMXkp+DnjaU8ddUlf8SmCT5SrTCtg4GNejvIplMfrlFAO/nq wvcrTLIsX0DHs8oad9NEX4HusoTtMNaaUCXlY5O60+ke1j4MWRMgaeFKACnVFVz5k0Hl TArGwLLIP7qJTodpQOdsfXvXyUt24kXZYyXeaLXu/+A7ngWyr1NG0JQ6gCEQLvzUrfOv B8kmWmdiHxueSi268qMFP135RvKbJGi2nV9U8lIoWyioM6+L8Zv5kEvfiwBZdDsz1ZMn UAWPQOEHcuOV/Vnium8B4MBJfRAFBXYnHO1P9aHInanjA29t4SsBA0zzW3SMKU9cJmXv EyZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=wFpDohVto6uoX2W5waXoFiYKAl66JhA2t9807XRdebY=; b=mtnLxepL57tYheogizqvmnXerxewuqZxo5+DsQl1J8Vi5390VjVFquxTGipidodzq0 LZsWVyARd9RL23sTIVq6vVK4xAJh6jb0hja+vHT8Iu9No3H3VjXrEyyMczZCuKhvo6y7 Ed1mImsp83QV6PGTiLYbN/eeR8mU5vEyw7mUDeMBFKovjllT26as/mW7o945TLpbiypK zNQTkgD0pRFoSitqwY5kBQlknwJ23QauN1xGeNnJAwGJ6Bkkj2YHpjPiiUzsFfxJKwTQ QWygCYn7l02E5vzgkyhEbebyJShqY04yvB8C71in/DKjae7fPm1266K3JsPsEE4S1UR9 vYCA== X-Gm-Message-State: AGi0PuZqKRA9HRHbo21ZBLmjugL2Oj8S5vb1loPMbcj/JCjL2k+Hmsba ayr9TUskJrCewNd4igevTxS308NE X-Received: by 2002:a1c:b38b:: with SMTP id c133mr9561157wmf.24.1587551544425; Wed, 22 Apr 2020 03:32:24 -0700 (PDT) Received: from localhost.localdomain (54033286.catv.pool.telekom.hu. [84.3.50.134]) by smtp.gmail.com with ESMTPSA id s12sm6891603wmc.7.2020.04.22.03.32.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Apr 2020 03:32:23 -0700 (PDT) From: Ingo Molnar To: linux-kernel@vger.kernel.org Cc: Peter Zijlstra , Josh Poimboeuf , Sami Tolvanen , Borislav Petkov , Linus Torvalds , Thomas Gleixner Subject: [PATCH 2/3] objtool: Rename elf_read() to elf_open_read() Date: Wed, 22 Apr 2020 12:32:04 +0200 Message-Id: <20200422103205.61900-3-mingo@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200422103205.61900-1-mingo@kernel.org> References: <20200422103205.61900-1-mingo@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 'struct elf *' handling is an open/close paradigm, make sure the naming matches that: elf_open_read() elf_write() elf_close() Signed-off-by: Ingo Molnar --- tools/objtool/check.c | 2 +- tools/objtool/elf.c | 2 +- tools/objtool/elf.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/objtool/check.c b/tools/objtool/check.c index f2a84271e807..12e2aea42bb2 100644 --- a/tools/objtool/check.c +++ b/tools/objtool/check.c @@ -2614,7 +2614,7 @@ int check(const char *_objname, bool orc) objname = _objname; - file.elf = elf_read(objname, orc ? O_RDWR : O_RDONLY); + file.elf = elf_open_read(objname, orc ? O_RDWR : O_RDONLY); if (!file.elf) return 1; diff --git a/tools/objtool/elf.c b/tools/objtool/elf.c index fab5534c3365..453b723c89d5 100644 --- a/tools/objtool/elf.c +++ b/tools/objtool/elf.c @@ -542,7 +542,7 @@ static int read_relas(struct elf *elf) return 0; } -struct elf *elf_read(const char *name, int flags) +struct elf *elf_open_read(const char *name, int flags) { struct elf *elf; Elf_Cmd cmd; diff --git a/tools/objtool/elf.h b/tools/objtool/elf.h index a55bcde9f1b1..5e76ac38cf99 100644 --- a/tools/objtool/elf.h +++ b/tools/objtool/elf.h @@ -113,7 +113,7 @@ static inline u32 rela_hash(struct rela *rela) return sec_offset_hash(rela->sec, rela->offset); } -struct elf *elf_read(const char *name, int flags); +struct elf *elf_open_read(const char *name, int flags); struct section *elf_create_section(struct elf *elf, const char *name, size_t entsize, int nr); struct section *elf_create_rela_section(struct elf *elf, struct section *base); void elf_add_rela(struct elf *elf, struct rela *rela); -- 2.20.1