Re: Brainy: Kernel Memory Leak in sdmmc

2015-02-15 Thread Doug Hogan
On Sun, Feb 15, 2015 at 08:53:08PM +, Miod Vallat wrote: This ought to fix this problem: This looks reasonable but needs a tweak if you want to keep the existing behavior. In the existing code, it has this section above the copyout(): rw_enter_write(sc-sc_lock);

Re: Brainy: Kernel Memory Leak in sdmmc

2015-02-15 Thread Miod Vallat
Hi, I put here a bug among others: -- dev/sdmmc/sdmmc.c -- 783 data = malloc(ucmd-c_datalen, M_TEMP, M_WAITOK | M_CANFAIL); if (data == NULL)

Re: Brainy: Kernel Memory Leak in sdmmc

2015-02-15 Thread Miod Vallat
On Sun, Feb 15, 2015 at 08:53:08PM +, Miod Vallat wrote: This ought to fix this problem: This looks reasonable but needs a tweak if you want to keep the existing behavior. In the existing code, it has this section above the copyout(): rw_enter_write(sc-sc_lock);