Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp3742533imm; Mon, 6 Aug 2018 09:49:09 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcG8JAzRmvxBgvzZeBnby3KA332Srk4iJASu4plPIUdJIpbc5LQZWjaafUgcxJDVeRPXyDD X-Received: by 2002:a63:c44a:: with SMTP id m10-v6mr15317576pgg.416.1533574149509; Mon, 06 Aug 2018 09:49:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533574149; cv=none; d=google.com; s=arc-20160816; b=nwEviqTz+fgWk5fufegAmh7zCBPNPdA8q05tRBdKjB+6cD2SBTcrVsB6SO4olSiwdC /obEsKSZxCmuUae2qNI7/mPF99CGt7csAKPdjc9YqZNRiKKEuIXJe5EkP9S0IfaGMJDr G6+kRm/YlP5ZUT8W3IKDgcW71VK/8oIZHDIHFTTO/EdEM6DvFx6MQOfpLSR1+RpT+Oas nOweqietcGXg3YtS+pw3Nzy0W1+pJywAM90cqH694IfyeL2HbfRgz1p0LebY2oWWyfo/ nSDwWVSENrxr3NyjrGjpeZ8hHLECOqaOTc2dfgOLihhMh1EbnwFtrgDjK0HNaZ66P0xz PNoQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=/cnOWC8Edr23vvjvVsKQdi+BtNqVacIxLDmDJm9HTqw=; b=WS8prq/mibmhB+fQHRVT40LSvwD/qKLMzP91Cy6kylby/e8r8mSHHUUynu8qOlyEla LQp7bdFsyeIEOwX3LLaPC0FlCH8y0DLkIIri7Ok0tjv4KJFidfz/k0la4U1bSy/cFgn0 pZGc6HmEILTOddtUiYXrkZwFutb6mv3T/P4SFR0aMKPuVQayOq4lueP2DeIMEvt29+Yt kALm5pESQtrrTdW8tyDEXuyDd4ZhJick8lQWRnoOs1guyVfODoirbebk+yXkWeisdXt5 j5Pz4ka1nzwc1Pzy72xhfneA4INs59Txfuxcj6TA7cW8tRDU484Uh5XpEhentt3VdZ4T rnaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=OAcU0W8F; 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=synopsys.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p65-v6si14034518pga.401.2018.08.06.09.48.54; Mon, 06 Aug 2018 09:49:09 -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=@synopsys.com header.s=mail header.b=OAcU0W8F; 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=synopsys.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732478AbeHFSy3 (ORCPT + 99 others); Mon, 6 Aug 2018 14:54:29 -0400 Received: from smtprelay4.synopsys.com ([198.182.47.9]:37058 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730503AbeHFSy3 (ORCPT ); Mon, 6 Aug 2018 14:54:29 -0400 Received: from mailhost.synopsys.com (mailhost1.synopsys.com [10.12.238.239]) by smtprelay.synopsys.com (Postfix) with ESMTP id E078A24E0513; Mon, 6 Aug 2018 09:44:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1533573874; bh=xusQBT7Tx5DnvNgWHCuXP4/Vag/vTHQUvbeKwVs2aCM=; h=From:To:Cc:Subject:Date:From; b=OAcU0W8FY45Tfe1jYcYp/uhGbSXEnub739xcxRjC4h1kGh0yo6HTZ9Igu7muUnx4D qTQBSdKSMmfzgB0hC0OEC1neXDJVKLunL11Bc38smUeYsBwYopf+3fZDTegFXl/ojn EJdeOyLzPyCjNnpD/O2vSF3tJ5Wj4lwRbHnGfGMTOtJjHKJoCvOzsxVQt4p9R26Cbj 7LFrnksRjObyAzwr9AlwJvhQy9nLdBo35p1EfNYwlE21w2Jwrl4q4m1efeNRlJIl7o C3b+ucEvi2yZpz9EqIgn0s8ZfefV4Xww42VKiEqHtBgMNyKZwFUDjxt/8CfmIh++r5 rVqiphymqCXyw== Received: from paltsev-e7480.internal.synopsys.com (unknown [10.121.8.86]) by mailhost.synopsys.com (Postfix) with ESMTP id DF0325155; Mon, 6 Aug 2018 09:44:31 -0700 (PDT) From: Eugeniy Paltsev To: linux-snps-arc@lists.infradead.org Cc: linux-kernel@vger.kernel.org, Vineet Gupta , Alexey Brodkin , Eugeniy Paltsev Subject: [PATCH 1/2] ARC: show_faulting_vma: remove unused variables Date: Mon, 6 Aug 2018 19:44:23 +0300 Message-Id: <20180806164424.32439-1-Eugeniy.Paltsev@synopsys.com> X-Mailer: git-send-email 2.14.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We get 'inode', 'dev', and 'ino' in show_faulting_vma() but never use them. So get rid of this variables and corresponding code. Signed-off-by: Eugeniy Paltsev --- arch/arc/kernel/troubleshoot.c | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/arch/arc/kernel/troubleshoot.c b/arch/arc/kernel/troubleshoot.c index 783b20354f8b..f7330a3a1c4d 100644 --- a/arch/arc/kernel/troubleshoot.c +++ b/arch/arc/kernel/troubleshoot.c @@ -83,9 +83,6 @@ static void print_task_path_n_nm(struct task_struct *tsk, char *buf) static void show_faulting_vma(unsigned long address, char *buf) { struct vm_area_struct *vma; - struct inode *inode; - unsigned long ino = 0; - dev_t dev = 0; char *nm = buf; struct mm_struct *active_mm = current->active_mm; @@ -99,12 +96,8 @@ static void show_faulting_vma(unsigned long address, char *buf) * if the container VMA is not found */ if (vma && (vma->vm_start <= address)) { - struct file *file = vma->vm_file; - if (file) { - nm = file_path(file, buf, PAGE_SIZE - 1); - inode = file_inode(vma->vm_file); - dev = inode->i_sb->s_dev; - ino = inode->i_ino; + if (vma->vm_file) { + nm = file_path(vma->vm_file, buf, PAGE_SIZE - 1); } pr_info(" @off 0x%lx in [%s]\n" " VMA: 0x%08lx to 0x%08lx\n", -- 2.14.4