Re: [PATCH v2] fbdev: platinumfb: add error checking for ioremap calls
Helge Deller <[email protected]>
| Newsgroups | org.kernel.vger.linux-fbdev,org.freedesktop.lists.dri-devel,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
On 8/17/26 08:39, yuebingkun wrote:
> The ioremap() and ioremap_wt() calls in platinumfb_probe() were not
> checked for failure. If any of these mappings fail, the driver would
> dereference NULL pointers, leading to a kernel panic.
>
> Add proper error checking and use goto-based cleanup to avoid code
> duplication across the error paths.
>
> Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
That Fixes line ^^^ has no value, so I dropped it.
> Signed-off-by: yuebingkun <[email protected]>
Would be nice to have your Name written out here, e.g. Yue Bing Kun (or something),
but I've left it as-is for now. In case you resend with full name, I can replace it
in the git tree.
> drivers/video/fbdev/platinumfb.c | 36 ++++++++++++++++++++++++++------
> 1 file changed, 30 insertions(+), 6 deletions(-)
Patch applied (with the Fixes line dropped).
Thanks!
Helge