Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp271265imm; Tue, 15 May 2018 01:13:05 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrkgZ2uXYCDnBQwqS0iTV8RVaokCwRoJsHRsYETBNe9xMbne1xvMHneGmoEDFAe3cMQ4Vb+ X-Received: by 2002:a62:1e02:: with SMTP id e2-v6mr14105175pfe.212.1526371985289; Tue, 15 May 2018 01:13:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526371985; cv=none; d=google.com; s=arc-20160816; b=SaFNCKuk1T0oLFca1bxw9lRrWH2BkfR2Te4+cpYGHGl6Xk+oeOJX/z0kHAaQm9xjpi MXqemnFJkF781ky+EgBCSMqLKhu691riDAwX3K3FZnRFph16ZKPvM9+ODzoGh27dQAt5 UJStz3UWdAKXoWgBbzrxsd3gqoudQ4PKIznWL6oL3UDd90kDovhl5x3C36sglAcVAIJB VOHp5b8asTRsczl3op8aiwaHdtaOrJNZWIyyUmH7sZyOXkWexHIgPDlNR4jXC2tsAMWR iWoL44gMuQPpFnjKMKlJ+17XMni09sPDRTGnAA8Wq9ziKmzeEooID5YflnqxRj+D4Nhl 3JZg== 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=avz9T8GOBPABhBmSIsHgU50Z7hweQE1QXsViuQmCEHE=; b=IDVxrQeiA+2/hCAnNqGxOfxLE3aEX9V32Hp31VqW6ayzyOv4ZCaqZD2TfHeu7YuVXZ kFMBUbiX6rwngcatBf/lGXYJG9YNwWWe7wcyT8XGQVWA8GHxCir63dMSYBNXerxaOlOw Cs0/ZKF8o99fGKHy7niOCj7vzYrRiictgYnfhabR37Tgplw7j7yWBIrqs2iZ9vJ+FxXd bIdW/mCu872jJQpIyUL4SktfJn4S3DHsTv3DB4ccFTDAFEV5pBRY7g4RkRWC97vqgY9R hK7+dQlYGgy0h9dULStJYW0y1zDicsCkTxQ0v+uAiZzy23/HY1HUSURaTVCrO3nuYrZJ 8VJQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IigHg9hz; 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 s20-v6si9046393pgv.668.2018.05.15.01.12.51; Tue, 15 May 2018 01:13:05 -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=IigHg9hz; 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 S1752575AbeEOILW (ORCPT + 99 others); Tue, 15 May 2018 04:11:22 -0400 Received: from mail-wm0-f66.google.com ([74.125.82.66]:54947 "EHLO mail-wm0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752410AbeEOH7h (ORCPT ); Tue, 15 May 2018 03:59:37 -0400 Received: by mail-wm0-f66.google.com with SMTP id f6-v6so17674144wmc.4 for ; Tue, 15 May 2018 00:59:37 -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=avz9T8GOBPABhBmSIsHgU50Z7hweQE1QXsViuQmCEHE=; b=IigHg9hzKXInLNSazSlvzd/bR2qGTRL8G3P3bTltflzQol4TLeVwlUK/fmStO6Kt94 9Avid3NoLBo4pcJBifXhBGYACB0RmtgmRIwzBK82zZDx+DxpXBLxmprX9bDWpcac4ScY /2yovhVUEoMUnUW7RFuYhIO9VX5Ev0vf0d1As= 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=avz9T8GOBPABhBmSIsHgU50Z7hweQE1QXsViuQmCEHE=; b=RREzTFCp6hgIjkzwkqIUxLnNDfnGwqDZZvstF0566xCCQ18f7Ymgnp0m2wtpMYft36 RXys4UUJYBXVq9pfl/K9/bslLB/YHBeSYiqJTjqtpZHRAM772JSHYaMNqty6HScQ+TOQ 5qv25AzxNwm0m71fFDuCCKBP/rmyYOYjTEzkhlFZpPYYi38FKfVBUXjKwPE/dC84pT6J zC4QCpNlsBvXer0NqwIyv/7H3FiaXW8nNSLn3kSbHeGUdRQE5TrjWS8gAX+LYthSTAxJ eXd/IiuSD0WIMemdolhCPzNyau/JkmAiwQh++u6f4MNK1vjgPZ3e90QgC5tpPpd1az50 9Gvg== X-Gm-Message-State: ALKqPwdG2bD45M+QmXobnAibSplE1k9YAGT2WiPVAwpzfKFYoHgl8sBA l3vZ+WY0iqWErE2k2PuYHVLhUg== X-Received: by 2002:a1c:424f:: with SMTP id p76-v6mr6584366wma.15.1526371176773; Tue, 15 May 2018 00:59:36 -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.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 15 May 2018 00:59:36 -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 09/29] venus: hfi_venus: move set of default properties to core init Date: Tue, 15 May 2018 10:58:39 +0300 Message-Id: <20180515075859.17217-10-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 moves setting of default properties (firmware debug, idle indicator and low power mode) from session init to core init. All of those properties are need to be enabled/disabled early so that they could be used before the clients are even initialized. The other reason is to set idle indicator property early before we enter into venus_suspend function where we need to check for ARM9 WFI. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/hfi_venus.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/media/platform/qcom/venus/hfi_venus.c b/drivers/media/platform/qcom/venus/hfi_venus.c index aac351f699a0..284da69eb81b 100644 --- a/drivers/media/platform/qcom/venus/hfi_venus.c +++ b/drivers/media/platform/qcom/venus/hfi_venus.c @@ -1090,6 +1090,10 @@ static int venus_core_init(struct venus_core *core) if (ret) dev_warn(dev, "failed to send image version pkt to fw\n"); + ret = venus_sys_set_default_properties(hdev); + if (ret) + return ret; + return 0; } @@ -1134,10 +1138,6 @@ static int venus_session_init(struct venus_inst *inst, u32 session_type, struct hfi_session_init_pkt pkt; int ret; - ret = venus_sys_set_default_properties(hdev); - if (ret) - return ret; - ret = pkt_session_init(&pkt, inst, session_type, codec); if (ret) goto err; -- 2.14.1