Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp364091imm; Wed, 3 Oct 2018 18:02:40 -0700 (PDT) X-Google-Smtp-Source: ACcGV600tf/WKYQGg0ZfIQvECSZZ59eVigFrSMnp2HSRbx5M+Dxf4WjO0yuUXHO2N9L1rfwtroOm X-Received: by 2002:a17:902:b7c3:: with SMTP id v3-v6mr4184479plz.182.1538614959992; Wed, 03 Oct 2018 18:02:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538614959; cv=none; d=google.com; s=arc-20160816; b=d4nUgWU28gxCBu5tp8rIoysKFUgKpN3PlbvZfPGSyfvQ9LOeV2Ly3UKhs8gYNDng0V exQBPEF61QgOUOwwlft0bqDGCMZIQ9ok08HiZtbTRVzavzh5q3FjRzYoEVJAH6qatN1t g2CIloEs7pvOJYWFZWzvwIi82FhpGiKqnBP2Ky4JNH0JXWn8IMJETd1EWSP6yq9DjdmY 4VDy4nccN+pyFlTMJl8rWdQJR8ycwPXZNT/yE12HUGrSALB+VxgoPa3WsucOhxQY8JBP PV6DCRQELIeXG0hE9lwzPfM//g0RhMvOnMFGz05MmcutjCHFnXsWdbhTD6TOntrWRyMM gstg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=Yzv8j5nNfSqSo8yLZdF6AXL8KtZq50GbDQcajX7W0MQ=; b=f8Dm04rwZqzlU9WyedKU7iVk7qg9HobX8L6mWPRJOb7o6Xouv2XzAHFQsBGnJx0gzZ nBl+JII9MPjPG4bZ5CCcl0YVN/ZdF/LACYjbmGpL7nuLDTn28ZcZ328QsEC71ioAlnpA rcUVnU/UtjR+GXC50VDD+AQ5M3UhWh0U40QqLV3bFsX7OoExpsqApx5JaySt3n7I4APz w4f/LMb0L1hhzvEjrOsWjU9Nmt69YnYDkvaoAFllh7iMBVV35ZbZ8uHGc2QyRTQ9IDZC /+6EkfUFUk3xgdLIA80OX75kS90pKY9Khp+TNZBuE3heuoZZPr0cAsCSYJeVoh/40rYp DpWA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Ecin5W3L; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 142-v6si3237505pga.540.2018.10.03.18.02.21; Wed, 03 Oct 2018 18:02:39 -0700 (PDT) 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=@gmail.com header.s=20161025 header.b=Ecin5W3L; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727115AbeJDHvu (ORCPT + 99 others); Thu, 4 Oct 2018 03:51:50 -0400 Received: from mail-oi1-f196.google.com ([209.85.167.196]:43069 "EHLO mail-oi1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726279AbeJDHvt (ORCPT ); Thu, 4 Oct 2018 03:51:49 -0400 Received: by mail-oi1-f196.google.com with SMTP id s69-v6so6110234oie.10; Wed, 03 Oct 2018 18:01:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=Yzv8j5nNfSqSo8yLZdF6AXL8KtZq50GbDQcajX7W0MQ=; b=Ecin5W3LvMebovdxOnx/G7VJXG1Uszry2NERF/cbjFHNwEKlpfHfLJ2IylH0DO48f5 8ZsAo0kanpXmWvyWcoec3NjLOBYltKI5USaC6MhjQcUXkI4+0XPbTtuPPgd/Y4+1u09Q vA/+UY7IMGSgsdcEnfVpRD8Vdd6aiXYCSn8A6h8carlNNf6RqxGhkev8UXwZHMBKXqXg s9LLlZgUUJQwyrkEb/zkqyidhl1BPJFSjZtQwrvJLP0iUXf+z3jL2qFmMwbxCo2wz2MF tV2sBp1rx7cQ1ETJ6aylmQrNwyDhuxuE5NTcHryFajW5lSPE6oEYYMucytDpz1icKLjV 8jnw== 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:cc:content-transfer-encoding; bh=Yzv8j5nNfSqSo8yLZdF6AXL8KtZq50GbDQcajX7W0MQ=; b=Sf6Rtvo631j8mARmuDpzF0qfBIL2E8f9bYUdJq8iUTfshn+ZdzpWcVVwbd4372VU6N 6fndNxyYTk/9Lr5vMONUVz2Olzfe0PGSbOcBMtqvNrWg37eKsIRq7trSjvdmwjdDpxYe 97Smw6o+Q6cJyyHikm1Vr/WpIz02wI88cUP5EGL0vpqhLmxfCNszKgDf4w9U6XONfUqW jogn/7vtdd5AHjA+tycnunrLGHTLh6QQlb7jkBKxUuCWDa1P/YLeKwLGWf4QCKp0iB2w Finh+CY2P4MF8+eWEzRdxYszrKu6XN6DZXMdKC/ewIyHGC5SLvGmfRkWD1xDxQ4jxli9 Ckpw== X-Gm-Message-State: ABuFfoiCqDdr2JfS4dCwT7JXkRMd3UUsWZWJyav10zhBqM8Vpjs3brBK LTkxT8njD0+utu0uLqSVm7+MLKimWTz3YcH4FLI= X-Received: by 2002:aca:2cc6:: with SMTP id s189-v6mr2065318ois.72.1538614860840; Wed, 03 Oct 2018 18:01:00 -0700 (PDT) MIME-Version: 1.0 References: <20180928020816.11251-1-leobras.c@gmail.com> <20180928020816.11251-6-leobras.c@gmail.com> <20181001124617.GA3185@osiris> In-Reply-To: <20181001124617.GA3185@osiris> From: Leonardo Bras Date: Wed, 3 Oct 2018 22:00:49 -0300 Message-ID: Subject: Re: [PATCH v3 5/7] drivers: s390: Avoids building drivers if ARCH is not s390. To: Heiko Carstens Cc: lkcamp@lists.libreplanetbr.org, Alexander Shishkin , Finn Thain , Robert Richter , "James E.J. Bottomley" , Helge Deller , Martin Schwidefsky , Geert Uytterhoeven , linux-kernel , linux-m68k@lists.linux-m68k.org, oprofile-list@lists.sf.net, linux-parisc@vger.kernel.org, linux-s390@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Oct 1, 2018 at 9:46 AM Heiko Carstens w= rote: > > On Thu, Sep 27, 2018 at 11:08:14PM -0300, Leonardo Br=C3=A1s wrote: > > Avoids building s390 drivers if 'make drivers/s390/' is called but > > ARCH is not s390. > > > > Signed-off-by: Leonardo Br=C3=A1s > > --- > > drivers/s390/Makefile | 8 ++++---- > > 1 file changed, 4 insertions(+), 4 deletions(-) > > > > diff --git a/drivers/s390/Makefile b/drivers/s390/Makefile > > index a863b0462b43..0575f02dba45 100644 > > --- a/drivers/s390/Makefile > > +++ b/drivers/s390/Makefile > > @@ -3,7 +3,7 @@ > > # Makefile for the S/390 specific device drivers > > # > > > > -obj-y +=3D cio/ block/ char/ crypto/ net/ scsi/ virtio/ > > - > > -drivers-y +=3D drivers/s390/built-in.a > > - > > +ifeq ($(ARCH),s390) > > + obj-y +=3D cio/ block/ char/ crypto/ net/ scsi/ virtio/ > > + drivers-y +=3D drivers/s390/built-in.a > > +endif > > And then somebody wants to build with e.g. "make drivers/s390/cio/" and i= t > still doesn't work. So _if_ this should be supported then it should work > with all directory levels and all configuration options. Otherwise this i= s > going to be a never ending story. > It makes sense. I proposed this change to help me solving a problem described here (https://lkml.org/lkml/2018/10/3/707), and for this it was enough if it did= n't build when "make drivers/s390/" was called. Sorry I didn't send the e-mail with the reason earlier. For solving my problem it was not necessary, but if you think it's interest= ing, I could refactor all drivers/s390 Makefiles to make them all build only if we are dealing with the s390 architecture. What do you think? Thanks for the reply, Leonardo Bras