From patchwork Tue Mar 16 18:05:33 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Wunderlich X-Patchwork-Id: 1454131 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=mailerdienst.de header.i=@mailerdienst.de header.a=rsa-sha256 header.s=20200217 header.b=uVJ3WeA2; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4F0LnC5rFYz9sVb for ; Wed, 17 Mar 2021 05:05:51 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D4C8582049; Tue, 16 Mar 2021 19:05:44 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=fw-web.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=mailerdienst.de header.i=@mailerdienst.de header.b="uVJ3WeA2"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 49E6B8204C; Tue, 16 Mar 2021 19:05:43 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from mxout1.routing.net (mxout1.routing.net [IPv6:2a03:2900:1:a::a]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 08F3B82047 for ; Tue, 16 Mar 2021 19:05:38 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=fw-web.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=linux@fw-web.de Received: from mxbox3.masterlogin.de (unknown [192.168.10.78]) by mxout1.routing.net (Postfix) with ESMTP id 71CFB3FE0A; Tue, 16 Mar 2021 18:05:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailerdienst.de; s=20200217; t=1615917938; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=ZsdXxhK0prxRXHB/nixtk5XlzrBoOV8sITPvaziD1Wc=; b=uVJ3WeA2aHCAgrQumOdq54e78P0PS8hlPhbHD7QakzeSDOfBG5ZMGYfoKhcxD1IgaY4BnG YQlsIerNDYD7RVfBgFwyJ0pajjA+K8hPPMSrd/raVfpjqbrouO73AW12sFUFJ5M7t6Dr7b Kfe403eMTzkJts0OZSQefj8eCK/BV7g= Received: from localhost.localdomain (unknown [80.245.77.133]) by mxbox3.masterlogin.de (Postfix) with ESMTPSA id 114F036022C; Tue, 16 Mar 2021 18:05:38 +0000 (UTC) From: Frank Wunderlich To: u-boot@lists.denx.de Cc: Frank Wunderlich Subject: [PATCH] ahci: mediatek: fix undefined reference of dev_err Date: Tue, 16 Mar 2021 19:05:33 +0100 Message-Id: <20210316180533.184794-1-linux@fw-web.de> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-Mail-ID: 10134e66-38de-42c5-9505-c2561a106a30 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.102.4 at phobos.denx.de X-Virus-Status: Clean From: Frank Wunderlich building with MTK_AHCI enabled results in implicit declaration and undefined reference of dev_err followed by a segfault of gcc drivers/ata/mtk_ahci.c: In function 'mtk_ahci_parse_property': drivers/ata/mtk_ahci.c:65:4: warning: implicit declaration of function 'dev_err' drivers/ata/mtk_ahci.c:65: undefined reference to `dev_err' in function `mtk_ahci_probe': drivers/ata/mtk_ahci.c:92: undefined reference to `dev_err' Segmentation fault fix this by adding the dm/device_compat.h to includes Signed-off-by: Frank Wunderlich --- drivers/ata/mtk_ahci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/ata/mtk_ahci.c b/drivers/ata/mtk_ahci.c index 554175bc0051..2c5227df306b 100644 --- a/drivers/ata/mtk_ahci.c +++ b/drivers/ata/mtk_ahci.c @@ -21,6 +21,7 @@ #include #include #include +#include #define SYS_CFG 0x14 #define SYS_CFG_SATA_MSK GENMASK(31, 30)