From patchwork Mon Jul 17 08:56:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 107877 Delivered-To: patch@linaro.org Received: by 10.140.101.44 with SMTP id t41csp4256296qge; Mon, 17 Jul 2017 01:59:51 -0700 (PDT) X-Received: by 10.98.50.133 with SMTP id y127mr17642649pfy.242.1500281991351; Mon, 17 Jul 2017 01:59:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1500281991; cv=none; d=google.com; s=arc-20160816; b=Ovno7fuZeMootxTNOOfj+zhx9uKp75EEbciNxpXcPzenjzeRnoKrLdfGp9Wkyzx5vQ EI6j9Fu6TXtJm4q+E/CJVlnf3de0Z6Akv+WAvIrCyEj/QlmLsrQTSEKq2/+6kHsec5zu cwdS3dv7QteYHPxMRsHZOVXMeZGfZVNWaPqaEKfVh/PpoJflP8UWcnSkGnAHSWMFMLZq M1haPysFIrNgRIe4o2/KydFWV1gWvs48tixqFfPv2EorwfbTyrfZ6lnUl4Gcg1QOfaa/ zh0gLOHQrZmOXuWmbafPZIyd49FXmAYnKTdrj16ntTymL1g+H1Hibrywi3NAt9pzcgpT kEyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=YcM+BnKMPVyRBe1YTuZaMK13ZVTufTUYCGc+dKBUFcQ=; b=O8VH31OusF2S4QvZWy3tLjunihZ4vRcurpwU57avlh0h3E0pgxs12roy4vz4urKqsK sOcO2jKjETlr66vHnceWDU0SrGznaO/zwB1wfpK1UTqnoj4z2ps/6bE8vgIrQiqXCgi5 pp8+7Obq//3uwwwZNJIXIbWWuG7/9O1WqU/9aWv5ZwjJOf2Ury5qSblk1A43APr4pqYg FHp+m5v6Xj3NC+Ud6Yquo0EbLehCLgPXOqMeZBb5hTGZC38CQpbBeSYj2JqCeUti++aP lGWy9BZ7ytU7yDMSHYdBJXxkettDsZrgXN9rDG2EpM2Et4pzWy1gUT8KUymqQ5u8MQQO C1WQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.b=Ba/xBHyx; 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=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g9si12778001pln.631.2017.07.17.01.59.51; Mon, 17 Jul 2017 01:59:51 -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=@linaro.org header.b=Ba/xBHyx; 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=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751473AbdGQI7r (ORCPT + 25 others); Mon, 17 Jul 2017 04:59:47 -0400 Received: from mail-wr0-f177.google.com ([209.85.128.177]:35346 "EHLO mail-wr0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751404AbdGQI6q (ORCPT ); Mon, 17 Jul 2017 04:58:46 -0400 Received: by mail-wr0-f177.google.com with SMTP id w4so18946625wrb.2 for ; Mon, 17 Jul 2017 01:58:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=YcM+BnKMPVyRBe1YTuZaMK13ZVTufTUYCGc+dKBUFcQ=; b=Ba/xBHyxVKwLhoT2D0k3KCXbEJEv3V3apJB/4TJezNvdz9SulYxGxCvFNW4SFCj3Fm VmR2nghDw8+qVTdAhAPHjfncEJYD0ecicSi0qreVU7Jjv33SYPpD6HIGRWzE3yq3AFI3 unNiqLluA4VLzAWaPsg0WjU5nVlyE5vAk6Id0= 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:in-reply-to :references; bh=YcM+BnKMPVyRBe1YTuZaMK13ZVTufTUYCGc+dKBUFcQ=; b=AvHEfu1wOyMlNwChKwdz3hI6mH3LINzVmb9m+dKQ4RitlxE/sEM5aAdLKQCS3kSNWr CJLx9Aifhw5uMx/nMm10WUsagQQYUeAvYaV54opfPvJfnYBVsDS+eg4aHIYzlD1uYF94 dBgiPFgea5XVlQrN7q8B7DRY+Z500jKuY9dwzSenktCL72itpI0nOoqwVHzEriLVRx1h yKr/gGtfmqGcMKm5iDsI+gUYorG7GALNXyZD1hvCOl6F/zYGQRDbZ9HLEyuJLVnlGQfO MNhhVFlLmOzKa7V7efFOE/v3UynCfugPMBSconXgwBtGFuRq5WMhljaAeVWcR6dl2wsH Ecvw== X-Gm-Message-State: AIVw110CwQ4p/G/qFVmXFQ8y4Fy8bU2bltEkADd/Z0ak36ALOWgB547y pHWu+Wa5PTKvWsz1 X-Received: by 10.223.151.82 with SMTP id r76mr10124416wrb.6.1500281925557; Mon, 17 Jul 2017 01:58:45 -0700 (PDT) Received: from localhost.localdomain ([37.157.136.206]) by smtp.gmail.com with ESMTPSA id q17sm11558700wmd.4.2017.07.17.01.58.44 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 17 Jul 2017 01:58:45 -0700 (PDT) From: Stanimir Varbanov To: Mauro Carvalho Chehab Cc: Hans Verkuil , Arnd Bergmann , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org Subject: [PATCH 3/4] venus: fix compile-test build on non-qcom ARM platform Date: Mon, 17 Jul 2017 11:56:49 +0300 Message-Id: <20170717085650.12185-4-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170717085650.12185-1-stanimir.varbanov@linaro.org> References: <20170717085650.12185-1-stanimir.varbanov@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arnd Bergmann If QCOM_MDT_LOADER is enabled, but ARCH_QCOM is not, we run into a build error: ERROR: "qcom_mdt_load" [drivers/media/platform/qcom/venus/venus-core.ko] undefined! ERROR: "qcom_mdt_get_size" [drivers/media/platform/qcom/venus/venus-core.ko] undefined! This changes the 'select' statement again, so we only try to enable those symbols when the drivers will actually get built, and explicitly test for QCOM_MDT_LOADER to be enabled before calling into it. Fixes: 76724b30f222 ("[media] media: venus: enable building with COMPILE_TEST") Signed-off-by: Arnd Bergmann Reviewed-by: Stanimir Varbanov --- drivers/media/platform/Kconfig | 4 ++-- drivers/media/platform/qcom/venus/firmware.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) -- 2.11.0 diff --git a/drivers/media/platform/Kconfig b/drivers/media/platform/Kconfig index 1313cd533436..fb1fa0b82077 100644 --- a/drivers/media/platform/Kconfig +++ b/drivers/media/platform/Kconfig @@ -475,8 +475,8 @@ config VIDEO_QCOM_VENUS tristate "Qualcomm Venus V4L2 encoder/decoder driver" depends on VIDEO_DEV && VIDEO_V4L2 && HAS_DMA depends on (ARCH_QCOM && IOMMU_DMA) || COMPILE_TEST - select QCOM_MDT_LOADER if (ARM || ARM64) - select QCOM_SCM if (ARM || ARM64) + select QCOM_MDT_LOADER if ARCH_QCOM + select QCOM_SCM if ARCH_QCOM select VIDEOBUF2_DMA_SG select V4L2_MEM2MEM_DEV ---help--- diff --git a/drivers/media/platform/qcom/venus/firmware.c b/drivers/media/platform/qcom/venus/firmware.c index d6d9560c1c19..521d4b36c090 100644 --- a/drivers/media/platform/qcom/venus/firmware.c +++ b/drivers/media/platform/qcom/venus/firmware.c @@ -38,7 +38,7 @@ int venus_boot(struct device *dev, const char *fwname) void *mem_va; int ret; - if (!qcom_scm_is_available()) + if (!IS_ENABLED(CONFIG_QCOM_MDT_LOADER) || !qcom_scm_is_available()) return -EPROBE_DEFER; node = of_parse_phandle(dev->of_node, "memory-region", 0);