From patchwork Fri Apr 2 10:06:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 414350 Delivered-To: patch@linaro.org Received: by 2002:a02:8562:0:0:0:0:0 with SMTP id g89csp1285289jai; Fri, 2 Apr 2021 03:08:03 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwep5VCxhkXlDsbfPjjp9nk3RlT6zGLCUP/rqdg196aQcA1Sz2935BD1a2DzTmpxBMpRsNa X-Received: by 2002:a92:d58a:: with SMTP id a10mr10646106iln.63.1617358083245; Fri, 02 Apr 2021 03:08:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1617358083; cv=none; d=google.com; s=arc-20160816; b=gP2hwU4TXr5NiQVKBcazAWF/wYm/QYe9GzIEoPb06C+vpE0L7eXW6jQEVAswSQ/0LJ k3qxPVOKc45KkB2h07RsV7/dh/RPYLUx3zX9zmSmOxmxt4i+ItrI/Gw0Xs+c3+EJ9ftb eNOFK2LHEt+Aw5bWx2RD57bL1tBUwqnXZ4TG3js4AAMLGr0xNq0rr/oxjczJS+wIuFdZ 4LWVwR3IgBciOgSkkp/ZTZemPdm0Zg6vStDli+a7I0N+lC3wdSVWklYiX2T9LVk/GTut PB6wsHAcwJicnAECTci3Va1tWUuw36h4QnHHwgR2oZTwGjmYZeDqalrVxi9EJIS5Ugv2 i/RA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=mdYuWwgCAgpe/tpCk/WPHQPCQeWl/PCSYj7cNktgbbg=; b=nYi6sarkAgc82+u4SOgBRlvHQD8CqXO0M1SJMf+VwsaECl6sZrIooB1c59mEknDeXU sO9wuul1Vb/LKkpf+hdYPSlpo7ZpYhdVur8EwkaWAA5rs7s/YMxm7QQIgbFzXEypOCYy /wUwZsGV2Y4ZJs4Cljoe9pGZksM6HQ1XGKHWbd3jaTq3M7KCF6Hd3DL99UVKNmECu2Ed YOhE/J9DfZmr5xrp3Om4+K+QTiH6rPQT9DRhRAKL0qLd8o7Lsh35gGkmu2xaSbWaYUd8 IflkIcNIX80gwGmF6zAPb2ltrmwL2/5kCo1OQn3PJ21KrGuAh7TWSuhBXnhwnXL4wUut K9sg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IQjVngta; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-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. [23.128.96.18]) by mx.google.com with ESMTP id g2si6942838ile.30.2021.04.02.03.08.03; Fri, 02 Apr 2021 03:08:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IQjVngta; spf=pass (google.com: domain of linux-arm-msm-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-arm-msm-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 S235162AbhDBKFq (ORCPT + 17 others); Fri, 2 Apr 2021 06:05:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45510 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235077AbhDBKFo (ORCPT ); Fri, 2 Apr 2021 06:05:44 -0400 Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7982AC0613E6 for ; Fri, 2 Apr 2021 03:05:43 -0700 (PDT) Received: by mail-wr1-x435.google.com with SMTP id x13so4293058wrs.9 for ; Fri, 02 Apr 2021 03:05:43 -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 :mime-version:content-transfer-encoding; bh=mdYuWwgCAgpe/tpCk/WPHQPCQeWl/PCSYj7cNktgbbg=; b=IQjVngtaEmv8R+bycJCfbeb4LCx60QpT0m+RAJ7LHyxaDRtdLhSMJhkSHcwO4e8XgA qr/emy+/hycZKPNrpCfCLWFZ7C2KdgVGXEoJTuuISSotKViPbeDBZ21AmWYhZ+45p0vq a+wo97dJNDZqIuflUgjpLT1sAu3WZT0y64ZyuweW5oyW3SFNCjLMrfX2hqf2zeOMkR3b K0Vo7cD7WjFu46mC7zjzgnj9GjBsDSMyX9rXFf1FTmKe3ltntKD0T10mu3Cw/5g5b2W8 9lSL+1di3+oO+MKHIDOmaDQKTqpfstQXJH0vJD3oty4AfqU/WXthLzC8A5YcYrGHk/U6 /pZA== 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:mime-version:content-transfer-encoding; bh=mdYuWwgCAgpe/tpCk/WPHQPCQeWl/PCSYj7cNktgbbg=; b=KvKOjeFrL0Zipo0E4pDkQKP6G23QEc8ot/et3KJ961DQSgGXr/0VVI0IZNdF0pTAcG fkp4CTS49NpC1UnWUIEwPyKZC79WxKqlR/GS+2FAhqsIikVnoQrMeEbz+nvoen85XbIv ToGCyublxoVpdIC9BepSHUuDaz0md+jY7fhg+FRfwnHCLQwcalanfiHtbjBG8fB4eDnT sUUFTTadljPOevFqx16fR5K0iAfUX4ejcvf/HRtzZRhBNz6Ub9Y53e2u2BGUD+16hNSo 3mnhgLJixxHznbMrijHDTC8lOoPBFo8Qa4sBp/mInc5wDX3e4PDg09bWCBfYzVUrKv8c DRiA== X-Gm-Message-State: AOAM531Q5Z9NqqhA1zv2wAAD2IjYbbTB9zqsaS8/qeB7LDWjevfACoeG gYRrswF8YyNfS0ks5eXZSnob6Q== X-Received: by 2002:a05:6000:1acd:: with SMTP id i13mr14378546wry.48.1617357942265; Fri, 02 Apr 2021 03:05:42 -0700 (PDT) Received: from sagittarius-a.chello.ie (188-141-3-169.dynamic.upc.ie. [188.141.3.169]) by smtp.gmail.com with ESMTPSA id v18sm15466618wrf.41.2021.04.02.03.05.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Apr 2021 03:05:41 -0700 (PDT) From: Bryan O'Donoghue To: stanimir.varbanov@linaro.org, agross@kernel.org, bjorn.andersson@linaro.org, mchehab@kernel.org, linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org Cc: bryan.odonoghue@linaro.org, dikshita@codeaurora.org, jonathan@marek.ca, vgarodia@codeaurora.org Subject: [PATCH v3 25/25] media: venus: vdec: Fix decoder cmd STOP issue Date: Fri, 2 Apr 2021 11:06:48 +0100 Message-Id: <20210402100648.1815854-26-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210402100648.1815854-1-bryan.odonoghue@linaro.org> References: <20210402100648.1815854-1-bryan.odonoghue@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Stanimir Varbanov Fixes an issue when issuing a stop command to the controller, negating the following firmware error. "SFR message from FW: Exception: TID = Unknown IP = 0x3b7dc FA = 0x0 cause = 0x6" Signed-off-by: Stanimir Varbanov Signed-off-by: Bryan O'Donoghue Acked-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/hfi_cmds.c | 2 +- drivers/media/platform/qcom/venus/vdec.c | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) -- 2.30.1 diff --git a/drivers/media/platform/qcom/venus/hfi_cmds.c b/drivers/media/platform/qcom/venus/hfi_cmds.c index 0bcd434e7876..fb64046d1e35 100644 --- a/drivers/media/platform/qcom/venus/hfi_cmds.c +++ b/drivers/media/platform/qcom/venus/hfi_cmds.c @@ -254,7 +254,7 @@ int pkt_session_unset_buffers(struct hfi_session_release_buffer_pkt *pkt, int pkt_session_etb_decoder(struct hfi_session_empty_buffer_compressed_pkt *pkt, void *cookie, struct hfi_frame_data *in_frame) { - if (!cookie || !in_frame->device_addr) + if (!cookie) return -EINVAL; pkt->shdr.hdr.size = sizeof(*pkt); diff --git a/drivers/media/platform/qcom/venus/vdec.c b/drivers/media/platform/qcom/venus/vdec.c index 0fe4863371e2..04f457cbf631 100644 --- a/drivers/media/platform/qcom/venus/vdec.c +++ b/drivers/media/platform/qcom/venus/vdec.c @@ -515,7 +515,10 @@ vdec_decoder_cmd(struct file *file, void *fh, struct v4l2_decoder_cmd *cmd) fdata.buffer_type = HFI_BUFFER_INPUT; fdata.flags |= HFI_BUFFERFLAG_EOS; - fdata.device_addr = 0xdeadb000; + if (IS_V6(inst->core)) + fdata.device_addr = 0; + else + fdata.device_addr = 0xdeadb000; ret = hfi_session_process_buf(inst, &fdata);