openwrtv3/target/linux/ar71xx
Gabor Juhos 4045f15a21 ar71xx: fix compiler warnings in mdio-bitbang.c for 4.4
Building Linux 4.4 for ar71xx throws the following warnings in
drivers/net/phy/mdio-bitbang.c:

    CC      drivers/net/phy/mdio-bitbang.o
  In file included from include/linux/irqflags.h:14:0,
                   from drivers/net/phy/mdio-bitbang.c:20:
  drivers/net/phy/mdio-bitbang.c: In function 'mdiobb_read':
  include/linux/typecheck.h:11:18: warning: comparison of distinct pointer types lacks a cast
    (void)(&__dummy == &__dummy2); \
                    ^
  include/linux/irqflags.h:63:3: note: in expansion of macro 'typecheck'
     typecheck(unsigned long, flags); \
     ^
  include/linux/irqflags.h:124:3: note: in expansion of macro 'raw_local_irq_save'
     raw_local_irq_save(flags);   \
     ^
  drivers/net/phy/mdio-bitbang.c:162:2: note: in expansion of macro 'local_irq_save'
    local_irq_save(flags);
    ^
  include/linux/typecheck.h:11:18: warning: comparison of distinct pointer types lacks a cast
    (void)(&__dummy == &__dummy2); \
                    ^
  include/linux/irqflags.h:68:3: note: in expansion of macro 'typecheck'
     typecheck(unsigned long, flags); \
     ^
  include/linux/irqflags.h:126:39: note: in expansion of macro 'raw_local_irq_restore'
   #define local_irq_restore(flags) do { raw_local_irq_restore(flags); } while (0)
                                         ^
  drivers/net/phy/mdio-bitbang.c:175:2: note: in expansion of macro 'local_irq_restore'
    local_irq_restore(flags);
    ^
  drivers/net/phy/mdio-bitbang.c:159:11: warning: unused variable 'i' [-Wunused-variable]
    int ret, i;
             ^
  In file included from include/linux/irqflags.h:14:0,
                   from drivers/net/phy/mdio-bitbang.c:20:
  drivers/net/phy/mdio-bitbang.c: In function 'mdiobb_write':
  include/linux/typecheck.h:11:18: warning: comparison of distinct pointer types lacks a cast
    (void)(&__dummy == &__dummy2); \
                    ^
  include/linux/irqflags.h:63:3: note: in expansion of macro 'typecheck'
     typecheck(unsigned long, flags); \
     ^
  include/linux/irqflags.h:124:3: note: in expansion of macro 'raw_local_irq_save'
     raw_local_irq_save(flags);   \
     ^
  drivers/net/phy/mdio-bitbang.c:185:2: note: in expansion of macro 'local_irq_save'
    local_irq_save(flags);
    ^
  include/linux/typecheck.h:11:18: warning: comparison of distinct pointer types lacks a cast
    (void)(&__dummy == &__dummy2); \
                    ^
  include/linux/irqflags.h:68:3: note: in expansion of macro 'typecheck'
     typecheck(unsigned long, flags); \
     ^
  include/linux/irqflags.h:126:39: note: in expansion of macro 'raw_local_irq_restore'
   #define local_irq_restore(flags) do { raw_local_irq_restore(flags); } while (0)
                                         ^
  drivers/net/phy/mdio-bitbang.c:200:2: note: in expansion of macro 'local_irq_restore'
    local_irq_restore(flags);
    ^

These are caused by the 900-mdio_bitbang_ignore_ta_value and
901-phy-mdio-bitbang-prevent-rescheduling-during-command patches.

The first patch removes some code but it does not remove the variable
which is used by the removed code only.

The second patch adds local_irq_{save,restore} calls. The type of the
argument of these calls must be 'unsigned long', but the patch defines
the variable as 'long'.

Fix both patches to silence the warnings.

Signed-off-by: Gabor Juhos <juhosg@freemail.hu>
2018-01-07 13:05:40 +01:00
..
base-files ar71xx: add support for MikroTik RouterBOARD 921GS-5HPacD r2 (mANTBox 15s) 2017-12-21 17:06:54 +01:00
files ag71xx: Fix rx ring buffer stall on small packets flood on qca956x and qca953x. 2017-12-29 15:17:07 +01:00
generic ar71xx: unify CONFIG_CMDLINE 2017-09-28 22:45:39 +02:00
image ar71xx: add support for MikroTik RouterBOARD 921GS-5HPacD r2 (mANTBox 15s) 2017-12-21 17:06:54 +01:00
mikrotik ar71xx: add support for TP-Link TL-WR1043N v5 2017-11-14 22:36:46 +01:00
nand ar71xx: add support for TP-Link TL-WR1043N v5 2017-11-14 22:36:46 +01:00
patches-4.4 ar71xx: fix compiler warnings in mdio-bitbang.c for 4.4 2018-01-07 13:05:40 +01:00
patches-4.9 kernel: Update kernel 4.9 to 4.9.70 2017-12-19 22:45:27 +01:00
config-4.4 ar71xx: add support for TP-Link TL-WR1043N v5 2017-11-14 22:36:46 +01:00
config-4.9 ar71xx: add support for TP-Link TL-WR1043N v5 2017-11-14 22:36:46 +01:00
Makefile ar71xx: use kernel 4.9 by default 2017-10-22 15:22:51 +02:00
modules.mk ar71xx: add LED driver NU801 2015-12-11 15:04:57 +00:00