From patchwork Wed Sep 12 06:55:41 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 968854 X-Patchwork-Delegate: agraf@suse.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.denx.de (client-ip=81.169.180.215; helo=lists.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="BSA0B/KC"; dkim-atps=neutral Received: from lists.denx.de (dione.denx.de [81.169.180.215]) by ozlabs.org (Postfix) with ESMTP id 429CGW3qddz9sB5 for ; Wed, 12 Sep 2018 16:55:29 +1000 (AEST) Received: by lists.denx.de (Postfix, from userid 105) id DBDBAC21FA6; Wed, 12 Sep 2018 06:55:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id 1B239C21EF0; Wed, 12 Sep 2018 06:55:17 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 4E2B9C21EF0; Wed, 12 Sep 2018 06:55:15 +0000 (UTC) Received: from mail-pl1-f194.google.com (mail-pl1-f194.google.com [209.85.214.194]) by lists.denx.de (Postfix) with ESMTPS id 9EB7FC21ED5 for ; Wed, 12 Sep 2018 06:55:14 +0000 (UTC) Received: by mail-pl1-f194.google.com with SMTP id j8-v6so492844pll.12 for ; Tue, 11 Sep 2018 23:55:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=j68+4aXzlEaRuEp6eo6xngCOWSYpu0GtQzmVEwggTnk=; b=BSA0B/KCU66aQL7NJS8QARewExo077EwwZIrLp1/pjedvgpQ0nPkLdS+7aFUQixf53 AP2VVTuLV9bYdVhIpHykqJM1u1fnWq+7Tu1xfh/NZsZ9hzyZxu5oJ8h2Gusmge7oGgBT iX/iEChJ73PoQnTwCKdGU07ejoXerQc74mPzw= 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:in-reply-to :references; bh=j68+4aXzlEaRuEp6eo6xngCOWSYpu0GtQzmVEwggTnk=; b=P+VbULbSC68Y2QIsu/RRpduP0eoffgwVE3ngzldbcVAYxAOz/snCIOubh04KeG4729 K6TOZbYhV578OTEjXnOSiY1Y3+Un44mAcP5cSvO0Q8IYNLAuVTFgltVYUdB7IL3cBZTk NTEBTi1EMKkME4NC4t5UwLEcG+QHBhre4MpH7OtOexWzoihJ29JKSNTve/k17I4IGhfI 8Oz5Pdly2jdhk5Vw1EDJSVpZ7YUAjjPhIR5nsRWW5P9GfC4YgwZtWdDC29vvf+eSNT7D 4Rz0OAJkYzwM2u02DYhN2LQ6sg0TTR/NyfrN5AAQAJEo2KaoHZ4dRrZAqSoNHX7WBXCZ AZIg== X-Gm-Message-State: APzg51CRXEQmdnwzyaslioVYlNzuhaFDXACNgxU8sk8f1M+WWmTzuEdb 5dLnfmVkz227DOmlOKcnKCGIOQ== X-Google-Smtp-Source: ANB0VdaWJofYOL+oXVonyX2osCvDN0h/kNA+ngqG4pV3/5lamzojW0bFC9U2qtHR/uSUaPiR1fWSsw== X-Received: by 2002:a17:902:8481:: with SMTP id c1-v6mr492664plo.177.1536735313002; Tue, 11 Sep 2018 23:55:13 -0700 (PDT) Received: from linaro.org ([121.95.100.191]) by smtp.googlemail.com with ESMTPSA id i185-v6sm317205pfg.89.2018.09.11.23.55.12 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 11 Sep 2018 23:55:12 -0700 (PDT) From: "Akashi, Takahiro" To: trini@konsulko.com Date: Wed, 12 Sep 2018 15:55:41 +0900 Message-Id: <20180912065541.6251-1-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180911065922.19141-2-takahiro.akashi@linaro.org> References: <20180911065922.19141-2-takahiro.akashi@linaro.org> Cc: u-boot@lists.denx.de, xypron.glpk@gmx.de, agraf@suse.de Subject: [U-Boot] [PATCH v3.1 01/26] fs: fat: guard the content of include/fat.h X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" From: AKASHI Takahiro The whole content of include/fat.h should be guarded with CONFIG_FS_FAT. This is necessary specifically because fs/fs.c unconditionally includes fat.h, which refers to a config symbol, CONFIG_FS_FAT_MAX_CLUSTSIZE. So if CONFIG_FS_FAT, and thus CONFIG_FS_FAT_MAX_CLUSTSIZE, is not defined, fs/fs.c will fail to compile. Signed-off-by: AKASHI Takahiro --- include/fat.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/fat.h b/include/fat.h index 09e142368585..8bc280e872ba 100644 --- a/include/fat.h +++ b/include/fat.h @@ -9,6 +9,9 @@ #ifndef _FAT_H_ #define _FAT_H_ +#include +#ifdef CONFIG_FS_FAT + #include #include @@ -202,4 +205,5 @@ int fat_opendir(const char *filename, struct fs_dir_stream **dirsp); int fat_readdir(struct fs_dir_stream *dirs, struct fs_dirent **dentp); void fat_closedir(struct fs_dir_stream *dirs); void fat_close(void); +#endif /* CONFIG_FS_FAT */ #endif /* _FAT_H_ */