* [PATCH] video: imxfb: Fix call of memalign()
@ 2022-06-27 9:58 Uwe Kleine-König
2022-06-29 7:11 ` Sascha Hauer
0 siblings, 1 reply; 2+ messages in thread
From: Uwe Kleine-König @ 2022-06-27 9:58 UTC (permalink / raw)
To: barebox
The first argument is the alignment not the allocation size ...
Fixes: 36152c5aa546 ("video: imx: assert that image buffer doesn't cross a 4 MiB boundary")
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
drivers/video/imx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/video/imx.c b/drivers/video/imx.c
index d15c2d88fb91..633815f5d919 100644
--- a/drivers/video/imx.c
+++ b/drivers/video/imx.c
@@ -404,7 +404,7 @@ static int imxfb_allocate_fbbuffer(const struct device_d *dev,
* allocation as necessary, but in the absense of a better
* function just use it.
*/
- info->screen_base = memalign(fbsize, SZ_4M);
+ info->screen_base = memalign(SZ_4M, fbsize);
if (!info->screen_base)
return -ENOMEM;
memset(info->screen_base, 0, fbsize);
base-commit: ff087598f4cdc426ba883a8720367a4ff3d6b9fe
--
2.36.1
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] video: imxfb: Fix call of memalign()
2022-06-27 9:58 [PATCH] video: imxfb: Fix call of memalign() Uwe Kleine-König
@ 2022-06-29 7:11 ` Sascha Hauer
0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2022-06-29 7:11 UTC (permalink / raw)
To: Uwe Kleine-König; +Cc: barebox
On Mon, Jun 27, 2022 at 11:58:55AM +0200, Uwe Kleine-König wrote:
> The first argument is the alignment not the allocation size ...
>
> Fixes: 36152c5aa546 ("video: imx: assert that image buffer doesn't cross a 4 MiB boundary")
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> ---
> drivers/video/imx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to master, thanks
Sascha
>
> diff --git a/drivers/video/imx.c b/drivers/video/imx.c
> index d15c2d88fb91..633815f5d919 100644
> --- a/drivers/video/imx.c
> +++ b/drivers/video/imx.c
> @@ -404,7 +404,7 @@ static int imxfb_allocate_fbbuffer(const struct device_d *dev,
> * allocation as necessary, but in the absense of a better
> * function just use it.
> */
> - info->screen_base = memalign(fbsize, SZ_4M);
> + info->screen_base = memalign(SZ_4M, fbsize);
> if (!info->screen_base)
> return -ENOMEM;
> memset(info->screen_base, 0, fbsize);
>
> base-commit: ff087598f4cdc426ba883a8720367a4ff3d6b9fe
> --
> 2.36.1
>
>
>
--
Pengutronix e.K. | |
Steuerwalder Str. 21 | http://www.pengutronix.de/ |
31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-06-29 7:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-27 9:58 [PATCH] video: imxfb: Fix call of memalign() Uwe Kleine-König
2022-06-29 7:11 ` Sascha Hauer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox