Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 120511
Collapse All | Expand All

(-)LVM2.2.01.14/lib/mm/pool-fast.c (-4 / +4 lines)
Lines 30-37 struct pool { Link Here
30
	unsigned object_alignment;
30
	unsigned object_alignment;
31
};
31
};
32
32
33
void _align_chunk(struct chunk *c, unsigned alignment);
33
static void _align_chunk(struct chunk *c, unsigned alignment);
34
struct chunk *_new_chunk(struct pool *p, size_t s);
34
static struct chunk *_new_chunk(struct pool *p, size_t s);
35
35
36
/* by default things come out aligned for doubles */
36
/* by default things come out aligned for doubles */
37
#define DEFAULT_ALIGNMENT __alignof__ (double)
37
#define DEFAULT_ALIGNMENT __alignof__ (double)
Lines 204-215 void pool_abandon_object(struct pool *p) Link Here
204
	p->object_alignment = DEFAULT_ALIGNMENT;
204
	p->object_alignment = DEFAULT_ALIGNMENT;
205
}
205
}
206
206
207
void _align_chunk(struct chunk *c, unsigned alignment)
207
static void _align_chunk(struct chunk *c, unsigned alignment)
208
{
208
{
209
	c->begin += alignment - ((unsigned long) c->begin & (alignment - 1));
209
	c->begin += alignment - ((unsigned long) c->begin & (alignment - 1));
210
}
210
}
211
211
212
struct chunk *_new_chunk(struct pool *p, size_t s)
212
static struct chunk *_new_chunk(struct pool *p, size_t s)
213
{
213
{
214
	struct chunk *c;
214
	struct chunk *c;
215
215

Return to bug 120511