Fix (erroneous) gcc warnings about usage of uninitialized variables in

sys/x86/iommu/intel_idpgtbl.c.

Reviewed by:	kib
This commit is contained in:
Dimitry Andric 2013-11-09 20:36:52 +00:00
parent 1bd7d0b7db
commit d4e70c8074

View File

@ -167,6 +167,8 @@ ctx_get_idmap_pgtbl(struct dmar_ctx *ctx, dmar_gaddr_t maxaddr)
vm_page_t m;
int leaf, i;
leaf = 0; /* silence gcc */
/*
* First, determine where to stop the paging structures.
*/
@ -619,6 +621,7 @@ ctx_unmap_buf_locked(struct dmar_ctx *ctx, dmar_gaddr_t base,
(uintmax_t)size));
KASSERT((flags & ~DMAR_PGF_WAITOK) == 0, ("invalid flags %x", flags));
pg_sz = 0; /* silence gcc */
base1 = base;
size1 = size;
flags |= DMAR_PGF_OBJL;