From patchwork Wed May 2 08:37:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joel Stanley X-Patchwork-Id: 907370 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 40bWrh6dNCz9s1d for ; Wed, 2 May 2018 18:38:28 +1000 (AEST) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=jms.id.au Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="BVNjLbtC"; dkim-atps=neutral Received: from lists.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 40bWrh4GQBzF2Sm for ; Wed, 2 May 2018 18:38:28 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=jms.id.au Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="BVNjLbtC"; dkim-atps=neutral X-Original-To: skiboot@lists.ozlabs.org Delivered-To: skiboot@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gmail.com (client-ip=2607:f8b0:400e:c05::22a; helo=mail-pg0-x22a.google.com; envelope-from=joel.stan@gmail.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=jms.id.au Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="BVNjLbtC"; dkim-atps=neutral Received: from mail-pg0-x22a.google.com (mail-pg0-x22a.google.com [IPv6:2607:f8b0:400e:c05::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 40bWrK5KtzzF2SD for ; Wed, 2 May 2018 18:38:09 +1000 (AEST) Received: by mail-pg0-x22a.google.com with SMTP id 82-v6so10104753pge.11 for ; Wed, 02 May 2018 01:38:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:subject:date:message-id; bh=Sf+rP7jL4hbClSeW9NmqvLqOd2lXdk6GZCRsskbQCww=; b=BVNjLbtCjQ2xJYAKnL+HZixZehgbBOZigWBf5AAjWSx+0I90Y6Jv5QmmqtCGxmn8X9 65U87wGhpbKNXMjka3egmqk7TneufKEn7vNopnp3J0z13TPZto159s8PF4GZOfFSxg2J 8nSPeRJiY4emJTQtJ3VAC57bSe74SqpZ57DQrNeKv+xeJpIzWsuGlWYhcxWhe8Bgieus Gs16MH9ai4HV2ib/0QNx9J8orUtOt1DaK/9UVkIE5z0VFiESjpwCsOsWZHSHoZ4vYm79 zw/PuLWBZ5Z/sIe3yEVXGtAsRv1A7zDtsl3eKyy+tLpTbYiiMkmFBU7fkPxn47VCq8TP fuGQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:subject:date:message-id; bh=Sf+rP7jL4hbClSeW9NmqvLqOd2lXdk6GZCRsskbQCww=; b=o1SjferOAzY+lbdrCdQI94J2jBM5ep56bi/vHgmWVO602bQU31WZhZBBsfz3DP/+ir tHP9mKg9KddHRbLT/tR5vADM8kSO47q01b0+eDumyIYW5bPwR2ppDpYbFw7HlpEDYsyH fETKb4Vip415sTcuu7GYLMuivEYnaKkgjToXAru68haK6U2WY/5i7ogt2s7kflQtlYxK wRG33vN2ywj58eD75sPUvnTA6WAZxp/t4KP1GPVSrgEnAiLXK36NQ4datzjXafkI0x3H t2Cgug3PGSE3RI0f9urVNEQ4M3knRxHBJXymGr/DPtpjx79MiD2Is4u4rVL6uKprOliu +vsw== X-Gm-Message-State: ALQs6tC9auFSdzPO2LQ3LptOZBUcVjqouWzm3e2QBCqsVYY3+bTGo/9d XVw7IBTVPneCPl0iZmz3zjRu+RLE X-Google-Smtp-Source: AB8JxZpDejBjWyflrK88Ksn+ZuAg5OEexaZfEMfMitPwhfS7wx7nUrchURPL76FiySIIATujkuxtfg== X-Received: by 2002:a17:902:4c88:: with SMTP id b8-v6mr8423464ple.285.1525250286332; Wed, 02 May 2018 01:38:06 -0700 (PDT) Received: from aurora.jms.id.au ([203.0.153.9]) by smtp.gmail.com with ESMTPSA id w19-v6sm16720290pgv.59.2018.05.02.01.38.03 for (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 02 May 2018 01:38:05 -0700 (PDT) Received: by aurora.jms.id.au (sSMTP sendmail emulation); Wed, 02 May 2018 18:08:00 +0930 From: Joel Stanley To: skiboot@lists.ozlabs.org Date: Wed, 2 May 2018 18:07:40 +0930 Message-Id: <20180502083753.25090-1-joel@jms.id.au> X-Mailer: git-send-email 2.17.0 Subject: [Skiboot] [PATCH 00/13] Support building with clang X-BeenThere: skiboot@lists.ozlabs.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: Mailing list for skiboot development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: skiboot-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Skiboot" Hello Skibooters! This series contains cleanups and modifications that are required to build skiboot with clang. If you want to try it out: $ sudo apt-get install clang $ make CC=clang I've done all of my testing with clang-7 (trunk). Clang 6 works fine too, but earlier versions have a number of issues. Most of the patches could be considered cleanup or have no impact on GCC builds. The last three that change the make file are quite clang specific, but again have no impact on normal building of skiboot. Please test, and if they look good, merge! I have plans down the track for using clang to improve our code quality. Cheers, Joel Joel Stanley (13): asm: Fix up assembly for clang cpu.h: Use this_cpu through accessor cpu.h: implement this_cpu for clang libflash/ecc: disable asm version for clang processor.h: implement sndmsg instructions Makefile: Use LD to link the final binary Fix asm-offsets generation pci-quirk: Fix initiliser warning imc: Remove extra parentheses in test fsp: Fix msg vaargs usage Makefile: Put some ppc options behind try-cflag tests Makefile: Add additional flags when using clang Makefile: Disable warnings to make clang happy Makefile.main | 44 ++++++++++++++++++++++++++++++++++++++------ asm/head.S | 4 ++-- core/pci-quirk.c | 2 +- hw/fsp/fsp.c | 4 ++-- hw/imc.c | 2 +- include/cpu.h | 24 +++++++++++++++++++++++- include/fsp.h | 4 ++-- include/processor.h | 33 ++++++++++++++++++++++++++++++--- libflash/ecc.c | 2 +- make_offsets.sh | 2 +- 10 files changed, 101 insertions(+), 20 deletions(-)