# \[PATCH\] video/console/sticore: Delete an error message for a failed memory allocation in sti\_try\_rom\_generic()

- Subsystems: FRAMEBUFFER LAYER, CONSOLE SUBSYSTEM, PARISC ARCHITECTURE, THE REST
- Maintainers: Helge Deller, Greg Kroah-Hartman, "James E.J. Bottomley", Linus Torvalds
- List: linux-fbdev
- 2 messages, 2 authors
- Page: https://ratatoskr.run/linux-fbdev/2017/12/5149689/t

## \[PATCH\] video/console/sticore: Delete an error message for a failed memory allocation in sti\_try\_rom\_generic()

- From: SF Markus Elfring \<hidden\>
- Date: 2017-12-05 18:00:39 
- Message: https://ratatoskr.run/linux-fbdev/2017/12/5149689.md

```text
From: Markus Elfring <redacted>
Date: Tue, 5 Dec 2017 18:45:42 +0100

Omit an extra message for a memory allocation failure in this function.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <redacted>
---
 drivers/video/console/sticore.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/video/console/sticore.c b/drivers/video/console/sticore.c
index d1d3796773aa..08b822656846 100644
--- a/drivers/video/console/sticore.c
+++ b/drivers/video/console/sticore.c
@@ -827,10 +827,8 @@ static struct sti_struct *sti_try_rom_generic(unsigned long address,
 	}
 	
 	sti = kzalloc(sizeof(*sti), GFP_KERNEL);
-	if (!sti) {
-		printk(KERN_ERR "Not enough memory !\n");
+	if (!sti)
 		return NULL;
-	}
 
 	spin_lock_init(&sti->lock);
 
-- 
2.15.1

```

## Re: \[PATCH\] video/console/sticore: Delete an error message for a failed memory allocation in sti\_try\_rom\_generic()

- From: Bartlomiej Zolnierkiewicz \<hidden\>
- Date: 2018-03-28 14:19:46 
- Message: https://ratatoskr.run/linux-fbdev/2018/03/5244843.md

```text
On Tuesday, December 05, 2017 07:00:22 PM SF Markus Elfring wrote:
> From: Markus Elfring <redacted>
> Date: Tue, 5 Dec 2017 18:45:42 +0100
> 
> Omit an extra message for a memory allocation failure in this function.
> 
> This issue was detected by using the Coccinelle software.
> 
> Signed-off-by: Markus Elfring <redacted>

Patch queued for 4.17, thanks.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

```
