[PATCH] hdparm utilizes shared memory for no good reason ?
Rob Landley
rob at landley.net
Wed May 17 04:24:54 UTC 2006
On Tuesday 16 May 2006 11:46 pm, Mike Frysinger wrote:
> On Tuesday 16 May 2006 16:23, Tito wrote:
> > the first patch adds a config option to disable the use of shared memory
> > segments when performing timings on devices and substitute them with
> > static or malloced buffers.
>
> i like this patch better ... also, it'd prob be a good idea to use mlock()
> on the buffer in the non-shared memory path and if the func fails, just
> spit a warning rather than aborting
> -mike
That's what I was thinking of. mlock().
Yeah, I think the use of shared memory should be ripped out and replaced with
mlock. The benchmark only has one process so there's no point in sharing the
memory, I'm fairly certain they were just trying to prevent it from swapping
out. I'm going to go fall over now. (Day schedule and late night use of
laptop do not mix. My sense of balance went 20 minutes ago...)
Rob
--
Never bet against the cheap plastic solution.
More information about the busybox
mailing list