Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1645532pxb; Mon, 8 Mar 2021 02:53:53 -0800 (PST) X-Google-Smtp-Source: ABdhPJwHDnCMHmiG9xM6O1EgXSerQRirZRCGdDljSz6m3zZjmhjxFeiph4Th+JDIDMYlkqn2yiOx X-Received: by 2002:a05:6402:26c3:: with SMTP id x3mr13527734edd.126.1615200833351; Mon, 08 Mar 2021 02:53:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615200833; cv=none; d=google.com; s=arc-20160816; b=0+9LaIFh/TSP2z/Q/KDy4jZdLk8aZv5+qnswhLCCfOQEbW+UIZVoJSWNKNOweH9XLf wS+fs/5BPpWc5/4Qx051bAagbDBKOgLJpNBbuLm5kFhloyrShsYR3CwW4mFu3/CiK96k 61p22ls2xfmTEypXh6T+bzUtoUoIqQJx1hwMpdIz/ZwLxHn4McVl6m26Qt3n2EpmR6Tu kOOfTpN2SPXVIlXFUE9jrQvdTgfvneY9HN1ayj3kxtTlWEmHccpmT8tdJr1186G9u1tX Oo6CGov0NxEUKoO2d6uZWozCK9wbH5Hnm4ZBSG/X1TankNE6Mel2O/9DCYL61j+fv2H6 1INg== 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=a1XuaInoR0tuPlY8Xeovw7fyTewNoHYbnAtL2fQF1jw=; b=eXnHGqXmtKJAhyGl8YW9W8+9FSsXuqeCS/2GEY80kg3YxHXlWgzRRuk6dIt5bOXdhP aPgI7tJwGtiWDiC4M3cSdqZB+KMPjCNk3yX/aKOTYj648cP8uLppa3av721Qtplk+8wk ZbdMypVpNYjAihyDmMC1iLegQ5KveD1783+bLVciVwh27DTGVVT3PB2giAOnWSvCrw1L +D7VYCDfm6M6qbkWeu/Abs5585DP+fGDcd1WsI0+GE2tjIyVhr/HFh80t+vB6uICcmK6 B1r75uauNWm3J9wxWRMyRtbEybzlw4Uw8+cR5PrWtH9RHXTWEIQeuDDa3ZQQSpNVt1Ui hAHQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=B6EOG3eE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id g12si6437662ejd.256.2021.03.08.02.53.31; Mon, 08 Mar 2021 02:53:53 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-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=B6EOG3eE; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S231215AbhCHKwg (ORCPT + 99 others); Mon, 8 Mar 2021 05:52:36 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37796 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230455AbhCHKwZ (ORCPT ); Mon, 8 Mar 2021 05:52:25 -0500 Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 39759C061761 for ; Mon, 8 Mar 2021 02:52:25 -0800 (PST) Received: by mail-ej1-x630.google.com with SMTP id p8so19345007ejb.10 for ; Mon, 08 Mar 2021 02:52:25 -0800 (PST) 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=a1XuaInoR0tuPlY8Xeovw7fyTewNoHYbnAtL2fQF1jw=; b=B6EOG3eEDx+Oq57f8XKABz8GGzN0l2eN6WPn8VX6m4aDlgPmjORd1DkwyCup85xFv9 md/fvXE7/rZ/ZdyT+mHt4QU7hohPSHIQ4PSd5RVHkBwZg3Mg76shM8kQizn/2IJNQaTi 4DHbm2JTmTy/uQqdiT0IO8iv2s7BZLf90C0HEZkWInFBREhFnQlhZkaaoj/51mVu3jVB hycNuaCsudNIvFqSITsfzDXS4mmVXbyJDTAJOSqG9SNtfjXosX0VWtQslSH3cn2Kwc6i ObkYDgZd6oJKcQjbQ4PnAKIR7Ul8GBJk6PLXa0B60m1DKWyylB76nCigzyzvfbY/kAUg fdEg== 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=a1XuaInoR0tuPlY8Xeovw7fyTewNoHYbnAtL2fQF1jw=; b=n+bRGKJBK/E9kPuLCpklWoo9vk8hvi4wetQXdeITMhptQvAybvJafiIKdbgPWjXYAh onEXxc6xSK3k4mzVQyME+l5wWaS3GAUfKzYibBU2ETY/tkOwreabR2AH4LCZBcV7WTMl RYSfU45Nymtf9O1uN5kNgVH3E7HQtSlHnjEL+pIVN6N7NoEi7QD7BpVB2j59TyiYd98Z FU7m37b8lPvGoPyx/beODnrK4AN9H4FPA7c4XTT9xV2rnODR9Wi6Bg6NQuIZfXS7eVPh PO8es7T/JHtfWEZ8DIxLpOdP7HjWGGr2lawxhgn+w/6BDdeJB2xd2/90hme56uPer9uj HhIQ== X-Gm-Message-State: AOAM532b8UhXFDznqDLeoMZ19kKd+GKvFuX106npK8CvoL0g7nFIhYXR WHWvRcY9llc3JeJKQoprZSTvRQ== X-Received: by 2002:a17:906:e84:: with SMTP id p4mr14252657ejf.30.1615200743927; Mon, 08 Mar 2021 02:52:23 -0800 (PST) Received: from localhost.localdomain (95-43-196-84.ip.btc-net.bg. [95.43.196.84]) by smtp.gmail.com with ESMTPSA id y9sm6386297ejd.110.2021.03.08.02.52.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Mar 2021 02:52:23 -0800 (PST) From: Stanimir Varbanov To: linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Cc: bryan.odonoghue@linaro.org, Stanimir Varbanov , stable@vger.kernel.org Subject: [PATCH 1/5] venus: hfi_parser: Don't initialize parser on v1 Date: Mon, 8 Mar 2021 12:52:01 +0200 Message-Id: <20210308105205.445148-2-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20210308105205.445148-1-stanimir.varbanov@linaro.org> References: <20210308105205.445148-1-stanimir.varbanov@linaro.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The Venus v1 behaves differently comparing with the other Venus version in respect to capability parsing and when they are send to the driver. So we don't need to initialize hfi parser for multiple invocations like what we do for > v1 Venus versions. Fixes: 10865c98986b ("media: venus: parser: Prepare parser for multiple invocations") Cc: stable@vger.kernel.org # v5.10+ Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/hfi_parser.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/qcom/venus/hfi_parser.c b/drivers/media/platform/qcom/venus/hfi_parser.c index 7263c0c32695..ce230974761d 100644 --- a/drivers/media/platform/qcom/venus/hfi_parser.c +++ b/drivers/media/platform/qcom/venus/hfi_parser.c @@ -277,8 +277,10 @@ u32 hfi_parser(struct venus_core *core, struct venus_inst *inst, void *buf, parser_init(inst, &codecs, &domain); - core->codecs_count = 0; - memset(core->caps, 0, sizeof(core->caps)); + if (core->res->hfi_version > HFI_VERSION_1XX) { + core->codecs_count = 0; + memset(core->caps, 0, sizeof(core->caps)); + } while (words_count) { data = word + 1; -- 2.25.1