From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D2262C433ED for ; Thu, 8 Apr 2021 11:38:23 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 58B4961139 for ; Thu, 8 Apr 2021 11:38:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 58B4961139 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ffwll.ch Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id ACEEE6B0078; Thu, 8 Apr 2021 07:38:22 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id A58DD6B007E; Thu, 8 Apr 2021 07:38:22 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 886018D0001; Thu, 8 Apr 2021 07:38:22 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0137.hostedemail.com [216.40.44.137]) by kanga.kvack.org (Postfix) with ESMTP id 66FD16B0078 for ; Thu, 8 Apr 2021 07:38:22 -0400 (EDT) Received: from smtpin34.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id 25E058248047 for ; Thu, 8 Apr 2021 11:38:22 +0000 (UTC) X-FDA: 78009001644.34.827A7D2 Received: from mail-wr1-f41.google.com (mail-wr1-f41.google.com [209.85.221.41]) by imf08.hostedemail.com (Postfix) with ESMTP id 618AD80192DD for ; Thu, 8 Apr 2021 11:38:13 +0000 (UTC) Received: by mail-wr1-f41.google.com with SMTP id e12so1759638wro.11 for ; Thu, 08 Apr 2021 04:38:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to; bh=HNjO0LstTaF0YJ+tzxAFP4Syvm5fGCE8nxebVcvJLjU=; b=eS60djC9Lqi8q7fWOXC+yuTwdoDdp/fK2d8XmHmBdVmsTRb7l+NFwK+960b7+jwa0f FmsY22x6AYJ4yv6tWLC7INl0trTXzlztAcd+b0jK6akV35kkzli/s4AEGxnp0E9T3Hzm WeCrdaOppkgKGi6FkMG4W1g5pPS3g8Esg94hM= 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 :mail-followup-to:references:mime-version:content-disposition :in-reply-to; bh=HNjO0LstTaF0YJ+tzxAFP4Syvm5fGCE8nxebVcvJLjU=; b=Q1p677/IOwH0eXCdi1l20pXyVtdMBd1lEAJJMmX/7PxMFa9ThpsoRgNgYQxbA3oUSC L05TS9b+xYbDefXdEzc9NjlzD2cA9mdw2LpJXcmjxcLxFwFsc1ZG7bUubVSQYA8WY7Yd cnXKWaMg8PzDI5hWW43RCAxhpAjF5yEAZmO4w8iNKCEVu9pCjKfebSKb48uyeBYjgY2C oVHCgs/6YDPUl2ltUe6Wk9YrXIUQck14hKpY6YGd2eg6Db4LT46qBq9qfFJJhaoGasu6 n9myrMqxyBfOaB4pQbF7tE0qerPaHuTGoBcnJBWtrCdhhvkmV9rtmcw7xwN7WbJdr+Yt wDFw== X-Gm-Message-State: AOAM532RIC5DvhkjDtFVoWahV7HS4K4rfF+ETSn6bcv9wtStsY2FcQkb MFbXJptKLWzn3W773LLHN1iQdA== X-Google-Smtp-Source: ABdhPJySG7qOaE9NShNXxHx9QrPK+umWifIaVL7kyUfSfMRMt7h7zvfu4kAyJkMeLpb8wsS1VXGRaA== X-Received: by 2002:a5d:6d0f:: with SMTP id e15mr9348009wrq.218.1617881900156; Thu, 08 Apr 2021 04:38:20 -0700 (PDT) Received: from phenom.ffwll.local ([2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa]) by smtp.gmail.com with ESMTPSA id n5sm24657875wrp.50.2021.04.08.04.38.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Apr 2021 04:38:19 -0700 (PDT) Date: Thu, 8 Apr 2021 13:38:17 +0200 From: Daniel Vetter To: Arnd Bergmann Cc: David Hildenbrand , Linux Kernel Mailing List , Linux-MM , Joel Stanley , David Airlie , Daniel Vetter , Andrew Jeffery , Lucas Stach , Russell King , Christian Gmeiner , Mike Rapoport , Bartlomiej Zolnierkiewicz , Linus Walleij , Michal Simek , Masahiro Yamada , Randy Dunlap , Peter Collingbourne , linux-aspeed , dri-devel , Linux ARM , The etnaviv authors , Linux Fbdev development list Subject: Re: [PATCH v1 2/2] drivers/gpu/drm: don't select DMA_CMA or CMA from aspeed or etnaviv Message-ID: Mail-Followup-To: Arnd Bergmann , David Hildenbrand , Linux Kernel Mailing List , Linux-MM , Joel Stanley , David Airlie , Andrew Jeffery , Lucas Stach , Russell King , Christian Gmeiner , Mike Rapoport , Bartlomiej Zolnierkiewicz , Linus Walleij , Michal Simek , Masahiro Yamada , Randy Dunlap , Peter Collingbourne , linux-aspeed , dri-devel , Linux ARM , The etnaviv authors , Linux Fbdev development list References: <20210408092011.52763-1-david@redhat.com> <20210408092011.52763-3-david@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: Linux phenom 5.7.0-1-amd64 X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: 618AD80192DD X-Stat-Signature: stu6dxrj7hfc7mkxayngfy55yh6myjho Received-SPF: none (ffwll.ch>: No applicable sender policy available) receiver=imf08; identity=mailfrom; envelope-from=""; helo=mail-wr1-f41.google.com; client-ip=209.85.221.41 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1617881893-662788 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Thu, Apr 08, 2021 at 12:20:50PM +0200, Arnd Bergmann wrote: > On Thu, Apr 8, 2021 at 11:22 AM David Hildenbrand wrote: > > > > Random drivers should not override a user configuration of core knobs > > (e.g., CONFIG_DMA_CMA=n). Use "imply" instead, to still respect > > dependencies and manual overrides. > > > > "This is similar to "select" as it enforces a lower limit on another > > symbol except that the "implied" symbol's value may still be set to n > > from a direct dependency or with a visible prompt." > > > > Implying DRM_CMA should be sufficient, as that depends on CMA. > > > > Note: If this is a real dependency, we should use "depends on DMA_CMA" > > instead - but I assume the driver can work without CMA just fine -- > > esp. when we wouldn't have HAVE_DMA_CONTIGUOUS right now. > > 'imply' is almost never the right solution, and it tends to cause more > problems than it solves. > > In particular, it does not prevent a configuration with 'DRM_CMA=m' > and 'DRMA_ASPEED_GFX=y', or any build failures from such > a configuration. > > If you want this kind of soft dependency, you need > 'depends on DRM_CMA || !DRM_CMA'. The problem is that depends on is a real pain for users to find their drivers. This is why we have a ton of select, because the kconfig ui tends to suck. If you want to change this, we need automatic conflict resolution like apt and other package managers have, with suggestions how to fix the config if you want to enable a driver, but some of its requirements are missing. The current approach of hiding driver symbols complete if any of their dependencies are off is really not great. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch