Write  to device.map instead of assuming .img. Make use of  and  in f_grub()