* [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-19 12:22 ` hackyzh002
0 siblings, 0 replies; 15+ messages in thread
From: hackyzh002 @ 2023-04-19 12:22 UTC (permalink / raw)
To: alexander.deucher
Cc: christian.koenig, Xinhui.Pan, airlied, daniel, sumit.semwal,
amd-gfx, dri-devel, linux-kernel, linux-media, linaro-mm-sig,
hackyzh002
The type of size is unsigned int, if size is 0x40000000, there will
be an integer overflow, size will be zero after size *= sizeof(uint32_t),
will cause uninitialized memory to be referenced later.
Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
index 08eced097..89bcacc65 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
@@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
uint64_t *chunk_array_user;
uint64_t *chunk_array;
uint32_t uf_offset = 0;
- unsigned int size;
+ size_t size;
int ret;
int i;
--
2.34.1
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-19 12:22 ` hackyzh002
0 siblings, 0 replies; 15+ messages in thread
From: hackyzh002 @ 2023-04-19 12:22 UTC (permalink / raw)
To: alexander.deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, sumit.semwal, linaro-mm-sig,
dri-devel, daniel, hackyzh002, airlied, christian.koenig,
linux-media
The type of size is unsigned int, if size is 0x40000000, there will
be an integer overflow, size will be zero after size *= sizeof(uint32_t),
will cause uninitialized memory to be referenced later.
Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
index 08eced097..89bcacc65 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
@@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
uint64_t *chunk_array_user;
uint64_t *chunk_array;
uint32_t uf_offset = 0;
- unsigned int size;
+ size_t size;
int ret;
int i;
--
2.34.1
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-19 12:22 ` hackyzh002
0 siblings, 0 replies; 15+ messages in thread
From: hackyzh002 @ 2023-04-19 12:22 UTC (permalink / raw)
To: alexander.deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, sumit.semwal, linaro-mm-sig,
dri-devel, hackyzh002, christian.koenig, linux-media
The type of size is unsigned int, if size is 0x40000000, there will
be an integer overflow, size will be zero after size *= sizeof(uint32_t),
will cause uninitialized memory to be referenced later.
Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
index 08eced097..89bcacc65 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
@@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
uint64_t *chunk_array_user;
uint64_t *chunk_array;
uint32_t uf_offset = 0;
- unsigned int size;
+ size_t size;
int ret;
int i;
--
2.34.1
^ permalink raw reply related [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
2023-04-19 12:22 ` hackyzh002
(?)
@ 2023-04-27 7:44 ` whitehat002 whitehat002
-1 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-27 7:44 UTC (permalink / raw)
To: alexander.deucher
Cc: christian.koenig, Xinhui.Pan, airlied, daniel, sumit.semwal,
amd-gfx, dri-devel, linux-kernel, linux-media, linaro-mm-sig
hello
What is the current status of this patch, has it been applied?
hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
>
> The type of size is unsigned int, if size is 0x40000000, there will
> be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> will cause uninitialized memory to be referenced later.
>
> Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> index 08eced097..89bcacc65 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> uint64_t *chunk_array_user;
> uint64_t *chunk_array;
> uint32_t uf_offset = 0;
> - unsigned int size;
> + size_t size;
> int ret;
> int i;
>
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-27 7:44 ` whitehat002 whitehat002
0 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-27 7:44 UTC (permalink / raw)
To: alexander.deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, sumit.semwal, linaro-mm-sig,
dri-devel, daniel, airlied, christian.koenig, linux-media
hello
What is the current status of this patch, has it been applied?
hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
>
> The type of size is unsigned int, if size is 0x40000000, there will
> be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> will cause uninitialized memory to be referenced later.
>
> Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> index 08eced097..89bcacc65 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> uint64_t *chunk_array_user;
> uint64_t *chunk_array;
> uint32_t uf_offset = 0;
> - unsigned int size;
> + size_t size;
> int ret;
> int i;
>
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-27 7:44 ` whitehat002 whitehat002
0 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-27 7:44 UTC (permalink / raw)
To: alexander.deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, sumit.semwal, linaro-mm-sig,
dri-devel, christian.koenig, linux-media
hello
What is the current status of this patch, has it been applied?
hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
>
> The type of size is unsigned int, if size is 0x40000000, there will
> be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> will cause uninitialized memory to be referenced later.
>
> Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> index 08eced097..89bcacc65 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> uint64_t *chunk_array_user;
> uint64_t *chunk_array;
> uint32_t uf_offset = 0;
> - unsigned int size;
> + size_t size;
> int ret;
> int i;
>
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
2023-04-27 7:44 ` whitehat002 whitehat002
(?)
@ 2023-04-27 12:39 ` Alex Deucher
-1 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-27 12:39 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: alexander.deucher, Xinhui.Pan, linux-kernel, amd-gfx,
sumit.semwal, linaro-mm-sig, dri-devel, daniel, airlied,
christian.koenig, linux-media
As per my prior reply, it has been applied.
Thanks,
Alex
On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> hello
> What is the current status of this patch, has it been applied?
>
>
> hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> >
> > The type of size is unsigned int, if size is 0x40000000, there will
> > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > will cause uninitialized memory to be referenced later.
> >
> > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > ---
> > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > index 08eced097..89bcacc65 100644
> > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > uint64_t *chunk_array_user;
> > uint64_t *chunk_array;
> > uint32_t uf_offset = 0;
> > - unsigned int size;
> > + size_t size;
> > int ret;
> > int i;
> >
> > --
> > 2.34.1
> >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-27 12:39 ` Alex Deucher
0 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-27 12:39 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, alexander.deucher, sumit.semwal,
linux-media
As per my prior reply, it has been applied.
Thanks,
Alex
On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> hello
> What is the current status of this patch, has it been applied?
>
>
> hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> >
> > The type of size is unsigned int, if size is 0x40000000, there will
> > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > will cause uninitialized memory to be referenced later.
> >
> > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > ---
> > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > index 08eced097..89bcacc65 100644
> > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > uint64_t *chunk_array_user;
> > uint64_t *chunk_array;
> > uint32_t uf_offset = 0;
> > - unsigned int size;
> > + size_t size;
> > int ret;
> > int i;
> >
> > --
> > 2.34.1
> >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-27 12:39 ` Alex Deucher
0 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-27 12:39 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, daniel, alexander.deucher, airlied,
sumit.semwal, linux-media
As per my prior reply, it has been applied.
Thanks,
Alex
On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> hello
> What is the current status of this patch, has it been applied?
>
>
> hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> >
> > The type of size is unsigned int, if size is 0x40000000, there will
> > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > will cause uninitialized memory to be referenced later.
> >
> > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > ---
> > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > index 08eced097..89bcacc65 100644
> > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > uint64_t *chunk_array_user;
> > uint64_t *chunk_array;
> > uint32_t uf_offset = 0;
> > - unsigned int size;
> > + size_t size;
> > int ret;
> > int i;
> >
> > --
> > 2.34.1
> >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
2023-04-27 12:39 ` Alex Deucher
(?)
@ 2023-04-28 0:45 ` whitehat002 whitehat002
-1 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-28 0:45 UTC (permalink / raw)
To: Alex Deucher
Cc: alexander.deucher, Xinhui.Pan, linux-kernel, amd-gfx,
sumit.semwal, linaro-mm-sig, dri-devel, daniel, airlied,
christian.koenig, linux-media
Alex,I have a question, why I don't see it on the
https://patchwork.freedesktop.org/
Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
>
> As per my prior reply, it has been applied.
>
> Thanks,
>
> Alex
>
> On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> <hackyzh002@gmail.com> wrote:
> >
> > hello
> > What is the current status of this patch, has it been applied?
> >
> >
> > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > >
> > > The type of size is unsigned int, if size is 0x40000000, there will
> > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > will cause uninitialized memory to be referenced later.
> > >
> > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > ---
> > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > index 08eced097..89bcacc65 100644
> > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > uint64_t *chunk_array_user;
> > > uint64_t *chunk_array;
> > > uint32_t uf_offset = 0;
> > > - unsigned int size;
> > > + size_t size;
> > > int ret;
> > > int i;
> > >
> > > --
> > > 2.34.1
> > >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-28 0:45 ` whitehat002 whitehat002
0 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-28 0:45 UTC (permalink / raw)
To: Alex Deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, alexander.deucher, sumit.semwal,
linux-media
Alex,I have a question, why I don't see it on the
https://patchwork.freedesktop.org/
Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
>
> As per my prior reply, it has been applied.
>
> Thanks,
>
> Alex
>
> On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> <hackyzh002@gmail.com> wrote:
> >
> > hello
> > What is the current status of this patch, has it been applied?
> >
> >
> > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > >
> > > The type of size is unsigned int, if size is 0x40000000, there will
> > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > will cause uninitialized memory to be referenced later.
> > >
> > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > ---
> > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > index 08eced097..89bcacc65 100644
> > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > uint64_t *chunk_array_user;
> > > uint64_t *chunk_array;
> > > uint32_t uf_offset = 0;
> > > - unsigned int size;
> > > + size_t size;
> > > int ret;
> > > int i;
> > >
> > > --
> > > 2.34.1
> > >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-28 0:45 ` whitehat002 whitehat002
0 siblings, 0 replies; 15+ messages in thread
From: whitehat002 whitehat002 @ 2023-04-28 0:45 UTC (permalink / raw)
To: Alex Deucher
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, daniel, alexander.deucher, airlied,
sumit.semwal, linux-media
Alex,I have a question, why I don't see it on the
https://patchwork.freedesktop.org/
Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
>
> As per my prior reply, it has been applied.
>
> Thanks,
>
> Alex
>
> On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> <hackyzh002@gmail.com> wrote:
> >
> > hello
> > What is the current status of this patch, has it been applied?
> >
> >
> > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > >
> > > The type of size is unsigned int, if size is 0x40000000, there will
> > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > will cause uninitialized memory to be referenced later.
> > >
> > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > ---
> > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > index 08eced097..89bcacc65 100644
> > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > uint64_t *chunk_array_user;
> > > uint64_t *chunk_array;
> > > uint32_t uf_offset = 0;
> > > - unsigned int size;
> > > + size_t size;
> > > int ret;
> > > int i;
> > >
> > > --
> > > 2.34.1
> > >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
2023-04-28 0:45 ` whitehat002 whitehat002
(?)
@ 2023-04-28 13:31 ` Alex Deucher
-1 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-28 13:31 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: alexander.deucher, Xinhui.Pan, linux-kernel, amd-gfx,
sumit.semwal, linaro-mm-sig, dri-devel, daniel, airlied,
christian.koenig, linux-media
these?
https://patchwork.freedesktop.org/series/116699/
https://patchwork.freedesktop.org/series/116695/
On Thu, Apr 27, 2023 at 8:45 PM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> Alex,I have a question, why I don't see it on the
> https://patchwork.freedesktop.org/
>
> Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
> >
> > As per my prior reply, it has been applied.
> >
> > Thanks,
> >
> > Alex
> >
> > On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> > <hackyzh002@gmail.com> wrote:
> > >
> > > hello
> > > What is the current status of this patch, has it been applied?
> > >
> > >
> > > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > > >
> > > > The type of size is unsigned int, if size is 0x40000000, there will
> > > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > > will cause uninitialized memory to be referenced later.
> > > >
> > > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > > ---
> > > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > index 08eced097..89bcacc65 100644
> > > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > > uint64_t *chunk_array_user;
> > > > uint64_t *chunk_array;
> > > > uint32_t uf_offset = 0;
> > > > - unsigned int size;
> > > > + size_t size;
> > > > int ret;
> > > > int i;
> > > >
> > > > --
> > > > 2.34.1
> > > >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-28 13:31 ` Alex Deucher
0 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-28 13:31 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, alexander.deucher, sumit.semwal,
linux-media
these?
https://patchwork.freedesktop.org/series/116699/
https://patchwork.freedesktop.org/series/116695/
On Thu, Apr 27, 2023 at 8:45 PM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> Alex,I have a question, why I don't see it on the
> https://patchwork.freedesktop.org/
>
> Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
> >
> > As per my prior reply, it has been applied.
> >
> > Thanks,
> >
> > Alex
> >
> > On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> > <hackyzh002@gmail.com> wrote:
> > >
> > > hello
> > > What is the current status of this patch, has it been applied?
> > >
> > >
> > > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > > >
> > > > The type of size is unsigned int, if size is 0x40000000, there will
> > > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > > will cause uninitialized memory to be referenced later.
> > > >
> > > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > > ---
> > > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > index 08eced097..89bcacc65 100644
> > > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > > uint64_t *chunk_array_user;
> > > > uint64_t *chunk_array;
> > > > uint32_t uf_offset = 0;
> > > > - unsigned int size;
> > > > + size_t size;
> > > > int ret;
> > > > int i;
> > > >
> > > > --
> > > > 2.34.1
> > > >
^ permalink raw reply [flat|nested] 15+ messages in thread
* Re: [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1
@ 2023-04-28 13:31 ` Alex Deucher
0 siblings, 0 replies; 15+ messages in thread
From: Alex Deucher @ 2023-04-28 13:31 UTC (permalink / raw)
To: whitehat002 whitehat002
Cc: Xinhui.Pan, linux-kernel, amd-gfx, christian.koenig,
linaro-mm-sig, dri-devel, daniel, alexander.deucher, airlied,
sumit.semwal, linux-media
these?
https://patchwork.freedesktop.org/series/116699/
https://patchwork.freedesktop.org/series/116695/
On Thu, Apr 27, 2023 at 8:45 PM whitehat002 whitehat002
<hackyzh002@gmail.com> wrote:
>
> Alex,I have a question, why I don't see it on the
> https://patchwork.freedesktop.org/
>
> Alex Deucher <alexdeucher@gmail.com> 于2023年4月27日周四 20:40写道:
> >
> > As per my prior reply, it has been applied.
> >
> > Thanks,
> >
> > Alex
> >
> > On Thu, Apr 27, 2023 at 8:39 AM whitehat002 whitehat002
> > <hackyzh002@gmail.com> wrote:
> > >
> > > hello
> > > What is the current status of this patch, has it been applied?
> > >
> > >
> > > hackyzh002 <hackyzh002@gmail.com> 于2023年4月19日周三 20:23写道:
> > > >
> > > > The type of size is unsigned int, if size is 0x40000000, there will
> > > > be an integer overflow, size will be zero after size *= sizeof(uint32_t),
> > > > will cause uninitialized memory to be referenced later.
> > > >
> > > > Signed-off-by: hackyzh002 <hackyzh002@gmail.com>
> > > > ---
> > > > drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +-
> > > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > > >
> > > > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > index 08eced097..89bcacc65 100644
> > > > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
> > > > @@ -192,7 +192,7 @@ static int amdgpu_cs_pass1(struct amdgpu_cs_parser *p,
> > > > uint64_t *chunk_array_user;
> > > > uint64_t *chunk_array;
> > > > uint32_t uf_offset = 0;
> > > > - unsigned int size;
> > > > + size_t size;
> > > > int ret;
> > > > int i;
> > > >
> > > > --
> > > > 2.34.1
> > > >
^ permalink raw reply [flat|nested] 15+ messages in thread
end of thread, other threads:[~2023-04-28 13:31 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-04-19 12:22 [PATCH v3 2/2] drm/amdgpu: Fix integer overflow in amdgpu_cs_pass1 hackyzh002
2023-04-19 12:22 ` hackyzh002
2023-04-19 12:22 ` hackyzh002
2023-04-27 7:44 ` whitehat002 whitehat002
2023-04-27 7:44 ` whitehat002 whitehat002
2023-04-27 7:44 ` whitehat002 whitehat002
2023-04-27 12:39 ` Alex Deucher
2023-04-27 12:39 ` Alex Deucher
2023-04-27 12:39 ` Alex Deucher
2023-04-28 0:45 ` whitehat002 whitehat002
2023-04-28 0:45 ` whitehat002 whitehat002
2023-04-28 0:45 ` whitehat002 whitehat002
2023-04-28 13:31 ` Alex Deucher
2023-04-28 13:31 ` Alex Deucher
2023-04-28 13:31 ` Alex Deucher
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.