msm: kgsl: Return error if the user allocates a buffer size of zero

Instead of calling BUG_ON if the user passes a zero length via
IOCTL_KGSL_GPUMEM_ALLOC to kgsl_sharedmem_alloc_user, return
-EINVAL instead and propegate the error back up to the user.

CRs-fixed: 389886
Change-Id: Ic0dedbad2dc1f68ad1d3227498893c73c2a1c59e
Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
msm: rmt_storage: Add support for reboot notifier

For graceful shutdown or reboot scenarios, RMT storage
sync must be completed successfuly before device shutdown.
So register with reboot notifier to initiate the RMT
storage force sync.

CRs-Fixed: 419695
CRs-Fixed: 548978
Change-Id: I6d8783d2ad2b7112fd6e84d3a9dcf033cc804a8c
Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
Signed-off-by: Pratibhasagar V <pratibha@codeaurora.org>
Merge "msm: kgsl: Return error if the user allocates a buffer size of zero"
Merge "msm: rmt_storage: Add support for reboot notifier"