diff options
author | Jiri Pirko <jiri@mellanox.com> | 2016-02-16 15:14:41 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-02-17 23:08:34 -0500 |
commit | 11ce2ba3d05b3ac330022da1f83b589a4f78569c (patch) | |
tree | 347eede72084986dda8564fa9acecea41efb820c /drivers/net/ethernet/rocker | |
parent | 0fe685f6a2831c8868e0a4389c76521d7fd42026 (diff) | |
download | talos-obmc-linux-11ce2ba3d05b3ac330022da1f83b589a4f78569c.tar.gz talos-obmc-linux-11ce2ba3d05b3ac330022da1f83b589a4f78569c.zip |
rocker: rename rocker.c to rocker_main.c
Since "rocker.c" is going to be split into multiple files, start with
renaming original "rocker.c" file to "rocker_main.c". Multiple code
parts are going to be cut from "rocker_main.c" later on.
Fix couple of checkpatch issues on the way.
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Acked-by: Scott Feldman <sfeldma@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/rocker')
-rw-r--r-- | drivers/net/ethernet/rocker/Makefile | 1 | ||||
-rw-r--r-- | drivers/net/ethernet/rocker/rocker_main.c (renamed from drivers/net/ethernet/rocker/rocker.c) | 15 |
2 files changed, 9 insertions, 7 deletions
diff --git a/drivers/net/ethernet/rocker/Makefile b/drivers/net/ethernet/rocker/Makefile index f85fb12f36f1..2bed42385076 100644 --- a/drivers/net/ethernet/rocker/Makefile +++ b/drivers/net/ethernet/rocker/Makefile @@ -3,3 +3,4 @@ # obj-$(CONFIG_ROCKER) += rocker.o +rocker-y := rocker_main.o diff --git a/drivers/net/ethernet/rocker/rocker.c b/drivers/net/ethernet/rocker/rocker_main.c index 3f1849877356..44fa9ac36d85 100644 --- a/drivers/net/ethernet/rocker/rocker.c +++ b/drivers/net/ethernet/rocker/rocker_main.c @@ -1,6 +1,6 @@ /* * drivers/net/ethernet/rocker/rocker.c - Rocker switch device driver - * Copyright (c) 2014 Jiri Pirko <jiri@resnulli.us> + * Copyright (c) 2014-2016 Jiri Pirko <jiri@mellanox.com> * Copyright (c) 2014 Scott Feldman <sfeldma@gmail.com> * * This program is free software; you can redistribute it and/or modify @@ -922,7 +922,8 @@ static bool rocker_desc_gen(const struct rocker_desc_info *desc_info) return comp_err & ROCKER_DMA_DESC_COMP_ERR_GEN ? true : false; } -static void *rocker_desc_cookie_ptr_get(const struct rocker_desc_info *desc_info) +static void * +rocker_desc_cookie_ptr_get(const struct rocker_desc_info *desc_info) { return (void *)(uintptr_t)desc_info->desc->cookie; } @@ -3435,10 +3436,10 @@ static int rocker_port_vlan(struct rocker_port *rocker_port, if (adding && test_bit(ntohs(internal_vlan_id), rocker_port->vlan_bitmap)) - return 0; /* already added */ + return 0; /* already added */ else if (!adding && !test_bit(ntohs(internal_vlan_id), rocker_port->vlan_bitmap)) - return 0; /* already removed */ + return 0; /* already removed */ change_bit(ntohs(internal_vlan_id), rocker_port->vlan_bitmap); @@ -4595,7 +4596,8 @@ static int rocker_port_vlan_dump(const struct rocker_port *rocker_port, vlan->flags = 0; if (rocker_vlan_id_is_internal(htons(vid))) vlan->flags |= BRIDGE_VLAN_INFO_PVID; - vlan->vid_begin = vlan->vid_end = vid; + vlan->vid_begin = vid; + vlan->vid_end = vid; err = cb(&vlan->obj); if (err) break; @@ -4998,7 +5000,7 @@ static int rocker_probe_port(struct rocker *rocker, unsigned int port_number) dev->ethtool_ops = &rocker_port_ethtool_ops; dev->switchdev_ops = &rocker_port_switchdev_ops; netif_tx_napi_add(dev, &rocker_port->napi_tx, rocker_port_poll_tx, - NAPI_POLL_WEIGHT); + NAPI_POLL_WEIGHT); netif_napi_add(dev, &rocker_port->napi_rx, rocker_port_poll_rx, NAPI_POLL_WEIGHT); rocker_carrier_init(rocker_port); @@ -5333,7 +5335,6 @@ static int rocker_port_bridge_leave(struct rocker_port *rocker_port) return err; } - static int rocker_port_ovs_changed(struct rocker_port *rocker_port, struct net_device *master) { |