From patchwork Tue May 15 07:58:36 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 135830 Delivered-To: patch@linaro.org Received: by 2002:a2e:9706:0:0:0:0:0 with SMTP id r6-v6csp668156lji; Tue, 15 May 2018 00:59:42 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrgaNbvuu3YJAcB8MfPIEALSxPW6dulhTR/rxKY6tDxwp2wy7orAyKdWIA0qPKWZNhmMeiE X-Received: by 2002:a63:9512:: with SMTP id p18-v6mr11052469pgd.183.1526371181921; Tue, 15 May 2018 00:59:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526371181; cv=none; d=google.com; s=arc-20160816; b=umRVizM1Xn8zy2UByC2Gu5P9WWzg5tCZwMsFaFYdkonqHRrQWjukoxE9AnJudR4H8v EWE/lcqzufZI0IMtRGDKn56NRke70cmHfzv2zj8ll5CUyhjEDhfy/ikpFB931ak20Zk4 LS57ojhW2jdcg1v6Id4ljL9AVOARtBg4Vo1LLmtyiAH0CHzcnBPsvOiVzqozn1KJvNOO EKGt9i3tL6y8DPwE8I5I+sK6hP3q7GrjFDJFmM3K68nG5tZ2EUKTk6qET+lk6HrAEJwv daZRle3wJxgDv6RKEbEGKjZB3+hsip55rHBRZ+p5UvKq4+XTgaCgI+1vAHUXYUyXZtIs iS4w== 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=l7eWwx060UJkZofhnU08VjnBmb5ZXk8vei9+yemmMhc=; b=WkF8Ywm1amYIc0cGRe0Goz77KGP3mwpe1KnKxSTJ1QVZ0gZSplwjR81e8z7tDPf5w8 8mwayybO/JCTYWsDbmI6MmUmuwQ2INS1UL8vwSKEqZYUEHgm9w1F73v32xMwojPY0NJN TVSamwH3oAlZ0dGAb/JYpPDiHSfEV444n4j/zoJZWCYnuJdRHOm17Bv11snJ2nrYHxEt FG160GOxv/Xu3Qk+el3UewbbRDAOWwbmwEaOJvZIHIAzyjjxVuvotABCkX67V9GcLQ89 xNSn2yX7Cu4d30rnh+0izXxXu1WA64fwKC08TKNDgAbLZTe2lh6AYngUDsTwl2qMArPZ 0WZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=C1P8Pikn; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=fail (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 a65-v6si1564927pgc.503.2018.05.15.00.59.41; Tue, 15 May 2018 00:59:41 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=C1P8Pikn; spf=pass (google.com: best guess record for domain of linux-arm-msm-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-arm-msm-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752537AbeEOH7j (ORCPT + 13 others); Tue, 15 May 2018 03:59:39 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:50646 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752188AbeEOH7e (ORCPT ); Tue, 15 May 2018 03:59:34 -0400 Received: by mail-wm0-f65.google.com with SMTP id t11-v6so17686700wmt.0 for ; Tue, 15 May 2018 00:59:34 -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=UJY1ElvCAePNUPkqjsGk3ZluUk9SleoeEVToFWcXc0U=; b=C1P8PiknuPwX3hDZMWhJntybejNb/CoX7QR4pYi6WT/3lDZwLB9BSqM53d+U8Ij19/ w+ZKNA9kIpCtWHWgOlw9AhUkqTOmkfOpkD+qkL43oQLc1rq86TJVrEe8C9OGrGdGHUak GDPojQmhO7yBLf9Kh+/M0JHEF3AvIAp6KvYic= 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=UJY1ElvCAePNUPkqjsGk3ZluUk9SleoeEVToFWcXc0U=; b=Ey35mHrKKBnHEZ2t/njAdhAkk7c7M0uQbEB6eqsNd7I68dOUMHic/wajG6i0HonboD BA1cKfwNYnJwzrCC2QwncIh/cug3gYr4pDtOtzeQk1IvWam8s+yq5tJqfcNm4e8UqI9f Vkvj15e+qNzzRJKYdTcWSOF/rhB+U8ABJ1hSsn49ZjFWzTv38Pm/1i7oEfCaCJtTzLfV Ni7FUC21ms0eblRfapn1TDCTHOHpqq4Fv6ZTbKrPvES4M9pDP2nhxOzXFdS+NXeBR9jt HsHizN+gdYyGODKzUY/AUwwXGr23tHqe1+tcF2KS+lVyGM4ezsyxYmbSYMHGlBygxT0/ 9HTw== X-Gm-Message-State: ALKqPwds2e3idADPNFuYTwWJKACvZKZG/c3nku591wjwasJ2Tmo/h8sb ldQ7gBIqoaPCsIBjgqEmiyOvESVXHvI= X-Received: by 2002:a1c:3313:: with SMTP id z19-v6mr490564wmz.48.1526371173836; Tue, 15 May 2018 00:59:33 -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.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 15 May 2018 00:59:33 -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 06/29] venus: hfi: handle buffer output2 type as well Date: Tue, 15 May 2018 10:58:36 +0300 Message-Id: <20180515075859.17217-7-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-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org This adds handling of buffers of type OUTPUT2 which is needed to support Venus 4xx version. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/hfi.c | 3 ++- drivers/media/platform/qcom/venus/hfi_msgs.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) -- 2.14.1 -- To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/media/platform/qcom/venus/hfi.c b/drivers/media/platform/qcom/venus/hfi.c index cbc6fad05e47..a570fdad0de0 100644 --- a/drivers/media/platform/qcom/venus/hfi.c +++ b/drivers/media/platform/qcom/venus/hfi.c @@ -473,7 +473,8 @@ int hfi_session_process_buf(struct venus_inst *inst, struct hfi_frame_data *fd) if (fd->buffer_type == HFI_BUFFER_INPUT) return ops->session_etb(inst, fd); - else if (fd->buffer_type == HFI_BUFFER_OUTPUT) + else if (fd->buffer_type == HFI_BUFFER_OUTPUT || + fd->buffer_type == HFI_BUFFER_OUTPUT2) return ops->session_ftb(inst, fd); return -EINVAL; diff --git a/drivers/media/platform/qcom/venus/hfi_msgs.c b/drivers/media/platform/qcom/venus/hfi_msgs.c index 5970e9b1716b..023802e62833 100644 --- a/drivers/media/platform/qcom/venus/hfi_msgs.c +++ b/drivers/media/platform/qcom/venus/hfi_msgs.c @@ -825,7 +825,8 @@ static void hfi_session_ftb_done(struct venus_core *core, error = HFI_ERR_SESSION_INVALID_PARAMETER; } - if (buffer_type != HFI_BUFFER_OUTPUT) + if (buffer_type != HFI_BUFFER_OUTPUT && + buffer_type != HFI_BUFFER_OUTPUT2) goto done; if (hfi_flags & HFI_BUFFERFLAG_EOS)