linux/drivers/net/dsa/b53
Vivien Didelot 9d490b4ee4 net: dsa: rename switch operations structure
Now that the dsa_switch_driver structure contains only function pointers
as it is supposed to, rename it to the more appropriate dsa_switch_ops,
uniformly to any other operations structure in the kernel.

No functional changes here, basically just the result of something like:
s/dsa_switch_driver *drv/dsa_switch_ops *ops/g

However keep the {un,}register_switch_driver functions and their
dsa_switch_drivers list as is, since they represent the -- likely to be
deprecated soon -- legacy DSA registration framework.

In the meantime, also fix the following checks from checkpatch.pl to
make it happy with this patch:

    CHECK: Comparison to NULL could be written "!ops"
    #403: FILE: net/dsa/dsa.c:470:
    +	if (ops == NULL) {

    CHECK: Comparison to NULL could be written "ds->ops->get_strings"
    #773: FILE: net/dsa/slave.c:697:
    +		if (ds->ops->get_strings != NULL)

    CHECK: Comparison to NULL could be written "ds->ops->get_ethtool_stats"
    #824: FILE: net/dsa/slave.c:785:
    +	if (ds->ops->get_ethtool_stats != NULL)

    CHECK: Comparison to NULL could be written "ds->ops->get_sset_count"
    #835: FILE: net/dsa/slave.c:798:
    +		if (ds->ops->get_sset_count != NULL)

    total: 0 errors, 0 warnings, 4 checks, 784 lines checked

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2016-08-24 21:45:39 -07:00
..
b53_common.c net: dsa: rename switch operations structure 2016-08-24 21:45:39 -07:00
b53_mdio.c net: dsa: b53: constify b53_io_ops structures 2016-08-09 15:09:40 -07:00
b53_mmap.c net: dsa: b53: constify b53_io_ops structures 2016-08-09 15:09:40 -07:00
b53_priv.h net: dsa: b53: constify b53_io_ops structures 2016-08-09 15:09:40 -07:00
b53_regs.h net: dsa: b53: Add missing ULL suffix for 64-bit constant 2016-08-06 00:11:08 -04:00
b53_spi.c net: dsa: b53: remove .owner and .bus fields for driver 2016-08-14 21:24:25 -07:00
b53_srab.c net: dsa: b53: constify b53_io_ops structures 2016-08-09 15:09:40 -07:00
Kconfig
Makefile