Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp259996imm; Tue, 15 May 2018 01:01:18 -0700 (PDT) X-Google-Smtp-Source: AB8JxZouFgQ1PujtAC+F8sxdODeUzMxUamFvs6s0a9otEWB4Zdi/u9C5iPe2UkzLpGIwQkXYEXKU X-Received: by 2002:a62:1fc8:: with SMTP id l69-v6mr14047039pfj.49.1526371278492; Tue, 15 May 2018 01:01:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526371278; cv=none; d=google.com; s=arc-20160816; b=WTayL5P0oe6fQBj2ddH+f6dJO0zPt9IxXwnRO80WCnt/fJ3qSxo6PxC6wFTPV7W7rY TTUS8DoEHdLqmqhyJvv/PznEYSODIfgqPBDIkCJbTt2XgmWMKpRWe881O54T0qJG/5ap UDagGDKrVYj7U+1P7TgwzchLfaCof4zIAUZ3W6NIkXILB6JJAv41oOxtmSX5YFcS0KgV e06OxYmoz8LZrjKxtbnuZGXDfjkSjbtQg8mcbVkolF756qVS1pEaZvIeXLhfZNSXGTEf lvMAly4rZUJqQRqXzl7DTgo+06C/FMYF4lla7eJh0ZVcD4scEzhqC4NK/EAoDp4Rlikg hcUQ== 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=X29eSoJZ0yZJujNimFriAnLn1bdouqTmBHJYnqFJFLw=; b=ZO5ydwC0Mn8a9YoZxCL09jfSMB8DMeFZ15MiAig+4WN3SSmPKqey/cjC7bQdg2Th16 xhLxgQ2VU/sz1PGduejOADIo+Ik8HxrM9FIcZIcAcVEhYyvr2RdH3lGbSfRRmkLtBrL5 MRJAXwrANOSdrkkMwruVFVQd+5+bav4AX25/p+6Wfy6uOsO1BWGqOKJBsygNSL6szp9a PBmMFOm9K71qMfSPMRxIU9JwKHgtOLumti/a5uE9Gku6tVZB2qW4rtPSXXoB2lAimjB9 6z+bKtIxllecqdKOaDyaWR8HWxPDpM1lbKyp5Ov2haM2jkS0xCKjCsdNHNAl0J/+fu0i HMxQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=O9Xf+Fz7; 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 a10-v6si10729678pfo.121.2018.05.15.01.01.03; Tue, 15 May 2018 01:01:18 -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.s=google header.b=O9Xf+Fz7; 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 S1752348AbeEOIA1 (ORCPT + 99 others); Tue, 15 May 2018 04:00:27 -0400 Received: from mail-wm0-f68.google.com ([74.125.82.68]:50694 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752654AbeEOH76 (ORCPT ); Tue, 15 May 2018 03:59:58 -0400 Received: by mail-wm0-f68.google.com with SMTP id t11-v6so17688468wmt.0 for ; Tue, 15 May 2018 00:59:57 -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=X29eSoJZ0yZJujNimFriAnLn1bdouqTmBHJYnqFJFLw=; b=O9Xf+Fz7VJl1t/PDM+sJw3MdGi0az8AtSybhLzfWT3eOE2sSg397iilJeBhz95igH1 s/FDHSMJXDkui0RioU1E5ulktW3wzl4PJMmn+fn562ZnaweImicDGpvg19v6LrFMH617 TX39XSAo57YE8rN8bVgs1twVSmKUGls99pAbI= 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=X29eSoJZ0yZJujNimFriAnLn1bdouqTmBHJYnqFJFLw=; b=Wzv+/Fxw/yVegzgg8ooF5iDHlmo5B5OcpuA+hbjzzuSLg3wKMcLEiE1Qvk5qoao+sh vXIpbxk1IDOWgEYwsRj7gOgDcy9x0zYt965cfaYPGsHngBOflROGb6AHT2dC+4SLt9HL dH272MHXIjL/E/7MWXzWLgiYuntE6q1ZWHqzDtKmCWSAFTh2ISwp1gDLJYSiJzd1WR0+ QGCXQcTsdDpHZhZGO7d2bhdGNGneqHh/Jp9JXij+QCqBi1GqqXCPLzMhWy0p5mC7tIE6 mXAHqeds9TAxAfegt0S7z5ZnpIDnneqqX9WLkuWvyviPp1EkVYE06V3DlZjM27TLypJ1 8m6g== X-Gm-Message-State: ALKqPwcYhjH/yDcpZM/KGcOY+IFRZUz5v43y4iYHYZYvX5VY5GjMwnt9 OzvJ5AtMEMovKHtegbbY44hgxA== X-Received: by 2002:a1c:c702:: with SMTP id x2-v6mr7715806wmf.57.1526371197189; Tue, 15 May 2018 00:59:57 -0700 (PDT) Received: from mms-0440.qualcomm.mm-sol.com ([37.157.136.206]) by smtp.gmail.com with ESMTPSA id 4-v6sm10918510wmg.40.2018.05.15.00.59.56 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 15 May 2018 00:59:56 -0700 (PDT) From: Stanimir Varbanov To: Mauro Carvalho Chehab , Hans Verkuil Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Vikash Garodia , Stanimir Varbanov Subject: [PATCH v2 28/29] venus: add sdm845 compatible and resource data Date: Tue, 15 May 2018 10:58:58 +0300 Message-Id: <20180515075859.17217-29-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180515075859.17217-1-stanimir.varbanov@linaro.org> References: <20180515075859.17217-1-stanimir.varbanov@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This adds sdm845 DT compatible string with it's resource data table. Reviewed-by: Rob Herring Signed-off-by: Stanimir Varbanov --- .../devicetree/bindings/media/qcom,venus.txt | 1 + drivers/media/platform/qcom/venus/core.c | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/Documentation/devicetree/bindings/media/qcom,venus.txt b/Documentation/devicetree/bindings/media/qcom,venus.txt index 2693449daf73..00d0d1bf7647 100644 --- a/Documentation/devicetree/bindings/media/qcom,venus.txt +++ b/Documentation/devicetree/bindings/media/qcom,venus.txt @@ -6,6 +6,7 @@ Definition: Value should contain one of: - "qcom,msm8916-venus" - "qcom,msm8996-venus" + - "qcom,sdm845-venus" - reg: Usage: required Value type: diff --git a/drivers/media/platform/qcom/venus/core.c b/drivers/media/platform/qcom/venus/core.c index 381bfdd688db..bb6add9d340e 100644 --- a/drivers/media/platform/qcom/venus/core.c +++ b/drivers/media/platform/qcom/venus/core.c @@ -450,9 +450,31 @@ static const struct venus_resources msm8996_res = { .fwname = "qcom/venus-4.2/venus.mdt", }; +static const struct freq_tbl sdm845_freq_table[] = { + { 1944000, 380000000 }, /* 4k UHD @ 60 */ + { 972000, 320000000 }, /* 4k UHD @ 30 */ + { 489600, 200000000 }, /* 1080p @ 60 */ + { 244800, 100000000 }, /* 1080p @ 30 */ +}; + +static const struct venus_resources sdm845_res = { + .freq_tbl = sdm845_freq_table, + .freq_tbl_size = ARRAY_SIZE(sdm845_freq_table), + .clks = {"core", "iface", "bus" }, + .clks_num = 3, + .max_load = 2563200, + .hfi_version = HFI_VERSION_4XX, + .vmem_id = VIDC_RESOURCE_NONE, + .vmem_size = 0, + .vmem_addr = 0, + .dma_mask = 0xe0000000 - 1, + .fwname = "qcom/venus-5.2/venus.mdt", +}; + static const struct of_device_id venus_dt_match[] = { { .compatible = "qcom,msm8916-venus", .data = &msm8916_res, }, { .compatible = "qcom,msm8996-venus", .data = &msm8996_res, }, + { .compatible = "qcom,sdm845-venus", .data = &sdm845_res, }, { } }; MODULE_DEVICE_TABLE(of, venus_dt_match); -- 2.14.1