Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'asm-generic-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic

Pull asm-generic cleanups from Arnd Bergmann:
"The asm-generic changes for 4.4 are mostly a series from Christoph
Hellwig to clean up various abuses of headers in there. The patch to
rename the io-64-nonatomic-*.h headers caused some conflicts with new
users, so I added a workaround that we can remove in the next merge
window.

The only other patch is a warning fix from Marek Vasut"

* tag 'asm-generic-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic:
asm-generic: temporarily add back asm-generic/io-64-nonatomic*.h
asm-generic: cmpxchg: avoid warnings from macro-ized cmpxchg() implementations
gpio-mxc: stop including <asm-generic/bug>
n_tracesink: stop including <asm-generic/bug>
n_tracerouter: stop including <asm-generic/bug>
mlx5: stop including <asm-generic/kmap_types.h>
hifn_795x: stop including <asm-generic/kmap_types.h>
drbd: stop including <asm-generic/kmap_types.h>
move count_zeroes.h out of asm-generic
move io-64-nonatomic*.h out of asm-generic

+103 -100
+1 -1
drivers/acpi/nfit.c
··· 27 27 * For readq() and writeq() on 32-bit builds, the hi-lo, lo-hi order is 28 28 * irrelevant. 29 29 */ 30 - #include <asm-generic/io-64-nonatomic-hi-lo.h> 30 + #include <linux/io-64-nonatomic-hi-lo.h> 31 31 32 32 static bool force_enable_dimms; 33 33 module_param(force_enable_dimms, bool, S_IRUGO|S_IWUSR);
+1 -1
drivers/acpi/osl.c
··· 43 43 44 44 #include <asm/io.h> 45 45 #include <asm/uaccess.h> 46 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 46 + #include <linux/io-64-nonatomic-lo-hi.h> 47 47 48 48 #include "internal.h" 49 49
+1 -1
drivers/block/drbd/drbd_bitmap.c
··· 29 29 #include <linux/string.h> 30 30 #include <linux/drbd.h> 31 31 #include <linux/slab.h> 32 - #include <asm/kmap_types.h> 32 + #include <linux/highmem.h> 33 33 34 34 #include "drbd_int.h" 35 35
-2
drivers/crypto/hifn_795x.c
··· 36 36 #include <crypto/algapi.h> 37 37 #include <crypto/des.h> 38 38 39 - #include <asm/kmap_types.h> 40 - 41 39 //#define HIFN_DEBUG 42 40 43 41 #ifdef HIFN_DEBUG
+1 -1
drivers/edac/i3200_edac.c
··· 15 15 #include <linux/io.h> 16 16 #include "edac_core.h" 17 17 18 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 18 + #include <linux/io-64-nonatomic-lo-hi.h> 19 19 20 20 #define I3200_REVISION "1.1" 21 21
+1 -1
drivers/edac/ie31200_edac.c
··· 39 39 #include <linux/pci_ids.h> 40 40 #include <linux/edac.h> 41 41 42 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 42 + #include <linux/io-64-nonatomic-lo-hi.h> 43 43 #include "edac_core.h" 44 44 45 45 #define IE31200_REVISION "1.0"
+1 -1
drivers/edac/x38_edac.c
··· 15 15 #include <linux/pci_ids.h> 16 16 #include <linux/edac.h> 17 17 18 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 18 + #include <linux/io-64-nonatomic-lo-hi.h> 19 19 #include "edac_core.h" 20 20 21 21 #define X38_REVISION "1.1"
+1 -1
drivers/gpio/gpio-mxc.c
··· 33 33 #include <linux/of.h> 34 34 #include <linux/of_device.h> 35 35 #include <linux/module.h> 36 - #include <asm-generic/bug.h> 36 + #include <linux/bug.h> 37 37 38 38 enum mxc_gpio_hwtype { 39 39 IMX1_GPIO, /* runs on i.mx1 */
+1 -1
drivers/i2c/busses/i2c-ismt.c
··· 67 67 #include <linux/acpi.h> 68 68 #include <linux/interrupt.h> 69 69 70 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 70 + #include <linux/io-64-nonatomic-lo-hi.h> 71 71 72 72 /* PCI Address Constants */ 73 73 #define SMBBAR 0
+1 -1
drivers/infiniband/hw/mlx5/main.c
··· 30 30 * SOFTWARE. 31 31 */ 32 32 33 - #include <asm-generic/kmap_types.h> 33 + #include <linux/highmem.h> 34 34 #include <linux/module.h> 35 35 #include <linux/init.h> 36 36 #include <linux/errno.h>
+1 -2
drivers/mfd/intel-lpss.c
··· 25 25 #include <linux/pm_qos.h> 26 26 #include <linux/pm_runtime.h> 27 27 #include <linux/seq_file.h> 28 - 29 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 28 + #include <linux/io-64-nonatomic-lo-hi.h> 30 29 31 30 #include "intel-lpss.h" 32 31
+1 -1
drivers/net/ethernet/intel/i40e/i40e_osdep.h
··· 35 35 #include <linux/highuid.h> 36 36 37 37 /* get readq/writeq support for 32 bit kernels, use the low-first version */ 38 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 38 + #include <linux/io-64-nonatomic-lo-hi.h> 39 39 40 40 /* File to be the magic between shared code and 41 41 * actual OS primitives
+1 -1
drivers/net/ethernet/intel/i40evf/i40e_osdep.h
··· 34 34 #include <linux/pci.h> 35 35 36 36 /* get readq/writeq support for 32 bit kernels, use the low-first version */ 37 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 37 + #include <linux/io-64-nonatomic-lo-hi.h> 38 38 39 39 /* File to be the magic between shared code and 40 40 * actual OS primitives
+1 -1
drivers/net/ethernet/mellanox/mlx5/core/cmd.c
··· 30 30 * SOFTWARE. 31 31 */ 32 32 33 - #include <asm-generic/kmap_types.h> 33 + #include <linux/highmem.h> 34 34 #include <linux/module.h> 35 35 #include <linux/errno.h> 36 36 #include <linux/pci.h>
+1 -1
drivers/net/ethernet/mellanox/mlx5/core/main.c
··· 30 30 * SOFTWARE. 31 31 */ 32 32 33 - #include <asm-generic/kmap_types.h> 33 + #include <linux/highmem.h> 34 34 #include <linux/module.h> 35 35 #include <linux/init.h> 36 36 #include <linux/errno.h>
+1 -1
drivers/net/ethernet/mellanox/mlx5/core/pagealloc.c
··· 30 30 * SOFTWARE. 31 31 */ 32 32 33 - #include <asm-generic/kmap_types.h> 33 + #include <linux/highmem.h> 34 34 #include <linux/kernel.h> 35 35 #include <linux/module.h> 36 36 #include <linux/mlx5/driver.h>
+1 -1
drivers/net/ethernet/rocker/rocker.c
··· 36 36 #include <net/ip_fib.h> 37 37 #include <net/netevent.h> 38 38 #include <net/arp.h> 39 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 39 + #include <linux/io-64-nonatomic-lo-hi.h> 40 40 #include <generated/utsrelease.h> 41 41 42 42 #include "rocker.h"
+1 -1
drivers/nvme/host/pci.c
··· 41 41 #include <linux/types.h> 42 42 #include <linux/pr.h> 43 43 #include <scsi/sg.h> 44 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 44 + #include <linux/io-64-nonatomic-lo-hi.h> 45 45 #include <asm/unaligned.h> 46 46 47 47 #include <uapi/linux/nvme_ioctl.h>
+1 -1
drivers/platform/x86/ibm_rtl.c
··· 33 33 #include <linux/mutex.h> 34 34 #include <asm/bios_ebda.h> 35 35 36 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 36 + #include <linux/io-64-nonatomic-lo-hi.h> 37 37 38 38 static bool force; 39 39 module_param(force, bool, 0);
+1 -1
drivers/platform/x86/intel_ips.c
··· 78 78 #include <asm/processor.h> 79 79 #include "intel_ips.h" 80 80 81 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 81 + #include <linux/io-64-nonatomic-lo-hi.h> 82 82 83 83 #define PCI_DEVICE_ID_INTEL_THERMAL_SENSOR 0x3b32 84 84
+1 -1
drivers/scsi/qla4xxx/ql4_nx.c
··· 12 12 #include "ql4_glbl.h" 13 13 #include "ql4_inline.h" 14 14 15 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 15 + #include <linux/io-64-nonatomic-lo-hi.h> 16 16 17 17 #define TIMEOUT_100_MS 100 18 18 #define MASK(n) DMA_BIT_MASK(n)
+1 -1
drivers/tty/n_tracerouter.c
··· 34 34 #include <linux/string.h> 35 35 #include <linux/mutex.h> 36 36 #include <linux/slab.h> 37 - #include <asm-generic/bug.h> 37 + #include <linux/bug.h> 38 38 #include "n_tracesink.h" 39 39 40 40 /*
+1 -1
drivers/tty/n_tracesink.c
··· 34 34 #include <linux/tty_ldisc.h> 35 35 #include <linux/errno.h> 36 36 #include <linux/string.h> 37 - #include <asm-generic/bug.h> 37 + #include <linux/bug.h> 38 38 #include "n_tracesink.h" 39 39 40 40 /*
+1 -2
drivers/usb/host/xhci.h
··· 28 28 #include <linux/timer.h> 29 29 #include <linux/kernel.h> 30 30 #include <linux/usb/hcd.h> 31 - 32 - #include <asm-generic/io-64-nonatomic-lo-hi.h> 31 + #include <linux/io-64-nonatomic-lo-hi.h> 33 32 34 33 /* Code sharing between pci-quirks and xhci hcd */ 35 34 #include "xhci-ext-caps.h"
+3 -3
include/asm-generic/bitops/count_zeros.h include/linux/count_zeros.h
··· 9 9 * 2 of the Licence, or (at your option) any later version. 10 10 */ 11 11 12 - #ifndef _ASM_GENERIC_BITOPS_COUNT_ZEROS_H_ 13 - #define _ASM_GENERIC_BITOPS_COUNT_ZEROS_H_ 12 + #ifndef _LINUX_BITOPS_COUNT_ZEROS_H_ 13 + #define _LINUX_BITOPS_COUNT_ZEROS_H_ 14 14 15 15 #include <asm/bitops.h> 16 16 ··· 54 54 return (x != 0) ? __ffs(x) : COUNT_TRAILING_ZEROS_0; 55 55 } 56 56 57 - #endif /* _ASM_GENERIC_BITOPS_COUNT_ZEROS_H_ */ 57 + #endif /* _LINUX_BITOPS_COUNT_ZEROS_H_ */
+7 -4
include/asm-generic/cmpxchg.h
··· 79 79 } 80 80 } 81 81 82 - #define xchg(ptr, x) \ 83 - ((__typeof__(*(ptr))) __xchg((unsigned long)(x), (ptr), sizeof(*(ptr)))) 82 + #define xchg(ptr, x) ({ \ 83 + ((__typeof__(*(ptr))) \ 84 + __xchg((unsigned long)(x), (ptr), sizeof(*(ptr)))); \ 85 + }) 84 86 85 87 #endif /* xchg */ 86 88 ··· 92 90 #include <asm-generic/cmpxchg-local.h> 93 91 94 92 #ifndef cmpxchg_local 95 - #define cmpxchg_local(ptr, o, n) \ 93 + #define cmpxchg_local(ptr, o, n) ({ \ 96 94 ((__typeof__(*(ptr)))__cmpxchg_local_generic((ptr), (unsigned long)(o),\ 97 - (unsigned long)(n), sizeof(*(ptr)))) 95 + (unsigned long)(n), sizeof(*(ptr)))); \ 96 + }) 98 97 #endif 99 98 100 99 #ifndef cmpxchg64_local
+2 -32
include/asm-generic/io-64-nonatomic-hi-lo.h
··· 1 - #ifndef _ASM_IO_64_NONATOMIC_HI_LO_H_ 2 - #define _ASM_IO_64_NONATOMIC_HI_LO_H_ 3 - 4 - #include <linux/io.h> 5 - #include <asm-generic/int-ll64.h> 6 - 7 - static inline __u64 hi_lo_readq(const volatile void __iomem *addr) 8 - { 9 - const volatile u32 __iomem *p = addr; 10 - u32 low, high; 11 - 12 - high = readl(p + 1); 13 - low = readl(p); 14 - 15 - return low + ((u64)high << 32); 16 - } 17 - 18 - static inline void hi_lo_writeq(__u64 val, volatile void __iomem *addr) 19 - { 20 - writel(val >> 32, addr + 4); 21 - writel(val, addr); 22 - } 23 - 24 - #ifndef readq 25 - #define readq hi_lo_readq 26 - #endif 27 - 28 - #ifndef writeq 29 - #define writeq hi_lo_writeq 30 - #endif 31 - 32 - #endif /* _ASM_IO_64_NONATOMIC_HI_LO_H_ */ 1 + /* XXX: delete asm-generic/io-64-nonatomic-hi-lo.h after converting new users */ 2 + #include <linux/io-64-nonatomic-hi-lo.h>
+2 -32
include/asm-generic/io-64-nonatomic-lo-hi.h
··· 1 - #ifndef _ASM_IO_64_NONATOMIC_LO_HI_H_ 2 - #define _ASM_IO_64_NONATOMIC_LO_HI_H_ 3 - 4 - #include <linux/io.h> 5 - #include <asm-generic/int-ll64.h> 6 - 7 - static inline __u64 lo_hi_readq(const volatile void __iomem *addr) 8 - { 9 - const volatile u32 __iomem *p = addr; 10 - u32 low, high; 11 - 12 - low = readl(p); 13 - high = readl(p + 1); 14 - 15 - return low + ((u64)high << 32); 16 - } 17 - 18 - static inline void lo_hi_writeq(__u64 val, volatile void __iomem *addr) 19 - { 20 - writel(val, addr); 21 - writel(val >> 32, addr + 4); 22 - } 23 - 24 - #ifndef readq 25 - #define readq lo_hi_readq 26 - #endif 27 - 28 - #ifndef writeq 29 - #define writeq lo_hi_writeq 30 - #endif 31 - 32 - #endif /* _ASM_IO_64_NONATOMIC_LO_HI_H_ */ 1 + /* XXX: delete asm-generic/io-64-nonatomic-lo-hi.h after converting new users */ 2 + #include <linux/io-64-nonatomic-lo-hi.h>
+32
include/linux/io-64-nonatomic-hi-lo.h
··· 1 + #ifndef _LINUX_IO_64_NONATOMIC_HI_LO_H_ 2 + #define _LINUX_IO_64_NONATOMIC_HI_LO_H_ 3 + 4 + #include <linux/io.h> 5 + #include <asm-generic/int-ll64.h> 6 + 7 + static inline __u64 hi_lo_readq(const volatile void __iomem *addr) 8 + { 9 + const volatile u32 __iomem *p = addr; 10 + u32 low, high; 11 + 12 + high = readl(p + 1); 13 + low = readl(p); 14 + 15 + return low + ((u64)high << 32); 16 + } 17 + 18 + static inline void hi_lo_writeq(__u64 val, volatile void __iomem *addr) 19 + { 20 + writel(val >> 32, addr + 4); 21 + writel(val, addr); 22 + } 23 + 24 + #ifndef readq 25 + #define readq hi_lo_readq 26 + #endif 27 + 28 + #ifndef writeq 29 + #define writeq hi_lo_writeq 30 + #endif 31 + 32 + #endif /* _LINUX_IO_64_NONATOMIC_HI_LO_H_ */
+32
include/linux/io-64-nonatomic-lo-hi.h
··· 1 + #ifndef _LINUX_IO_64_NONATOMIC_LO_HI_H_ 2 + #define _LINUX_IO_64_NONATOMIC_LO_HI_H_ 3 + 4 + #include <linux/io.h> 5 + #include <asm-generic/int-ll64.h> 6 + 7 + static inline __u64 lo_hi_readq(const volatile void __iomem *addr) 8 + { 9 + const volatile u32 __iomem *p = addr; 10 + u32 low, high; 11 + 12 + low = readl(p); 13 + high = readl(p + 1); 14 + 15 + return low + ((u64)high << 32); 16 + } 17 + 18 + static inline void lo_hi_writeq(__u64 val, volatile void __iomem *addr) 19 + { 20 + writel(val, addr); 21 + writel(val >> 32, addr + 4); 22 + } 23 + 24 + #ifndef readq 25 + #define readq lo_hi_readq 26 + #endif 27 + 28 + #ifndef writeq 29 + #define writeq lo_hi_writeq 30 + #endif 31 + 32 + #endif /* _LINUX_IO_64_NONATOMIC_LO_HI_H_ */
+1 -1
lib/mpi/longlong.h
··· 19 19 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, 20 20 * MA 02111-1307, USA. */ 21 21 22 - #include <asm-generic/bitops/count_zeros.h> 22 + #include <linux/count_zeros.h> 23 23 24 24 /* You have to define the following before including this file: 25 25 *
+1 -1
lib/mpi/mpicoder.c
··· 19 19 */ 20 20 21 21 #include <linux/bitops.h> 22 - #include <asm-generic/bitops/count_zeros.h> 22 + #include <linux/count_zeros.h> 23 23 #include "mpi-internal.h" 24 24 25 25 #define MAX_EXTERN_MPI_BITS 16384