Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 64939C7EE21 for ; Thu, 4 May 2023 09:38:36 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 900C3847D4; Thu, 4 May 2023 11:38:34 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1683193114; bh=uQYO74TAlzO5KYpIVIIwTU0qkaypY+Ob9ZB8a5a318s=; h=Date:Subject:To:Cc:References:From:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=Fu8/4r/uS9icSFpORRTOFpBpjCyrymrwT2NLO24WnxEWJGAp2kiqcg09FgD6dpgjl RxFYh1iHO9drxLARjKjAJcKxPLD1VKDQGPQKfU5eqSXg4zBQgEFmqaRNpBQUq3kPUb Z/Zohdq9txl/WZMFJqY1+wvP+R7Zkxf0iFq8Jl1+hLIznYN5KmCdaNKCd7GmVjd+Dh e0oPQz1IiTbJoDQWcGhv30jrTsG4HC81Sq/J1gh4sRQ1sr1D0WBFNkNRNUeyNZ/M5x l+9BBI73cjfBWMt7vK8XX/HOoNcseyjmMVhqjXYSohiauv6DxBGjkl044zKyQR2SVF VjxatTOw4ItCw== Received: from [127.0.0.1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 0F2B98474D; Thu, 4 May 2023 11:38:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1683193113; bh=uQYO74TAlzO5KYpIVIIwTU0qkaypY+Ob9ZB8a5a318s=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=IHVnOOJhoGPFvaTzVFyMzul9UwSrZw2x3HtfgZr5B4R4Wmr54flXDnIa/tzR5QfPZ P9oUZjgz377THTzmoMfKVQumDvew9RQqXMiJrDCBHyUnRxGIyrfFHuZ/9xMmid0IP6 6ic6vlUdK4d/mzKrxfpmUJk5fnG3jxHbtzVPqPbPP5sXYOpPsdndjO4gOo8sqoSyq1 ApDIR3Ijn8xd1CnfCIme4NR2TSzEyY4g1XmacLWJe6PQ5S7C4qYK0+Kh9LyoiJK54i aD+kOUDmJ6NHy0Yx/bWCa+CIs6UjJMLtdm/TmeNfcyiFQ+qf/mtxJkr1v04hyPIURK pDXbaPulZN+7w== Message-ID: Date: Thu, 4 May 2023 11:17:54 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.0 Subject: Re: [PATCH] usb: gadget: Compile USB ethernet gadget only if NET is enabled To: Lukasz Majewski Cc: u-boot@lists.denx.de References: <20230430212035.379838-1-marex@denx.de> <20230504110445.733f58f5@wsk> Content-Language: en-US From: Marek Vasut In-Reply-To: <20230504110445.733f58f5@wsk> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean On 5/4/23 11:04, Lukasz Majewski wrote: > On Sun, 30 Apr 2023 23:20:35 +0200 > Marek Vasut wrote: > >> In case NET networking is not enabled, it is not possible to compile >> the USB ethernet gadget. Protect the symbols in Makefile to avoid >> build failure. Such build failure may occur e.g. in case NET and USB >> ethernet gadget is enabled in U-Boot proper, but not in SPL. >> >> Signed-off-by: Marek Vasut >> --- >> Cc: Lukasz Majewski >> --- >> drivers/usb/gadget/Makefile | 2 ++ >> 1 file changed, 2 insertions(+) >> >> diff --git a/drivers/usb/gadget/Makefile b/drivers/usb/gadget/Makefile >> index 6cfe0f3a041..36f65e7eb95 100644 >> --- a/drivers/usb/gadget/Makefile >> +++ b/drivers/usb/gadget/Makefile >> @@ -34,8 +34,10 @@ endif >> >> obj-$(CONFIG_CI_UDC) += ci_udc.o >> >> +ifeq ($(CONFIG_$(SPL_TPL_)NET),y) >> obj-$(CONFIG_USB_ETHER) += ether.o >> obj-$(CONFIG_USB_ETH_RNDIS) += rndis.o >> +endif >> >> # Devices not related to the new gadget layer depend on >> CONFIG_USB_DEVICE # This is really only N900 and USBTTY now. > > Reviewed-by: Lukasz Majewski NAK (so this does not get applied by accident, because ongoing discussion about Kconfig symbols)