From patchwork Tue Aug 28 14:24:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam Protsenko X-Patchwork-Id: 10578631 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id E3F945A4 for ; Tue, 28 Aug 2018 14:24:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D4A6C2996A for ; Tue, 28 Aug 2018 14:24:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C8C2F29BD7; Tue, 28 Aug 2018 14:24:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 779A82996A for ; Tue, 28 Aug 2018 14:24:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728195AbeH1SQW (ORCPT ); Tue, 28 Aug 2018 14:16:22 -0400 Received: from mail-lj1-f196.google.com ([209.85.208.196]:35871 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726998AbeH1SQV (ORCPT ); Tue, 28 Aug 2018 14:16:21 -0400 Received: by mail-lj1-f196.google.com with SMTP id v26-v6so1591177ljj.3 for ; Tue, 28 Aug 2018 07:24:26 -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=tIDOHwRKxCYxaDFqqH/tkWpkFutM4/6P5ONExsDModw=; b=gRHDlIgw/UL2aiHtKC8zHOGTa3c5PW+AggNOiUH4/CFBjvmuSvo3wH5Smp7FOeAY5F tbRQSyTaNHb3Svvgs99hQcVnktN2joNMFxh1o8DJzMvZIOwyUEDq2oNdgw3Pm+IXXF37 I0/iEbngr1/FsFku7xLKT66iwsdoUK22UInqk= 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=tIDOHwRKxCYxaDFqqH/tkWpkFutM4/6P5ONExsDModw=; b=FpEs2J7qUgRF2/wKO37Cp47qFXvYQP75kisUYV63oPdZn4Sh9FnxWdZyIFALJHJ39Z P79OkZcmGZJd6w6ZqtwCWKXhUIENW5nSbnSEXBXoNkDhelZYJw1s00BZ67lt2UNRc80W EVEq/otQtplk42Saa3oIgcCbm4rxXVFqzpFcl688GvHQWrB9Pd26CFIreOm/TFC9Ed5/ YV4LrxCN/zDRjvmFznmvxaWZem3YtC/r/swXUuYiKedExQYRjnFJ17Zjdndg0JRP9WRl mUpG9X9NtubmWSJmStCBo84faUawG8jZo7osViBXOArpfqafL+N07tzxYSndRJxr9l2j G1Zg== X-Gm-Message-State: APzg51B4NwpdMRFK7EY7udF2NcL1P2W2kLUConXmul9ojaih588Dc59N RAW3/8Ij8/+pYZShqPAQUwOO+w== X-Google-Smtp-Source: ANB0VdYOduSlaB9j8au62yV/wHCyyB7JttltZw8IsIh9q67YiziWWqni9nn2b7rm1cMI/D1xJ3wzZA== X-Received: by 2002:a2e:9ec9:: with SMTP id h9-v6mr1293583ljk.133.1535466265246; Tue, 28 Aug 2018 07:24:25 -0700 (PDT) Received: from localhost ([195.238.92.132]) by smtp.gmail.com with ESMTPSA id u4-v6sm246231ljh.36.2018.08.28.07.24.24 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 28 Aug 2018 07:24:24 -0700 (PDT) From: Sam Protsenko To: linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org, codalist@coda.cs.cmu.edu, coda@cs.cmu.edu Cc: Jan Harkes , "James E.J. Bottomley" , "Martin K. Petersen" , Praneeth Bajjuri , Paul Sokolovsky , Miklos Szeredi , Sumit Semwal , Ruslan Bilovol , Andy Shevchenko Subject: [PATCH 1/2] codafs: Fix build using bare-metal toolchain Date: Tue, 28 Aug 2018 17:24:20 +0300 Message-Id: <20180828142421.15335-2-semen.protsenko@linaro.org> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180828142421.15335-1-semen.protsenko@linaro.org> References: <20180828142421.15335-1-semen.protsenko@linaro.org> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The kernel is self-contained project and can be built with bare-metal toolchain. But bare-metal toolchain doesn't define u_quad_t type. Because of this codafs build fails when building with bare-metal toolchain. This patch fixes it by defining u_quad_t type in case when non-Linux toolchain is used. Signed-off-by: Sam Protsenko --- include/uapi/linux/coda.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/uapi/linux/coda.h b/include/uapi/linux/coda.h index 695fade33c64..098a6c318b0a 100644 --- a/include/uapi/linux/coda.h +++ b/include/uapi/linux/coda.h @@ -96,6 +96,11 @@ typedef unsigned long long u_quad_t; #endif /* !KERNEL */ #endif /* !DJGPP */ +/* Handle bare-metal toolchain case */ +#if defined(__KERNEL__) && !defined(__linux__) && !defined(_UQUAD_T_) && \ +!defined(__UQUAD_TYPE) +typedef unsigned long long u_quad_t; +#endif #if defined(__linux__) #include