From patchwork Mon Nov 14 13:03:06 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 82104 Delivered-To: patch@linaro.org Received: by 10.140.97.165 with SMTP id m34csp995829qge; Mon, 14 Nov 2016 05:03:16 -0800 (PST) X-Received: by 10.98.194.130 with SMTP id w2mr35611315pfk.143.1479128595985; Mon, 14 Nov 2016 05:03:15 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e11si13321893pgp.204.2016.11.14.05.03.15; Mon, 14 Nov 2016 05:03:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org; dmarc=fail (p=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932257AbcKNNDO (ORCPT + 3 others); Mon, 14 Nov 2016 08:03:14 -0500 Received: from mail-lf0-f42.google.com ([209.85.215.42]:33477 "EHLO mail-lf0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932179AbcKNNDN (ORCPT ); Mon, 14 Nov 2016 08:03:13 -0500 Received: by mail-lf0-f42.google.com with SMTP id c13so57587385lfg.0 for ; Mon, 14 Nov 2016 05:03:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=VzOi7Nvd6ZaIq/pGG7h715UqdliC3gFRaLtIx0Yd17E=; b=BXTwHdr3ohlOy/YyzpNYT9AFOiwBfwZo48wOK8OvyauWbPNMom7xCYV9juvNIKyvDE wxSO9D55ed/d0izK3W0paWVHnVZWN2uXCEbDH3FsVtz4+5JGsjh5I4BxhC5+cFdmksa6 AWaleARsZcQGQS8NeC7j/HSzCOzvkyGCSPq2g= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=VzOi7Nvd6ZaIq/pGG7h715UqdliC3gFRaLtIx0Yd17E=; b=JULIhF20LU96UzlYDhTqDn92kI+aku2gUwd3pBsLWIN6OspWCM7rmIowM0Tyjp3ZK0 fsqaJ+xBuEQvTx5hmmadeyYVKPfb5TaSHjwr+rMmXTbcMrIMRj/cteX4vtYMxJP3hdlN t6ipQH3mRM/hG6zqdqgn2hrY8tRy6BWCaGwKNMbKPr+roPmz5OkafJUOKuXJzGtvAvNb 1AWZlxL6T2KE3D0K/URhjHkfpLDhdz90HZqpsjnwvKt02f+qKgTj8PbMo+pkZ7DD8vgT MxkpJsZwOXED4Kkj8PUyn2PeAK7vgiIoQaX8jxDdMIby3HArx5oYgaTWNBuMLtEPF6OE S/YQ== X-Gm-Message-State: ABUngvcBJO4EvWg/YJmJRekn9bTZSB6JRN/DTnmb8sek4pWNIKyaCQ8ktT2h23wUlM8ONCq9 X-Received: by 10.25.159.78 with SMTP id i75mr8228010lfe.123.1479128591941; Mon, 14 Nov 2016 05:03:11 -0800 (PST) Received: from linuslaptop.ideon.se ([85.235.10.227]) by smtp.gmail.com with ESMTPSA id z26sm5010588lja.49.2016.11.14.05.03.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 14 Nov 2016 05:03:11 -0800 (PST) From: Linus Walleij To: Wolfram Sang , linux-i2c@vger.kernel.org Cc: Linus Walleij , stable@vger.kernel.org, Jonathan Cameron , Peter Rosin Subject: [PATCH] i2c: mux: fix up dependencies Date: Mon, 14 Nov 2016 14:03:06 +0100 Message-Id: <1479128586-17052-1-git-send-email-linus.walleij@linaro.org> X-Mailer: git-send-email 2.7.4 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org We get the following build error from UM Linux after adding an entry to drivers/iio/gyro/Kconfig that issues "select I2C_MUX": ERROR: "devm_ioremap_resource" [drivers/i2c/muxes/i2c-mux-reg.ko] undefined! ERROR: "of_address_to_resource" [drivers/i2c/muxes/i2c-mux-reg.ko] undefined! It appears that the I2C mux core code actually only requires CONFIG_OF, but depends on HAS_IOMEM for historical reasons, while CONFIG_I2C_MUX_REG does *not* have a direct dependency on HAS_IOMEM. This creates a situation where a allyesconfig or allmodconfig for UM Linux will select I2C_MUX, and will implicitly enable I2C_MUX_REG as well, and the compilation will fail for the register driver. Fix this up by making I2C_MUX_REG depend on HAS_IOMEM and the I2C_MUX depend on OF. Cc: stable@vger.kernel.org Reported-by: kbuild test robot Reported-by: Jonathan Cameron Cc: Jonathan Cameron Cc: Peter Rosin Signed-off-by: Linus Walleij --- drivers/i2c/Kconfig | 2 +- drivers/i2c/muxes/Kconfig | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe stable" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/i2c/Kconfig b/drivers/i2c/Kconfig index d223650a97e4..b9e378cfe1d1 100644 --- a/drivers/i2c/Kconfig +++ b/drivers/i2c/Kconfig @@ -59,7 +59,7 @@ config I2C_CHARDEV config I2C_MUX tristate "I2C bus multiplexing support" - depends on HAS_IOMEM + depends on OF help Say Y here if you want the I2C core to support the ability to handle multiplexed I2C bus topologies, by presenting each diff --git a/drivers/i2c/muxes/Kconfig b/drivers/i2c/muxes/Kconfig index e280c8ecc0b5..96de9ce5669b 100644 --- a/drivers/i2c/muxes/Kconfig +++ b/drivers/i2c/muxes/Kconfig @@ -63,6 +63,7 @@ config I2C_MUX_PINCTRL config I2C_MUX_REG tristate "Register-based I2C multiplexer" + depends on HAS_IOMEM help If you say yes to this option, support will be included for a register based I2C multiplexer. This driver provides access to