Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp357549pxb; Wed, 14 Apr 2021 17:43:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwxOR6ngLFR64WcH/KZs0jhTb7jGsuXS4ByRURNuPbJkPA+Pxx6BXjIWeq01laDujbO2Rp2 X-Received: by 2002:a17:906:c34d:: with SMTP id ci13mr709281ejb.430.1618447432890; Wed, 14 Apr 2021 17:43:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618447432; cv=none; d=google.com; s=arc-20160816; b=sXwALPUwDwmBtWK1uF4eJ+vOUQsNPu5djecdvIhGj3kyWfUteD0KUFU1OyvTEsdmim w+QgqjOKqzrFV6Bx5Nm6P2AD/5cnW8I92wJ14IOTy9B4DE5P9rd/Fg5ma2CEBJnymaOI J3DPJVAnEG3rrr9iH88fE3kyJJrkNWyVHUu+0VDVlc5o+z4xW00k/pq9lFZL3SKWUTfd MYwJfyWevflvIlUYbQJSMMIUCvaLEqwkvYyx7UXyu70oy6vU5vgNSHIlKV+5C+/oBUlh 03hL18SSAyy5F3Fu8dYHDxaEN0tAt0YwRT0SUGMAPboDB3veavNDDXNnOVhXSkhWvBhk tqPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version; bh=b+tmZI5JiTVWm421cIPTsk+PGdNmsovX4NE2wqukjp8=; b=ByikCPY8/1uG6xxlhHwBM8V86yzaJBZerV0yD38NOpwqfh4SabIOreqHCSTqaOWOKp Ag7e3/5rxDw57M2ojt4zQ/TyC7rz6+/ya4GC2iwTg6PHv5K9qfmMLe/9TyWAYp1QiTBH bfLVuXYjxrMxRYGocbfl8kGx8TWZTIeQ3mCPeX7P6bPi8wgMPDNigkHylMPVLo9AaurK 6S6fvAySSdM3Ju3U1uikxsKzWRgyc60BYBJNpNqwbjdgoumXd4RwDNqWZRnz7egLk1Zh RqW69ptumGyoPnpj9CiSBlZQenotOlwaI68Y/E8ZA2lIHuC8ueCcvLNr5l06O4ZY1km1 5Xvw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: 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 n20si486750ejz.161.2021.04.14.17.43.30; Wed, 14 Apr 2021 17:43:52 -0700 (PDT) Received-SPF: pass (google.com: 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; spf=pass (google.com: 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 S1353353AbhDNTWN (ORCPT + 99 others); Wed, 14 Apr 2021 15:22:13 -0400 Received: from mail-ua1-f43.google.com ([209.85.222.43]:40486 "EHLO mail-ua1-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345520AbhDNTWM (ORCPT ); Wed, 14 Apr 2021 15:22:12 -0400 Received: by mail-ua1-f43.google.com with SMTP id 33so6750182uaa.7; Wed, 14 Apr 2021 12:21:50 -0700 (PDT) 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; bh=b+tmZI5JiTVWm421cIPTsk+PGdNmsovX4NE2wqukjp8=; b=NYbAlfcsB1+PePQwoubcuMaK4skNyTEp8F2DsczMW0Imq0eMa8Qjx0RqcTLyZIyfZD Kh2NhTmtJcqrUJGbD4HE8F9YljpdCHvAfGyOiUdikEowaAAd1v2Oxu9OBmszTXkTmDua dQOrJ+kR8HQTKVoaQGRNEFs6GunFZEQvuDzgy600yq5fUcjKUy99v6Y1AE59BpTJpbDk EsEL1UjIcvMdapLCAATPnMlOw7xGnxn8Pr3RoAoX87yU8Rn6GCHdClajMFyOYMWFNhae wwC6LIhT+nEbY5pgwmTUzrZHDewuKE1Fq86Ng9ioyuLjWEaXMLU9JB6KraspfP7+K9Tb p8OA== X-Gm-Message-State: AOAM530RvbecmwShCrau5bBJDyxzhu/wDcSE6jp5D2lm7EXHA5Hbfaps vkBj9nxmvHf2S3hiY+kQasNsfkHr81rrsnQCYq0= X-Received: by 2002:a9f:3852:: with SMTP id q18mr19839105uad.58.1618428110127; Wed, 14 Apr 2021 12:21:50 -0700 (PDT) MIME-Version: 1.0 References: <26db9291095c1dfd81c73b0f5f1434f9b399b1f5.1618316565.git.geert+renesas@glider.be> In-Reply-To: From: Geert Uytterhoeven Date: Wed, 14 Apr 2021 21:21:38 +0200 Message-ID: Subject: Re: [PATCH] i2c: I2C_HISI should depend on ARCH_HISI && ACPI To: Andy Shevchenko Cc: Yicong Yang , Wei Xu , Wolfram Sang , Dmitry Osipenko , Linux I2C , Linux ARM , Linux Kernel Mailing List , Linuxarm Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Andy, On Wed, Apr 14, 2021 at 9:14 PM Andy Shevchenko wrote: > On Wed, Apr 14, 2021 at 08:55:21PM +0200, Geert Uytterhoeven wrote: > > On Wed, Apr 14, 2021 at 8:18 PM Andy Shevchenko > > wrote: > > > On Wed, Apr 14, 2021 at 08:06:18PM +0200, Geert Uytterhoeven wrote: > > > > On Wed, Apr 14, 2021 at 11:24 AM Yicong Yang wrote: > > > > > On 2021/4/13 20:26, Geert Uytterhoeven wrote: > > > > > > The HiSilicon Kunpeng I2C controller is only present on HiSilicon > > > > > > Kunpeng SoCs, and its driver relies on ACPI to probe for its presence. > > > > > > Hence add dependencies on ARCH_HISI and ACPI, to prevent asking the user > > > > > > about this driver when configuring a kernel without Hisilicon platform > > > > > > or ACPI firmware support. > > > > > > > > > > this is a public IP which doesn't specifically depend on ARCH_HISI. I'm > > > > > not sure all the platform this IP on has ARCH_HISI configured. The driver > > > > > will not be compiled by default config. This is not correct to have > > > > > this dependence. > > > > > > > > Thanks for your answer! > > > > > > > > I guess it's still fine to add a dependency on ACPI? > > > > > > But why? > > > > Please tell me how/when the driver is used when CONFIG_ACPI=n. > > I'm not using it at all. Ask the author :-) > > But if we follow your logic, then we need to mark all the _platform_ drivers > for x86 world as ACPI dependent? This sounds ugly. Do all other x86 platform drivers have (1) an .acpi_match_table[] and (2) no other way of instantiating their devices? The first driver from the top of my memory I looked at is rtc-cmos: it has no .acpi_match_table[], and the rtc-cmos device is instantiated from arch/x86/kernel/rtc.c. For drivers with only an .of_match_table(), and no legacy users instantiating platform devices, we do have dependencies on OF. Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds