msm_rtb: Don't lose the __user tag on relaxed reads/writes
The RTB logging was accidently losing the __user tag from I/O operation addresses which caused the static analysis tools to be upset. Force a void * address for the logger but leave the original address untouched for the actual operation. Change-Id: Ic0dedbad38a49d6bfd9e102f91bbf9ae21c4c14c Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
This commit is contained in:
parent
0e2097ce85
commit
fc44c0ba38
@ -69,11 +69,10 @@ int uncached_logk(enum logk_event_type log_type, void *data);
|
||||
/* Override the #defines in asm/io.h with the logged ones */
|
||||
#define __raw_read_logged(a, _l, _t) ({ \
|
||||
_t __a; \
|
||||
void *_addr = (void *)(a); \
|
||||
int _ret; \
|
||||
_ret = uncached_logk(LOGK_READL, _addr); \
|
||||
_ret = uncached_logk(LOGK_READL, (__force void *) a); \
|
||||
ETB_WAYPOINT; \
|
||||
__a = __raw_read##_l(_addr); \
|
||||
__a = __raw_read##_l(a); \
|
||||
if (_ret) \
|
||||
LOG_BARRIER; \
|
||||
__a; \
|
||||
@ -136,10 +135,9 @@ int uncached_logk(enum logk_event_type log_type, void *data);
|
||||
|
||||
#define __raw_write_logged(v, a, _t) ({ \
|
||||
int _ret; \
|
||||
void *_addr = (void *)(a); \
|
||||
_ret = uncached_logk(LOGK_WRITEL, _addr); \
|
||||
_ret = uncached_logk(LOGK_WRITEL, (__force void *) a); \
|
||||
ETB_WAYPOINT; \
|
||||
__raw_write##_t((v), _addr); \
|
||||
__raw_write##_t((v), a); \
|
||||
if (_ret) \
|
||||
LOG_BARRIER; \
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user