lkml.org 
[lkml]   [2019]   [May]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] net: via-rhine: net: Fix a resource leak in rhine_init()
From
From: Jia-Ju Bai <baijiaju1990@gmail.com>
Date: Sat, 4 May 2019 11:08:13 +0800

> When platform_driver_register() fails, pci_unregister_driver() is not
> called to release the resource allocated by pci_register_driver().
>
> To fix this bug, error handling code for platform_driver_register() and
> pci_register_driver() is separately implemented.
>
> This bug is found by a runtime fuzzing tool named FIZZER written by us.
>
> Signed-off-by: Jia-Ju Bai <baijiaju1990@gmail.com>

I think the idea here is that PCI is not enabled in the kernel, it is
fine for the pci register to fail and only the platform register to
succeed.

You are breaking that.

\
 
 \ /
  Last update: 2019-05-04 05:15    [W:0.401 / U:0.432 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site