From patchwork Tue May 26 13:01:57 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: You-Sheng Yang X-Patchwork-Id: 1298067 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=canonical.com Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49WZ2s0Q3Sz9sV1; Tue, 26 May 2020 23:05:57 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1jdZHE-0007vf-A5; Tue, 26 May 2020 13:05:52 +0000 Received: from mail-pg1-f194.google.com ([209.85.215.194]) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1jdZFr-0006go-CA for kernel-team@lists.ubuntu.com; Tue, 26 May 2020 13:04:27 +0000 Received: by mail-pg1-f194.google.com with SMTP id j21so10045892pgb.7 for ; Tue, 26 May 2020 06:04:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=kwZXpTxETVOVrB6EaiNIrD+yMSNzd85HwAobaxVXw1I=; b=LVTFS3fvHx2jpL6SQ/raETn9fy5y0aTxjaAehLYAOg3+JIqFZO/SleOEzLWUKlzf2r E3Dch5l/eaRMrt2x54xGgOWOilLWVDQn1yOATj5FXmF3rLCvtlJZqou6BH8YwHFpHK0H fJTuASuaqQXj8VL9IMV+6devBAmrWF1qeULLV3fkcf7L12gujEbdVB5VmySE6Mnd4CpY v9PHjKt3eOpZ77z6kuHqDmsNf4b1lz5k9vndkaUgtfNkEK6mlVvmUcyZsxGTneJbtRo2 ER7b/wdXKpRgqJd4Riagjpz/p+d3LKQIRHIGDvVg4KqG7wdAZtd+eTR7AwR0kDwjmyRA C0gQ== X-Gm-Message-State: AOAM533ZqitJjeFTV+x6Fgiuz+8X08DrpL52KtACnDQ0mlDwlBHx0FET rGoOow6JtDFHUzuh48hiMdPMV4bwTwU= X-Google-Smtp-Source: ABdhPJxvStI15kbBvIuMAfHcRdoKL9djvDS37AGO8nENAndaR5pOvQY8Z0h6NV4zsndiCKURqoIZCQ== X-Received: by 2002:a63:9258:: with SMTP id s24mr986920pgn.362.1590498264272; Tue, 26 May 2020 06:04:24 -0700 (PDT) Received: from localhost (61-220-137-37.HINET-IP.hinet.net. [61.220.137.37]) by smtp.gmail.com with ESMTPSA id k65sm15348473pfd.156.2020.05.26.06.04.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 26 May 2020 06:04:23 -0700 (PDT) From: You-Sheng Yang To: kernel-team@lists.ubuntu.com Subject: [PATCH 53/60][SRU][OEM-5.6] UBUNTU: SAUCE: iommu/amd: Fix variable "iommu" set but not used Date: Tue, 26 May 2020 21:01:57 +0800 Message-Id: <20200526130204.238445-54-vicamo.yang@canonical.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200526130204.238445-1-vicamo.yang@canonical.com> References: <20200526130204.238445-1-vicamo.yang@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" From: Qian Cai BugLink: https://bugs.launchpad.net/bugs/1876707 The commit dce8d6964ebd ("iommu/amd: Convert to probe/release_device() call-backs") introduced an unused variable, drivers/iommu/amd_iommu.c: In function 'amd_iommu_uninit_device': drivers/iommu/amd_iommu.c:422:20: warning: variable 'iommu' set but not used [-Wunused-but-set-variable] struct amd_iommu *iommu; ^~~~~ Signed-off-by: Qian Cai Link: https://lore.kernel.org/r/20200509015645.3236-1-cai@lca.pw Fixes: dce8d6964ebd ("iommu/amd: Convert to probe/release_device() call-backs") Signed-off-by: Joerg Roedel (cherry picked from commit cfcccbe8879f79bc9f8a162bcb482c74b8768094 iommu/next) Signed-off-by: You-Sheng Yang --- drivers/iommu/amd_iommu.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/iommu/amd_iommu.c b/drivers/iommu/amd_iommu.c index d6abad7f8fd1..257bcdbfafa1 100644 --- a/drivers/iommu/amd_iommu.c +++ b/drivers/iommu/amd_iommu.c @@ -419,15 +419,12 @@ static void iommu_ignore_device(struct device *dev) static void amd_iommu_uninit_device(struct device *dev) { struct iommu_dev_data *dev_data; - struct amd_iommu *iommu; int devid; devid = get_device_id(dev); if (devid < 0) return; - iommu = amd_iommu_rlookup_table[devid]; - dev_data = search_dev_data(devid); if (!dev_data) return;