
7 Feb
2008
7 Feb
'08
3:58 p.m.
On Thu, 7 Feb 2008, Jerry Van Baren wrote:
Your original question/concept still used the name "addr_mask" which caused confusion on my part.
Ahhh, that's just a variable name:-)
It really should be a length, not a mask.
Of course.
Illustrating with a hand-generated patch, what I am now hearing is the following change:
addr_mask = ((ulong)end - (ulong)start)/sizeof(vu_long);
len = ((ulong)end - (ulong)start)/sizeof(vu_long);
...
for (offset = 1; (offset & addr_mask) != 0; offset <<= 1) {
}for (offset = 1; offset < len; offset <<= 1) { start[offset] = pattern;
That makes sense to me.
Exactly. If everyone agrees, I'll try not to forget to cook up a patch.
Thanks Guennadi --- Guennadi Liakhovetski