From eeae1d48c011839d9e1cdc1e8aacf0193c9d8197 Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Wed, 7 May 2008 13:26:27 +0200 Subject: block: use unitialized_var() in bio_alloc_bioset() Better than setting idx to some random value and it silences the same bogus gcc warning. Signed-off-by: Jens Axboe --- fs/bio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fs/bio.c') diff --git a/fs/bio.c b/fs/bio.c index 799f86deff2..2fa04ff8670 100644 --- a/fs/bio.c +++ b/fs/bio.c @@ -158,7 +158,7 @@ struct bio *bio_alloc_bioset(gfp_t gfp_mask, int nr_iovecs, struct bio_set *bs) bio_init(bio); if (likely(nr_iovecs)) { - unsigned long idx = 0; /* shut up gcc */ + unsigned long uninitialized_var(idx); bvl = bvec_alloc_bs(gfp_mask, nr_iovecs, &idx, bs); if (unlikely(!bvl)) { -- cgit v1.2.3-70-g09d2