Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp4566077ybb; Tue, 14 Apr 2020 09:44:35 -0700 (PDT) X-Google-Smtp-Source: APiQypKaixZvZWbVO6/cj9tkGMkKTUlSTe2cqz3DbYGyiFHFLyDgOFr6MxpBvXFjjvOB0KQMT3XZ X-Received: by 2002:aa7:dccd:: with SMTP id w13mr21840958edu.94.1586882675320; Tue, 14 Apr 2020 09:44:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586882675; cv=none; d=google.com; s=arc-20160816; b=LzybbdlO99sX8RehAkEpienDFAdlX3OlsaKxhBi0sjxpRiVqYYUU2Jtgu2oIGzCFAZ FRagL9Y4iv+P22T+ejLJ5/INNzn8xulTQmNW+HUMPriP9yZH4Tz/xU1h7nrsKlhDBAI4 WbnCZ0YnFgBSWA4nYgLKCVARCrPykMA+sSVgftP879nmrbkSzjMPDwOpsm5dMndEMSd9 UcAFe5Uxh5p+J7JDinV9aw8yUwFJvZWipoW96xVc6CHriAQTIb5Mt1MfafBBeXrmtKGi BMjcefnO3Wi2pdU6Fx4L+FTzyJmAHPVOyQhNq1U8EpQBf6yb1MCDwlvQ1w/SvXW65kwa c6GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=mFojnywoPNyFdhtgvXnmkYzEiNUOhwI6TxTxAvK3xdg=; b=D9RiLpm6ZkN6tpBP0dizp5i0fiyFD+2XMsB4Ay/vbF+Xh6Y75jlq8xZ8Uz3AKDE2Xe ggiAqYzyXyTw19PjqgAdlj9gMyihNk0GGwsfBsPYZdi6iKBRCCdMM+koVtTyAHj288tP Nzykz32RnzBud5A5z1MRETNFfjN3ZXFvCB823gdE2T01MQfxzNePDTwxYKuzstWHDU5y XCiI5av8ND9KjzMfRp1Q4LryRZ6fdiZJFIuKbVJLa2W04rSgKOg3G8cduONFXmRUM8vN zoAa2Wx6ZmVLIj6daB58AbOheuPakEwaxaTGEwpatdSHsr+JtuULyxG8QloddGouZlmv QmKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=SS4y0Whv; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dk9si2787148edb.403.2020.04.14.09.44.11; Tue, 14 Apr 2020 09:44:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=SS4y0Whv; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2440380AbgDNPYQ (ORCPT + 99 others); Tue, 14 Apr 2020 11:24:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46784 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S2390836AbgDNPXP (ORCPT ); Tue, 14 Apr 2020 11:23:15 -0400 Received: from mail-qv1-xf41.google.com (mail-qv1-xf41.google.com [IPv6:2607:f8b0:4864:20::f41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C336BC061A0E for ; Tue, 14 Apr 2020 08:23:14 -0700 (PDT) Received: by mail-qv1-xf41.google.com with SMTP id ef12so6356695qvb.11 for ; Tue, 14 Apr 2020 08:23:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=mFojnywoPNyFdhtgvXnmkYzEiNUOhwI6TxTxAvK3xdg=; b=SS4y0WhvQF1bhRQ3pn3wLMCiWkfm25jaLNJNqFQ3AGdG5Ie+8aNc3U9tGocHDfSWTi nP+oDC2NmQXii1RTPcUNQIL8gVaiNDH9qzhRCfQwRsuSwl/EmmYHOIZ9KjxJur5xTeSL 7Vjbus/zWtsfWnZ8bBIMSrZuDZ0y/TqLZ0QIUfvodRUt9yC0QUXhZMc9fdqbHI2yoa6K w1ySea+kHv4r8Ugu79ALt3mtAd1B/Ihd2AamFw/3d/AtK6QauU6u7ZaiyS4j+fQmNDwy EDJOBUhMExnxLYWwN9HQ1rqa8gZ/OgdahR8fmY45lXLkUx5Vq8b+XdpMp0OL1rfhdNWu ti+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=mFojnywoPNyFdhtgvXnmkYzEiNUOhwI6TxTxAvK3xdg=; b=tQbJKXOb0Y7CSnlkx26GeS3KSgTRX3HEL0nhViKK2UYs0IZ6izkiagRjdwvAqi4Eb6 bmsLBGUYoSS3tuMGH5MOn3MgiKd4UPcQfb4+HSb5bUQYq6kkWveW3PM2cCBN/fsjSCMs hfKk3/5L4hv8igA13jdPXF7jTZh0unpsgV387agpXidFRp83LrzDNMXjwrnSxF8VbjYj 4e2V0SkZ6xaxXT5S1omPosdjyGeLlpKluxM/5eJC/6b6nGg+IcOv5EVsbi9u955fpDkB JbsMlNPHXsDK/o37ZTzQglJ2C23TFK589leOcXTNurZDD6suTYPTyRcistf3qo7ST0C2 7vrg== X-Gm-Message-State: AGi0PuaX8rVIIgD6T62GrI4mXESZ+dusFej3tUDMHbYkCjPLWb4MjbSf nt7UlTuTNb5TTHb65O83k23S2A== X-Received: by 2002:a0c:ac48:: with SMTP id m8mr509910qvb.13.1586877793898; Tue, 14 Apr 2020 08:23:13 -0700 (PDT) Received: from ziepe.ca (hlfxns017vw-142-68-57-212.dhcp-dynamic.fibreop.ns.bellaliant.net. [142.68.57.212]) by smtp.gmail.com with ESMTPSA id m11sm10391993qkg.130.2020.04.14.08.23.12 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 14 Apr 2020 08:23:13 -0700 (PDT) Received: from jgg by mlx.ziepe.ca with local (Exim 4.90_1) (envelope-from ) id 1jONP6-0005EN-Cy; Tue, 14 Apr 2020 12:23:12 -0300 Date: Tue, 14 Apr 2020 12:23:12 -0300 From: Jason Gunthorpe To: Arnd Bergmann Cc: Saeed Mahameed , "narmstrong@baylibre.com" , "masahiroy@kernel.org" , "Laurent.pinchart@ideasonboard.com" , "davem@davemloft.net" , "leon@kernel.org" , "linux-kernel@vger.kernel.org" , "nico@fluxnic.net" , "dri-devel@lists.freedesktop.org" , "linux-renesas-soc@vger.kernel.org" , "kieran.bingham+renesas@ideasonboard.com" , "linux-rdma@vger.kernel.org" , "jani.nikula@linux.intel.com" , "a.hajda@samsung.com" , "jonas@kwiboo.se" , "netdev@vger.kernel.org" , "airlied@linux.ie" , "jernej.skrabec@siol.net" Subject: Re: [RFC 0/6] Regressions for "imply" behavior change Message-ID: <20200414152312.GF5100@ziepe.ca> References: <20200408202711.1198966-1-arnd@arndb.de> <20200408224224.GD11886@ziepe.ca> <87k12pgifv.fsf@intel.com> <7d9410a4b7d0ef975f7cbd8f0b6762df114df539.camel@mellanox.com> <20200410171320.GN11886@ziepe.ca> <16441479b793077cdef9658f35773739038c39dc.camel@mellanox.com> <20200414132900.GD5100@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 14, 2020 at 04:27:41PM +0200, Arnd Bergmann wrote: > On Tue, Apr 14, 2020 at 3:29 PM Jason Gunthorpe wrote: > > On Fri, Apr 10, 2020 at 07:04:27PM +0000, Saeed Mahameed wrote: > > > On Fri, 2020-04-10 at 14:13 -0300, Jason Gunthorpe wrote: > > > > On Fri, Apr 10, 2020 at 02:40:42AM +0000, Saeed Mahameed wrote: > > > > > > > > > This assumes that the module using FOO has its own flag > > > > > representing > > > > > FOO which is not always the case. > > > > > > > > > > for example in mlx5 we use VXLAN config flag directly to compile > > > > > VXLAN related files: > > > > > > > > > > mlx5/core/Makefile: > > > > > > > > > > obj-$(CONFIG_MLX5_CORE) += mlx5_core.o > > > > > > > > > > mlx5_core-y := mlx5_core.o > > > > > mlx5_core-$(VXLAN) += mlx5_vxlan.o > > > > > > > > > > and in mlx5_main.o we do: > > > > > > > > Does this work if VXLAN = m ? > > > > > > Yes, if VXLAN IS_REACHABLE to MLX5, mlx5_vxlan.o will be > > > compiled/linked. > > > > So mlx5_core-m does the right thing somehow? > > What happens with CONFIG_VXLAN=m is that the above turns into > > mlx5_core-y := mlx5_core.o > mlx5_core-m += mlx5_vxlan.o > > which in turn leads to mlx5_core.ko *not* containing mlx5_vxlan.o, > and in turn causing that link error against > mlx5_vxlan_create/mlx5_vxlan_destroy, unless the IS_ENABLED() > is changed to IS_REACHABLE(). What about the reverse if mlx5_core is 'm' and VLXAN is 'y'? mlx5_core-m := mlx5_core.o mlx5_core-y += mlx5_vxlan.o Magically works out? > > IIRC that isn't what the expression does, if vxlan is 'n' then > > n || !n == true > > It forces MLX5_CORE to 'm' or 'n' but not 'y' if VXLAN=m, > but allows any option if VXLAN=y And any option if VXLAN=n ? Jason