drivers/base//regmap/regmap-mmio.c:283:2: error: duplicate case value

From: kbuild test robot
Date: Fri Feb 23 2018 - 20:59:32 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 9cb9c07d6b0c5fd97d83b8ab14d7e308ba4b612f
commit: 101110f6271ce956a049250c907bc960030577f8 Kbuild: always define endianess in kconfig.h
date: 2 days ago
config: m32r-allyesconfig (attached as .config)
compiler: m32r-linux-gcc (GCC) 7.2.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 101110f6271ce956a049250c907bc960030577f8
# save the attached .config to linux build tree
make.cross ARCH=m32r

All errors (new ones prefixed by >>):

In file included from arch/m32r/include/uapi/asm/byteorder.h:8:0,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/clk.h:16,
from drivers/base//regmap/regmap-mmio.c:19:
include/linux/byteorder/big_endian.h:8:2: warning: #warning inconsistent configuration, needs CONFIG_CPU_BIG_ENDIAN [-Wcpp]
#warning inconsistent configuration, needs CONFIG_CPU_BIG_ENDIAN
^~~~~~~
drivers/base//regmap/regmap-mmio.c: In function 'regmap_mmio_gen_context':
>> drivers/base//regmap/regmap-mmio.c:283:2: error: duplicate case value
case REGMAP_ENDIAN_NATIVE:
^~~~
drivers/base//regmap/regmap-mmio.c:255:2: note: previously used here
case REGMAP_ENDIAN_NATIVE:
^~~~
--
include/uapi/linux/byteorder/little_endian.h:38:0: warning: "__be64_to_cpu" redefined
#define __be64_to_cpu(x) __swab64((__force __u64)(__be64)(x))

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:38:0: note: this is the location of the previous definition
#define __be64_to_cpu(x) ((__force __u64)(__be64)(x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:39:0: warning: "__cpu_to_be32" redefined
#define __cpu_to_be32(x) ((__force __be32)__swab32((x)))

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:39:0: note: this is the location of the previous definition
#define __cpu_to_be32(x) ((__force __be32)(__u32)(x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:40:0: warning: "__be32_to_cpu" redefined
#define __be32_to_cpu(x) __swab32((__force __u32)(__be32)(x))

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:40:0: note: this is the location of the previous definition
#define __be32_to_cpu(x) ((__force __u32)(__be32)(x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:41:0: warning: "__cpu_to_be16" redefined
#define __cpu_to_be16(x) ((__force __be16)__swab16((x)))

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:41:0: note: this is the location of the previous definition
#define __cpu_to_be16(x) ((__force __be16)(__u16)(x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:42:0: warning: "__be16_to_cpu" redefined
#define __be16_to_cpu(x) __swab16((__force __u16)(__be16)(x))

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:42:0: note: this is the location of the previous definition
#define __be16_to_cpu(x) ((__force __u16)(__be16)(x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:44:31: error: redefinition of '__cpu_to_le64p'
static __always_inline __le64 __cpu_to_le64p(const __u64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:44:31: note: previous definition of '__cpu_to_le64p' was here
static __always_inline __le64 __cpu_to_le64p(const __u64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:48:30: error: redefinition of '__le64_to_cpup'
static __always_inline __u64 __le64_to_cpup(const __le64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:48:30: note: previous definition of '__le64_to_cpup' was here
static __always_inline __u64 __le64_to_cpup(const __le64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:52:31: error: redefinition of '__cpu_to_le32p'
static __always_inline __le32 __cpu_to_le32p(const __u32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:52:31: note: previous definition of '__cpu_to_le32p' was here
static __always_inline __le32 __cpu_to_le32p(const __u32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:56:30: error: redefinition of '__le32_to_cpup'
static __always_inline __u32 __le32_to_cpup(const __le32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:56:30: note: previous definition of '__le32_to_cpup' was here
static __always_inline __u32 __le32_to_cpup(const __le32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:60:31: error: redefinition of '__cpu_to_le16p'
static __always_inline __le16 __cpu_to_le16p(const __u16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:60:31: note: previous definition of '__cpu_to_le16p' was here
static __always_inline __le16 __cpu_to_le16p(const __u16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:64:30: error: redefinition of '__le16_to_cpup'
static __always_inline __u16 __le16_to_cpup(const __le16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:64:30: note: previous definition of '__le16_to_cpup' was here
static __always_inline __u16 __le16_to_cpup(const __le16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:68:31: error: redefinition of '__cpu_to_be64p'
static __always_inline __be64 __cpu_to_be64p(const __u64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:68:31: note: previous definition of '__cpu_to_be64p' was here
static __always_inline __be64 __cpu_to_be64p(const __u64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:72:30: error: redefinition of '__be64_to_cpup'
static __always_inline __u64 __be64_to_cpup(const __be64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:72:30: note: previous definition of '__be64_to_cpup' was here
static __always_inline __u64 __be64_to_cpup(const __be64 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:76:31: error: redefinition of '__cpu_to_be32p'
static __always_inline __be32 __cpu_to_be32p(const __u32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:76:31: note: previous definition of '__cpu_to_be32p' was here
static __always_inline __be32 __cpu_to_be32p(const __u32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:80:30: error: redefinition of '__be32_to_cpup'
static __always_inline __u32 __be32_to_cpup(const __be32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:80:30: note: previous definition of '__be32_to_cpup' was here
static __always_inline __u32 __be32_to_cpup(const __be32 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:84:31: error: redefinition of '__cpu_to_be16p'
static __always_inline __be16 __cpu_to_be16p(const __u16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:84:31: note: previous definition of '__cpu_to_be16p' was here
static __always_inline __be16 __cpu_to_be16p(const __u16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
>> include/uapi/linux/byteorder/little_endian.h:88:30: error: redefinition of '__be16_to_cpup'
static __always_inline __u16 __be16_to_cpup(const __be16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:88:30: note: previous definition of '__be16_to_cpup' was here
static __always_inline __u16 __be16_to_cpup(const __be16 *p)
^~~~~~~~~~~~~~
In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:92:0: warning: "__cpu_to_le64s" redefined
#define __cpu_to_le64s(x) do { (void)(x); } while (0)

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:92:0: note: this is the location of the previous definition
#define __cpu_to_le64s(x) __swab64s((x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:93:0: warning: "__le64_to_cpus" redefined
#define __le64_to_cpus(x) do { (void)(x); } while (0)

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:93:0: note: this is the location of the previous definition
#define __le64_to_cpus(x) __swab64s((x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:94:0: warning: "__cpu_to_le32s" redefined
#define __cpu_to_le32s(x) do { (void)(x); } while (0)

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:94:0: note: this is the location of the previous definition
#define __cpu_to_le32s(x) __swab32s((x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:95:0: warning: "__le32_to_cpus" redefined
#define __le32_to_cpus(x) do { (void)(x); } while (0)

In file included from include/linux/byteorder/big_endian.h:5:0,
from arch/m32r/include/uapi/asm/byteorder.h:8,
from arch/m32r/include/asm/bitops.h:22,
from include/linux/bitops.h:38,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/rculist.h:10,
from include/linux/sched/signal.h:5,
from drivers/staging//rtl8723bs/include/drv_types.h:26,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/big_endian.h:95:0: note: this is the location of the previous definition
#define __le32_to_cpus(x) __swab32s((x))

In file included from include/linux/byteorder/little_endian.h:5:0,
from drivers/staging//rtl8723bs/include/rtw_byteorder.h:19,
from drivers/staging//rtl8723bs/include/drv_types.h:30,
from drivers/staging//rtl8723bs/core/rtw_ap.c:17:
include/uapi/linux/byteorder/little_endian.h:96:0: warning: "__cpu_to_le16s" redefined
..

vim +283 drivers/base//regmap/regmap-mmio.c

45f5ff810 Stephen Warren 2012-04-04 219
878ec67b3 Philipp Zabel 2013-02-14 220 static struct regmap_mmio_context *regmap_mmio_gen_context(struct device *dev,
878ec67b3 Philipp Zabel 2013-02-14 221 const char *clk_id,
878ec67b3 Philipp Zabel 2013-02-14 222 void __iomem *regs,
45f5ff810 Stephen Warren 2012-04-04 223 const struct regmap_config *config)
45f5ff810 Stephen Warren 2012-04-04 224 {
45f5ff810 Stephen Warren 2012-04-04 225 struct regmap_mmio_context *ctx;
f01ee60ff Stephen Warren 2012-04-09 226 int min_stride;
878ec67b3 Philipp Zabel 2013-02-14 227 int ret;
45f5ff810 Stephen Warren 2012-04-04 228
451485ba6 Xiubo Li 2014-03-28 229 ret = regmap_mmio_regbits_check(config->reg_bits);
451485ba6 Xiubo Li 2014-03-28 230 if (ret)
451485ba6 Xiubo Li 2014-03-28 231 return ERR_PTR(ret);
45f5ff810 Stephen Warren 2012-04-04 232
45f5ff810 Stephen Warren 2012-04-04 233 if (config->pad_bits)
45f5ff810 Stephen Warren 2012-04-04 234 return ERR_PTR(-EINVAL);
45f5ff810 Stephen Warren 2012-04-04 235
75fb0aaea Xiubo Li 2015-12-03 236 min_stride = regmap_mmio_get_min_stride(config->val_bits);
75fb0aaea Xiubo Li 2015-12-03 237 if (min_stride < 0)
75fb0aaea Xiubo Li 2015-12-03 238 return ERR_PTR(min_stride);
45f5ff810 Stephen Warren 2012-04-04 239
f01ee60ff Stephen Warren 2012-04-09 240 if (config->reg_stride < min_stride)
f01ee60ff Stephen Warren 2012-04-09 241 return ERR_PTR(-EINVAL);
f01ee60ff Stephen Warren 2012-04-09 242
463351194 Dimitris Papastamos 2012-07-18 243 ctx = kzalloc(sizeof(*ctx), GFP_KERNEL);
45f5ff810 Stephen Warren 2012-04-04 244 if (!ctx)
45f5ff810 Stephen Warren 2012-04-04 245 return ERR_PTR(-ENOMEM);
45f5ff810 Stephen Warren 2012-04-04 246
45f5ff810 Stephen Warren 2012-04-04 247 ctx->regs = regs;
45f5ff810 Stephen Warren 2012-04-04 248 ctx->val_bytes = config->val_bits / 8;
6b8e090ec Stephen Warren 2013-11-25 249 ctx->clk = ERR_PTR(-ENODEV);
45f5ff810 Stephen Warren 2012-04-04 250
0dbdb76c0 Mark Brown 2016-03-29 251 switch (regmap_get_val_endian(dev, &regmap_mmio, config)) {
922a9f936 Mark Brown 2016-01-27 252 case REGMAP_ENDIAN_DEFAULT:
922a9f936 Mark Brown 2016-01-27 253 case REGMAP_ENDIAN_LITTLE:
922a9f936 Mark Brown 2016-01-27 254 #ifdef __LITTLE_ENDIAN
922a9f936 Mark Brown 2016-01-27 255 case REGMAP_ENDIAN_NATIVE:
922a9f936 Mark Brown 2016-01-27 256 #endif
922a9f936 Mark Brown 2016-01-27 257 switch (config->val_bits) {
922a9f936 Mark Brown 2016-01-27 258 case 8:
922a9f936 Mark Brown 2016-01-27 259 ctx->reg_read = regmap_mmio_read8;
922a9f936 Mark Brown 2016-01-27 260 ctx->reg_write = regmap_mmio_write8;
922a9f936 Mark Brown 2016-01-27 261 break;
922a9f936 Mark Brown 2016-01-27 262 case 16:
922a9f936 Mark Brown 2016-01-27 263 ctx->reg_read = regmap_mmio_read16le;
922a9f936 Mark Brown 2016-01-27 264 ctx->reg_write = regmap_mmio_write16le;
922a9f936 Mark Brown 2016-01-27 265 break;
922a9f936 Mark Brown 2016-01-27 266 case 32:
922a9f936 Mark Brown 2016-01-27 267 ctx->reg_read = regmap_mmio_read32le;
922a9f936 Mark Brown 2016-01-27 268 ctx->reg_write = regmap_mmio_write32le;
922a9f936 Mark Brown 2016-01-27 269 break;
922a9f936 Mark Brown 2016-01-27 270 #ifdef CONFIG_64BIT
922a9f936 Mark Brown 2016-01-27 271 case 64:
922a9f936 Mark Brown 2016-01-27 272 ctx->reg_read = regmap_mmio_read64le;
922a9f936 Mark Brown 2016-01-27 273 ctx->reg_write = regmap_mmio_write64le;
922a9f936 Mark Brown 2016-01-27 274 break;
922a9f936 Mark Brown 2016-01-27 275 #endif
922a9f936 Mark Brown 2016-01-27 276 default:
922a9f936 Mark Brown 2016-01-27 277 ret = -EINVAL;
922a9f936 Mark Brown 2016-01-27 278 goto err_free;
922a9f936 Mark Brown 2016-01-27 279 }
922a9f936 Mark Brown 2016-01-27 280 break;
922a9f936 Mark Brown 2016-01-27 281 case REGMAP_ENDIAN_BIG:
922a9f936 Mark Brown 2016-01-27 282 #ifdef __BIG_ENDIAN
922a9f936 Mark Brown 2016-01-27 @283 case REGMAP_ENDIAN_NATIVE:
922a9f936 Mark Brown 2016-01-27 284 #endif
922a9f936 Mark Brown 2016-01-27 285 switch (config->val_bits) {
922a9f936 Mark Brown 2016-01-27 286 case 8:
922a9f936 Mark Brown 2016-01-27 287 ctx->reg_read = regmap_mmio_read8;
922a9f936 Mark Brown 2016-01-27 288 ctx->reg_write = regmap_mmio_write8;
922a9f936 Mark Brown 2016-01-27 289 break;
922a9f936 Mark Brown 2016-01-27 290 case 16:
922a9f936 Mark Brown 2016-01-27 291 ctx->reg_read = regmap_mmio_read16be;
922a9f936 Mark Brown 2016-01-27 292 ctx->reg_write = regmap_mmio_write16be;
922a9f936 Mark Brown 2016-01-27 293 break;
922a9f936 Mark Brown 2016-01-27 294 case 32:
922a9f936 Mark Brown 2016-01-27 295 ctx->reg_read = regmap_mmio_read32be;
922a9f936 Mark Brown 2016-01-27 296 ctx->reg_write = regmap_mmio_write32be;
922a9f936 Mark Brown 2016-01-27 297 break;
922a9f936 Mark Brown 2016-01-27 298 default:
922a9f936 Mark Brown 2016-01-27 299 ret = -EINVAL;
922a9f936 Mark Brown 2016-01-27 300 goto err_free;
922a9f936 Mark Brown 2016-01-27 301 }
922a9f936 Mark Brown 2016-01-27 302 break;
922a9f936 Mark Brown 2016-01-27 303 default:
922a9f936 Mark Brown 2016-01-27 304 ret = -EINVAL;
922a9f936 Mark Brown 2016-01-27 305 goto err_free;
922a9f936 Mark Brown 2016-01-27 306 }
922a9f936 Mark Brown 2016-01-27 307
878ec67b3 Philipp Zabel 2013-02-14 308 if (clk_id == NULL)
45f5ff810 Stephen Warren 2012-04-04 309 return ctx;
878ec67b3 Philipp Zabel 2013-02-14 310
878ec67b3 Philipp Zabel 2013-02-14 311 ctx->clk = clk_get(dev, clk_id);
878ec67b3 Philipp Zabel 2013-02-14 312 if (IS_ERR(ctx->clk)) {
878ec67b3 Philipp Zabel 2013-02-14 313 ret = PTR_ERR(ctx->clk);
878ec67b3 Philipp Zabel 2013-02-14 314 goto err_free;
878ec67b3 Philipp Zabel 2013-02-14 315 }
878ec67b3 Philipp Zabel 2013-02-14 316
878ec67b3 Philipp Zabel 2013-02-14 317 ret = clk_prepare(ctx->clk);
878ec67b3 Philipp Zabel 2013-02-14 318 if (ret < 0) {
878ec67b3 Philipp Zabel 2013-02-14 319 clk_put(ctx->clk);
878ec67b3 Philipp Zabel 2013-02-14 320 goto err_free;
878ec67b3 Philipp Zabel 2013-02-14 321 }
878ec67b3 Philipp Zabel 2013-02-14 322
878ec67b3 Philipp Zabel 2013-02-14 323 return ctx;
878ec67b3 Philipp Zabel 2013-02-14 324
878ec67b3 Philipp Zabel 2013-02-14 325 err_free:
878ec67b3 Philipp Zabel 2013-02-14 326 kfree(ctx);
878ec67b3 Philipp Zabel 2013-02-14 327
878ec67b3 Philipp Zabel 2013-02-14 328 return ERR_PTR(ret);
45f5ff810 Stephen Warren 2012-04-04 329 }
45f5ff810 Stephen Warren 2012-04-04 330

:::::: The code at line 283 was first introduced by commit
:::::: 922a9f936e40001f9b921379aab90047d5990923 regmap: mmio: Convert to regmap_bus and fix accessor usage

:::::: TO: Mark Brown <broonie@xxxxxxxxxx>
:::::: CC: Mark Brown <broonie@xxxxxxxxxx>

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation

Attachment: .config.gz
Description: application/gzip