Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp192456imu; Wed, 21 Nov 2018 17:59:32 -0800 (PST) X-Google-Smtp-Source: AJdET5dMuQrvGXKDy81B/MB8uW2mlJH6fHpYqtEqjQYB2QFeUQyfGH/vHr8iq8/7osmIBcVNYNGK X-Received: by 2002:a62:6801:: with SMTP id d1-v6mr9330035pfc.7.1542851972485; Wed, 21 Nov 2018 17:59:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542851972; cv=none; d=google.com; s=arc-20160816; b=xVvV539tgyRrFLfsbcMhdSxT17gPmLi+KwB7Tjgn13rFhoJOpZfj4Cu3k3U9baH1P4 hP/RT6SX57yOL+7B/RKAfBB6rce3de9UCoJfEUamxlmzgJwUU1Lc6cojXTCQz6XFfAC8 95KUwAcmcKeX+3Mg0JbC25mnHK5Zl5VkP67p3ps6JiXcpa6B6OREZeeBhFS8QkfadEeH uMG+oUVEijhSekJdIQsmC0LUFK7A4l41TCN6q/ChHOG+HYOO+Ya0xc6ttNYRHaziarpX QMd0/vJ6BQqCYBXrDrObhWeXEcwrFi/lNeRAGsT2MWBtdh5C0Qy518+YWpuDaB4C5X+E NHCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=ayAX5yROzFHa0W15ZIyP8hS/ArZSAo7yB9oVrA+i4KA=; b=qV2xwcNiCHNpurxA7ZTTq5XdtHccERNn2aDaq8EPLVP801JvSrRW2wabTeLpBxjRVZ Ed4FO/FbrsO25Gbx8GjkOmCeFowJvdOW0Mqaz859aVKs7X0+iN96f6lJ6rmnmDTlzlcz BGOWLR4J0R5Hcl/gcrE9Vbk8j5b/4tEgULdf+c54E6S67NC1cd03WXkyOmgN5BTEnZpa +99hitrQ9tp1aovEboCGiqMoW5zrBU3fZCEKFERS70dAcFaQPBgOBu9WmhlUlRHfRVG0 4CtDqhTrsYkuaiNZZVk8UjHbsfMZty7id4p6iTIKA+428wPd/pwHOBIDZ3C7ZDnKOfzd dI2w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=JyJjhfft; 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=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ca19si29057489plb.238.2018.11.21.17.59.18; Wed, 21 Nov 2018 17:59:32 -0800 (PST) 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=@linaro.org header.s=google header.b=JyJjhfft; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732711AbeKVGMk (ORCPT + 99 others); Thu, 22 Nov 2018 01:12:40 -0500 Received: from mail-wr1-f66.google.com ([209.85.221.66]:44546 "EHLO mail-wr1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730560AbeKVGMk (ORCPT ); Thu, 22 Nov 2018 01:12:40 -0500 Received: by mail-wr1-f66.google.com with SMTP id z5so2620365wrt.11 for ; Wed, 21 Nov 2018 11:37:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=ayAX5yROzFHa0W15ZIyP8hS/ArZSAo7yB9oVrA+i4KA=; b=JyJjhfftf0AJT9rLfDS98HgGhuZHyO2X/HVA/q7LebH+qvYaeOJm40Xwf9mG+kL3L7 unVmtyvb1i2ZVW8AP0O88M2ODHBVSm1kz8bKrU4qGOlj3nBgUCbCiJyTLJmQyzQifwPp inW9UeOqUDDN9PHeKemlF2kKjulSn/7ElXQss= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=ayAX5yROzFHa0W15ZIyP8hS/ArZSAo7yB9oVrA+i4KA=; b=nZF/qMj5pC3D+oaA0z9eHBhHO61D3i+CgJ2vvX6TY7/VxBtgXSFkoUratyP6oaz5Hn o3ba67FHq+HhRy1kY8ARCvb3QG/83Wtydc1AwVsF8BH7Ep9oAM/KZhHbNtg5GihrJHEs VGzNuX9+LmF2BTGH8bhagYgF54O4Bu33jiYBHmV2o4qnt2iIiZeA2OPfrVTpEAGsOEJz yxyR+riuUPU1DX3V3F5YnGEdp5MqWgKXLQ/9HD1gGaB5qt9xT5lWH0PIEqcDmhqLGIWP kmF+v4cP/nZBIDSV9sp1Z/bJSZ0WOCeK4GHp6EyhRkZme8J8NsIE0YudknG+49wzUrYX nMNQ== X-Gm-Message-State: AA+aEWZiGdPCw4P8pLgTCSE0H2d4zkMk0NpqdPeqXW4U1D2XdwtopXjq 9rikEiB8hrxtNMAp38QBIfnu8QzanThIiC9I5Js3Ew== X-Received: by 2002:a5d:43d0:: with SMTP id v16mr7474044wrr.67.1542829020273; Wed, 21 Nov 2018 11:37:00 -0800 (PST) MIME-Version: 1.0 References: <20181030202713.26203-1-semen.protsenko@linaro.org> <20181121181042.4gzuniz2vzjikpwc@cs.cmu.edu> In-Reply-To: <20181121181042.4gzuniz2vzjikpwc@cs.cmu.edu> From: Sam Protsenko Date: Wed, 21 Nov 2018 21:36:48 +0200 Message-ID: Subject: Re: [PATCH v2] codafs: Fix build using bare-metal toolchain To: Andy Shevchenko , hch@lst.de, Andrew Morton , kernel-janitors@vger.kernel.org, Linux Kernel Mailing List , linux-scsi@vger.kernel.org, Praneeth Bajjuri , Ruslan Bilovol Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 21, 2018 at 8:10 PM Jan Harkes wrote: > > On Wed, Nov 21, 2018 at 06:41:13PM +0200, Andy Shevchenko wrote: > > I'm not sure how you managed to miss people in this list (perhaps by > > default you have suppress all Cc in your Git configuration), but I > > guess we may gently ask Christoph to apply this in case Jan will not > > appear. > > You have got to give me a little more than 10 minutes to respond before > assuming that I would not appear... I don't think I've ignored any > previous emails on this subject and the only issues has been some people > not receiving my responses for unknown reasons (agressive spam filter?). > > I have no problem with this patch, have it sitting with some other > non-urgent patches and in case it doesn't appear upstream it should > piggyback with whatever I have to send. > Thanks, Jan, really appreciate it. We need this patch to fix our tests with allmodconfig configuration (in Linaro CI loops). > I still don't know why the bare-metal toolchain couldn't just add a > -D__linux__. I understand that this define is expected to be always > present while compiling kernel headers so that there is no good reason > to even bother testing for it, which is why I have no issue with the > patch. But it seems it would make your life a lot easier if you had it > defined. > As I understand it, from toolchain's point of view, if __linux__ is defined then it means that the program is being built *for* Linux (i.e. we can use Linux specific features, ABI, like syscalls). Checking this definition can make sense in uapi headers, but in kernel code we shouldn't use it (as kernel is baremetal program and not compiled for some OS). I presume that's why __linux__ is not defined in bare-metal toolchains (as those don't provide Linux specific features, libc, etc). > Jan >