Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp311377imm; Tue, 25 Sep 2018 22:21:55 -0700 (PDT) X-Google-Smtp-Source: ACcGV62aPc4tg5Dg9FB3OneYSarLKx204colfKiaSlmytD+otIJNWwTbOUHtfINv5yppANdOu9/z X-Received: by 2002:a62:c40f:: with SMTP id y15-v6mr3837828pff.161.1537939315553; Tue, 25 Sep 2018 22:21:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537939315; cv=none; d=google.com; s=arc-20160816; b=LLmwUtoRizmscBxNgAC6ss0aV4J+hbXYOqezt0ztDMpY60SdvitknVWz3YHu2ooI0k khhLXWj1sGAQCFRfmsynRCedmKy8WJUlf7OQdD35XUArg+vhrCEpIgIBNM6fR/COCHAw OaTRHY28Z+BkIRTLDJjQ2BIybnMJcrgJjyL0TPW3oddNFV9acuqr6UrMmIB+QGhpjWcA 0S0nd9PYbKfuS3NtNrv4S40lSIpf8P4gOEjtXuADARVYN7CRFs4aKe7K3Q4lpNwyNhGb VHDoLDN9romOJ358HEZsd2t7G/QTV+qzAsWIbdlHtBHMfDVdDmR2Gc8dxbyV5W488MHQ 7tAQ== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=wMxy9odM3Lh06EGEquedZ58Dwp03RDMkTWHS4zeDbHA=; b=ZWMowJYCMfST943NuqiSv+uNhylYqgH19RPnZYKnJ6or3k+QokQ+5YmRF3q5a0EkSQ 6E+/vuY2f8SB+q4u+Atb3r6kmrLRZr6n95LQZIFUAqKxKQfUL6zpMurpWEVw8DEQHZld 4ZmkKHM0uwX6N6ZB5yZfpxidv7g92V5SCIwi7ShNbqBQLvK68pND1xUulSnaUY1bPcYZ FVGhOfJ/JyNsPcl/m3uW3mvKlN/TYFZ3vYxb5q5IujbjvyTNE2nsAtXL0SxeHTlS3GXY sDTfCmRbxr551JHP8uJrTQfthD9KwWvLARbKeeEGmL8ahtkB881IIxCmRqkHeMubbl/t Id7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=JewELMNz; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z10-v6si4485267pgh.310.2018.09.25.22.21.27; Tue, 25 Sep 2018 22:21:55 -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=@gmail.com header.s=20161025 header.b=JewELMNz; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726386AbeIZLca (ORCPT + 99 others); Wed, 26 Sep 2018 07:32:30 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:55209 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726289AbeIZLc3 (ORCPT ); Wed, 26 Sep 2018 07:32:29 -0400 Received: by mail-wm1-f65.google.com with SMTP id c14-v6so771732wmb.4; Tue, 25 Sep 2018 22:21:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=wMxy9odM3Lh06EGEquedZ58Dwp03RDMkTWHS4zeDbHA=; b=JewELMNzuY/lq7tIH2G7CAy0KMLu0CnCRk5eZvym9VQanBkvdCsQUzL0B4kPCpQLXQ NBSDJsxNIBJneXW7Cx1kihTvJapKGCsFwz1HtzXtSypaZQRT/ZvpJGQ+oPI5d2tf7hd9 ICDy4Oqvu+uJDc+WLrs10IygLVvIdlzhHGy1zSQf2L5t7Ma7VFK8tFLKU+nnqRDbpOAw dFyNw6ag9lT7viXWq44ZZ0yPB4cUBIcVxck9xjP0wRnkxkXRUiS41MBdwYwtqNGQa7YC CcyjzX5CpCTjhUxQ8DrGJqxUkXJNO3sP1hOu7mIiqOtLDtnOYL82X6vRNtlUHyfKWVhz K0XQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=wMxy9odM3Lh06EGEquedZ58Dwp03RDMkTWHS4zeDbHA=; b=cMlRgQVkYKXtI5IPGPw9peRGzaGdCjqtmjpvDvQw/rT+Mr4d5bCSRoGAGg/6wVWfLJ rP4lhKTNcmM1omsKWBn2SD4hPZP4MP9aOFT2AaOS+0gUT1Egc14uXMohZHt7RQc7L6gr rZojU9GNUSBELTUUS7kMf+e1Lq3JyYuZw3I8RZkYs8Pan9yzpBQ/TFUSUgtcW/+zF35b p3egMSX0KljSIOj7u7PmEx8E5nNeTI3B4E64yoqF/hT7sBTvVJSzkTRgCjOqjNpsNqfN ThdqkrhKJ4XkZLXBnAu8x8MgePEVfDVoQHfk+jKxLDLIbrsiqIwe8zg16VoZW1puHW0x fxYw== X-Gm-Message-State: ABuFfoioSFgQF42GbtUSDWZ0OFQAJ2GySedCxjCTJDNCXfPaCUvJ2hpP HtEuFKAVQrl3D4ubptRE2ho= X-Received: by 2002:a1c:9b95:: with SMTP id d143-v6mr2974645wme.95.1537939281884; Tue, 25 Sep 2018 22:21:21 -0700 (PDT) Received: from localhost.localdomain ([2a01:4f8:10b:24a5::2]) by smtp.gmail.com with ESMTPSA id q5-v6sm3209512wru.79.2018.09.25.22.21.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 25 Sep 2018 22:21:21 -0700 (PDT) From: Nathan Chancellor To: Vadim Pasternak , Darren Hart , Andy Shevchenko Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, Nathan Chancellor Subject: [PATCH] platform/x86: mlx-platform: Properly use mlxplat_mlxcpld_msn201x_items Date: Tue, 25 Sep 2018 22:21:15 -0700 Message-Id: <20180926052115.21223-1-natechancellor@gmail.com> X-Mailer: git-send-email 2.19.0 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 Clang warns that mlxplat_mlxcpld_msn201x_items is not going to be emitted in the final assembly because it's only used in ARRAY_SIZE right now, which is a compile time evaluation since the array's size is known. drivers/platform/x86/mlx-platform.c:555:32: warning: variable 'mlxplat_mlxcpld_msn201x_items' is not needed and will not be emitted [-Wunneeded-internal-declaration] static struct mlxreg_core_item mlxplat_mlxcpld_msn201x_items[] = { ^ 1 warning generated. It appears this was a copy and paste mistake from when this item was first added. Use the definition in mlxplat_mlxcpld_msn201x_data so that Clang no longer warns. Link: https://github.com/ClangBuiltLinux/linux/issues/141 Fixes: a49a41482f61 ("platform/x86: mlx-platform: Add support for new msn201x system type") Signed-off-by: Nathan Chancellor --- drivers/platform/x86/mlx-platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/platform/x86/mlx-platform.c b/drivers/platform/x86/mlx-platform.c index d89936c93ba0..c2c3a1a19879 100644 --- a/drivers/platform/x86/mlx-platform.c +++ b/drivers/platform/x86/mlx-platform.c @@ -575,7 +575,7 @@ static struct mlxreg_core_item mlxplat_mlxcpld_msn201x_items[] = { static struct mlxreg_core_hotplug_platform_data mlxplat_mlxcpld_msn201x_data = { - .items = mlxplat_mlxcpld_msn21xx_items, + .items = mlxplat_mlxcpld_msn201x_items, .counter = ARRAY_SIZE(mlxplat_mlxcpld_msn201x_items), .cell = MLXPLAT_CPLD_LPC_REG_AGGR_OFFSET, .mask = MLXPLAT_CPLD_AGGR_MASK_DEF, -- 2.19.0