login
Header Space

 
 

Re: [PATCH] CDROM: use kmalloced buffers instead of buffers on stack

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Thomas Bogendoerfer <tsbogend@...>
Cc: <linux-kernel@...>, <axboe@...>
Date: Sunday, March 23, 2008 - 7:47 am

[Thomas Bogendoerfer - Sun, Mar 23, 2008 at 12:15:32PM +0100]
| If cdrom commands are issued to a scsi drive in most cases the buffer
| will be filled via dma. This leads to bad stack corruption on non coherent
| platforms, because the buffers are neither cache line aligned nor is
| the size a multiple of the cache line size. Using kmalloced buffers
| avoids this.
| 
| Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
| ---
| 
|  drivers/cdrom/cdrom.c |  274 ++++++++++++++++++++++++++++++++-----------------
|  1 files changed, 181 insertions(+), 93 deletions(-)
| 
[...]

Hi Thomas,

maybe would be better to use one memory pool instead?

		- Cyrill -
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH] CDROM: use kmalloced buffers instead of buffers on s..., Thomas Bogendoerfer, (Sun Mar 23, 7:15 am)
Re: [PATCH] CDROM: use kmalloced buffers instead of buffers ..., Cyrill Gorcunov, (Sun Mar 23, 7:47 am)
speck-geostationary