Commit 39757e7351f874a614a46d634c415ca69e154e53

Authored by Linus Torvalds

Merge tag 'nios2-fixes-v3.19' of git://git.rocketboards.org/linux-socfpga-next

Pull arch/nios2 fixes from Ley Foon Tan:
 - add definition of ioremap_wc to io.h to fix build error from make
   allmodconfig
 - fix make defconfig
 - fix sparse error

* tag 'nios2-fixes-v3.19' of git://git.rocketboards.org/linux-socfpga-next:
  nios2/uaccess: fix sparse errors
  nios2: enable "make defconfig"
  nios2: add definition of ioremap_wc to io.h

Showing 3 changed files Side-by-side Diff

... ... @@ -14,6 +14,8 @@
14 14 # Nios2 port by Wind River Systems Inc trough:
15 15 # fredrik.markstrom@gmail.com and ivarholmqvist@gmail.com
16 16  
  17 +KBUILD_DEFCONFIG := 3c120_defconfig
  18 +
17 19 UTS_SYSNAME = Linux
18 20  
19 21 export MMU
arch/nios2/include/asm/io.h
... ... @@ -45,6 +45,8 @@
45 45 __iounmap(addr);
46 46 }
47 47  
  48 +#define ioremap_wc ioremap_nocache
  49 +
48 50 /* Pages to physical address... */
49 51 #define page_to_phys(page) virt_to_phys(page_to_virt(page))
50 52 #define page_to_bus(page) page_to_virt(page)
arch/nios2/include/asm/uaccess.h
... ... @@ -168,7 +168,7 @@
168 168 const __typeof__(*(ptr)) __user *__gu_ptr = (ptr); \
169 169 unsigned long __gu_val; \
170 170 __get_user_common(__gu_val, sizeof(*(ptr)), __gu_ptr, __gu_err);\
171   - (x) = (__typeof__(x))__gu_val; \
  171 + (x) = (__force __typeof__(x))__gu_val; \
172 172 __gu_err; \
173 173 })
174 174  
... ... @@ -180,7 +180,7 @@
180 180 if (access_ok(VERIFY_READ, __gu_ptr, sizeof(*__gu_ptr))) \
181 181 __get_user_common(__gu_val, sizeof(*__gu_ptr), \
182 182 __gu_ptr, __gu_err); \
183   - (x) = (__typeof__(x))__gu_val; \
  183 + (x) = (__force __typeof__(x))__gu_val; \
184 184 __gu_err; \
185 185 })
186 186