From patchwork Tue Dec 6 08:34:01 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Caione X-Patchwork-Id: 13065531 X-Patchwork-Delegate: neil.armstrong@linaro.org 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 52418C352A1 for ; Tue, 6 Dec 2022 08:34:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=4prvvD4a6OjXalGlX/kHbeqSvo9y8EQgoL7eZMQWTYg=; b=xj0P24z4iBJs9y BWSqXg3ApHBhDbS+7ejCi73flCnkjOTXwzXLN/ePQnluO6D7LjmV6c5Fb9zzi7Q2oL9X8r5Rk+PZC nlawUsHkhHMdE8aI6mDF3f+L9miUIothhKKxPJfwbyDPErpqIi0I6j16y5QhxImw1sTUg9XdLn4Bj UPckDlFLVfyUAbxbfJjFug8dAe2DSQEdfyxJosXY6+mBGJaBDlwWjgSMFCiqAPZpHeO2o6QUMov4B 8+BIUIog23NSTi/tAbo/rssQ7pfGxb1XaC4ZQEeMOdszCVcQEoW2Kmh65X4jYJgDOHKeGFdhP1ZZu FWhc9TbXfufYkKMcBgaw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TPO-004vPU-B3; Tue, 06 Dec 2022 08:34:34 +0000 Received: from mail-ej1-x62d.google.com ([2a00:1450:4864:20::62d]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TP3-004uvm-NU for linux-amlogic@lists.infradead.org; Tue, 06 Dec 2022 08:34:17 +0000 Received: by mail-ej1-x62d.google.com with SMTP id kw15so958354ejc.10 for ; Tue, 06 Dec 2022 00:34:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=3BPaUYtbAIV1BLKNgYdAozqHw0R4+q9lV2NZg2CpgKo=; b=H2H7JKYXXvAfClM3nA4go1vg+3MHl1e/2zDDCysrg3tEabCsIvKnRzv0Wvtb2s10VN 304O8iUaaCjy+dnUF4jp5tvxQ7MKMC2YGkV23TPpDOStSB2Upw0HDsdfWJMs2ioAEOrO fhKRJupDAIl1fLdC4rmrOPBhagh95bOmoINpnJ0Zam1PJQYxiVWiFMx4uAO8/VhJige/ q5RIt7kTTdZLXfDSogK4wYnAWCRuJIegjkPjFnq6DxnHXIQKAcCVC2EWQgKtVEUTgRU7 MuUyGBNerPFdl7BnbM83N10a7qTIxPVwG7X9BJpk4AcHrfhY18IPOxuXDtofPfhLSKvV XlpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3BPaUYtbAIV1BLKNgYdAozqHw0R4+q9lV2NZg2CpgKo=; b=1N7ComipkuF9sbJmwLsTZHqoj9UEItykPfsXNIuS0yS7K3Rs5DIOMWFsWvWMpCEeNw 8g03E8YnOg2C+oRfCbU8OwXj51PmB1G5cPGCT4vmIrosTcgTcFp0VDbJp2bpjfxMc4QL HYQPno9SxCrJfy7QnT5NetdCwHfZnB6GYCuZRvyZzZC1ET40ohT0Ch8TI081DN6OwFZp t2CwLbMPO3ehoJjuO8P6jLKPtbhVUGIbKzxcAQQAIhJuEknO3qvdivG7jeF5oC7y2ZqY kI3myk6L6eHlOaW+fuvPgx9CcSiguuI3/0CSLvVlDYFnse5XVioaxk3wZy5ghbz+IsB2 nC/A== X-Gm-Message-State: ANoB5pnVSQj6C9bx7DPaCmCjzkC7OR6j/DJ7+8Zt6A39UE7CZKY2biQt vynwZ0MxfL3Zo565DPvzlUEcvw== X-Google-Smtp-Source: AA0mqf5Pz039HsSECacZv7n6SegwyteVoV+SG8Cjh+HO/AU52+pi8GERHDDdw5tp9McDI8DIbvAY2w== X-Received: by 2002:a17:907:2c75:b0:7c0:bbab:a550 with SMTP id ib21-20020a1709072c7500b007c0bbaba550mr14397235ejc.168.1670315649259; Tue, 06 Dec 2022 00:34:09 -0800 (PST) Received: from [127.0.1.1] ([2a0e:41a:894f:0:2017:359e:18ef:1c49]) by smtp.gmail.com with ESMTPSA id g18-20020a17090604d200b0078d9b967962sm7019390eja.65.2022.12.06.00.34.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 00:34:08 -0800 (PST) From: Carlo Caione Date: Tue, 06 Dec 2022 09:34:01 +0100 Subject: [PATCH v3 1/3] drm/tiny: ili9486: Enable driver module autoloading MIME-Version: 1.0 Message-Id: <20221116-s905x_spi_ili9486-v3-1-59c6b58cbfe3@baylibre.com> References: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> In-Reply-To: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> To: Daniel Vetter , Jerome Brunet , David Airlie , Kamlesh Gurudasani , Mark Brown , Martin Blumenstingl , Kevin Hilman , Neil Armstrong Cc: linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, Carlo Caione , linux-kernel@vger.kernel.org X-Mailer: b4 0.10.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221206_003413_834655_8B35FCDE X-CRM114-Status: UNSURE ( 8.26 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+linux-amlogic=archiver.kernel.org@lists.infradead.org SPI devices use the spi_device_id for module autoloading even on systems using device tree. Add the spi_device_id entry to enable autoloading for the 3.5inch RPi Display (rpi-lcd-35 and piscreen). Reviewed-by: Neil Armstrong Signed-off-by: Carlo Caione --- drivers/gpu/drm/tiny/ili9486.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/tiny/ili9486.c b/drivers/gpu/drm/tiny/ili9486.c index c80028bb1d11..2ca7c59771f3 100644 --- a/drivers/gpu/drm/tiny/ili9486.c +++ b/drivers/gpu/drm/tiny/ili9486.c @@ -183,6 +183,8 @@ MODULE_DEVICE_TABLE(of, ili9486_of_match); static const struct spi_device_id ili9486_id[] = { { "ili9486", 0 }, + { "rpi-lcd-35", 0 }, + { "piscreen", 0 }, { } }; MODULE_DEVICE_TABLE(spi, ili9486_id); From patchwork Tue Dec 6 08:34:02 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Caione X-Patchwork-Id: 13065532 X-Patchwork-Delegate: neil.armstrong@linaro.org 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 103F3C3A5A7 for ; Tue, 6 Dec 2022 08:35:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Znsbugip0ELAbx5QV57JWETNPpbBVJ+xZuArsffikdY=; b=mE1k3t2axDV9aZ xYo8Znqp+jTu35y3xfoVcWlhxR8SRpB90VUlFtVZBYPXiqKzh7gIdjv1ggM2yJdrunCcxDTkASIKT tw1XztRNXyRqFAnsX7QtcOMHaUeJVtPtBn/j7/VqiH0OetXX7fwGUDaRm8nJfP9MUDhHJzg3uG9aD Uj0GVSvd/KosBowlZoYBF2GptrUVzi30R/VXDHofOEsJwssJ9GsJCHIVqoVW5PpXaH3mAwxKK5/gx xkSYfexeNs6SFj7zeItELrMRI/rGljEdtDu3f1UvkqHBzWrlHKSDyzXy5l3Pg9uIK6glxvxSKXgoy T18WRxLW5eXoIiF1bpRw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TPq-004vsV-4b; Tue, 06 Dec 2022 08:35:02 +0000 Received: from mail-ed1-x536.google.com ([2a00:1450:4864:20::536]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TP3-004uwH-TP for linux-amlogic@lists.infradead.org; Tue, 06 Dec 2022 08:34:19 +0000 Received: by mail-ed1-x536.google.com with SMTP id d14so14296487edj.11 for ; Tue, 06 Dec 2022 00:34:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=6+091FGCQ4rhzDvkB3AYfkA+OM7BJLCJxULLW5x6V0Y=; b=CMulTRGHBt8iZM34cI32BL92j4m/IGpI6bWJ+J8LmB3Bk9XlO8T2iVFu0JkuBVf5zj 8Wr0rXr9XVkORpLTFHEUXRXlrgQds3a+N8OJcv8pyp5UWyhX043kgJV1IYaeEM1if5ls fcn1Xmbm29SFIoT4NocFl/j01Dm8x/9dT3pH/70rdtr7Eiq5IyhhHdZgMX3hHJEvfaOw uXWTFUo5QnhQaRm3Q8kBsLYm1Rz7Cg/AknnwM7TowRNpVAl9Bh3+7ivfKDgQHnnwTSgu 669PfAVJ5wR334uRsypLCsWVOL5aYLZS1wPHtmj3LtsaCbwak5Q8yk1GI3C4z0kIfkyk FLgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=6+091FGCQ4rhzDvkB3AYfkA+OM7BJLCJxULLW5x6V0Y=; b=4qPFLkQ7gO+2ZOtzRQlbc5FxaWVwTqxGEfWLi0zzq1IyM6+0uTr2yluklHI5ux+HXL fabmNtdTSNX2myZQZ7Y4aMO/mu+9G1XDuJE/PQui4shbAl30dm28nAVgsmBGM/4GIfmc u48SZTZP9m2lORAg+Q05fw+7pmNVNEAm8rGeD1TyZF8IorY1t1R2mryAnqpu0gLoglDr Deqb9aJNSFSdCm+OzMawVUnHyqCCjNVN7Ih4HqQw3ajPFYDHMPiPbYE15d92OHQOtS8Q FBhwtT4PHOG921bvEwzKVpl3dE4jXDG8VayVOqPSHnKNCCevsX3sL6BpFQg7inOkpEWp kClw== X-Gm-Message-State: ANoB5pkaRvo4dTKIa8eu2q3/FBo/E7qPvysdFB2Scv9BN5czJj4iMmJi qDN4jbBA39SJ3M2p6atLAN75Jw== X-Google-Smtp-Source: AA0mqf7xShBddJAwFF9w5fCy8BkqKLZeSqJlo3zmXsOR6j9nvha3NC93Pz85cGp3Hed4/H9Fmoo1IQ== X-Received: by 2002:a05:6402:4516:b0:467:b88c:f3af with SMTP id ez22-20020a056402451600b00467b88cf3afmr1991786edb.24.1670315650207; Tue, 06 Dec 2022 00:34:10 -0800 (PST) Received: from [127.0.1.1] ([2a0e:41a:894f:0:2017:359e:18ef:1c49]) by smtp.gmail.com with ESMTPSA id g18-20020a17090604d200b0078d9b967962sm7019390eja.65.2022.12.06.00.34.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 00:34:09 -0800 (PST) From: Carlo Caione Date: Tue, 06 Dec 2022 09:34:02 +0100 Subject: [PATCH v3 2/3] drm/tiny: ili9486: Do not assume 8-bit only SPI controllers MIME-Version: 1.0 Message-Id: <20221116-s905x_spi_ili9486-v3-2-59c6b58cbfe3@baylibre.com> References: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> In-Reply-To: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> To: Daniel Vetter , Jerome Brunet , David Airlie , Kamlesh Gurudasani , Mark Brown , Martin Blumenstingl , Kevin Hilman , Neil Armstrong Cc: linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, Carlo Caione , linux-kernel@vger.kernel.org X-Mailer: b4 0.10.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221206_003413_980559_E0439AA4 X-CRM114-Status: GOOD ( 18.71 ) X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+linux-amlogic=archiver.kernel.org@lists.infradead.org The pixel data for the ILI9486 is always 16-bits wide and it must be sent over the SPI bus. When the controller is only able to deal with 8-bit transfers, this 16-bits data needs to be swapped before the sending to account for the big endian bus, this is on the contrary not needed when the SPI controller already supports 16-bits transfers. The decision about swapping the pixel data or not is taken in the MIPI DBI code by probing the controller capabilities: if the controller only suppors 8-bit transfers the data is swapped, otherwise it is not. This swapping/non-swapping is relying on the assumption that when the controller does support 16-bit transactions then the data is sent unswapped in 16-bits-per-word over SPI. The problem with the ILI9486 driver is that it is forcing 8-bit transactions also for controllers supporting 16-bits, violating the assumption and corrupting the pixel data. Align the driver to what is done in the MIPI DBI code by adjusting the transfer size to the maximum allowed by the SPI controller. Reviewed-by: Neil Armstrong Signed-off-by: Carlo Caione --- drivers/gpu/drm/tiny/ili9486.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/tiny/ili9486.c b/drivers/gpu/drm/tiny/ili9486.c index 2ca7c59771f3..14a9e6ad2d15 100644 --- a/drivers/gpu/drm/tiny/ili9486.c +++ b/drivers/gpu/drm/tiny/ili9486.c @@ -43,6 +43,7 @@ static int waveshare_command(struct mipi_dbi *mipi, u8 *cmd, u8 *par, size_t num) { struct spi_device *spi = mipi->spi; + unsigned int bpw = 8; void *data = par; u32 speed_hz; int i, ret; @@ -56,8 +57,6 @@ static int waveshare_command(struct mipi_dbi *mipi, u8 *cmd, u8 *par, * The displays are Raspberry Pi HATs and connected to the 8-bit only * SPI controller, so 16-bit command and parameters need byte swapping * before being transferred as 8-bit on the big endian SPI bus. - * Pixel data bytes have already been swapped before this function is - * called. */ buf[0] = cpu_to_be16(*cmd); gpiod_set_value_cansleep(mipi->dc, 0); @@ -71,12 +70,18 @@ static int waveshare_command(struct mipi_dbi *mipi, u8 *cmd, u8 *par, for (i = 0; i < num; i++) buf[i] = cpu_to_be16(par[i]); num *= 2; - speed_hz = mipi_dbi_spi_cmd_max_speed(spi, num); data = buf; } + /* + * Check whether pixel data bytes needs to be swapped or not + */ + if (*cmd == MIPI_DCS_WRITE_MEMORY_START && !mipi->swap_bytes) + bpw = 16; + gpiod_set_value_cansleep(mipi->dc, 1); - ret = mipi_dbi_spi_transfer(spi, speed_hz, 8, data, num); + speed_hz = mipi_dbi_spi_cmd_max_speed(spi, num); + ret = mipi_dbi_spi_transfer(spi, speed_hz, bpw, data, num); free: kfree(buf); From patchwork Tue Dec 6 08:34:03 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Caione X-Patchwork-Id: 13065533 X-Patchwork-Delegate: neil.armstrong@linaro.org 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5C234C352A1 for ; Tue, 6 Dec 2022 08:35:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To:References:Message-Id :MIME-Version:Subject:Date:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=dCAPz9LQjPucx/rLlcH+ulIy5tmTEggGITzW+pNntY8=; b=iLEka+1kFEHiYG TM4/XJuaK33KQI3LOtPbdwAN2ptrwgR0y+BrSUtWN/EfSto0Dfwd3LV/bw7ee9HfX6J+jfADdopuN Jcg/GrfIOSp3zJ9xgDRgTNUxZlkkTFX16MzenlaSIyertRFEsbTJ8ADbsTSSlrnVagWTLOZwr+yo5 Ld1tMrfzDph7QkFJEbKxZlRizj6KC4yEoU7h+CSTh2ENTqYk7srDgXA3ENXVGU3cT6+vWbJN8fy7j yrt4XGgYbnCz9X49PD6+jv8HklRGL2JRysxT7cDKOcE+mv6qanjA+7/fba6hL3Ksu8SXzn3mHyAvV I4qXQdlK9R02d/BgeyFA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TPq-004vst-Oi; Tue, 06 Dec 2022 08:35:02 +0000 Received: from mail-ej1-x62a.google.com ([2a00:1450:4864:20::62a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1p2TP4-004uwP-Qy for linux-amlogic@lists.infradead.org; Tue, 06 Dec 2022 08:34:20 +0000 Received: by mail-ej1-x62a.google.com with SMTP id n21so4368937ejb.9 for ; Tue, 06 Dec 2022 00:34:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=dcRZDjg3O3q6T3Sk5c09WrJuoI7e4rWvSzYj/Z5H43A=; b=4WirXC4jMxNwlMz6xJ0Jso5tI43SM73m6Z9nAG5UcC6cra+AVeRVqQ34JVt6DgZKgV c9hIcYbA/AvXNIM6RMGCohkjPKGrjCTBPl9oU3bNjAjQ/umGlKZLpggA155FB0vJk6Ct rVcHJ0ILj6BY4HBabqfD7FJVizZkw3Ldgd5e3xJbSInv7XpX/wYG6HZCmV7RsRmxhpIu XkwElGUBdmrQGgZBpaz/Yd6JEAvU7fw8grj8BxnZf8UlHql26r0u8WY4z+Mv4oLZ0koR xQtcD4jBbiBlgU3ycjVbJlgfX5rdOKY5JE6tHR1X8QYJktlo5P4BCCoaT1FmCpd7wM9l 2tgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dcRZDjg3O3q6T3Sk5c09WrJuoI7e4rWvSzYj/Z5H43A=; b=eTYHBErxXjILQ/1I1R5jI1mAXmASOmuMGAtwM3YPNq6hK5Ichy4rufaHxJJSFNfPfW Mz8VQ2aPR5vXr267QlE1hlN25MG94uThiP0USGdCpCuZ0Buju9d/e27/9srbMeXU4S/1 mQYreqYF5oUmED16OSiGaq1eT3n3H5R12XS7DA5FVvDkVnW6YuVdDA8zcGZkCfurqZT4 02eTr8yADssqgijqRdTyCbVxRmE5P1CfDjDgHEoyuB77IcLSSvPM5w0Ka/TziAXLzXZE iC8aQ/cWVaAypyT5CL4iQ7tlBl1nVCHYng9zvhbpItdiMdP9ELaad8BopHHXAiNqbQxU 4jvA== X-Gm-Message-State: ANoB5pnGAP2RT8koY7CYaIPLeA1V7QJdKO4KVAaPVgqD5D/HQffUL7cB Ygaoa1xyKWJK6c4dJcYlyVgG2Q== X-Google-Smtp-Source: AA0mqf5gb/HnDPmrEu015wzGjESF27vgWXcc+GMbiF/NffvzbIeSzlwquLLovFxqS8JOcTBj9/5vKQ== X-Received: by 2002:a17:906:164d:b0:7c0:b602:f9a1 with SMTP id n13-20020a170906164d00b007c0b602f9a1mr17569290ejd.88.1670315651166; Tue, 06 Dec 2022 00:34:11 -0800 (PST) Received: from [127.0.1.1] ([2a0e:41a:894f:0:2017:359e:18ef:1c49]) by smtp.gmail.com with ESMTPSA id g18-20020a17090604d200b0078d9b967962sm7019390eja.65.2022.12.06.00.34.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Dec 2022 00:34:10 -0800 (PST) From: Carlo Caione Date: Tue, 06 Dec 2022 09:34:03 +0100 Subject: [PATCH v3 3/3] drm/tiny: ili9486: remove conflicting framebuffers MIME-Version: 1.0 Message-Id: <20221116-s905x_spi_ili9486-v3-3-59c6b58cbfe3@baylibre.com> References: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> In-Reply-To: <20221116-s905x_spi_ili9486-v3-0-59c6b58cbfe3@baylibre.com> To: Daniel Vetter , Jerome Brunet , David Airlie , Kamlesh Gurudasani , Mark Brown , Martin Blumenstingl , Kevin Hilman , Neil Armstrong Cc: linux-arm-kernel@lists.infradead.org, dri-devel@lists.freedesktop.org, linux-amlogic@lists.infradead.org, Carlo Caione , linux-kernel@vger.kernel.org X-Mailer: b4 0.10.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221206_003414_923216_D0BEBDE6 X-CRM114-Status: UNSURE ( 8.55 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-amlogic@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-amlogic" Errors-To: linux-amlogic-bounces+linux-amlogic=archiver.kernel.org@lists.infradead.org For platforms using simplefb / efifb, call drm_aperture_remove_framebuffers() to remove the conflicting framebuffer. Signed-off-by: Carlo Caione --- drivers/gpu/drm/tiny/ili9486.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/drm/tiny/ili9486.c b/drivers/gpu/drm/tiny/ili9486.c index 14a9e6ad2d15..6fd4d42437fd 100644 --- a/drivers/gpu/drm/tiny/ili9486.c +++ b/drivers/gpu/drm/tiny/ili9486.c @@ -14,6 +14,7 @@ #include