msm: pil: Add support for ramdumping images
PIL drivers know where their images are going to be loaded and so
they have hard-coded the region of memory reserved for their
image into the kernel to pass to the ramdump function. This has
worked out well so far because the fixed memory map rarely
changes after the development phase. For relocatable images this
won't work because we no longer know where the images reside at
compile time.
Add a new API
int pil_do_ramdump(struct pil_desc *desc, void *ramdump_dev);
that takes a ramdump device and a pil descriptor and dumps the
image's segments to the ramdump device. This should allow us to
clean up all the PIL drivers so that they just call this function
instead of hard-coding addresses in their driver. It has the
added benefit of making ramdumps work for relocatable images.
Change-Id: Iac4fa64e810529bc7fb9b3269c416f7d43b57418
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
2 files changed