Received: by 10.192.165.156 with SMTP id m28csp391330imm; Mon, 16 Apr 2018 01:51:02 -0700 (PDT) X-Google-Smtp-Source: AIpwx49lTdAc3GhQRhOSAmTHzCdzF+LNtAd6BNM/tqpmbGtM6QIKQg7BYMgrcShTZZI8vIaZQV1o X-Received: by 10.99.97.151 with SMTP id v145mr2728031pgb.35.1523868662111; Mon, 16 Apr 2018 01:51:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523868662; cv=none; d=google.com; s=arc-20160816; b=jGR/2cr8w+//PgWueL1gxVRlMCD3e3p367D6gpw4hz4Gwyp4C49lLPV5K9oZoZb5vB lOcydyxSydvslpZnhhZ8IQ4hBj2CT82Oxez/5/VrhpPg/eszmZpMcynDJzZb41HlKke5 3V9rq234LUWreWerhJSDbC1Ia1OjIlLfyJzpXsYvIlsKeUzZ1bZToDFG7Dt/E06GE+GZ 0HsfNEandQ7diB4e0VahTWleiN8dD0B8TtuYu6Vi97MARyaHCXtZs+yWtEwD2GNz2q8+ Vbxs9Lpp91iNYqCDKy/vnTEMLJSWT0eu8Rwdw/EBc7ss79FByufdgPo1Uib6LOaFVktW InKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature:arc-authentication-results; bh=55cbyLXszy1FKh6dCUeqINtuHlim0n/6DGNK+ma27Z0=; b=fXurmi9aSC5ywelz6Eoi6ubIyOVwSaLUlLUpgfmrGLQrMrXj30+Ri0sXAx9YxhPUwp mF7d6BoQ/+n1H1YyhzJzmdC0dnBWZAyHxWfLp6vDufVs5M4XUt8NoIgheqP2HRfHwFWV FZXNQOBxJaPOoQqaH397JcBC0mRZvStGVaKAVHWFUmKEhlXmVaPi8gEDeiPfMmbVeHku eACvuvxjYv054irI6LtEZ5FywqKMnpyxYMxv9UT2h81JV+IXF9rmGwh93YXxE1RQQlaF WqpS5LgIZ5HaPU/JLLVNxf8GEWxu3/Ds+LLXdDAw+T8tWLjdGKrW6Uz5ZOrWWIY6Wj8O zcTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=aUoiRsXQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d23si9291386pgn.3.2018.04.16.01.50.47; Mon, 16 Apr 2018 01:51:02 -0700 (PDT) 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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=aUoiRsXQ; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754128AbeDPIt0 (ORCPT + 99 others); Mon, 16 Apr 2018 04:49:26 -0400 Received: from mail-wr0-f193.google.com ([209.85.128.193]:42727 "EHLO mail-wr0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754037AbeDPItZ (ORCPT ); Mon, 16 Apr 2018 04:49:25 -0400 Received: by mail-wr0-f193.google.com with SMTP id s18so23592505wrg.9 for ; Mon, 16 Apr 2018 01:49:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=55cbyLXszy1FKh6dCUeqINtuHlim0n/6DGNK+ma27Z0=; b=aUoiRsXQ1c3863RGQ2E3/s/5mrBvX6TDMbu5lZYx5Epsi43l1TWAiYmNrUoEdXGiXh J5uW7afSueEA9467KtVuizXALpLLU4zzEjFT4uMIorsWi+VKz/LmMhLMw2VtUzKYTy87 YZGO4jQI4BhN+4wYNZwGR6qdN9IQC4BZFb5B/KrfVKvyvP3GDGCcKff1M4BL+ERfNMe6 v2DWu1Ip1ZY+FtC3QxNH9ZgMpbvXKhXsTOCNYGf9prNFFhlV+qE8tgROuMRAIAZUhLvT RjuywWFQ9eoafzV8S5uOSiKY0LbQmnOdfB/qPrp9as1m9RMJCX65HTkzrSCRfMSJFLle pVIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=55cbyLXszy1FKh6dCUeqINtuHlim0n/6DGNK+ma27Z0=; b=ZRlUixrcNh4bfYxaKLSuRDuPxJWZ8rc+PDaD7cSuxlvRmZskbYTbdRAkwXq2fOIdi5 zWUerat5iVytwdpbBabsxVS822Dn4GRQ6X9e46BnOQgVXfdBoiHM8E2o/lOtXoupvYzr 4Xy8msSWSDu9hzmpeaofxQB65rJnwb/SNYttUolDfIx6c4L+XhCZ23/+knGl0WBolJFh Cpp43jCHVe3T7AlHMPe0Mkj7nsEUzZbqYWkyqh/qWUIHNnaXqyU5UP3hq75SryPyJ7to I7/ibxbeuozfQVIOVisQvShJqHlChTpE2T0NBG2DbQzkrgIpgEIJkz8ku40hjUeMp/v/ YpGw== X-Gm-Message-State: ALQs6tDfjc+XpEJkSPMaxxLbcnYiKroZC1ugL15HhYgjbhhVraEZfZIF e/wOtzPX07CRCwJJfq1rads= X-Received: by 10.223.193.5 with SMTP id r5mr9089823wre.274.1523868564027; Mon, 16 Apr 2018 01:49:24 -0700 (PDT) Received: from [127.0.1.1] ([83.243.48.53]) by smtp.gmail.com with ESMTPSA id b47sm9516600wrg.13.2018.04.16.01.49.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 16 Apr 2018 01:49:23 -0700 (PDT) From: Tobias Regnery To: cw00.choi@samsung.com, myungjoo.ham@samsung.com, wens@csie.org, hdegoede@redhat.com, linux-kernel@vger.kernel.org Cc: Tobias Regnery Subject: [PATCH] extcon: axp288: fix link error Date: Mon, 16 Apr 2018 10:40:03 +0200 Message-Id: <20180416084003.13847-1-tobias.regnery@gmail.com> X-Mailer: git-send-email 2.17.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org With CONFIG_AXP288=y and CONFIG_USB_COMMON=n there is the following link error: drivers/extcon/extcon-axp288.o: In function `axp288_put_role_sw': extcon-axp288.c:(.text+0xa0): undefined reference to `usb_role_switch_put' drivers/extcon/extcon-axp288.o: In function `axp288_usb_role_work': extcon-axp288.c:(.text+0xec): undefined reference to `usb_role_switch_get_role' extcon-axp288.c:(.text+0x12c): undefined reference to `usb_role_switch_set_role' drivers/extcon/extcon-axp288.o: In function `axp288_extcon_probe': extcon-axp288.c:(.text+0x59d): undefined reference to `usb_role_switch_get' The above functions are defined in drivers/usb/common/roles.c, but the build system only enters the common directory depending on CONFIG_USB_COMMON. Fix this by selecting the USB_COMMON symbol. Fixes: d54f063cdbe4 ("extcon: axp288: Set USB role where necessary") Signed-off-by: Tobias Regnery --- Hi, there is another solution for this problem: replace depends on USB_SUPPORT with depends on USB, but since CONFIG_USB selects other symbols I went with the minimal fix and select the USB_COMMON symbol. --- drivers/extcon/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig index de15bf55895b..0897bee54c2b 100644 --- a/drivers/extcon/Kconfig +++ b/drivers/extcon/Kconfig @@ -31,6 +31,7 @@ config EXTCON_ARIZONA config EXTCON_AXP288 tristate "X-Power AXP288 EXTCON support" depends on MFD_AXP20X && USB_SUPPORT && X86 + select USB_COMMON select USB_ROLE_SWITCH help Say Y here to enable support for USB peripheral detection -- 2.17.0