linux/drivers/infiniband/sw/siw
Jason Gunthorpe 4c7d6dcd36 RDMA/siw: Fix DEFINE_PER_CPU compilation when ARCH_NEEDS_WEAK_PER_CPU
The initializer for the variable cannot be inside the macro (and zero
initialization isn't needed anyhow).

include/linux/percpu-defs.h:92:33: warning: '__pcpu_unique_use_cnt' initialized and declared 'extern'
  extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;  \
                                 ^~~~~~~~~~~~~~
include/linux/percpu-defs.h:115:2: note: in expansion of macro 'DEFINE_PER_CPU_SECTION'
  DEFINE_PER_CPU_SECTION(type, name, "")
  ^~~~~~~~~~~~~~~~~~~~~~
drivers/infiniband/sw/siw/siw_main.c:129:8: note: in expansion of macro 'DEFINE_PER_CPU'
 static DEFINE_PER_CPU(atomic_t, use_cnt = ATOMIC_INIT(0));
        ^~~~~~~~~~~~~~

Also the rules for PER_CPU require the variable names to be globally
unique, so prefix them with siw_

Fixes: b9be6f18cf ("rdma/siw: transmit path")
Fixes: bdcf26bf9b ("rdma/siw: network and RDMA core interface")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
2019-07-08 11:52:50 -03:00
..
Kconfig rdma/siw: addition to kernel build environment 2019-07-02 17:03:41 -03:00
Makefile rdma/siw: addition to kernel build environment 2019-07-02 17:03:41 -03:00
iwarp.h
siw.h
siw_cm.c rdma/siw: connection management 2019-07-02 17:03:40 -03:00
siw_cm.h rdma/siw: connection management 2019-07-02 17:03:40 -03:00
siw_cq.c rdma/siw: completion queue methods 2019-07-02 17:03:41 -03:00
siw_main.c RDMA/siw: Fix DEFINE_PER_CPU compilation when ARCH_NEEDS_WEAK_PER_CPU 2019-07-08 11:52:50 -03:00
siw_mem.c rdma/siw: application buffer management 2019-07-02 17:03:40 -03:00
siw_mem.h rdma/siw: application buffer management 2019-07-02 17:03:40 -03:00
siw_qp.c rdma/siw: queue pair methods 2019-07-02 17:03:41 -03:00
siw_qp_rx.c rdma/siw: receive path 2019-07-02 17:03:41 -03:00
siw_qp_tx.c RDMA/siw: Fix DEFINE_PER_CPU compilation when ARCH_NEEDS_WEAK_PER_CPU 2019-07-08 11:52:50 -03:00
siw_verbs.c rdma/siw: application interface 2019-07-02 17:03:40 -03:00
siw_verbs.h rdma/siw: application interface 2019-07-02 17:03:40 -03:00