Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp6580069imm; Wed, 27 Jun 2018 09:47:40 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdCw1/h5qQCO+HTg7K8Y6fZf5NLWeQb1ZzleqYmnRc2sS5OZoRj6FcyLUpcG9aEKJuMaREB X-Received: by 2002:a17:902:8f86:: with SMTP id z6-v6mr2490518plo.38.1530118060589; Wed, 27 Jun 2018 09:47:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1530118060; cv=none; d=google.com; s=arc-20160816; b=eyT1JsL102Bb2GpPNzM63K6wcRRBYKk9AbXx/ih9zI69xPEEAS1DVDW1MvnCW9WamY V2rJSxjCmbt3d7nGEhYZMI3n99KKnpJPpUDtYrk2a4BJka2IrvgmiJXGYoVphlOwjCcv 7DvtExHvqYYsfYHZ0O2J9voU1hw1N7j6x7XUDK3BTXboMEBufpaJItvng863u8tyXUgw ylarXZ2336XT9czRZMrBCeVgDckc/ljTPusO0dqzTKqVhqafYU8TQK+CLIhU4Y603Aqc Ed1HNaFVyd0WLO+qY5KAQS3BEHUVO4KN1M4zEylJlnAFqAAQMzij/H98XBC9+YK8n/ZV G0hA== 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=DopT6tfRa5ZXddiWA2KYWqHxQ5fQ330DwA7mzNfZ1z4=; b=NI9mBgHlsepfFAILdymhaa4QNCYfId+sUHSSQt/OCOh7fF9gaMm/MltA1ozRk1eHqg Gk1k7Vpu0vTTcebzDA7CD+FdZ3tl+BPMGh3BFKQFSAZJ1iqyfFHN940PciTVE1Luvo7z C4kfPMUxIeD0Q21Zwt1QtNEZhLqyG2ai8Xg2lOsElaw6Ol10LIrwqHSlUMfzqJ18qsD8 d3A+ss79PyR5j0JugKgMTfAPD1514pKVRdv3DxtSiNKKoK1UtLDvHcifI1zUG/5KfT+y gIJdKhq7EIqTnxsUQBCRFGYAbMWnBu9x21Viblp9ppA9fPRZHMoVN3wjdMlRUbLqoGjt CSoA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RTTIUh1N; 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 t123-v6si4276765pfd.13.2018.06.27.09.47.26; Wed, 27 Jun 2018 09:47:40 -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=RTTIUh1N; 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 S965537AbeF0Pew (ORCPT + 99 others); Wed, 27 Jun 2018 11:34:52 -0400 Received: from mail-wr0-f195.google.com ([209.85.128.195]:41848 "EHLO mail-wr0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934639AbeF0P2F (ORCPT ); Wed, 27 Jun 2018 11:28:05 -0400 Received: by mail-wr0-f195.google.com with SMTP id h10-v6so2468123wrq.8 for ; Wed, 27 Jun 2018 08:28:05 -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=DopT6tfRa5ZXddiWA2KYWqHxQ5fQ330DwA7mzNfZ1z4=; b=RTTIUh1NszVoP/tmJF2cGpBKo3PWNyEcYbh7tdayfs5Z+EgDM4BA0/5xTEokTLG/LY /95pr2bp4ocyxMdG6PcNQhuwWys59pCt0g7vM3t6EA1xpm9BGqkpU/jqzuD++JJEUxOS Wy8DFHjD3HOZG1iH4Avy5Fvm1GL+c3wh7CaPc= 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=DopT6tfRa5ZXddiWA2KYWqHxQ5fQ330DwA7mzNfZ1z4=; b=b/f+2B1N4QtqIPpZJKt+xELFx0r5cH/KAqh85snxyLwQ0NyohEcG5bEsfsKK4I6hJK efpoXtg8go2Y7LxbbrIEKsabr5/fAZdxfLGPmclEToJFGfH2xV3I3Fs1NV3yNp9I3w19 oI6eRIeE0RUk2xTO6Y2SnTSonc2iwuZCfj0HI1RK05ruwiEBmFMBnN7rlclogkIDjOuY z+FVk+vJeJO4nzSOfWEC1cgsdWFE+Z6zGCf5bh1d9SW7BqCy5N3Y2Xz+ZCkA1s6SsQ7s RVIaJXIZf/GGdz4GuaO/Ko7cPIQ0D7+hSpcMV165LmtmDSqVWVvyxHPn6hsziuExDfh0 rW8g== X-Gm-Message-State: APt69E2wDkpKg9gpZha0sA+8LbeIyZgNiq6akbrqfDCHSjso/RwaM7rJ u68JpBaZof3hbi7shRcT9rrozRnSc2Y= X-Received: by 2002:adf:e590:: with SMTP id l16-v6mr5281175wrm.190.1530113284727; Wed, 27 Jun 2018 08:28:04 -0700 (PDT) Received: from mms-0440.qualcomm.mm-sol.com ([37.157.136.206]) by smtp.gmail.com with ESMTPSA id o203-v6sm2916075wmd.30.2018.06.27.08.28.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jun 2018 08:28:04 -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 , Tomasz Figa , Stanimir Varbanov Subject: [PATCH v4 06/27] venus: hfi: handle buffer output2 type as well Date: Wed, 27 Jun 2018 18:27:04 +0300 Message-Id: <20180627152725.9783-7-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180627152725.9783-1-stanimir.varbanov@linaro.org> References: <20180627152725.9783-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 handling of buffers of type OUTPUT2 which is needed to support Venus 4xx version. Signed-off-by: Stanimir Varbanov Reviewed-by: Tomasz Figa --- drivers/media/platform/qcom/venus/hfi.c | 3 ++- drivers/media/platform/qcom/venus/hfi_msgs.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) 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 54cd41e5837c..c0f3bef8299f 100644 --- a/drivers/media/platform/qcom/venus/hfi_msgs.c +++ b/drivers/media/platform/qcom/venus/hfi_msgs.c @@ -823,7 +823,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) -- 2.14.1