From patchwork Mon May 2 16:53:14 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bjorn Andersson X-Patchwork-Id: 568768 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 93946C433EF for ; Mon, 2 May 2022 16:51:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345277AbiEBQzI (ORCPT ); Mon, 2 May 2022 12:55:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35132 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243123AbiEBQzF (ORCPT ); Mon, 2 May 2022 12:55:05 -0400 Received: from mail-oa1-x30.google.com (mail-oa1-x30.google.com [IPv6:2001:4860:4864:20::30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4468C6273 for ; Mon, 2 May 2022 09:51:35 -0700 (PDT) Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-ed9ac77cbbso4230029fac.1 for ; Mon, 02 May 2022 09:51:35 -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=K90a1QhJHpsQXxatRkh1e5e68HIkTPZWj4pLHJQIQOA=; b=FQdtOKJDpPgUqFOC6SLrbP7LwibhmUyCwt5JMP8J7hd8YFMu7yfmlKGGywt9yD2AzZ 4bNOCHHiB4eybvTS1NLlgDgqEqzaXe1WLrpi6/yEbiUSZF2iTfhDUcdd1aTSBJeMO0s+ RNrSMxkgJ+cDk16I0j3q/QuMvq9FTTHLpjVDaOXW87Soxx1WNnA4G05KHPsHX0Bt1RQA Che3UYlwJtgGsO1iyGUIuklvTidR98D2Ml6CHj7wHGh1HQDEJRNLfW0dOlqfrKO3it+q zq7mWXF6EKGzBH3tI8Ob+j4wTCs0Uu1e3d+TRSRlrso0O0Uq58gkXqcVYskUpugAfKiT Z9gA== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=K90a1QhJHpsQXxatRkh1e5e68HIkTPZWj4pLHJQIQOA=; b=EnChXjxoDZcuKn7OI+q8KGJPcE2AgvKDuMZUEqylGiRT4hFasMK5ERiQIuzsMCwNes FClDK9jEFbP6PF9X1Tnncp/shJQDcQv/eL0vkkPemtp/7jOBsr8kA/kxtiayQHqA4PFx 4Z1EWqm0jPZwRMXmyjTMS4d8I/HucT2u00KYHmPHidx40Sqmq9egdvztWZo5yfdGS9s1 Kxo1d5l8n6E9guFbtIODnuEBMNWpf6+5nvJaek4Ax/M9SGECtboPmiookn0LDLhhlekb NdJYuMA9xBoKLQ+ULALBX2URRVnvNk/fUx0lxuKmqwZDNnhnBzOhlI7REmpTj40+LlOD Mysg== X-Gm-Message-State: AOAM5324XZImCMW7nrB6fJ92XlqS6XWMA1/8R/LJnDAW7jGjy0eVGSd7 UFYeQXSczjfr3w2gNH/4Jcm5cg== X-Google-Smtp-Source: ABdhPJzCOneZu4AMnooib+bg8ZJwce3fsqFCE7WWhYymkLStPsKv55OzdAyCgnQNFba6Oycz1dDM2g== X-Received: by 2002:a05:6870:70a8:b0:e6:30d9:c7f6 with SMTP id v40-20020a05687070a800b000e630d9c7f6mr2821oae.179.1651510294594; Mon, 02 May 2022 09:51:34 -0700 (PDT) Received: from ripper.. (104-57-184-186.lightspeed.austtx.sbcglobal.net. [104.57.184.186]) by smtp.gmail.com with ESMTPSA id h11-20020a4add8b000000b0035eb4e5a6ccsm4029422oov.34.2022.05.02.09.51.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 May 2022 09:51:34 -0700 (PDT) From: Bjorn Andersson To: Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Tvrtko Ursulin , Rob Clark , Sean Paul , Abhinav Kumar , Heikki Krogerus , Greg Kroah-Hartman , Dmitry Baryshkov , Kuogee Hsieh Cc: Stephen Boyd , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, linux-arm-msm@vger.kernel.org, freedreno@lists.freedesktop.org, linux-usb@vger.kernel.org Subject: [PATCH v4 3/5] drm/bridge_connector: implement oob_hotplug_event Date: Mon, 2 May 2022 09:53:14 -0700 Message-Id: <20220502165316.4167199-4-bjorn.andersson@linaro.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220502165316.4167199-1-bjorn.andersson@linaro.org> References: <20220502165316.4167199-1-bjorn.andersson@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org From: Dmitry Baryshkov Implement the oob_hotplug_event() callback. Translate it to the HPD notification sent to the HPD bridge in the chain. Signed-off-by: Dmitry Baryshkov Signed-off-by: Bjorn Andersson --- Changes since v3: - New patch drivers/gpu/drm/drm_bridge_connector.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/gpu/drm/drm_bridge_connector.c b/drivers/gpu/drm/drm_bridge_connector.c index 0f6f3f653f65..6a0a6b14360a 100644 --- a/drivers/gpu/drm/drm_bridge_connector.c +++ b/drivers/gpu/drm/drm_bridge_connector.c @@ -123,6 +123,17 @@ static void drm_bridge_connector_hpd_cb(void *cb_data, drm_kms_helper_hotplug_event(dev); } +static void drm_bridge_connector_oob_hotplug_event(struct drm_connector *connector, + enum drm_connector_status status) +{ + struct drm_bridge_connector *bridge_connector = + to_drm_bridge_connector(connector); + struct drm_bridge *hpd = bridge_connector->bridge_hpd; + + if (hpd) + drm_bridge_hpd_notify(hpd, status); +} + /** * drm_bridge_connector_enable_hpd - Enable hot-plug detection for the connector * @connector: The DRM bridge connector @@ -233,6 +244,7 @@ static const struct drm_connector_funcs drm_bridge_connector_funcs = { .atomic_duplicate_state = drm_atomic_helper_connector_duplicate_state, .atomic_destroy_state = drm_atomic_helper_connector_destroy_state, .debugfs_init = drm_bridge_connector_debugfs_init, + .oob_hotplug_event = drm_bridge_connector_oob_hotplug_event, }; /* -----------------------------------------------------------------------------