/* img_update_free: Frees the buffer allocated for storing BIOS image Always called with lock held and returned with lock held  */
static void img_update_free(void)
/* img_update_free: Frees the buffer allocated for storing BIOS image Always called with lock held and returned with lock held  */
static void img_update_free(void)
{
	if (!rbu_data.image_update_buffer)
		return;
	memset(rbu_data.image_update_buffer, 0,
		rbu_data.image_update_buffer_size);
	if (rbu_data.dma_alloc == 1)
		dma_free_coherent(NULL, rbu_data.bios_image_size,
			rbu_data.image_update_buffer, dell_rbu_dmaaddr);
	else
		free_pages((unsigned long) rbu_data.image_update_buffer,
			rbu_data.image_update_ordernum);
	rbu_data.image_update_ordernum = -1;
	rbu_data.image_update_buffer = NULL;
	rbu_data.image_update_buffer_size = 0;
	rbu_data.bios_image_size = 0;
	rbu_data.dma_alloc = 0;
}