platform/x86: wmi: Remove unnecessary out-of-memory message

If kzalloc() fails, an out-of-memory message is already
printed. Remove the unnecessary second warning message.

Signed-off-by: Armin Wolf <W_Armin@gmx.de>
Link: https://lore.kernel.org/r/20240206220447.3102-3-W_Armin@gmx.de
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
This commit is contained in:
Armin Wolf 2024-02-06 23:04:46 +01:00 committed by Ilpo Järvinen
parent d0c595a117
commit 49c67cd5b6
No known key found for this signature in database
GPG Key ID: 59AC4F6153E5CE31

View File

@ -1093,10 +1093,8 @@ static int parse_wdg(struct device *wmi_bus_dev, struct platform_device *pdev)
continue;
wblock = kzalloc(sizeof(*wblock), GFP_KERNEL);
if (!wblock) {
dev_err(wmi_bus_dev, "Failed to allocate %pUL\n", &gblock[i].guid);
if (!wblock)
continue;
}
wblock->acpi_device = device;
wblock->gblock = gblock[i];