From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756151AbdESBZV (ORCPT ); Thu, 18 May 2017 21:25:21 -0400 Received: from mail-pg0-f44.google.com ([74.125.83.44]:32904 "EHLO mail-pg0-f44.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755110AbdESBZP (ORCPT ); Thu, 18 May 2017 21:25:15 -0400 From: Matthias Kaehlcke To: Jens Axboe Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, Matthias Kaehlcke Subject: [PATCH] block: partitions: mac: Mark mac_fix_string() as __maybe_unused Date: Thu, 18 May 2017 18:24:54 -0700 Message-Id: <20170519012454.66962-1-mka@chromium.org> X-Mailer: git-send-email 2.13.0.303.g4ebf302169-goog Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The function is only used when CONFIG_PPC_PMAC=y. Adding the attribute fixes the following warning when building with clang: block/partitions/mac.c:22:20: error: unused function 'mac_fix_string' [-Werror,-Wunused-function] Signed-off-by: Matthias Kaehlcke --- block/partitions/mac.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/partitions/mac.c b/block/partitions/mac.c index 621317ac4d59..57483faddaac 100644 --- a/block/partitions/mac.c +++ b/block/partitions/mac.c @@ -19,7 +19,7 @@ extern void note_bootable_part(dev_t dev, int part, int goodness); * Code to understand MacOS partition tables. */ -static inline void mac_fix_string(char *stg, int len) +static inline void __maybe_unused mac_fix_string(char *stg, int len) { int i; -- 2.13.0.303.g4ebf302169-goog