From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f50.google.com (mail-wm1-f50.google.com [209.85.128.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B46103921D6 for ; Tue, 11 Aug 2026 15:10:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.50 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786461032; cv=none; b=OVK/RzXd0XTU8yuXKBFRFmXK21etk4VhjD+W+yMEysz9yG1CSF7Qz+S1WD15GVc1eTHWu1LfGWotZhfjqwBYiafXZpKpmaTc2P0DgJVVCrJ9ER8S5WkbahPOD5Qe8nEO/hiSvbUk7QBV/HpKOBpK3AqTPGFJVkeBmdh59nF5pW4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786461032; c=relaxed/simple; bh=ivn5FpbqzOafjFUR6DTQdE0pEGfE/tKP3Qlpdn992Gc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=OK7EiKCwiuUxNSG8nh7zKPVI+shbvoYnBpyZBePiSKiuFjP7AFD58xy0W9Xl03EhN0KrJJBthcIRv5+jjR6OGe+Izs78TeGgKykW9zxR4pSnqza1o6fn6ckQ3t0lNh79NMdsc9TWyALUpKZ9sAZdUyhI2/KyYXMNVd0QukTr7Vk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=SBpTlCFA; arc=none smtp.client-ip=209.85.128.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="SBpTlCFA" Received: by mail-wm1-f50.google.com with SMTP id 5b1f17b1804b1-490cf322ed0so26278495e9.1 for ; Tue, 11 Aug 2026 08:10:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1786461028; x=1787065828; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=+5cZFvCl/vAsUiXuIlHQJb7GfBLhg5GlqSTHb/6mrLQ=; b=SBpTlCFAHb68hUQsGS6D6rz/6+kN7BGKxEXOJrNfXVki2qBQauomXVTsuMl6nXW0uo Umm6ySsESHTJ3pe6wEbVDQHmXjsHpOOVAxW9aNeRK3Zbl0dntufz2r74qB84040SBXXb ciUj1YN6XIk1kjouGXeziOuvCxj1bvtSYf5fR5c+i821Q2f8boMhFlOLwSBBxH3XdPlg kWlISDS+PpsLE1t8p+oWCqnNksHq9JNK5xZAatgSM9cY0K012ZABjGPaGGgDgYpN2NGD y1E2UEiuG/2tvd+wC/anCQbJLXEDk0ctQ6S1L5UwyM4A1iR5/sfLIAniWQsCvATtp5Px MysQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786461028; x=1787065828; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=+5cZFvCl/vAsUiXuIlHQJb7GfBLhg5GlqSTHb/6mrLQ=; b=HgUWdveF/W6VIHG1dxj4WCDNrNVvOqkyrZkqeARHcF6fKlh6Uvp0Ye8vBwgQO69xt0 aRO4Tl8oWYObOHBnqC/y7+xC6hD6cNaWbOa8JdblT8GCyCw4PMMmUK+r6mavvQgZeR+v lyb9dXCXLzaMu7OkJmxHcZzyoyMs1mO5zpX3YxgyLsGZycJ1aUX+DIqSB5gddp6rjch0 v6vQJH58gGNYO4KkkWDhAMUkjKOa7Ea+pNO3QZlxHoVAE9ox4GyPCfc5/xTholB1XMgi c1Q9XGCeTW0KisTyM7degzNJbpAQXxwBB3oVll5KprwOx9bYPt89TogbcaXqoSWYk0vM e8IQ== X-Forwarded-Encrypted: i=1; AHgh+RrfTo7xUYDJY0MIq9U5mlfZWMUWqM49qbZhZmKjuvQZFhpmOBfFbILn2ATGPqQzxdd1hDF/LEpCJZeNFN0=@vger.kernel.org X-Gm-Message-State: AOJu0Yy/cnYR60nQWTO/ZU2fhV/lTHItavNjZLV3RhjhjwUtcufijVD7 uWYaG2Y0x5UKD1FmJ12fGIvO1f8+4PaSGvSNGvUZnEYoJEfcQzUw4IgF X-Gm-Gg: AR+sD12+X0hx7urlg4BFqefS1frmMbYQwYC/lvKLDiyEWPFXTcH5g8xDGYzs+gzpjTh 41/A4QlvMGX1X1j0sW2ykXDFZgGGXg5Ui5OR2k3Uo1F4Na5HZrsN3Z4NujktujRHqOKRngkt3Lb 1TOXHLwo9XATqMtLz7mqNhlywEn42jxKPaMWzSY/ZF5mI3d6Ai3MZuw7MFK6CteEsBR8m91DloK riHnKHYMcd/hKstKtRTTbf/FgRnPbDi9Q5rYXcZVnNUK4bUAF/5nDAuGY6jTQkz5JiGj3qDyblV 55IwjDhZmf9QTsWpl7DqlSpHNDGnd5YwYdEpWz5rmHLht/SUdfveb91myqEOe3IEuPvPl6O2F7k Y1L3PKpKcDwqfJpFOidDrfkBa6SgNu6GhaXDIVVpW+wbfbWVwQj1WoonLiAIy/At6cyO/q0e4nM 1kBYiePDAkyDdOqJYvhnLsTuUUXUlepK3k6NjgBPALvru+yg5XNNVlAU4YTw4wWKj0Ka2Aa8hQN 1O+yVKNJdkAdaev9/xecYIe X-Received: by 2002:a05:600c:c163:b0:499:4892:d022 with SMTP id 5b1f17b1804b1-4997843e95fmr79403415e9.8.1786461027590; Tue, 11 Aug 2026 08:10:27 -0700 (PDT) Received: from osama.. ([2a02:908:185:7e40:b0cf:778:ae86:13b1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-49977e57785sm54307265e9.2.2026.08.11.08.10.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Aug 2026 08:10:27 -0700 (PDT) From: Osama Abdelkader To: Neil Armstrong , Jessica Zhang , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Jerry Han , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Cc: Osama Abdelkader Subject: [PATCH 1/6] drm/panel: Use devm_mipi_dsi_attach in BOE panels Date: Tue, 11 Aug 2026 17:09:45 +0200 Message-ID: <20260811151000.75038-2-osama.abdelkader@gmail.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260811151000.75038-1-osama.abdelkader@gmail.com> References: <20260811151000.75038-1-osama.abdelkader@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Use the managed MIPI DSI attach helper in BOE panel drivers and drop the corresponding manual detach calls from remove paths. --- drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c | 8 +------- drivers/gpu/drm/panel/panel-boe-himax8279d.c | 8 +------- drivers/gpu/drm/panel/panel-boe-td4320.c | 8 +------- drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c | 4 +--- drivers/gpu/drm/panel/panel-boe-tv101wum-ll2.c | 8 +------- drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 7 +------ 6 files changed, 6 insertions(+), 37 deletions(-) diff --git a/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c b/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c index 84c21c62a43e..6a74523a6614 100644 --- a/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c +++ b/drivers/gpu/drm/panel/panel-boe-bf060y8m-aj0.c @@ -359,7 +359,7 @@ static int boe_bf060y8m_aj0_probe(struct mipi_dsi_device *dsi) drm_panel_add(&boe->panel); - ret = mipi_dsi_attach(dsi); + ret = devm_mipi_dsi_attach(&dsi->dev, dsi); if (ret < 0) { dev_err(dev, "Failed to attach to DSI host: %d\n", ret); return ret; @@ -371,12 +371,6 @@ static int boe_bf060y8m_aj0_probe(struct mipi_dsi_device *dsi) static void boe_bf060y8m_aj0_remove(struct mipi_dsi_device *dsi) { struct boe_bf060y8m_aj0 *boe = mipi_dsi_get_drvdata(dsi); - int ret; - - ret = mipi_dsi_detach(dsi); - if (ret < 0) - dev_err(&dsi->dev, "Failed to detach from DSI host: %d\n", ret); - drm_panel_remove(&boe->panel); } diff --git a/drivers/gpu/drm/panel/panel-boe-himax8279d.c b/drivers/gpu/drm/panel/panel-boe-himax8279d.c index 4a8560b4b899..ffcb63f65b75 100644 --- a/drivers/gpu/drm/panel/panel-boe-himax8279d.c +++ b/drivers/gpu/drm/panel/panel-boe-himax8279d.c @@ -881,7 +881,7 @@ static int panel_probe(struct mipi_dsi_device *dsi) if (err < 0) return err; - err = mipi_dsi_attach(dsi); + err = devm_mipi_dsi_attach(&dsi->dev, dsi); if (err < 0) drm_panel_remove(&pinfo->base); @@ -891,12 +891,6 @@ static int panel_probe(struct mipi_dsi_device *dsi) static void panel_remove(struct mipi_dsi_device *dsi) { struct panel_info *pinfo = mipi_dsi_get_drvdata(dsi); - int err; - - err = mipi_dsi_detach(dsi); - if (err < 0) - dev_err(&dsi->dev, "failed to detach from DSI host: %d\n", err); - drm_panel_remove(&pinfo->base); } diff --git a/drivers/gpu/drm/panel/panel-boe-td4320.c b/drivers/gpu/drm/panel/panel-boe-td4320.c index 23558a76dd72..704d5a9c13e7 100644 --- a/drivers/gpu/drm/panel/panel-boe-td4320.c +++ b/drivers/gpu/drm/panel/panel-boe-td4320.c @@ -204,7 +204,7 @@ static int boe_td4320_probe(struct mipi_dsi_device *dsi) drm_panel_add(&ctx->panel); - ret = mipi_dsi_attach(dsi); + ret = devm_mipi_dsi_attach(&dsi->dev, dsi); if (ret < 0) { drm_panel_remove(&ctx->panel); return dev_err_probe(dev, ret, "Failed to attach to DSI host\n"); @@ -216,12 +216,6 @@ static int boe_td4320_probe(struct mipi_dsi_device *dsi) static void boe_td4320_remove(struct mipi_dsi_device *dsi) { struct boe_td4320 *ctx = mipi_dsi_get_drvdata(dsi); - int ret; - - ret = mipi_dsi_detach(dsi); - if (ret < 0) - dev_err(&dsi->dev, "Failed to detach from DSI host: %d\n", ret); - drm_panel_remove(&ctx->panel); } diff --git a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c index a70a2e58f88c..94cc675973e6 100644 --- a/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c +++ b/drivers/gpu/drm/panel/panel-boe-th101mb31ig002-28a.c @@ -393,7 +393,7 @@ static int boe_th101mb31ig002_dsi_probe(struct mipi_dsi_device *dsi) drm_panel_add(&ctx->panel); - ret = mipi_dsi_attach(dsi); + ret = devm_mipi_dsi_attach(&dsi->dev, dsi); if (ret < 0) { dev_err_probe(&dsi->dev, ret, "Failed to attach panel to DSI host\n"); @@ -407,8 +407,6 @@ static int boe_th101mb31ig002_dsi_probe(struct mipi_dsi_device *dsi) static void boe_th101mb31ig002_dsi_remove(struct mipi_dsi_device *dsi) { struct boe_th101mb31ig002 *ctx = mipi_dsi_get_drvdata(dsi); - - mipi_dsi_detach(dsi); drm_panel_remove(&ctx->panel); } diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-ll2.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-ll2.c index 20b6e11a7d84..2ab7764d4094 100644 --- a/drivers/gpu/drm/panel/panel-boe-tv101wum-ll2.c +++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-ll2.c @@ -200,7 +200,7 @@ static int boe_tv101wum_ll2_probe(struct mipi_dsi_device *dsi) drm_panel_add(&ctx->panel); - ret = mipi_dsi_attach(dsi); + ret = devm_mipi_dsi_attach(&dsi->dev, dsi); if (ret < 0) { drm_panel_remove(&ctx->panel); return dev_err_probe(dev, ret, "Failed to attach to DSI host\n"); @@ -212,12 +212,6 @@ static int boe_tv101wum_ll2_probe(struct mipi_dsi_device *dsi) static void boe_tv101wum_ll2_remove(struct mipi_dsi_device *dsi) { struct boe_tv101wum_ll2 *ctx = mipi_dsi_get_drvdata(dsi); - int ret; - - ret = mipi_dsi_detach(dsi); - if (ret < 0) - dev_err(&dsi->dev, "Failed to detach from DSI host: %d\n", ret); - drm_panel_remove(&ctx->panel); } diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c index 150dff3ab6c3..7d2672578dd8 100644 --- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c +++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c @@ -1765,7 +1765,7 @@ static int boe_panel_probe(struct mipi_dsi_device *dsi) mipi_dsi_set_drvdata(dsi, boe); - ret = mipi_dsi_attach(dsi); + ret = devm_mipi_dsi_attach(&dsi->dev, dsi); if (ret) drm_panel_remove(&boe->base); @@ -1775,11 +1775,6 @@ static int boe_panel_probe(struct mipi_dsi_device *dsi) static void boe_panel_remove(struct mipi_dsi_device *dsi) { struct boe_panel *boe = mipi_dsi_get_drvdata(dsi); - int ret; - - ret = mipi_dsi_detach(dsi); - if (ret < 0) - dev_err(&dsi->dev, "failed to detach from DSI host: %d\n", ret); if (boe->base.dev) drm_panel_remove(&boe->base); -- 2.43.0