* [PATCH] parport: Revert "parport: fix memory leak"
@ 2015-07-25 7:49 Sudip Mukherjee
2015-07-25 17:22 ` Sudip Mukherjee
0 siblings, 1 reply; 2+ messages in thread
From: Sudip Mukherjee @ 2015-07-25 7:49 UTC (permalink / raw)
To: Greg KH; +Cc: linux-kernel, Ying Huang, Sudip Mukherjee
This reverts commit 23c405912b88 ("parport: fix memory leak")
par_dev->state was already being removed in parport_unregister_device().
Reported-by: Ying Huang <ying.huang@intel.com>
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
But I am surprised at two points:
1) Why the error came while loading the gs_fpgaboot module?
Maybe the double freeing has freed some memory which fpga was
using.
2) Why the dmesg showed "panel: could not claim access to parport0. Aborting."?
Because of 50566ac87065 ("parport: check exclusive access before
register") the panel driver should not even register and it
should have failed at parport_register_dev_model().
drivers/parport/share.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/parport/share.c b/drivers/parport/share.c
index c02b5f2..5ce5ef2 100644
--- a/drivers/parport/share.c
+++ b/drivers/parport/share.c
@@ -816,7 +816,6 @@ static void free_pardevice(struct device *dev)
struct pardevice *par_dev = to_pardevice(dev);
kfree(par_dev->name);
- kfree(par_dev->state);
kfree(par_dev);
}
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] parport: Revert "parport: fix memory leak"
2015-07-25 7:49 [PATCH] parport: Revert "parport: fix memory leak" Sudip Mukherjee
@ 2015-07-25 17:22 ` Sudip Mukherjee
0 siblings, 0 replies; 2+ messages in thread
From: Sudip Mukherjee @ 2015-07-25 17:22 UTC (permalink / raw)
To: Greg KH; +Cc: linux-kernel, Ying Huang
On Sat, Jul 25, 2015 at 01:19:40PM +0530, Sudip Mukherjee wrote:
> 2) Why the dmesg showed "panel: could not claim access to parport0. Aborting."?
> Because of 50566ac87065 ("parport: check exclusive access before
> register") the panel driver should not even register and it
> should have failed at parport_register_dev_model().
Because panel is not claiming exclusive access of parport.
regards
sudip
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-07-25 17:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-07-25 7:49 [PATCH] parport: Revert "parport: fix memory leak" Sudip Mukherjee
2015-07-25 17:22 ` Sudip Mukherjee
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox