From patchwork Thu Feb 17 04:16:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 543357 Delivered-To: patch@linaro.org Received: by 2002:ac0:e142:0:0:0:0:0 with SMTP id r2csp97581imn; Wed, 16 Feb 2022 20:16:29 -0800 (PST) X-Google-Smtp-Source: ABdhPJx9yv8NTNLFo8ssAVbyzGCh1kENNh6qD27AXKQtylnjLcvFo2GTa3TxaFL1e4GQLjLfv8iO X-Received: by 2002:a17:90a:b015:b0:1b9:e11d:3a78 with SMTP id x21-20020a17090ab01500b001b9e11d3a78mr5353727pjq.42.1645071389025; Wed, 16 Feb 2022 20:16:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645071389; cv=none; d=google.com; s=arc-20160816; b=hqktw85dvkTj+pLZz04+jHiKVzQZO03Mf0mCy97YJ03JB/PjqU8CYCUNtcLdFEOFXQ 1n9Rpo9gsaepBKNJZ1+KgxQrNb1l+rdemnDwuzYJkmWFSOG6lnoirGiPaf4FC0U6NPJ4 TXFEFq4lA4V8M2my+aLW6mm+fmiOIxxdseExaODoMbhNYs+/xZIPXYM7kAcUCenyvU6U XNPbRQUtAqu8LeQGw85FcjbAD5YN99ErX8rT6p/xzPgxxoAeEU4KuoH1CvZunwbAvEHJ Ah2a6oHCWwdh6o+r/RVimANChnV3XOQ2/xAvwDgjMACnDC+kb0VuUivXC4GT65xJIjiH nc6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:to:from:dkim-signature :delivered-to; bh=loQg9Lv88UsmY/ReqbxoXCP0a5sJwzcAHa4A0tvMWIs=; b=YtwQqA0hYVRUVaCdPBscYhcTnsKV8JeOGPotZ63DTlnatMw7Io6NuyWTn/hrRPNurN N0BatSHvjLVb/GYwmmDMJrOqsc1T+PdDNRvmoFVGGg+THJErA0m4fmC7Ta1yKetg8TE8 5pPxE+yfjwkg8kbPXEP9RFtNCdQLyhrCtaSjcP30DTPTVti0/glC8Lst+vlTLcunP2ME SV0M2F58aacT84TbooiUytmdhXMPQ889wMF3uQazak9ZfcE2HNfui3zag7VqoqTWcj2y IRaIN6WUJVlxDk8XOJeOmQVtWatKOu2xNSYEEUf5RuZ3QGln6t1fouA+4P5jFpgOZH7S 70+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=AzFuca5f; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTPS id h16si5413867pfh.345.2022.02.16.20.16.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Feb 2022 20:16:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) client-ip=131.252.210.177; Authentication-Results: mx.google.com; dkim=fail header.i=@linaro.org header.s=google header.b=AzFuca5f; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 131.252.210.177 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DEEAD10E747; Thu, 17 Feb 2022 04:16:21 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lf1-x135.google.com (mail-lf1-x135.google.com [IPv6:2a00:1450:4864:20::135]) by gabe.freedesktop.org (Postfix) with ESMTPS id BBC8E10E796 for ; Thu, 17 Feb 2022 04:16:20 +0000 (UTC) Received: by mail-lf1-x135.google.com with SMTP id bu29so7739136lfb.0 for ; Wed, 16 Feb 2022 20:16:20 -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:mime-version :content-transfer-encoding; bh=loQg9Lv88UsmY/ReqbxoXCP0a5sJwzcAHa4A0tvMWIs=; b=AzFuca5fyFdYdw6eKegri3YbNYkKo9TFBMH08tlGI52ZWeHBe3m0WtmMjkOzo7fH2M GtneKaRdUQVuePkl4ZqLFqTN+5BtdGE9lyc9tq+NcwbciJjhcW9FciRpVSdSXAqwpjL5 T/FX+3TorFhs+7M34ym/rHtn1PWNPGDfp9OfG3TUk6GyUhV9owo9yehPlR3r5F9PYM1F oZ8r85FnlxXWRxgghC2IYcKfn3c71EO4qgrkhtqZW8P/cOgpBrI+bPb1A28NYJg5iuzH siXGcvYeI+LhQK9kgFRcolK+E5alJ8pfSlx1cjn2lIB7FS4d1ndG0onXCMqrhrYlrx7d EREQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=loQg9Lv88UsmY/ReqbxoXCP0a5sJwzcAHa4A0tvMWIs=; b=ntxRg5a2/2Dts0B39QhltMtCXWEmZC/ri79G0Q+GuEFyMmbv7skmPrsfC688RnhxOe 4toW2ZgRI29XUPNg+Edv1/88uWsg+PwtLyRsRqLWW741jPsCS1s2Am+d8f/pWg5RhUCw hAqvJSVKr5AbZkH5fTji08B5+74lRekJAEnpqMbynUJMjaElhmLScoaqZKeYzIhg1tEU JikS12wdIhHAAoIt4dLQSjUsqBZ9HJ4KpLSIm6s7rbjZV4uykVXObT5Afxmpro8JMv4T s5h8i81NSwODHfWxMAJNn+MDOQ5yWDpyd8NF1kcrGc0Y/GVjCM7j0mUy5FxcinrW0hEr Kzmw== X-Gm-Message-State: AOAM533HS1bGlcpfs99e7+Uq/QGkkFXhn4HfYLavrdMkxcIz0t/I6Can WveHec35o2r4lyOSCkLdDeNqKPGsy8/Tsg== X-Received: by 2002:a05:6512:3ba2:b0:443:6701:bb04 with SMTP id g34-20020a0565123ba200b004436701bb04mr787098lfv.644.1645071379010; Wed, 16 Feb 2022 20:16:19 -0800 (PST) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id k16sm2452349ljg.25.2022.02.16.20.16.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 16 Feb 2022 20:16:18 -0800 (PST) From: Dmitry Baryshkov To: Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar Subject: [PATCH v2 0/6] drm/msm/dpu: simplify IRQ helpers Date: Thu, 17 Feb 2022 07:16:11 +0300 Message-Id: <20220217041617.470875-1-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" This is the second part of https://patchwork.freedesktop.org/series/91631/ reworked and cleaned up. Changes since v1: - Use ARRAY_SIZE() rather INTR_IDX_MAX when clearing irq arrays. Changes since the original pull request: - Split applied patches - Add unlikely and WARN_ON in dpu_core_irq_register_callback() - Remove extra checks in dpu_core_irq_unregister_callback() - Remove unused arguments of dpu_core_irq_unregister_callback() - Clean the cb and arg in dpu_core_irq_unregister_callback() - Split the last patch. Leave enum dpu_intr_idx intact. Pass irq index, callback and data directly to dpu_encoder helpers. Dmitry Baryshkov (6): drm/msm/dpu: remove extra wrappers around dpu_core_irq drm/msm/dpu: remove always-true argument of dpu_core_irq_read() drm/msm/dpu: allow just single IRQ callback drm/msm/dpu: get rid of dpu_encoder_helper_(un)register_irq drm/msm/dpu: remove struct dpu_encoder_irq drm/msm/dpu: pass irq to dpu_encoder_helper_wait_for_irq() drivers/gpu/drm/msm/disp/dpu1/dpu_core_irq.h | 32 ++-- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 112 +++---------- .../gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 43 +---- .../drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c | 92 +++++----- .../drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 51 +++--- .../gpu/drm/msm/disp/dpu1/dpu_hw_interrupts.c | 157 +++++++----------- .../gpu/drm/msm/disp/dpu1/dpu_hw_interrupts.h | 12 +- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 27 +-- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.h | 12 -- drivers/gpu/drm/msm/disp/dpu1/dpu_trace.h | 53 +++--- 10 files changed, 193 insertions(+), 398 deletions(-)