uaccess: fix nios2 and microblaze get_user_8()
stable inclusion from stable-v5.10.110 commit 7ce3e6e1036e98eb3712b29433784061cfa0bbff bugzilla: https://gitee.com/openeuler/kernel/issues/I574AL Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=7ce3e6e1036e98eb3712b29433784061cfa0bbff -------------------------------- [ Upstream commit a97b693c ] These two architectures implement 8-byte get_user() through a memcpy() into a four-byte variable, which won't fit. Use a temporary 64-bit variable instead here, and use a double cast the way that risc-v and openrisc do to avoid compile-time warnings. Fixes: 6a090e97 ("arch/microblaze: support get_user() of size 8 bytes") Fixes: 5ccc6af5 ("nios2: Memory management") Reviewed-by: NChristoph Hellwig <hch@lst.de> Acked-by: NDinh Nguyen <dinguyen@kernel.org> Signed-off-by: NArnd Bergmann <arnd@arndb.de> Signed-off-by: NSasha Levin <sashal@kernel.org> Signed-off-by: NYu Liao <liaoyu15@huawei.com> Reviewed-by: NWei Li <liwei391@huawei.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录