Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp4464261pxb; Sat, 6 Nov 2021 14:36:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwBKHVvMHjJjqsHiwbLxRZvbg13Y1ZuQ+4ZSkDg8oFg0ECMdsyNvbGIqAnMRSk6gszPXxNQ X-Received: by 2002:a05:6402:280d:: with SMTP id h13mr42228793ede.346.1636234602616; Sat, 06 Nov 2021 14:36:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1636234602; cv=none; d=google.com; s=arc-20160816; b=EZrrFwStA922MwBP/RqqrJCEOWVwaVIkDRVsRPqgj62ZmxUdr4sD72prX0HFAaSk5g FbKAOjc2WXGBpdCCcH4kjcv0oZfXrrBEStp4kiKIA46BBQdoyF26KTyLSeEnmlAHiATY KxYpTwW2CI4gZ6OspPK3I4ZqRUm+ptzrbcbSEVmekoG6B0DrZHrgv182KsrsLaaqNmgO yliNMC5XW7AwxgKhbwPgAy9idh9Fb3+tuVkuhQkI+TqLE2kJBB3wYIMpREdZGEdHLsMX koGkT6jbLdEj6tykkcvGLDcSZeTVwSMeSnbKsNtEkzO0QZ6jvSN/xj0NQAn6bG/wqNm8 pvYg== 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=R9PO0YzwC2Jw+Hhm1KmFXfAei65K8Unw+7A6Xi9XIdM=; b=FVnFzOOZF8KAGoGzUWQl+mprtUbxuFD4G9sPa4ifcRbiSsefRY5XzrffC/n3+a8zbB ct+vu6NT+380s1bAC43p02WGFPDoSWzMNXJufJR/BvNRPzZovfuK71sD0E0g9xhfmL6H H/vUR1HDOG2VAhqgyzNuvkeVqrwBro/0Lw/bUXU4geb/077AXWnaexPnS2Tv6q32GOTI 7xAPNibXSUaZyrsWRjgK7yAreubfamW/qd5KPtqr7oahKZt/byOi04IviTkPQdwngePj 5nMnXhdJZpIpKGRqdInrvAdCPg+jztHw/0p8COauIRTVkqO9qwlhKvJIH16F3qIrjb/9 CqdQ== 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 e9si26426012edz.251.2021.11.06.14.36.19; Sat, 06 Nov 2021 14:36:42 -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 S234633AbhKFQyS (ORCPT + 99 others); Sat, 6 Nov 2021 12:54:18 -0400 Received: from mail-vk1-f174.google.com ([209.85.221.174]:35729 "EHLO mail-vk1-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232907AbhKFQyR (ORCPT ); Sat, 6 Nov 2021 12:54:17 -0400 Received: by mail-vk1-f174.google.com with SMTP id u130so6111582vku.2; Sat, 06 Nov 2021 09:51:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=R9PO0YzwC2Jw+Hhm1KmFXfAei65K8Unw+7A6Xi9XIdM=; b=AprHLVYC68mFjVrjQ4lqLlZbTEwaVZ8CctKYpsxeijSs5JNeizPvDJp6Sex2nw1L+Y T1FI2yBdNB38fAREOAL/T3TVNddik2cQShAZhIlgww6KdLx5haxAebtcRaBa9256Pmrr FePYdY9wkD9KgjIvX04n0ykS/5e94WgT3FkAZgiHycbOFUujf7ajqsAtgk99VE+tsGAd TH+1weKUCG0fdHLiP1Ky2MmhyqNz4NJ80bot7uJqyOy/M6ihRvssW/vAeAQx7nxGWCqJ TuMUSCJiG+hBjCA4EOrxsjL6H67iYAgxDqzeECYkptglGsVHuyOv+xOuEjqYN0dRxTcf AyvQ== X-Gm-Message-State: AOAM530rWNRZrTnbMp91MmbN+Oyx52nYiZ5NjjfAHkNkCc7xvRn2FgMP ABUxEf+ijVTEvFxCKCc4xBOeO81DmFI8dA== X-Received: by 2002:a1f:2345:: with SMTP id j66mr81593322vkj.20.1636217495538; Sat, 06 Nov 2021 09:51:35 -0700 (PDT) Received: from mail-vk1-f174.google.com (mail-vk1-f174.google.com. [209.85.221.174]) by smtp.gmail.com with ESMTPSA id r25sm1830298uab.13.2021.11.06.09.51.35 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 06 Nov 2021 09:51:35 -0700 (PDT) Received: by mail-vk1-f174.google.com with SMTP id e64so6137640vke.4; Sat, 06 Nov 2021 09:51:35 -0700 (PDT) X-Received: by 2002:a05:6122:20ab:: with SMTP id i43mr3542895vkd.19.1636217494892; Sat, 06 Nov 2021 09:51:34 -0700 (PDT) MIME-Version: 1.0 References: <20210927084615.1938432-1-anders.roxell@linaro.org> In-Reply-To: <20210927084615.1938432-1-anders.roxell@linaro.org> From: Geert Uytterhoeven Date: Sat, 6 Nov 2021 17:51:23 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCHv2] scsi: ufs: Kconfig: SCSI_UFS_HWMON depens on HWMON=y To: Anders Roxell Cc: "James E.J. Bottomley" , "Martin K. Petersen" , Jean Delvare , Guenter Roeck , avri.altman@wdc.com, scsi , Linux Kernel Mailing List , linux-hwmon@vger.kernel.org, Randy Dunlap Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Anders, On Mon, Sep 27, 2021 at 10:47 AM Anders Roxell wrote: > When building an allmodconfig kernel, the following build error shows > up: > > aarch64-linux-gnu-ld: drivers/scsi/ufs/ufs-hwmon.o: in function `ufs_hwmon_probe': > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:177: undefined reference to `hwmon_device_register_with_info' > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:177:(.text+0x510): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `hwmon_device_register_with_info' > aarch64-linux-gnu-ld: drivers/scsi/ufs/ufs-hwmon.o: in function `ufs_hwmon_remove': > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:195: undefined reference to `hwmon_device_unregister' > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:195:(.text+0x5c8): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `hwmon_device_unregister' > aarch64-linux-gnu-ld: drivers/scsi/ufs/ufs-hwmon.o: in function `ufs_hwmon_notify_event': > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:206: undefined reference to `hwmon_notify_event' > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:206:(.text+0x64c): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `hwmon_notify_event' > aarch64-linux-gnu-ld: /home/anders/src/kernel/next/drivers/scsi/ufs/ufs-hwmon.c:209: undefined reference to `hwmon_notify_event' > /kernel/next/drivers/scsi/ufs/ufs-hwmon.c:209:(.text+0x66c): relocation truncated to fit: R_AARCH64_CALL26 against undefined symbol `hwmon_notify_event' > > Since fragment 'SCSI_UFS_HWMON' can't be build as a module, > 'SCSI_UFS_HWMON' has to depend on 'HWMON=y'. > > Fixes: e88e2d32200a ("scsi: ufs: core: Probe for temperature notification support") > Also-Reported-by: Randy Dunlap > Signed-off-by: Anders Roxell > Acked-by: Randy Dunlap # build-tested > Acked-by: Avri Altman > --- > drivers/scsi/ufs/Kconfig | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/scsi/ufs/Kconfig b/drivers/scsi/ufs/Kconfig > index 565e8aa6319d..2ca69f87e4de 100644 > --- a/drivers/scsi/ufs/Kconfig > +++ b/drivers/scsi/ufs/Kconfig > @@ -202,7 +202,7 @@ config SCSI_UFS_FAULT_INJECTION > > config SCSI_UFS_HWMON > bool "UFS Temperature Notification" > - depends on SCSI_UFSHCD && HWMON > + depends on SCSI_UFSHCD=HWMON || HWMON=y Which is also true if both SCSI_UFSHCD and HWMON are disabled, thus exposing this question to everyone? Fix sent "[PATCH] scsi: ufs: Wrap Universal Flash Storage drivers in SCSI_UFSHCD" https://lore.kernel.org/all/20211106164650.1571068-1-geert@linux-m68k.org/ > help > This provides support for UFS hardware monitoring. If enabled, > a hardware monitoring device will be created for the UFS device. 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