From mboxrd@z Thu Jan 1 00:00:00 1970 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (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 3B347C61D97 for ; Fri, 24 Nov 2023 01:14:43 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id DD9FD10E779; Fri, 24 Nov 2023 01:14:41 +0000 (UTC) Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) by gabe.freedesktop.org (Postfix) with ESMTPS id 26AB510E775 for ; Fri, 24 Nov 2023 01:14:40 +0000 (UTC) Received: by mail-ed1-x534.google.com with SMTP id 4fb4d7f45d1cf-548a2c20f50so1892159a12.1 for ; Thu, 23 Nov 2023 17:14:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700788478; x=1701393278; darn=lists.freedesktop.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=63sQ1AH1I32ffRCwtEtkqR0j31IoAtIR8HssDvXhDlI=; b=mmhX87GjhttAkb+C9N9eyi/bmtS+L+bR0TnColw5ckGDYBtQZjaiZoEgYMSigWw/Xh yUFQxUgai8d7id5Qq9OhgEBEmtoosIwwo8XwCYNWPkGBjK57F4tj/cZDcLFluWZbc0yr kaVSGsM3VAaXtlE+3xdV5qbw7nsTaD4zakOjI/im/0us6pwINxelwvS+jEy99hlDwIQf gWMM3X+84nGB153XgQFo4LSFJ3hgg9jy5x0y/kVpw5S8ejVShdvRAkZ3jJkeXn7dASpb 2S7sKgMbbVZSlAQjn9gQ01q1I5P1Xuu0adks3IfG4/YYD5wHgxTwN9rTCGHgEcmIcPH1 hbww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700788478; x=1701393278; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=63sQ1AH1I32ffRCwtEtkqR0j31IoAtIR8HssDvXhDlI=; b=t6M3uZ9RJivGMyR2puR4f/GkEicTvw0AvL/GIn7H1ItBzwrYpC0pDQP2Hub3MRE6SC DOjLir38hu1MEgD417bES+C8ToM4hXygJtKjqXL0AaKBaJ59H/NftfnrR4yaQ7fJYBgg NzxNg1ZcxuZ0+BgzFKYyRqJakc1biWL7XAAxGG761T0MwNjwD6cMX6P+z+lCKK4hEpcK MUbbnPsDg5XCJtYahcH+kHjymBUutu+09RZ2RMRXGMPbVuWJFC9QvjEBGevTWEttiP85 AiCv6tLCJURQO5fs46M+ZE4d2cUk8MW6OId8sSrEZ8emTmceDJkgx3W6fhHmvmfUki6q RiGg== X-Gm-Message-State: AOJu0YxfEMHsCWKPrZtwRpCHUTCyywJJkxAcLvcYFYVlv/0rcdRp9NUr 1q0ZWfb+lFs9Bgt0HC/rdqqSXE5yvr4x5im/28tBbAIaCo4= X-Google-Smtp-Source: AGHT+IHLIX9nFgHWswrxl4QhZA1sMO6aysJc8mE548EEq2zaQNtD+vtju8Lr3kfPZInT9eHY959lN4T9+2J71dDRGtk= X-Received: by 2002:a17:907:1310:b0:a04:8ee8:5e58 with SMTP id vj16-20020a170907131000b00a048ee85e58mr574460ejb.45.1700788477971; Thu, 23 Nov 2023 17:14:37 -0800 (PST) MIME-Version: 1.0 References: <20231120225537.1270358-1-inki.dae@samsung.com> In-Reply-To: <20231120225537.1270358-1-inki.dae@samsung.com> From: Dave Airlie Date: Fri, 24 Nov 2023 11:14:26 +1000 Message-ID: Subject: Re: [GIT PULL] exynos-drm-fixes To: Inki Dae Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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: airlied@linux.ie, linux-samsung-soc@vger.kernel.org, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Tue, 21 Nov 2023 at 09:00, Inki Dae wrote: > > Hi Dave and Daniel, > > Two fixups - fixing a potential error pointer dereference and wrong > error checking. Hi Inki, This fails to build on arm32, and it seems one of the fixes is wrong [airlied@dreadlord drm-fixes]$ make ARCH=3Darm CROSS_COMPILE=3Darm-linux-gnu- O=3D../../arm-build-fixes/ -j16 make[1]: Entering directory '/home/airlied/devel/kernel/arm-build-fixes' GEN Makefile CALL /home/airlied/devel/kernel/dim/drm-fixes/scripts/checksyscall= s.sh CC [M] drivers/gpu/drm/exynos/exynos_drm_dma.o /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c: In function =E2=80=98exynos_drm_register_dma=E2=80=99: /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c:119:40: error: passing argument 1 of =E2=80=98PTR_ERR=E2=80=99 makes pointer from i= nteger without a cast [-Werror=3Dint-conversion] 119 | return PTR_ERR(-ENODEV); In file included from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/string.h:9, from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/dma-mapping.h:7, from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/dma-map-ops.h:9, from /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c:7: /home/airlied/devel/kernel/dim/drm-fixes/include/linux/err.h:49:61: note: expected =E2=80=98const void *=E2=80=99 but argument is of type =E2= =80=98int=E2=80=99 49 | static inline long __must_check PTR_ERR(__force const void *ptr) | ~~~~~~~~~~~~^~~ cc1: all warnings being treated as errors I think it should just be return -ENODEV, since the function returns an int= . Please fix it up and resend. Thanks, Dave. > > Ps. regarding the first patch, I had sent a GIT-PULL[1] but it seems > you missed. > [1] https://lore.kernel.org/dri-devel/20231006040950.4397-1-inki.dae@s= amsung.com/T/#u > > Please kindly let me know if there is any problem. > > Thanks, > Inki Dae > > The following changes since commit 98b1cc82c4affc16f5598d4fa14b1858671b22= 63: > > Linux 6.7-rc2 (2023-11-19 15:02:14 -0800) > > are available in the Git repository at: > > git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos tags/e= xynos-drm-fixes-for-v6.7-rc3 > > for you to fetch changes up to a30ba4bd7cdb5726d86a557c5df8df71c7bc7fad: > > drm/exynos: fix a wrong error checking (2023-11-21 07:41:11 +0900) > > ---------------------------------------------------------------- > Two fixups > - Fix a potential error pointer dereference by checking the return value > of exynos_drm_crtc_get_by_type() function before accessing to crtc > object. > - Fix a wrong error checking in exynos_drm_dma.c modules, which was repor= ted > by Dan[1] > > [1] https://lore.kernel.org/all/33e52277-1349-472b-a55b-ab5c3462bfcf@moro= to.mountain/ > > ---------------------------------------------------------------- > Inki Dae (1): > drm/exynos: fix a wrong error checking > > Xiang Yang (1): > drm/exynos: fix a potential error pointer dereference > > drivers/gpu/drm/exynos/exynos_drm_dma.c | 8 +++----- > drivers/gpu/drm/exynos/exynos_hdmi.c | 2 ++ > 2 files changed, 5 insertions(+), 5 deletions(-) From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="OfYpdWqd" Received: from mail-ej1-x62e.google.com (mail-ej1-x62e.google.com [IPv6:2a00:1450:4864:20::62e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E97D7D56 for ; Thu, 23 Nov 2023 17:14:39 -0800 (PST) Received: by mail-ej1-x62e.google.com with SMTP id a640c23a62f3a-9ff26d7c0a6so196431766b.2 for ; Thu, 23 Nov 2023 17:14:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1700788478; x=1701393278; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=63sQ1AH1I32ffRCwtEtkqR0j31IoAtIR8HssDvXhDlI=; b=OfYpdWqdhKiLGydU0JGuj5mBlvhiF5wQdo9F6qORlE5+siMdahtPKUiduC/JdABMl7 2pb8QWVaTJXwej06raj48IZsK77N9LWWq9OM6R8nAW3EYDVxNwMBry0lt/7DShZBq9zJ x/UIzr07yM+Q9XlSqpC9+pRRSzlcgspQERQ2VYCAwkr0At8cszBkHMTkmZCs1TQ7dbOL H+ZYjajD4sa443Jl9diemzV8j69CcTVd5mrKWE+jFy2GWa5YTNB03FEj8KoXAUDGIUSY ZbSBcrrZdQOFXiul08rR8b/2Ipt3byb+RM08e6CUTG066htf3QbH0VATQ2WQ1NQu2C3s Up8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700788478; x=1701393278; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=63sQ1AH1I32ffRCwtEtkqR0j31IoAtIR8HssDvXhDlI=; b=HoMCctdRzOz62Ce387Ol0922nFt0cXyK7aUGNvm5Gd311ftzYu1RYKfcB3CxtHoigJ 8qxYn8BCsaUI+Z7pssuJ+GSGvxjlvZpMb3Ui6IJ7x3FSZdhw8urEf/9PS/IQc8bylOj5 PppdodIvVmBewhrWzhybXlnEeMr3TAza9UhYLO/NXffuDt/q8ojQvw1XbpokccSbl2rf LUlYnPfhHkFgnrZPlz0L8Yz9ew5DLO9CnDhP7/dro+/9wrPBrSAyIWiZZ2FwflY0ztx3 lSCDMoV8muTB8sIY9cT5j9xpnKYZZpaHQCB8AIrCCzLa0ttjuax5gL+i1j9a100TONfS YvlA== X-Gm-Message-State: AOJu0YxxsH2GTSU34HnECC62wio/ksAAqoK+9+/sJXCkxHUlmx+ObuZv 1qP/ZTqKAMloKW/uknKkAaomyD+9fSr7ZeJNY40= X-Google-Smtp-Source: AGHT+IHLIX9nFgHWswrxl4QhZA1sMO6aysJc8mE548EEq2zaQNtD+vtju8Lr3kfPZInT9eHY959lN4T9+2J71dDRGtk= X-Received: by 2002:a17:907:1310:b0:a04:8ee8:5e58 with SMTP id vj16-20020a170907131000b00a048ee85e58mr574460ejb.45.1700788477971; Thu, 23 Nov 2023 17:14:37 -0800 (PST) Precedence: bulk X-Mailing-List: linux-samsung-soc@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20231120225537.1270358-1-inki.dae@samsung.com> In-Reply-To: <20231120225537.1270358-1-inki.dae@samsung.com> From: Dave Airlie Date: Fri, 24 Nov 2023 11:14:26 +1000 Message-ID: Subject: Re: [GIT PULL] exynos-drm-fixes To: Inki Dae Cc: airlied@linux.ie, daniel@ffwll.ch, linux-samsung-soc@vger.kernel.org, dri-devel@lists.freedesktop.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, 21 Nov 2023 at 09:00, Inki Dae wrote: > > Hi Dave and Daniel, > > Two fixups - fixing a potential error pointer dereference and wrong > error checking. Hi Inki, This fails to build on arm32, and it seems one of the fixes is wrong [airlied@dreadlord drm-fixes]$ make ARCH=3Darm CROSS_COMPILE=3Darm-linux-gnu- O=3D../../arm-build-fixes/ -j16 make[1]: Entering directory '/home/airlied/devel/kernel/arm-build-fixes' GEN Makefile CALL /home/airlied/devel/kernel/dim/drm-fixes/scripts/checksyscall= s.sh CC [M] drivers/gpu/drm/exynos/exynos_drm_dma.o /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c: In function =E2=80=98exynos_drm_register_dma=E2=80=99: /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c:119:40: error: passing argument 1 of =E2=80=98PTR_ERR=E2=80=99 makes pointer from i= nteger without a cast [-Werror=3Dint-conversion] 119 | return PTR_ERR(-ENODEV); In file included from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/string.h:9, from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/dma-mapping.h:7, from /home/airlied/devel/kernel/dim/drm-fixes/include/linux/dma-map-ops.h:9, from /home/airlied/devel/kernel/dim/drm-fixes/drivers/gpu/drm/exynos/exynos_drm_= dma.c:7: /home/airlied/devel/kernel/dim/drm-fixes/include/linux/err.h:49:61: note: expected =E2=80=98const void *=E2=80=99 but argument is of type =E2= =80=98int=E2=80=99 49 | static inline long __must_check PTR_ERR(__force const void *ptr) | ~~~~~~~~~~~~^~~ cc1: all warnings being treated as errors I think it should just be return -ENODEV, since the function returns an int= . Please fix it up and resend. Thanks, Dave. > > Ps. regarding the first patch, I had sent a GIT-PULL[1] but it seems > you missed. > [1] https://lore.kernel.org/dri-devel/20231006040950.4397-1-inki.dae@s= amsung.com/T/#u > > Please kindly let me know if there is any problem. > > Thanks, > Inki Dae > > The following changes since commit 98b1cc82c4affc16f5598d4fa14b1858671b22= 63: > > Linux 6.7-rc2 (2023-11-19 15:02:14 -0800) > > are available in the Git repository at: > > git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos tags/e= xynos-drm-fixes-for-v6.7-rc3 > > for you to fetch changes up to a30ba4bd7cdb5726d86a557c5df8df71c7bc7fad: > > drm/exynos: fix a wrong error checking (2023-11-21 07:41:11 +0900) > > ---------------------------------------------------------------- > Two fixups > - Fix a potential error pointer dereference by checking the return value > of exynos_drm_crtc_get_by_type() function before accessing to crtc > object. > - Fix a wrong error checking in exynos_drm_dma.c modules, which was repor= ted > by Dan[1] > > [1] https://lore.kernel.org/all/33e52277-1349-472b-a55b-ab5c3462bfcf@moro= to.mountain/ > > ---------------------------------------------------------------- > Inki Dae (1): > drm/exynos: fix a wrong error checking > > Xiang Yang (1): > drm/exynos: fix a potential error pointer dereference > > drivers/gpu/drm/exynos/exynos_drm_dma.c | 8 +++----- > drivers/gpu/drm/exynos/exynos_hdmi.c | 2 ++ > 2 files changed, 5 insertions(+), 5 deletions(-)