intel-iommu: cast the type before left shift

To avoid overflow, cast the type of some variables before left shift.

Signed-off-by: Le Tan <tamlokveer@gmail.com>
intel-iommu: fix iq_last_desc_type and the handle of Invalidation Wait Descriptor

Update IntelIOMMUState->iq_last_desc_type when process a invalidation descriptor.
Use cpu_to_le32() before dma_memory_write() in vtd_process_wait_desc().

Signed-off-by: Le Tan <tamlokveer@gmail.com>