From patchwork Fri Jan 1 13:55:24 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 101224 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp3971602lbb; Fri, 1 Jan 2016 05:56:46 -0800 (PST) X-Received: by 10.98.14.151 with SMTP id 23mr40212595pfo.154.1451656606151; Fri, 01 Jan 2016 05:56:46 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 5si55214135pft.6.2016.01.01.05.56.45; Fri, 01 Jan 2016 05:56:46 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752036AbcAAN4D (ORCPT + 29 others); Fri, 1 Jan 2016 08:56:03 -0500 Received: from mout.kundenserver.de ([212.227.126.131]:60784 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751840AbcAANz7 (ORCPT ); Fri, 1 Jan 2016 08:55:59 -0500 Received: from wuerfel.localnet ([134.3.118.24]) by mrelayeu.kundenserver.de (mreue003) with ESMTPSA (Nemesis) id 0LZjFg-1ZpbaV3bTg-00lYFw; Fri, 01 Jan 2016 14:55:27 +0100 From: Arnd Bergmann To: netdev@vger.kernel.org, David Miller Cc: Igal Liberman , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH] fsl/fman: allow modular build Date: Fri, 01 Jan 2016 14:55:24 +0100 Message-ID: <4109142.02mezJXbJM@wuerfel> User-Agent: KMail/4.11.5 (Linux/3.16.0-10-generic; KDE/4.11.5; x86_64; ; ) MIME-Version: 1.0 X-Provags-ID: V03:K0:vow8YKDRx6cHPCSqhNIHsZFXEZdT2ILPjDASPoIuJRagAPQiCEf KEqOsaZYx7AAqbFzb8FC4mEwpm3miwUF5F6V7Q4+FmBc2mhKPBXg8f5EghDDTxcqjnbBCoQ YGnimFbf1MqShWssBLIZrowbFx/nd8i4JHgdUevIbAN2xEzfLK9Z9bmJVHOg6ecIsXETELH sgtpnyjELPXf0rfBkY+kA== X-UI-Out-Filterresults: notjunk:1; V01:K0:ytTMZ678gSM=:8w73ypJ93HBU14QzXyVsRO YC+tQAFxFmaUyeFlUWpH3SUDdMgXNKhfrAOpd+uHNlmKFsbAlGaRas2vCSIw5HOL5f5kNR8bE odLCW3Hay6jDT+1uK7CNuePhU7p8fmwfDWqcZtuPwOyD3gsd8aZJaMTlFalSqvji0Y+aOX3ck 4yy7vQ3c/RNlZyVNVsfvFZd6uQARhEQduAfQf3Rltbl9endESYN//boZwkjJ72RP5N6u2gVQv m7WDcT+n3BOxHlrPWTGWqV8VrTbCTp0y5g2zlHUitVXM+U4It2wKgWbhgJTlyCxgE3DIbbttF R2jBaE4oET41FafEY4b6onIgJjDIn5lxjW9Fixha/IlxdPxm2EH9fgXdfG4GxObOZBr84/pYt iHNHglJRtH4kvPL/BmsqpIzT/qYHPVFSZDtPJRg7f5CIV5QjCgjVbaHk40koYvww4fxqhLYL+ xEODiaHh4SzbW1ApJWJ4vlp9nHPFPNjqlgRb8YBS3sdyt/Bsi+BJh93bGsuw5F8+AcfdzBXeg 0F06YySV8NdxYs/whM1QqDgvyYMdMA0mFMAPTMtTcTjw+q4jfeJJwDARkpwMaLDUGoG+c1qA9 6fLEMzgd724/5aU12MG2dezMREqvu39Sq95g073tw0BpbfxvNlG8EpyNooxZ/uxcE/UOrpqzY zxN7JbXzcI7hzLcqdXf2lw+CuNlFsZBwAJTfzi+c8V/qTPUD3UXCqPEqBukcsx6bqpU4uGSeS N36YR/2qU8ctAkIi Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ARM allmodconfig fails because of the addition of the FMAN driver: drivers/built-in.o: In function `dtsec_restart_autoneg': binder.c:(.text+0x173328): undefined reference to `mdiobus_read' binder.c:(.text+0x173348): undefined reference to `mdiobus_write' drivers/built-in.o: In function `dtsec_config': binder.c:(.text+0x173d24): undefined reference to `of_phy_find_device' drivers/built-in.o: In function `init_phy': binder.c:(.text+0x1763b0): undefined reference to `of_phy_connect' drivers/built-in.o: In function `stop': binder.c:(.text+0x176014): undefined reference to `phy_stop' drivers/built-in.o: In function `start': binder.c:(.text+0x176078): undefined reference to `phy_start' The reason is that the driver uses PHYLIB, but that is a loadable module here, and fman itself is built-in. This patch makes it possible to configure fman as a module as well so we don't change the status of PHYLIB in an allmodconfig kernel, and it adds a 'select PHYLIB' statement to ensure that phylib is always built-in when fman is. The driver uses "builtin_platform_driver(fman_driver);", which means it cannot be unloaded, but it's still possible to have it as a loadable module that gets loaded once and never removed. Signed-off-by: Arnd Bergmann Fixes: 5adae51a64b8 ("fsl/fman: Add FMan MURAM support") -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ diff --git a/drivers/net/ethernet/freescale/fman/Kconfig b/drivers/net/ethernet/freescale/fman/Kconfig index 66b729692b48..79b7c84b7869 100644 --- a/drivers/net/ethernet/freescale/fman/Kconfig +++ b/drivers/net/ethernet/freescale/fman/Kconfig @@ -1,7 +1,8 @@ config FSL_FMAN - bool "FMan support" + tristate "FMan support" depends on FSL_SOC || COMPILE_TEST select GENERIC_ALLOCATOR + select PHYLIB default n help Freescale Data-Path Acceleration Architecture Frame Manager